Mono-D icon indicating copy to clipboard operation
Mono-D copied to clipboard

Dynamic Libraries on Platforms Other Than Windows: Very Broken

Open Orvid opened this issue 11 years ago • 0 comments

On OSX, when compiling a shared library, the following command is used:

/Applications/MyApps/dmd8/install/bin/dmd -debug -g "orvid/graphics/image.d" 
"/Applications/MyApps/dmd8/install/lib/libdruntime-osx64.a"
"/Applications/MyApps/dmd8/install/lib/libphobos2.a" 
"-I/Applications/MyApps/dmd8/install/import"
"-L/IMPLIB:/Applications/MyApps/Projects/Orvid.Graphics/Orvid.Graphics/bin/Debug/Orvid.a"
"-odobj/Debug" 
"-of/Applications/MyApps/Projects/Orvid.Graphics/Orvid.Graphics/bin/Debug/Orvid.so"

There are a couple of things wrong here:

  • /IMPLIB is a windows-specific flag
  • .so instead of .dynlib
  • Orvid as the output file name instead of the requested Orvid.Graphics

Orvid avatar Mar 04 '14 17:03 Orvid