gcc编译问题_C/C++_编程开发_程序员俱乐部

中国优秀的程序员网站程序员频道CXYCLUB技术地图
热搜:
更多>>
 
您所在的位置: 程序员俱乐部 > 编程开发 > C/C++ > gcc编译问题

gcc编译问题

 2011/12/20 10:54:48  gushengchang  http://gushengchang.iteye.com  我要评论(0)
  • 摘要:[hadoop@hs15soap2.21]$makegcc-c-msse3-O3-funroll-loops-maccumulate-outgoing-args-fomit-frame-pointer-DMAKE_TIME=\""`date`"\"-DPTHREADSBWT.c-oBWT.oBWT.c:537:error:shiftmustbeanimmediateBWT.c:424:error:shiftmustbeanimmediateBWT.c:425:error
  • 标签:编译 问题
[hadoop@hs15 soap2.21]$ make
gcc  -c -msse3 -O3 -funroll-loops -maccumulate-outgoing-args -fomit-frame-pointer  -DMAKE_TIME=\""`date`"\" -DPTHREADS BWT.c -o BWT.o
BWT.c:537: error: shift must be an immediate
BWT.c:424: error: shift must be an immediate
BWT.c:425: error: shift must be an immediate
make: *** [BWT.o] Error 1


出现这个问题是GCC版本的问题,当前机器的版本为:
[hadoop@hs15 soap2.21]$ gcc -v
Using built-in specs.
Target: x86_64-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=x86_64-redhat-linux
Thread model: posix
gcc version 4.1.2 20080704 (Red Hat 4.1.2-48)


把代码放到高版本GCC的机器上编译就通过了。
[hadoop@hs12 b]$ gcc -v
Using built-in specs.
Target: x86_64-redhat-linux6E
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --with-bugurl=http://bugzilla.redhat.com/bugzilla --enable-bootstrap --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-languages=c,c++,fortran --disable-libgcj --with-mpfr=/builddir/build/BUILD/gcc-4.4.0-20090514/obj-x86_64-redhat-linux6E/mpfr-install/ --with-ppl=/builddir/build/BUILD/gcc-4.4.0-20090514/obj-x86_64-redhat-linux6E/ppl-install --with-cloog=/builddir/build/BUILD/gcc-4.4.0-20090514/obj-x86_64-redhat-linux6E/cloog-install --with-tune=generic --with-arch_32=i586 --build=x86_64-redhat-linux6E
Thread model: posix
gcc version 4.4.0 20090514 (Red Hat 4.4.0-6) (GCC) 


发表评论
用户名: 匿名