building gdc on Debian 64-bit (wheezy)

Brad brad.lanam.comp_NOSPAM_ at gmail.com
Fri Oct 28 15:49:37 PDT 2011


Does anyone know how to get gdc to build on a 64-bit linux machine?
I can build gdc on linuxmint11 (32-bit) and gdc v2 on FreeBSD 8.2 (32-bit).
I have included below the script I use.
I've tried removing "." from PATH; I've tried --enable-multilib and --disable-multilib.

The error I get is:
checking whether the /home/bll/gdc/gdc2/dev/gcc-4.6.1/objdir/./gcc/xgcc -B/home/
bll/gdc/gdc2/dev/gcc-4.6.1/objdir/./gcc/ -B/opt/gdc2/x86_64-unknown-linux-gnu/bi
n/ -B/opt/gdc2/x86_64-unknown-linux-gnu/lib/ -isystem /opt/gdc2/x86_64-unknown-l
inux-gnu/include -isystem /opt/gdc2/x86_64-unknown-linux-gnu/sys-include    link
er (/home/bll/gdc/gdc2/dev/gcc-4.6.1/objdir/./gcc/collect-ld -m elf_x86_64) supp
orts shared libraries... yes
checking dynamic linker characteristics... configure: error: Link tests are not allowed after GCC_NO_EXECUTABLES.
make[1]: *** [configure-target-libquadmath] Error 1
[...]
checking whether the /home/bll/gdc/gdc2/dev/gcc-4.6.1/objdir/./gcc/xgcc -B/home/bll/gdc/gdc2/dev/gcc-4.6.1/objdir/./gcc/ -B/opt/gdc2/x86_64-unknown-linux-gnu/bin/ -B/opt/gdc2/x86_64-unknown-linux-gnu/lib/ -isystem /opt/gdc2/x86_64-unknown-linux-gnu/include -isystem /opt/gdc2/x86_64-unknown-linux-gnu/sys-include    linker (/home/bll/gdc/gdc2/dev/gcc-4.6.1/objdir/./gcc/collect-ld -m elf_x86_64) supports shared libraries... yes
checking dynamic linker characteristics... configure: error: Link tests are not allowed after GCC_NO_EXECUTABLES.
make[1]: *** [configure-target-libssp] Error 1


#!/bin/sh
#
#    * wget
#    * mercurial
#
#    * gcc and g++
#    * autoconf2.59
#    * automake1.9
#    * libmpfr-dev
#    * libmpc-dev
#    * libgmp3-dev
#    * patch 
#
#    * gcc-multilib
#    * libcloog-ppl-dev
#

# temporary...
PATH=$(echo $PATH | sed 's/:*$//;s/::/:/g;s/^:*//')
echo $PATH > /dev/tty

MAKE=make
if [ -x /usr/local/bin/gmake ]; then
  MAKE=gmake
fi
export MAKE
cwd=$(pwd)

gccvers=4.6.1
if [ ! -f gcc-${gccvers}.tar.bz2 ]; then
  echo "## fetching gcc" > /dev/tty
  wget "http://fileboar.com/gcc/releases/gcc-${gccvers}/gcc-${gccvers}.tar.bz2"
#  wget "http://mirrors.kernel.org/gnu/gcc/gcc-${gccvers}/gcc-${gccvers}.tar.bz2"
fi

echo "## removing old dirs" > /dev/tty
test -d gdcold && rm -rf gdcold
test -d gdc && rm -rf gdc
test -d gdc2 && rm -rf gdc2
test -d gdc1 && rm -rf gdc1
echo "## fetching gdc" > /dev/tty
hg clone https://goshawk@bitbucket.org/goshawk/gdc
mv gdc gdc2

mkdir gdc2/dev
echo "## extracting gcc" > /dev/tty
(cd gdc2/dev;tar xfj ../../gcc-${gccvers}.tar.bz2)
echo "## copying gdc2 to gdc1" > /dev/tty
cp -pr gdc2 gdc1

for d in gdc2 gdc1; do
  cd ${cwd}
  cd ${d}/dev/gcc-${gccvers}
  ln -sf ../../../d gcc/d
  echo "## ${d}: setup-gcc.sh" >/dev/tty
  if [ $d = "gdc2" ]; then
    ./gcc/d/setup-gcc.sh -v2
  else
    ./gcc/d/setup-gcc.sh -v1
  fi
  mkdir objdir
  cd objdir 
  echo "## ${d}: configure" > /dev/tty
  ../configure \
        CC=$(which cc) \
        --prefix=/opt/${d} \
        --enable-languages=d \
        --disable-shared \
        --disable-bootstrap \
        --with-bugurl="https://bitbucket.org/goshawk/gdc/issues" \
        --enable-checking=release \
        --enable-multilib
  echo "## ${d}: make" > /dev/tty
  ${MAKE} -j4
  rc=$?
  if [ $rc -ne 0 ]; then
    break
  fi
  echo "## ${d}: make install" > /dev/tty
  ${MAKE} install
done



More information about the D.gnu mailing list