You first need to edit the minimap mask which is under surfaces/ingame/minimapmask.png, after you get that into a square, you need to modify the minimap square frame (that's if you want a custom one), if you won't use a custom one but settle for the stock one, then just resize the square minimapmask to the exact dimensions of the square that fits inside the stock minimap frame, so it fits perfectly.
Lastly, you need to align everything by editing the map files inside the surfaces file with notepad/UI editor.