I am trying to install gcc (a branch of gcc, not the trunk in the svn), and I configured it with:
./configure --prefix=/home/user/myroot/ --enable-languages=c,c++ \
--disable-multilib --libexecdir=/usr/lib --without-included-gettext \
--enable-threads=posix --disable-werror --with-arch-32=i486 \
--with-tune=generic --enable-checking=release --build=i486-linux-gnu \
--host=i486-linux-gnu --target=i486-linux-gnu
/home/user/myroot is a directory that exists.
When I run make, it builds gcc fine.
However, when I do make install, this is what I get:
make[1]: Entering directory `/home/user/gcc/gcc-cjung'
/bin/bash ./mkinstalldirs /home/user/myroot /home/user/myroot
make[2]: Entering directory `/home/user/gcc/gcc-cjung/host-i486-linux-gnu/fixincludes'
rm -rf /usr/lib/gcc/i486-linux-gnu/4.5.0/install-tools
/bin/bash ../.././fixincludes/../mkinstalldirs /usr/lib/gcc/i486-linux-gnu/4.5.0/install-tools
mkdir -p -- /usr/lib/gcc/i486-linux-gnu/4.5.0/install-tools
mkdir: cannot create directory `/usr/lib/gcc/i486-linux-gnu/4.5.0': Permission denied
make[2]: *** [install] Error 1
make[2]: Leaving directory `/home/user/gcc/gcc-cjung/host-i486-linux-gnu/fixincludes'
make[1]: *** [install-fixincludes] Error 2
make[1]: Leaving directory `/home/user/gcc/gcc-cjung'
make: *** [install] Error 2
Why does it still want to copy stuff to /usr/lib when I specified the prefix to be /home/user/myroot?
Btw, I am using Ubuntu 9.10 if that matters. I have already installed b开发者_如何学Pythonuild-essential, gawk, flex, bison, and libmpfr.
Why did you set the libexecdir
to /usr/lib
? That means it will have to install things into /usr/lib
, a directory to which you cannot write.
You probably want --libexecdir=/home/user/myroot/usr/lib
精彩评论