Am Sun, 10 Nov 2013 14:20:05 +0100 schrieb Jacob Carlborg <d...@me.com>:
> On 2013-11-10 12:14, Iain Buclaw wrote: > > > It also makes no sense as both have wildly different compiler switch > > names. And for the switches that are the same, both interpret the > > switches differently. ie: '-I ./imports' works for GDC but not DMD > > (for some reason DMD doesn't like spaces between switches and switch > > arguments). > > Right, it also depends on the flag. They're all quite inconsistent. Well, it doesn't hurt to add a "dc" symlink the way you described it. As long as you use no spaces after -I and resort to the basic stuff like adding -release -O -inline etc. it should work. I'm currently testing the parallel installation of dmd-versions in Gentoo. After finding starting and stopping work on a few experiments to figure out what is possible with ebuilds, it was time for something simpler. The biggest problem was the library path. I chose /usr/lib{32,64}/dlang/<compiler>/ for now, where <compiler> is "dmd-2.064". I don't know if I should add the .2 minor version, too. But that's really a minor detail. I solved that by replacing all occurrences of /etc/ with /etc/dlang/dmd-<version>/ in inifile.c and then putting dmd.conf there with two sections for [Environment32] and [Environment64], that point to the afore mentioned library paths for 32-bit and 64-bit respectively. I didn't know of these two sections until I looked at the dmd source code. They also mean that I can remove --no-warn-search-mismatch from DFLAGS, since 32-bit and 64-bit libraries are now clearly separated. Next, I'll probably modify the dmd-2.063.2 ebuild in the same fashion and look at the eselect python module to create a counterpart for dlang. -- Marco