www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - Is it possible to build lib with LDC from Windows\Linux to MacOSX?

reply Suliman <evermind live.ru> writes:
I wrote lib in betterC mode, is it possible to compile it to 
MacOSX without MacOSX?
Jun 06
parent Adam D. Ruppe <destructionator gmail.com> writes:
On Saturday, 6 June 2026 at 15:19:28 UTC, Suliman wrote:
 I wrote lib in betterC mode, is it possible to compile it to 
 MacOSX without MacOSX?
OpenD supports library cross compile with `opend --target=mac -lib` (or `--target=mac-arm` for those) but important to note this generates a .a file. The application must still be linked on the Mac hardware; this is an Apple EULA requirement. With upstream ldc you can do something similar with `-mtriple=x86_64-apple-darwin` or aarch64 instead of x86
Jun 06