Unfortunately, I keep getting build errors: g++: unrecognized option '-static-libstdc++' conftest.cpp:11:2: error: #error -static-libstdc++ not implemented conftest.c:18: error: 'choke' undeclared (first use in this function) conftest.c:18: error: (Each undeclared identifier is reported only once conftest.c:18: error: for each function it appears in.) conftest.c:18: error: expected ';' before 'me' On Sat, Jun 14, 2014 at 5:21 PM, Ivan Stalev <idstalev@xxxxxxxxx> wrote: > Hi, > > Yes, I removed everything inside the build directory (rm -r *). I > suppose I will retry again. > > Thanks, > > Ivan > > On Sat, Jun 14, 2014 at 5:16 PM, /jd <lists@xxxxxxxxxxxxxxx> wrote: >> >> On 6/14/14, 2:09 PM, Ivan Stalev wrote: >>> >>> Thank you for getting back to me. >>> >>> I ran ./contrib/download_prerequisites as it states in the FAQ. >>> >>> I then configured like this: >>> >>> ../gcc-4.8.1/configure --prefix=/home/mdl/ids103/gcc-4.8.1-install >>> --with-ld=/home/mdl/ids103/binutils-2.24-install/bin >>> --with-as=/home/mdl/ids103/binutils-2.24-install/bin >>> >>> I used --prefix because I do not have sudo permissions to install in >>> default directory. I use --with-ld and --with-as because the default >>> installed versions are old and the software that I will be compiling >>> requires newer versions of the binutils. >>> >>> Unfortunately, I still get the same error. >>> >>> >>> On Sat, Jun 14, 2014 at 4:12 PM, Jonathan Wakely <jwakely.gcc@xxxxxxxxx> >>> wrote: >>>> >>>> On 14 June 2014 21:07, Ivan Stalev <idstalev@xxxxxxxxx> wrote: >>>>> >>>>> Hi, >>>>> >>>>> Okay, now I configured like this: >>>>> >>>>> ../gcc-4.8.1/configure --prefix=/home/mdl/ids103/gcc-4.8.1-install >>>>> --enable-shared --enable-threads=posix --enable-__cxa_atexit >>>>> --enable-clocale=gnu --enable-lto --enable-languages=c,c++,fortran >>>>> --with-ld=/home/mdl/ids103/binutils-2.24-install/bin >>>>> --with-as=/home/mdl/ids103/binutils-2.24-install/bin >>>>> --disable-multilib --with-cloog=/home/mdl/ids103/install >>>>> --with-gmp=/home/mdl/ids103/install >>>>> --with-mpfr=/home/mdl/ids103/install >>>>> --with-mpc=/home/mdl/ids103/install >>>>> >>>>> I started the build, and 10 minutes into it, I get this error: >>>>> >>>>> checking for x86_64-unknown-linux-gnu-gcc... >>>>> /home/mdl/ids103/gcc-4.8.1-build/./gcc/xgcc >>>>> -B/home/mdl/ids103/gcc-4.8.1-build/./gcc/ >>>>> -B/home/mdl/ids103/gcc-4.8.1-install/x86_64-unknown-linux-gnu/bin/ >>>>> -B/home/mdl/ids103/gcc-4.8.1-install/x86_64-unknown-linux-gnu/lib/ >>>>> -isystem >>>>> /home/mdl/ids103/gcc-4.8.1-install/x86_64-unknown-linux-gnu/include >>>>> -isystem >>>>> /home/mdl/ids103/gcc-4.8.1-install/x86_64-unknown-linux-gnu/sys-include >>>>> checking for suffix of object files... configure: error: in >>>>> `/home/mdl/ids103/gcc-4.8.1-build/x86_64-unknown-linux-gnu/libgcc': >>>>> configure: error: cannot compute suffix of object files: cannot compile >>>> >>>> Read the link I gave you. It links to the FAQ explaining this error: >>>> https://gcc.gnu.org/wiki/FAQ#configure_suffix >>>> >>>> And it also shows a much simpler way to build GCC that avoids this >>>> problem. Stop trying to do it the complicated way. >> >> >> Did you forcibly remove the config.cache? Likely you're getting the same >> error because of that. The approach you're using (recommended by Jonathan) >> definitely works. If you're in doubt, remove the directory you're trying to >> build into, but use rm -f, like so: >> >> $ find . -name config.cache -exec rm -f {} \; >> >> That will clear your cache from any previous failed configuration attempts. >> >> John >>