If you are using dmd, then a simple
<br>pragma(lib, "gtkd");<br>
is all that's necessary. But note that gdc completely ignores that. I
have no clue what ldc does.I usually include a pragma(lib, "whatever") even if I have a build script.
It makes it easier for (myself or others) to pick it apart and compile
individual sections.
I canvibe
, or dmd -Isource -J... whatever and it still links fine.As an added bonus, It's a nice way to keep the list of external libs in
one place. Self-documenting code and all that.
So... I would do both pragmas and the dflags method mentioned.
Does anyone have any luck linking with libxml2 ??
I have tried
pragma(lib, "libxml-2.0");
and
pragma(lib, "libxml2");
But neither seems to work.