On Tue, 04 Feb 2014 10:16:35 +0100, Sönke Ludwig wrote:

Am 04.02.2014 07:05, schrieb cal:

I need to set -defaultlib=libphobos2.so on linux. Can't use DFLAGS environment variable, since it doesn't seem to work (I guess the issue is this http://d.puremagic.com/issues/show_bug.cgi?id=1660).

DUB supports dflags, but as far as I can tell this only applies during the build step, whereas I need to set the switch during the link step.

Any workarounds for this currently?

The separate compile/link build mode is kind of a strange beast. There
is currently a set of compiler flags which are automatically passed to
the link stage (e.g. -g or -m64). I'll add -defaultlib to this set.

Should work now as of 569b5f0.