On Sun, 21 Sep 2014 09:38:55 +0200, Sönke Ludwig wrote:

Am 20.09.2014 16:39, schrieb Daniel Kozak:

Is there a way how to select with linker shoud be used?
For e.g. with default archlinux linker (ld.bfd) it takes about 8s for linking vibe.d basic app.
But with gold linker (ld.gold), it goes down to 1s.

That should be configurable for either DMD or GCC somehow (dmd.conf?). I
didn't do that so far, so I don't know how that would look. If nothing
else helps, it should also be possible to re-symlink /usr/bin/ld to
the desired binary.

DUB itself just invokes the compiler, which in turn invokes the linker
somehow, so there is not much that can be done there right now (without
duplicating what the compiler does).

Unfortunately it is not possible to setup gcc nor dmd to use different linker. So the only way is make link of ld.gold to /usr/local/bin/ld and put /usr/local/bin before /usr/bin in $PATH