没有安装Debian。

时间:2021-06-16 09:13:34

I'm having trouble installing gcc 4.6.3 on Debian squeeze. 4.4 is currently installed but I need 4.6.x to run php-hiphop. I've tried looking for similar problems but haven't found any with the error I have.

在Debian压缩中安装gcc 4.6.3有困难。4.4目前安装,但我需要4.6。x php-hiphop运行。我试过寻找类似的问题,但没有发现任何错误。

I install using these instructions:

我安装使用这些说明:

wget ftp://ftp.gnu.org/gnu/gcc/gcc-4.6.3/gcc-4.6.3.tar.gz
tar -xzvf gcc-4.6.3.tar.gz
cd gcc-4.6.3
./contrib/download_prerequisites
cd ..
mkdir objdir
cd objdir
£PWD/../gcc-4.6.3/configure --prefix=/opt/gcc-4.6.3
make
make install

on the make command everything seems to be going fine for a good 20 or more minutes then, BLAMO! This pops up:

在make命令的命令下,一切似乎都可以顺利进行20分钟或更长时间,BLAMO!这个弹出:

make[5]: Entering directory `/root/objdir/x86_64-unknown-linux-gnu/32/libgcc'
# If this is the top-level multilib, build all the other
# multilibs.
/root/objdir/./gcc/xgcc -B/root/objdir/./gcc/ -B/opt/gcc-4.6.3/x86_64-unknown-linux-gnu/bin/ -B/opt/gcc-4.6.3/x86_64-unknown-linux-gnu/lib/ -isystem /opt/gcc-4.6.3/x86_64-unknown-linux-gnu/include -isystem /opt/gcc-4.6.3/x86_64-unknown-linux-gnu/sys-include    -g -O2 -m32 -O2  -g -O2 -DIN_GCC   -W -Wall -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition  -isystem ./include  -fPIC -g -DHAVE_GTHR_DEFAULT -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -fno-stack-protector   -I. -I. -I../../.././gcc -I/root/objdir/../gcc-4.6.3/libgcc -I/root/objdir/../gcc-4.6.3/libgcc/. -I/root/objdir/../gcc-4.6.3/libgcc/../gcc -I/root/objdir/../gcc-4.6.3/libgcc/../include -I/root/objdir/../gcc-4.6.3/libgcc/config/libbid -DENABLE_DECIMAL_BID_FORMAT -DHAVE_CC_TLS  -DUSE_TLS -o _muldi3.o -MT _muldi3.o -MD -MP -MF _muldi3.dep -DL_muldi3 -c /root/objdir/../gcc-4.6.3/libgcc/../gcc/libgcc2.c \
          -fvisibility=hidden -DHIDE_EXPORTS
In file included from /usr/include/features.h:378:0,
                 from /usr/include/stdio.h:28,
                 from /root/objdir/../gcc-4.6.3/libgcc/../gcc/tsystem.h:87,
                 from /root/objdir/../gcc-4.6.3/libgcc/../gcc/libgcc2.c:29:
/usr/include/gnu/stubs.h:7:27: fatal error: gnu/stubs-32.h: No such file or directory
compilation terminated.
make[5]: *** [_muldi3.o] Error 1
make[5]: Leaving directory `/root/objdir/x86_64-unknown-linux-gnu/32/libgcc'
make[4]: *** [multi-do] Error 1
make[4]: Leaving directory `/root/objdir/x86_64-unknown-linux-gnu/libgcc'
make[3]: *** [all-multi] Error 2
make[3]: Leaving directory `/root/objdir/x86_64-unknown-linux-gnu/libgcc'
make[2]: *** [all-stage1-target-libgcc] Error 2
make[2]: Leaving directory `/root/objdir'
make[1]: *** [stage1-bubble] Error 2
make[1]: Leaving directory `/root/objdir'
make: *** [all] Error 2
root@localvm:~/objdir#

I see what's causing it, stubs.h cannot be found, but how do I fix this? Is there a separate library I need, or has something else gone wrong? Thanks in advance.

我知道是怎么回事了,斯图布。无法找到h,但我如何解决这个问题呢?我需要的是一个单独的图书馆,还是有别的地方出了问题?提前谢谢。

EDIT downloading the multilib dependencies sorted out the above error. The make command ran for a good 5 hours, yes 5 hours, or so and then came crashing down with another error to do with zips and jars and I'm stumped.

编辑下载的多库依赖项解决上述错误。make命令运行了5个小时,是的,5个小时左右,然后又出现了另一个错误,用zips和jars来处理,我被难住了。

checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... mawk
checking whether make sets $(MAKE)... yes
checking for style of include used by make... GNU
checking dependency style of /root/objdir/./gcc/xgcc -B/root/objdir/./gcc/ -B/opt/gcc-4.6.3/x86_64-unknown-linux-gnu/bin/ -B/opt/gcc-4.6.3/x86_64-unknown-linux-gnu/lib/ -isystem /opt/gcc-4.6.3/x86_64-unknown-linux-gnu/include -isystem /opt/gcc-4.6.3/x86_64-unknown-linux-gnu/sys-include   ... gcc3
checking dependency style of  /root/objdir/./gcc/xgcc -shared-libgcc -B/root/objdir/./gcc -nostdinc++ -L/root/objdir/x86_64-unknown-linux-gnu/libstdc++-v3/src -L/root/objdir/x86_64-unknown-linux-gnu/libstdc++-v3/src/.libs -B/opt/gcc-4.6.3/x86_64-unknown-linux-gnu/bin/ -B/opt/gcc-4.6.3/x86_64-unknown-linux-gnu/lib/ -isystem /opt/gcc-4.6.3/x86_64-unknown-linux-gnu/include -isystem /opt/gcc-4.6.3/x86_64-unknown-linux-gnu/sys-include   ... gcc3
checking for x86_64-unknown-linux-gnu-as... /root/objdir/./gcc/as
checking for x86_64-unknown-linux-gnu-ld... /root/objdir/./gcc/collect-ld
checking for x86_64-unknown-linux-gnu-ar... ar
checking for x86_64-unknown-linux-gnu-ranlib... ranlib
checking for x86_64-unknown-linux-gnu-dlltool... dlltool
checking for gawk... (cached) mawk
checking for jar... no
checking for fastjar... no
checking for gjar... no
checking for zip... no
checking for unzip... unzip
configure: error: cannot find neither zip nor jar, cannot continue
make[1]: *** [configure-target-libjava] Error 1
make[1]: Leaving directory `/root/objdir'
make: *** [all] Error 2
root@localvm:~/objdir#

4 个解决方案

#1


3  

I think you need multilib support, because you are trying to install 32 bits libraries in a 64 bit machine.

我认为您需要多lib支持,因为您试图在64位机器上安装32位库。

#2


3  

Thanks to logoff for solving my initial problem, and I sorted out the one I ran into later. unzip6.0 and zip3.0 need to be installed to finish off the make action. Follow these commands:

感谢logoff解决了我最初的问题,我整理了我后来遇到的问题。unzip6.0和zip3.0需要安装以完成make操作。遵循这些命令:

wget ftp://ftp.info-zip.org/pub/infozip/src/unzip60.tgz
gunzip unzip60.tgz
tar -xvf unzip60.tar
cd unzip60
make -f unix/Makefile generic
make -f unix/Makefile install

and the same for zip3.0

zip3.0也是如此。

wget ftp://ftp.info-zip.org/pub/infozip/src/zip30.tgz
gunzip zip30.tgz
tar -xvf zip30.tar
cd zip30
make -f unix/Makefile generic
make -f unix/Makefile install

#3


0  

As a side-note to boundless08's second problem and answer: On Debian (and presumably Ubuntu) installing zip seems to be enough:

作为一个旁注,它的第二个问题和答案是:在Debian(可能是Ubuntu)上安装zip似乎已经足够了:

sudo apt-get install zip

(I would have written a comment, but I don't seem to have enough reputation for that!)

(我会写评论,但我似乎没有足够的声誉!)

#4


0  

Disable multilib support for GCC configuration using below option while Compiling.

在编译时使用以下选项禁用对GCC配置的多lib支持。

    $ ./configure --prefix=$GCC_PREFIX \
    --enable-shared \
    --disable-multilib \

#1


3  

I think you need multilib support, because you are trying to install 32 bits libraries in a 64 bit machine.

我认为您需要多lib支持,因为您试图在64位机器上安装32位库。

#2


3  

Thanks to logoff for solving my initial problem, and I sorted out the one I ran into later. unzip6.0 and zip3.0 need to be installed to finish off the make action. Follow these commands:

感谢logoff解决了我最初的问题,我整理了我后来遇到的问题。unzip6.0和zip3.0需要安装以完成make操作。遵循这些命令:

wget ftp://ftp.info-zip.org/pub/infozip/src/unzip60.tgz
gunzip unzip60.tgz
tar -xvf unzip60.tar
cd unzip60
make -f unix/Makefile generic
make -f unix/Makefile install

and the same for zip3.0

zip3.0也是如此。

wget ftp://ftp.info-zip.org/pub/infozip/src/zip30.tgz
gunzip zip30.tgz
tar -xvf zip30.tar
cd zip30
make -f unix/Makefile generic
make -f unix/Makefile install

#3


0  

As a side-note to boundless08's second problem and answer: On Debian (and presumably Ubuntu) installing zip seems to be enough:

作为一个旁注,它的第二个问题和答案是:在Debian(可能是Ubuntu)上安装zip似乎已经足够了:

sudo apt-get install zip

(I would have written a comment, but I don't seem to have enough reputation for that!)

(我会写评论,但我似乎没有足够的声誉!)

#4


0  

Disable multilib support for GCC configuration using below option while Compiling.

在编译时使用以下选项禁用对GCC配置的多lib支持。

    $ ./configure --prefix=$GCC_PREFIX \
    --enable-shared \
    --disable-multilib \