Installing with non-standard prefix fails - please help
Marc Glisse
marc.glisse@inria.fr
Tue Aug 30 11:54:00 GMT 2011
On Tue, 30 Aug 2011, H_Jarausch wrote:
> I need to install gcc-4.7-SVN onto a machine where I don't have root access.
> I'd like to install with the /kurs/cpp prefix. For doing so, I configure
> like
>
> CFLAGS='-L/kurs/cpp/lib' LDFLAGS="-L/kurs/cpp/lib -Wl,-rpath,/kurs/cpp/lib"
> \
> ./configure --prefix=/kurs/cpp --enable-languages="c++" \
> --with-gmp=/kurs/cpp --with-mpfr=/kurs/cpp
> --with-mpc=/kurs/cpp
It would be easier to compile gmp/mpfr/mpc as static-only
(--disable-shared) which is what gcc does if you let it build them itself.
> Still I get a configure error when the new gcclib is built:
> configure:3540: checking for suffix of object files
> configure:3562: /kurs/cpp/Src/gcc-4.7-110729/host-i686-pc-linux-gnu/gcc/xgcc
> -B/kurs/cpp/Src/gcc-4.7-110729/host-i686-pc-linux-gnu/gcc/
> -B/kurs/cpp/i686-pc-linux-gnu/bin/ -B/kurs/cpp/i686-pc-linux-gnu/lib/
> -isystem /kurs/cpp/i686-pc-linux-gnu/include -isystem
> /kurs/cpp/i686-pc-linux-gnu/sys-include -c -g -L/kurs/cpp/lib conftest.c
>> &5
> /kurs/cpp/Src/gcc-4.7-110729/host-i686-pc-linux-gnu/gcc/cc1: error while
> loading shared libraries: libmpc.so.2: cannot open shared object file: No
> such file or directory
LDFLAGS is only used for stage1. Things like BOOT_LDFLAGS (or others) may
help, see the doc. The -L shouldn't be needed (you have --with-gmp),
especially in CFLAGS.
--
Marc Glisse
More information about the Gcc-help
mailing list