檢查帖子後:檢查相關帖子後,仍然無法在沒有root權限的Linux上安裝GCC 4.7?
Install gcc on linux with no root privilege
https://stackoverflow.com/questions/9316118/installing-gcc-as-non-root
我的問題仍不能得到解決,所以我在這裏發佈。
我試圖在Linux上安裝GCC 4.7.2版本,使用gcc 4.1.2版本20080704(Red Hat 4.1.2-52)。
我運行configure的前綴是我的主目錄。
./configure \
--with-gmp=/remote/home/gcc_4_7_2012_5_28/gmp505 \
--with-mpfr=/remote/home/gcc_4_7_2012_5_28/mpfr242 \
--with-mpc=/remote/home/gcc_4_7_2012_5_28/mpc081 \
--disable-libjava
然後,make ok。但是,檢查並不好,我得到了錯誤:
make[1]: Entering directory `/remote/home/gcc_4_7_2012_5_28/trunk'
make[2]: Entering directory `/remote/gcc_4_7_2012_5_28/trunk/host-x86_64-unknown-linux-gnu/fixincludes'
autogen -T ../.././fixincludes/check.tpl ../.././fixincludes/inclhack.def
make[2]: execvp: autogen: Permission denied
make install is not ok.
make[1]: Entering directory `/remote/home/gcc_4_7_2012_5_28/trunk'
/bin/sh ./mkinstalldirs /usr/local /usr/local
make[2]: Entering directory `/remote/home/gcc_4_7_2012_5_28/trunk/host-x86_64-unknown-linux-gnu/fixincludes'
rm -rf /usr/local/libexec/gcc/x86_64-unknown-linux-gnu/4.8.0/install-tools
/bin/sh ../.././fixincludes/../mkinstalldirs /usr/local/libexec/gcc/x86_64-unknown-linux-gnu/4.8.0/install-tools
mkdir -p -- /usr/local/libexec/gcc/x86_64-unknown-linux-gnu/4.8.0/install-tools
mkdir: cannot create directory `/usr/local/libexec/gcc': Permission denied
我無法獲得root權限。
任何幫助表示讚賞。
謝謝!
運行configure時似乎沒有'--prefix'參數 – nos