MacOS equivalent for Ubuntu Linker (ld) command?
Linker scripts can be used with the GNU version of ld to customise how you want your program to be linked. Essentially not all customizations can be made with command line arguments, and instead you specify them in a linker script.
The ld command on macOS on the other hand allows you to specify all the possible customizations through the command line arguments. Therefore linker scripts are not used and not supported.
If you really want to find an &quot;equivalent&quot; option to -T, it would be @. You can go ld @file [...] and the contents of the file named file will be added to the command line arguments. It does not give you further possibilities for customisation than those already available as command line arguments.
Note that linker scripts made for the GNU version of ld cannot be used with the standard macOS supplied version of ld.