I've exported those variables but it didn't work.
This is needed in my zshrc file on Ubuntu:
LIBRARY_PATH=/usr/lib/i386-linux-gnu
CPATH=/usr/include/i386-linux-gnu
export LIBRARY_PATH CPATH
First error I get is this:
In file included from /usr/include/features.h:388:0,
from /usr/include/stdio.h:28,
from ../../../libgcc/../gcc/tsystem.h:87,
from ../../../libgcc/../gcc/libgcc2.c:29:
/usr/include/gnu/stubs.h:7:27: fatal error: gnu/stubs-32.h: No such file or directory
Easily fixed by doing creating a symbolic link to /usr/include/i386... in /usr/include
then I get
checking whether make sets $(MAKE)... yes
checking
for i686-pc-linux-gnu-gcc...
/home/maartenvd1994/gdc_building/gdc/dev/gcc-4.6.1/objdir/./gcc/xgcc
-B/home/maartenvd1994/gdc_building/gdc/dev/gcc-4.6.1/objdir/./gcc/
-B/opt/gdc/i686-pc-linux-gnu/bin/ -B/opt/gdc/i686-pc-linux-gnu/lib/
-isystem /opt/gdc/i686-pc-linux-gnu/include -isystem
/opt/gdc/i686-pc-linux-gnu/sys-include
checking for C compiler default output file name...
configure: error: in `/home/maartenvd1994/gdc_building/gdc/dev/gcc-4.6.1/objdir/i686-pc-linux-gnu/libgomp':
configure: error: C compiler cannot create executables
I'm going to try a clean debian stable install in a virtual machine if I have time and try there