Summary: | ASTERISK-05558: amd64 / em64t compile error | ||
Reporter: | lters (lters) | Labels: | |
Date Opened: | 2005-11-10 12:04:33.000-0600 | Date Closed: | 2008-01-15 15:55:19.000-0600 |
Priority: | Minor | Regression? | No |
Status: | Closed/Complete | Components: | Core/CodecInterface |
Versions: | Frequency of Occurrence | ||
Related Issues: | |||
Environment: | Attachments: | ||
Description: | Compiling on a clean install of an amd64 box, compile stopes at the gsm codec. To fix the problem or work around it I had comment out the march option in asterisk/codecs/gsm/Makefile like this: 52c52 < OPTIMIZE+=-march=$(PROC) --- > #OPTIMIZE+=-march=$(PROC) This seem to let it compile fine. ****** ADDITIONAL INFORMATION ****** uname -a Linux pbx02.ekn.com 2.6.8-11-em64t-p4 #1 Wed Jun 1 00:22:21 CEST 2005 x86_64 GNU/Linux dpkg -l | grep gcc ii gcc 3.3.5-3 The GNU C compiler ii gcc-3.3 3.3.5-13 The GNU C compiler ii gcc-3.3-base 3.3.5-13 The GNU Compiler Collection (base package) ii lib32gcc1 3.4.3-13 GCC support library (ia32) ii libgcc1 3.4.3-13 GCC support library Debian/Stable cat /proc/cpuinfo processor : 0 vendor_id : GenuineIntel cpu family : 15 model : 4 model name : Intel(R) Xeon(TM) CPU 2.80GHz stepping : 1 cpu MHz : 2793.306 cache size : 1024 KB fpu : yes fpu_exception : yes cpuid level : 5 wp : yes flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm syscall lm pni monitor ds_cpl cid cmpxchg16b bogomips : 5521.40 clflush size : 64 cache_alignment : 128 address sizes : 36 bits physical, 48 bits virtual power management: | ||
Comments: | By: Jason Parker (jparker) 2005-11-10 12:11:06.000-0600 What does `uname -m` return for you? I didn't think Intel 64 showed up as x86_64 (which has an ifneq in the Makefile). By: Kevin P. Fleming (kpfleming) 2005-11-10 19:38:01.000-0600 It does, and it should compile fine using that name, since (as you say) the Makefile specifically accomodates it. I've just done a build on a Xeon EM64T system running Gentoo 2005.1 in 64-bit mode without any problem. If you can reproduce this problem and it's clearly the fault of the Makefile, please reopen the bug and post the compiler output. Thanks! By: lters (lters) 2005-11-10 20:03:00.000-0600 Here is the compiler output: make -C gsm lib/libgsm.a make[2]: Entering directory `/usr/src/asterisk/codecs/gsm' gcc -pipe -Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -g -Iinclude -I../include -D_REENTRANT -D_GNU_SOURCE -O6 -m64 -fomit-frame-pointer -fPIC -I/usr/include/speex -c -DNeedFunctionPrototypes=1 -funroll-loops -O6 -march=k8 -fPIC -DSASR -DNDEBUG -DWAV49 -I./inc src/add.c cc1: error: bad value (k8) for -march= switch cc1: error: bad value (k8) for -mcpu= switch make[2]: *** [src/add.o] Error 1 make[2]: Leaving directory `/usr/src/asterisk/codecs/gsm' make[1]: *** [gsm/lib/libgsm.a] Error 2 make[1]: Leaving directory `/usr/src/asterisk/codecs' make: *** [subdirs] Error 1 Here is the output of uname -m #uname -m x86_64 By: Kevin P. Fleming (kpfleming) 2005-11-10 20:06:37.000-0600 As we suspected, the x86_64 string is not the issue at all... it's the -march=k8 coming from the main Asterisk Makefile. Your compiler for some reason doesn't support this architecture setting, so you can easily edit the Makefile to avoid it being passed. Just choose another optimization architecture that your compiler does support and you'll be fine. By: Digium Subversion (svnbot) 2008-01-15 15:55:19.000-0600 Repository: asterisk Revision: 7053 U trunk/ChangeLog U trunk/apps/app_queue.c ------------------------------------------------------------------------ r7053 | kpfleming | 2008-01-15 15:55:19 -0600 (Tue, 15 Jan 2008) | 2 lines issue ASTERISK-5558 ------------------------------------------------------------------------ http://svn.digium.com/view/asterisk?view=rev&revision=7053 |