
我知道我的 linux 機器是 x86_64,我希望能夠透過 GCC 編譯 FOR x86_64。現在...
gcc -v
節目
Using built-in specs.
**Target: i386-redhat-linux**
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info
--enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-
__cxa_atexit --disable-libunwind-exceptions --enable-libgcj-multifile --enable-
languages=c,c++,objc,obj-c++,java,fortran,ada --enable-java-awt=gtk --disable-dssi --enable-plugin
--with-java-home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre --with-cpu=generic **--host=i386-redhat-linux**
Thread model: posix
gcc version 4.1.2 20080704 (Red Hat 4.1.2-48)
如何將 Target: 更改為 x86_64 並將 --host 更改為 x86_64?
答案1
結果我需要升級gcc
到 x86_64。我運行的是 x86_64,但由於某種原因我運行gcc
的是 i386。我gcc
透過在 yum 上搜尋將其升級到 64 位,然後嘗試更新。我必須刪除 i386gcc
及其一些依賴項,然後更新才起作用。gcc -v
現在顯示目標:x86_64-redhat-linux