There's an application I'd like to compile which requires C++11 which gcc 4.4.3 apparently doesn't support. I am trying to install gcc 4.6.2 alongside 4.4.3 into /usr/local/gcc462 so I can compile this program. But I don't want to interfere or mess up my normal gcc install. I'd love to use a repository package instead, but none for gcc 4.6.2 exist which are compatible with the older Ubuntu distribution I am using (Ubuntu 10.04). ____________________________________________________________________________ Reference guide: http://www.linuxquestions.org/questions/linux-newbie-8/build-gcc-4-6-2error-on-i686-pc-linux-gnu-machine-929660/#8 Source locations: http://gcc.gnu.org/mirrors.html http://gmplib.org/list-archives/gmp-announce/2010-January/000025.html http://www.mpfr.org/mpfr-3.1.0/ http://www.multiprecision.org/?prog=mpc&page=download $ sudo apt-get install libppl0.10-dev $ wget http://gcc.parentingamerica.com/snapshots/LATEST-4.6/gcc-4.6-20120817.tar.bz2 $ unp gcc-4.6-20120817.tar.bz2 Rename gcc gcc-4.6-20120817 to gcc-4.6.2 $ cd gcc-4.6.2 $ wget ftp://ftp.gnu.org/gnu/gmp/gmp-4.3.2.tar.bz2 $ wget http://www.mpfr.org/mpfr-3.1.0/mpfr-3.1.0.tar.bz2 $ wget http://www.multiprecision.org/mpc/download/mpc-0.9.tar.gz $ unp mpc-0.9.tar.gz $ unp mpfr-3.1.0.tar.bz2 $ unp gmp-4.3.2.tar.bz2 Rename the folders to the below, drwxr-xr-x 15 superkuh superkuh 4.0K 2010-01-07 14:10 gmp drwxr-xr-x 6 superkuh superkuh 4.0K 2011-02-21 05:15 mpc drwxr-xr-x 9 superkuh superkuh 4.0K 2011-10-03 04:43 mpfr $ sudo mkdir /usr/local/gcc462 $ cd mpfr $ ./configure $ make $ cd .. $ cd gmp $ ./configure $ make $ cd .. $ cd mpc $ ./configure --with-mpfr-include=/home/superkuh/app_installs/gcc-4.6.2/mpfr/src --with-mpfr-lib=/home/superkuh/app_installs/gcc-4.6.2/mpfr/src/.libs --with-gmp=/home/superkuh/app_installs/gcc-4.6.2/gmp $ make $ cd .. $ make distclean $ ./configure --prefix=/usr/local/gcc462 --enable-shared --enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu --enable-languages=c,c++,fortran --disable-multilib --with-system-zlib --with-mpfr-include=/home/superkuh/app_installs/gcc-4.6.2/mpfr/src --with-mpfr-lib=/home/superkuh/app_installs/gcc-4.6.2/mpfr/src/.libs --with-gmp=/home/superkuh/app_installs/gcc-4.6.2/gmp --with-mpc-lib=/home/superkuh/app_installs/gcc-4.6.2/mpc/src/.libs --with-mpc-include=/home/superkuh/app_installs/gcc-4.6.2/mpc/src/ $ make ... ... Configuring stage 1 in host-x86_64-unknown-linux-gnu/gmp configure: creating cache ./config.cache checking build system type... x86_64-unknown-linux-gnu checking host system type... none-unknown-linux-gnu checking for a BSD-compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for gawk... gawk checking whether make sets $(MAKE)... yes configure: error: source directory already configured; run "make distclean" there first make[2]: *** [configure-stage1-gmp] Error 1 make[2]: Leaving directory `/home/superkuh/app_installs/gcc-4.6.2' make[1]: *** [stage1-bubble] Error 2 make[1]: Leaving directory `/home/superkuh/app_installs/gcc-4.6.2' make: *** [all] Error 2 __DATA__ ../gcc-4.6.2/configure --prefix=/usr/local/gcc462 --enable-shared --enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu --enable-languages=c,c++,fortran --disable-multilib --with-system-zlib --with-mpfr-include=$(pwd)/../gcc-4.6.1/mpfr/src --with-mpfr-lib=$(pwd)/mpfr/src/.libs