View Issue Details

IDProjectCategoryView StatusLast Update
0003040FSSCPBuild systempublic2014-05-11 01:54
Reportermarcoms Assigned Toniffiwan  
PriorityhighSeverityblockReproducibilityalways
Status closedResolutionno change required 
PlatformLinuxOSArch Linux 
Product Version3.7.0 
Fixed in Version3.7.2 
Summary0003040: Conflicting CXXFLAGS in Makefile
DescriptionPlain CXXFLAGS in the Makefile include -m64 and -mtune=i686, which obiously conflict (32bit && 64bit). As a result I get "error: CPU you selected does not support x86-64 instruction set" right after running make (first target).

Oddly, this didn't happen about a month ago (2014-04-01), when I last compiled fs2_open, so it might possibly be a change in gcc which made it stricter in this sense. Nonetheless, it is still an obvious bug and should be fixed.
Steps To Reproduce$ ./autogen.sh
$ make
Additional Information$ gcc --version
gcc (GCC) 4.9.0 20140507 (prerelease)

$ V=1 make
Making all in code
make[1]: Entering directory '/home/marcoms/fs2open.github.com/code'
g++ -DPACKAGE_NAME=\"fs2_open\" -DPACKAGE_TARNAME=\"fs2_open\" -DPACKAGE_VERSION=\"3.7.0\" -DPACKAGE_STRING=\"fs2_open\ 3.7.0\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE_URL=\"\" -DNO_CD_CHECK=1 -DFS2_SPEECH=1 -D_DEBUG=1 -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DSCP_UNIX=1 -DNO_DIRECT3D=1 -I. -m64 -mtune=i686 -msse -msse2 -ansi -DLUA_USE_LINUX -O0 -g -Wall -Wextra -Wno-unused-parameter -Wno-write-strings -Wshadow -funroll-loops -I/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT -I/usr/include/libpng16 -I/usr/include/lua5.1 -fsigned-char -Wno-unknown-pragmas -Wno-deprecated -Wno-char-subscripts -MT ai.o -MD -MP -MF .deps/ai.Tpo -c -o ai.o `test -f 'ai/ai.cpp' || echo './'`ai/ai.cpp
ai/ai.cpp:1:0: error: CPU you selected does not support x86-64 instruction set
 /*
 ^
Makefile:1894: recipe for target 'ai.o' failed
make[1]: *** [ai.o] Error 1
make[1]: Leaving directory '/home/marcoms/fs2open.github.com/code'
Makefile:510: recipe for target 'all-recursive' failed
make: *** [all-recursive] Error 1
TagsNo tags attached.

Activities

marcoms

2014-05-10 17:59

reporter   ~0015738

Setting -m32 in CXXFLAGS in the configure script is a temporary fix

niffiwan

2014-05-11 01:53

developer   ~0015739

-mtune=i686 isn't set anywhere in autotools in the current trunk:

$ git svn info
Path: .
URL: svn://svn.icculus.org/fs2open/trunk/fs2_open
Repository Root: svn://svn.icculus.org/fs2open
Repository UUID: 387891d4-d844-0410-90c0-e4c51a9137d3
Revision: 10665
Node Kind: directory
Schedule: normal
Last Changed Author: niffiwan
Last Changed Rev: 10665
Last Changed Date: 2014-05-10 15:13:56 +1000 (Sat, 10 May 2014)

$ grep i686 configure.ac
$

But it was that way in 3.7.0:

$ git checkout fs2_open_3_7_0
$ grep i686 configure.ac
        D_CFLAGS="$D_CFLAGS -m64 -mtune=i686 -msse -msse2 -ansi"
        D_CFLAGS="$D_CFLAGS -mtune=i686 -mfpmath=sse -msse -msse2 -ansi"

Therefore I believe this is already fixed :)

niffiwan

2014-05-11 01:54

developer   ~0015740

Already fixed in latest trunk.

Issue History

Date Modified Username Field Change
2014-05-10 17:53 marcoms New Issue
2014-05-10 17:53 marcoms Status new => assigned
2014-05-10 17:53 marcoms Assigned To => chief1983
2014-05-10 17:59 marcoms Note Added: 0015738
2014-05-11 01:53 niffiwan Note Added: 0015739
2014-05-11 01:53 niffiwan Assigned To chief1983 => niffiwan
2014-05-11 01:54 niffiwan Note Added: 0015740
2014-05-11 01:54 niffiwan Status assigned => closed
2014-05-11 01:54 niffiwan Resolution open => no change required
2014-05-11 01:54 niffiwan Fixed in Version => 3.7.2