Problem building 4.2.1-rc on AIX 5.3
Torbjorn Granlund
tege at swox.com
Mon May 8 12:07:42 CEST 2006
Albert Chin <gmp-bugs at mlists.thewrittenword.com> writes:
I attempted to build gmp-4.2.1-rc.tar.bz2 on AIX 5.3 with the IBM C
compiler v7.0:
$ cd /opt/build/chin
$ gtar jxf gmp-4.2.1-rc.tar.bz2
$ cd gmp-4.2.1-rc
$ ./configure CC=xlc CFLAGS="-O2 -qro -qroconst -qmaxmem=-1 -qarch=ppc" \
CXX=xlC CXXFLAGS="-O2 -qro -qroconst -qmaxmem=-1" -qarch=com" \
LDFLAGS="-Wl,-brtl" ABI=32 M4=/opt/TWWfsw/m4/bin/gm4 --enable-shared \
--enable-static --disable-dependency-tracking
...
$ gmake
...
/opt/TWWfsw/m4/bin/gm4 -DHAVE_CONFIG_H -D__GMP_WITHIN_GMP -DOPERATION_mode1o -DPIC mode1o.asm >tmp-mode1o.s
xlc -c -DHAVE_CONFIG_H -I. -I. -I.. -D__GMP_WITHIN_GMP -I.. -DOPERATION_mode1o -O2 -qro -qroconst -qmaxmem=-1 -qarch=ppc tmp-mode1o.s -DPIC -o .libs/mode1o.o
Assembler:
tmp-mode1o.s: line 145: undefined symbol "__gmp_modlimb_invert_table"
tmp-mode1o.s: line 145: illegal expression
gmake[2]: *** [mode1o.lo] Error 1
gmake[2]: Leaving directory `/opt/build/china/gmp-4.2.1-rc/mpn'
$ uname -a
AIX yawara 3 5 00CB661F4C00
$ oslevel -r
5300-03
$ lslpp -L vac.C
Fileset Level State Type Description (Uninstaller)
----------------------------------------------------------------------------
vac.C 7.0.0.6 A F IBM XL C Compiler
$ ./config.guess
powerpc64-ibm-aix5.3.0.0
$ ./configfsf.guess
powerpc-ibm-aix5.3.0.0
I've attached a copy of mpn/tmp-mode1o.s.
A model for a bug report. :-)
The used assembly code is modelled after the gcc output (from a now
obsolete gcc version). It seems it is rejected by IBM's xlc compiler.
With the change below, I get clean builds with both xlc and gcc, using
it. Please test the patch and report the outcome.
Index: mpn/powerpc32/aix.m4
===================================================================
RCS file: /home/cvsfiles/gmp42/mpn/powerpc32/aix.m4,v
retrieving revision 1.3
retrieving revision 1.4
diff -p -2 -r1.3 -r1.4
*** mpn/powerpc32/aix.m4 19 Apr 2006 08:40:28 -0000 1.3
--- mpn/powerpc32/aix.m4 8 May 2006 09:47:12 -0000 1.4
*************** m4_assert_numargs(2)
*** 52,56 ****
` .toc
tc$2:
! .tc $2[TC], $2[RW]')'
` lwz $1, tc$2(2)')
--- 52,56 ----
` .toc
tc$2:
! .tc $2[TC], $2')'
` lwz $1, tc$2(2)')
--
Torbjörn
More information about the gmp-bugs
mailing list