uname -a Linux nx4.priv 2.6.32-573.3.1.el6.x86_64 #1 SMP Thu A-6ren">
gpt4 book ai didi

linux - "fatal error: gnu/stubs-32.h: No such file or directory"但存在 stubs-64.h

转载 作者:塔克拉玛干 更新时间:2023-11-03 00:14:01 36 4
gpt4 key购买 nike

我正在运行 Linux,如下所示:

dbliss@nx4[objdir]> uname -a
Linux nx4.priv 2.6.32-573.3.1.el6.x86_64 #1 SMP Thu Aug 13 22:55:16 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux
dbliss@nx4[objdir]> cat /etc/*release
CentOS release 6.7 (Final)
LSB_VERSION=base-4.0-amd64:base-4.0-noarch:core-4.0-amd64:core-4.0-noarch:graphics-4.0-amd64:graphics-4.0-noarch:printing-4.0-amd64:printing-4.0-noarch
CentOS release 6.7 (Final)
CentOS release 6.7 (Final)

我刚刚下载了 gcc4.8.4 版本,并尝试按如下方式配置和构建它:

dbliss@nx4[objdir]> ~/srcdir/configure --prefix=$HOME --with-gmp=$HOME
dbliss@nx4[objdir]> make

这些命令中的最后一个引发了以下错误:

make[5]: Entering directory `/home/despo/dbliss/objdir/x86_64-unknown-linux-gnu/32/libgcc'
# If this is the top-level multilib, build all the other
# multilibs.
DEFINES='' HEADERS='/home/despo/dbliss/srcdir/libgcc/config/i386/value-unwind.h' \
/home/despo/dbliss/srcdir/libgcc/mkheader.sh > tmp-libgcc_tm.h
/bin/sh /home/despo/dbliss/srcdir/libgcc/../move-if-change tmp-libgcc_tm.h libgcc_tm.h
echo timestamp > libgcc_tm.stamp
/home/despo/dbliss/objdir/./gcc/xgcc -B/home/despo/dbliss/objdir/./gcc/ -B/home/despo/dbliss/x86_64-unknown-linux-gnu/bin/ -B/home/despo/dbliss/x86_64-unknown-linux-gnu/lib/ -isystem /home/despo/dbliss/x86_64-unknown-linux-gnu/include -isystem /home/despo/dbliss/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 -mlong-double-80 -g -DIN_LIBGCC2 -fbuilding-libgcc -fno-stack-protector -fpic -mlong-double-80 -I. -I. -I../../.././gcc -I/home/despo/dbliss/srcdir/libgcc -I/home/despo/dbliss/srcdir/libgcc/. -I/home/despo/dbliss/srcdir/libgcc/../gcc -I/home/despo/dbliss/srcdir/libgcc/../include -I/home/despo/dbliss/srcdir/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 /home/despo/dbliss/srcdir/libgcc/libgcc2.c -fvisibility=hidden -DHIDE_EXPORTS
In file included from /usr/include/features.h:385:0,
from /usr/include/stdio.h:28,
from /home/despo/dbliss/srcdir/libgcc/../gcc/tsystem.h:87,
from /home/despo/dbliss/srcdir/libgcc/libgcc2.c:27:
/usr/include/gnu/stubs.h:7:27: fatal error: gnu/stubs-32.h: No such file or directory
# include <gnu/stubs-32.h>
^
compilation terminated.
make[5]: *** [_muldi3.o] Error 1
make[5]: Leaving directory `/home/despo/dbliss/objdir/x86_64-unknown-linux-gnu/32/libgcc'
make[4]: *** [multi-do] Error 1
make[4]: Leaving directory `/home/despo/dbliss/objdir/x86_64-unknown-linux-gnu/libgcc'
make[3]: *** [all-multi] Error 2
make[3]: Leaving directory `/home/despo/dbliss/objdir/x86_64-unknown-linux-gnu/libgcc'
make[2]: *** [all-stage1-target-libgcc] Error 2
make[2]: Leaving directory `/home/despo/dbliss/objdir'
make[1]: *** [stage1-bubble] Error 2
make[1]: Leaving directory `/home/despo/dbliss/objdir'
make: *** [all] Error 2

我从这里得到的是 make 需要 /usr/include/gnu/ 中的文件 stubs-32.h,但是找不到。

但是,我在这个目录中有一个文件 stubs-64.h:

dbliss@nx4[objdir]> ls /usr/include/gnu
libc-version.h lib-names.h stubs-64.h stubs.h

我的问题是,我是否应该在调用 configure 时以某种方式指定我使用的是 64 位系统,因此 stubs-64.h 应该使用?还是 stubs-32.h 总是必需的?如果需要 stubs-32.h,我获取和安装它的最佳方式是什么——考虑到我不是这个计算系统的管理员并且需要在本地安装它(并且让 make 在本地找到它)。

最佳答案

在 Ubuntu 上

sudo apt install libc6-dev:i386

关于linux - "fatal error: gnu/stubs-32.h: No such file or directory"但存在 stubs-64.h,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33059187/

36 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com