我尝试过从源代码编译xdebug,但是我变成了这样的输出:
/配置:加载站点脚本/usr/share/ site /x86_64-未知-linux-gnu检查处理长行和-e的grep。/usr/bin/grep检查白鹭。/usr/bin/grep -E检查不截断输出的sed ./usr/bin/sed检查cc.cc检查C编译器是否工作..。无配置: error: in
/home/fobo66/xdebug-2.3.3': configure: error: C compiler cannot create executables Seeconfig.log‘以获取更多详细信息
我发现了可能的错误:
/usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/bin/ld: i386 architecture of input file '/usr/lib/crt1.o' is incompatible with i386:x86-64 output /usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/bin/ld: i386 architecture of input file '/usr/lib/crti.o' is incompatible with i386:x86-64 output /usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/bin/ld: i386 architecture of input file '/usr/lib/crtn.o' is incompatible with i386:x86-64 output /usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/bin/ld: dynamic STT_GNU_IFUNC symbol 'strcmp' with pointer equality in '/usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../lib64/libc.a(strcmp.o)' can not be used when making an executable; recompile with -fPIE and relink with -pie
那么,当我的编译器不能工作时,如何解决这个问题呢?
发布于 2015-07-21 09:03:40
解决了!
我刚刚用正确的架构重新安装了glibc-devel。
如何做到:
glibcglibc和glibc-devel以进行更新(单击复选框)glibc包2.19-16.15.1-x86_64glibc-devel包并为它做6和7在此之后,编译应该能够正常工作。
这是类似Windows的方法,这就是为什么它很糟糕的原因:)
当有人知道如何从终端做这件事时,请在这里写上答案。
发布于 2015-07-20 08:03:59
尝试用gcc编译一些简单的代码。
#include <stdio.h>
int main () { printf("hello world\n"); return 0; }有命令
gcc -o simple simple.c如果会出现像“命令找不到”这样的错误,那么gcc就不在环境的路径上。
还要确保gcc能够找到标准的头文件(比如stdio.h和e.t.c)
发布于 2015-07-20 08:50:33
/usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/bin/ld: i386 architecture of input file '/usr/lib/crt1.o' is incompatible with i386:x86-64 output看起来链接器正在获取所需的obj文件的32位版本,其中它需要64位文件。尝试将LD_LIBRARY_PATH环境变量设置为/usr/lib64 64中的适当路径,然后重新编译。
https://stackoverflow.com/questions/31511070
复制相似问题