unable to build gmp on ARMv7

Nikolai Sokolov nzamb7 at gmail.com
Sun Dec 1 12:58:30 UTC 2013


I'm receiving error during compiling gmp-5.1.3 on ARM. I can only build if
I use  --enable-assembly=false

make[2]: Entering directory `/data/home/k/gmp-5.1.3/mpn'
/bin/bash ../libtool --mode=compile --tag=CC ../mpn/m4-ccas --m4="m4" gcc
-std=gnu99 -c -DHAVE_CONFIG_H -I. -I.. -D__GMP_WITHIN_GMP -I..
-DOPERATION_`echo rsh1add_n | sed 's/_$//'`    -marm -O2 -pedantic
-fomit-frame-pointer -march=armv7-a -Wa,--noexecstack `test -f
'rsh1add_n.asm' || echo './'`rsh1add_n.asm
libtool: compile:  ../mpn/m4-ccas --m4=m4 gcc -std=gnu99 -c -DHAVE_CONFIG_H
-I. -I.. -D__GMP_WITHIN_GMP -I.. -DOPERATION_rsh1add_n -marm -O2 -pedantic
-fomit-frame-pointer -march=armv7-a -Wa,--noexecstack rsh1add_n.asm  -fPIC
-DPIC -o .libs/rsh1add_n.o
m4  -DHAVE_CONFIG_H -D__GMP_WITHIN_GMP -DOPERATION_rsh1add_n -DPIC
rsh1add_n.asm >tmp-rsh1add_n.s
 gcc -std=gnu99 -c -DHAVE_CONFIG_H -I. -I.. -D__GMP_WITHIN_GMP -I..
-DOPERATION_rsh1add_n -marm -O2 -pedantic -fomit-frame-pointer
-march=armv7-a -Wa,--noexecstack tmp-rsh1add_n.s -fPIC -DPIC -o
.libs/rsh1add_n.o
tmp-rsh1add_n.s: Assembler messages:
tmp-rsh1add_n.s:81: Error: bad instruction `rrxs r12,r7'
tmp-rsh1add_n.s:92: Error: bad instruction `rrxs r12,r7'
tmp-rsh1add_n.s:93: Error: bad instruction `rrxs r6,r6'
tmp-rsh1add_n.s:94: Error: bad instruction `rrxs r5,r5'
tmp-rsh1add_n.s:95: Error: bad instruction `rrxs r4,r4'
tmp-rsh1add_n.s:108: Error: bad instruction `rrxs r12,r6'
tmp-rsh1add_n.s:109: Error: bad instruction `rrxs r5,r5'
tmp-rsh1add_n.s:110: Error: bad instruction `rrxs r4,r4'
tmp-rsh1add_n.s:120: Error: bad instruction `rrxs r12,r5'
tmp-rsh1add_n.s:121: Error: bad instruction `rrxs r4,r4'
tmp-rsh1add_n.s:126: Error: bad instruction `rrxs r4,r4'
make[2]: *** [rsh1add_n.lo] Error 1
make[2]: Leaving directory `/data/home/k/gmp-5.1.3/mpn'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/data/home/k/gmp-5.1.3'
make: *** [all] Error 2


configure: summary of build options:

  Version:           GNU MP 5.1.3
  Host type:         armcortexa9-unknown-linux-gnueabi
  ABI:               standard
  Install prefix:    /usr/local
  Compiler:          gcc -std=gnu99
  Static libraries:  yes
  Shared libraries:  yes


gcc -v
Using built-in specs.
Target: arm-linux-gnueabi
Configured with: ../src/configure -v --with-pkgversion='Ubuntu
4.3.3-5ubuntu4' --with-bugurl=file:///usr/share/doc/gcc-4.3/README.Bugs
--enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr --enable-shared
--with-system-zlib --libexecdir=/usr/lib --without-included-gettext
--enable-threads=posix --enable-nls
--with-gxx-include-dir=/usr/include/c++/4.3 --program-suffix=-4.3
--enable-clocale=gnu --enable-libstdcxx-debug --enable-objc-gc
--enable-mpfr --disable-libssp --disable-sjlj-exceptions --with-arch=armv5t
--with-tune=cortex-a8 --enable-checking=release --build=arm-linux-gnueabi
--host=arm-linux-gnueabi --target=arm-linux-gnueabi
Thread model: posix
gcc version 4.3.3 (Ubuntu 4.3.3-5ubuntu4)

./config.guess
armcortexa9-unknown-linux-gnueabi

uname -a
Linux localhost 2.6.32.9 #2 SMP PREEMPT Mon Dec 12 13:23:17 CST 2011 armv7l
unknown


 cat /proc/cpuinfo
Processor       : ARMv7 Processor rev 0 (v7l)
processor       : 0
BogoMIPS        : 1992.29

Features        : swp half thumb fastmult vfp edsp vfpv3 vfpv3d16
CPU implementer : 0x41
CPU architecture: 7
CPU variant     : 0x1
CPU part        : 0xc09
CPU revision    : 0

Hardware        : Olympus
Revision        : 83f0
Serial          : 027c100341404457

dnl config.m4.  Generated automatically by configure.
changequote(<,>)
ifdef(<__CONFIG_M4_INCLUDED__>,,<
define(<CONFIG_TOP_SRCDIR>,<`../.'>)
define(<WANT_ASSERT>,0)
define(<WANT_PROFILING>,<`no'>)
define(<M4WRAP_SPURIOUS>,<no>)
define(<TEXT>, <.text>)
define(<DATA>, <.data>)
define(<LABEL_SUFFIX>, <:>)
define(<GLOBL>, <.globl>)
define(<GLOBL_ATTR>, <>)
define(<GSYM_PREFIX>, <>)
define(<RODATA>, <      .section        .rodata>)
define(<TYPE>, <.type   $1,#$2>)
define(<SIZE>, <.size   $1,$2>)
define(<LSYM_PREFIX>, <.L>)
define(<W32>, <.long>)
define(<ALIGN_LOGARITHMIC>,<yes>)
define(<SQR_TOOM2_THRESHOLD>,<50>)
define(<BMOD_1_TO_MOD_1_THRESHOLD>,<33>)
define(<SIZEOF_UNSIGNED>,<4>)
define(<GMP_LIMB_BITS>,32)
define(<GMP_NAIL_BITS>,0)
define(<GMP_NUMB_BITS>,eval(GMP_LIMB_BITS-GMP_NAIL_BITS))
>)
changequote(`,')
ifdef(`__CONFIG_M4_INCLUDED__',,`
include(CONFIG_TOP_SRCDIR`/mpn/asm-defs.m4')
include_mpn(`arm/arm-defs.m4')
define_not_for_expansion(`HAVE_HOST_CPU_armcortexa9')
define_not_for_expansion(`HAVE_ABI_standard')
define_not_for_expansion(`HAVE_LIMB_LITTLE_ENDIAN')
define_not_for_expansion(`HAVE_DOUBLE_IEEE_LITTLE_ENDIAN')
')
define(`__CONFIG_M4_INCLUDED__')


More information about the gmp-bugs mailing list