Problem with compiling static libraries
Mike Parker
aldacron at gmail.com
Sun Jun 30 06:57:27 PDT 2013
I've finally been playing around with LDC on Windows and I love
it so far. But I've run into something rather frustrating and I
don't know if it's a bug or by design.
I'm using the MinGW backed version. The problem is that when I
compile a static library, LDC decides to automatically prepends
'lib' and appends '.lib' to the output. That was really
unexpected. It breaks the build script I have for Derelict, which
handles library name formatting based on platform and also drops
all the libraries into a lib directory. DMD and GDC do the right
thing, but given this command:
-ofC:\lib\libFoo.a
The compiler errors out because it's truing to find
libC:\lib\libFoo.a.lib.
I've been scrolling through compiler options and can't find
anything that allows me to set the output directory for the
binary. -od handles object files well enough, but doesn't put the
library there.
Have I overlooked something? Is there a way to specify the output
directory for the binary?
More information about the digitalmars-d-ldc
mailing list