summaryrefslogtreecommitdiffstats
path: root/meta/packages/gmp
diff options
context:
space:
mode:
authorRichard Purdie <richard@openedhand.com>2006-11-20 20:36:11 +0000
committerRichard Purdie <richard@openedhand.com>2006-11-20 20:36:11 +0000
commitede06b01b5cfeb4720a610d549becbf01a007dac (patch)
tree141baeb59ca9b62612e92f19adf78efa933e21a3 /meta/packages/gmp
parentc5afcd84e7d03e6bf3353e82da633adab3a15e0c (diff)
downloadpoky-ede06b01b5cfeb4720a610d549becbf01a007dac.tar.gz
gmp: Upgrade to 4.2.1 from OE.dev
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@896 311d38ba-8fff-0310-9ca6-ca027cbcb966
Diffstat (limited to 'meta/packages/gmp')
-rw-r--r--meta/packages/gmp/gmp-4.1.2/amd64.patch16
-rw-r--r--meta/packages/gmp/gmp-4.1.2/configure.patch864
-rw-r--r--meta/packages/gmp/gmp-4.1.2/gcc-compile.patch72
-rw-r--r--meta/packages/gmp/gmp-4.1.4/configure.patch837
-rw-r--r--meta/packages/gmp/gmp-4.2.1/amd64.patch (renamed from meta/packages/gmp/gmp-4.1.4/amd64.patch)0
-rw-r--r--meta/packages/gmp/gmp-4.2.1/configure.patch195
-rw-r--r--meta/packages/gmp/gmp-4.2.1/sh4-asmfix.patch (renamed from meta/packages/gmp/gmp-4.1.4/sh4-asmfix.patch)0
-rw-r--r--meta/packages/gmp/gmp-native.inc23
-rw-r--r--meta/packages/gmp/gmp-native_4.1.2.bb7
-rw-r--r--meta/packages/gmp/gmp-native_4.2.1.bb2
-rw-r--r--meta/packages/gmp/gmp.inc (renamed from meta/packages/gmp/gmp_4.1.4.bb)5
-rw-r--r--meta/packages/gmp/gmp_4.1.2.bb18
-rw-r--r--meta/packages/gmp/gmp_4.2.1.bb3
13 files changed, 224 insertions, 1818 deletions
diff --git a/meta/packages/gmp/gmp-4.1.2/amd64.patch b/meta/packages/gmp/gmp-4.1.2/amd64.patch
deleted file mode 100644
index bbede7fcc7..0000000000
--- a/meta/packages/gmp/gmp-4.1.2/amd64.patch
+++ /dev/null
@@ -1,16 +0,0 @@
1Index: gmp-4.1.2/longlong.h
2===================================================================
3--- gmp-4.1.2.orig/longlong.h 2005-06-24 13:38:06.787570452 -0700
4+++ gmp-4.1.2/longlong.h 2005-06-24 13:38:31.539556496 -0700
5@@ -715,8 +715,10 @@
6 } while (0)
7 #define count_trailing_zeros(count, x) \
8 do { \
9+ UDItype __cbtmp; \
10 ASSERT ((x) != 0); \
11- __asm__ ("bsfq %1,%0" : "=r" (count) : "rm" ((UDItype)(x))); \
12+ __asm__ ("bsfq %1,%0" : "=r" (__cbtmp) : "rm" ((UDItype)(x))); \
13+ (count) = __cbtmp; \
14 } while (0)
15 #endif /* x86_64 */
16
diff --git a/meta/packages/gmp/gmp-4.1.2/configure.patch b/meta/packages/gmp/gmp-4.1.2/configure.patch
deleted file mode 100644
index 94ad97e919..0000000000
--- a/meta/packages/gmp/gmp-4.1.2/configure.patch
+++ /dev/null
@@ -1,864 +0,0 @@
1
2#
3# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher
4#
5
6--- gmp-4.1.2/mpfr/Makefile.am~configure 2002-05-15 20:27:52.000000000 -0400
7+++ gmp-4.1.2/mpfr/Makefile.am 2004-01-25 12:53:19.000000000 -0500
8@@ -28,7 +28,7 @@
9 SUBDIRS = tests
10
11 INCLUDES = -I$(top_srcdir)
12-CFLAGS = @MPFR_CFLAGS@
13+AM_CFLAGS = @MPFR_CFLAGS@
14 LIBS = @MPFR_LIBS@
15
16 if WANT_MPFR
17--- gmp-4.1.2/mpfr/tests/Makefile.am~configure 2002-11-24 17:00:42.000000000 -0500
18+++ gmp-4.1.2/mpfr/tests/Makefile.am 2004-01-25 12:53:19.000000000 -0500
19@@ -22,7 +22,7 @@
20 AUTOMAKE_OPTIONS = gnu no-dependencies $(top_builddir)/ansi2knr
21
22 INCLUDES = -I$(top_srcdir) -I$(top_srcdir)/mpfr
23-CFLAGS = @MPFR_CFLAGS@
24+AM_CFLAGS = @MPFR_CFLAGS@
25 LIBS = @MPFR_LIBS@
26
27 LDADD = ../libmpfr.a $(top_builddir)/libgmp.la
28--- gmp-4.1.2/configure.in~configure 2002-12-23 15:52:09.000000000 -0500
29+++ gmp-4.1.2/configure.in 2004-01-25 12:53:19.000000000 -0500
30@@ -26,15 +26,16 @@
31
32
33 AC_REVISION($Revision: 1.425.2.17 $)
34-AC_PREREQ(2.52)
35-AC_INIT(gmp-impl.h)
36-m4_pattern_forbid([^[ \t]*GMP_])
37-m4_pattern_forbid([^[ \t]*MPFR_CONFIGS])
38-m4_pattern_allow(GMP_LDFLAGS)
39-m4_pattern_allow(GMP_LIMB_BITS)
40-m4_pattern_allow(GMP_MPARAM_H_SUGGEST)
41-m4_pattern_allow(GMP_NAIL_BITS)
42-m4_pattern_allow(GMP_NUMB_BITS)
43+AC_PREREQ(2.57)
44+AC_INIT
45+AC_CONFIG_SRCDIR([gmp-impl.h])
46+
47+
48+
49+
50+
51+
52+
53
54 # If --target is not used then $target_alias is empty, but if say
55 # "./configure athlon-pc-freebsd3.5" is used, then all three of
56@@ -56,7 +57,7 @@
57 GMP_DEFINE_RAW("define_not_for_expansion(\`HAVE_HOST_CPU_$tmp_host')", POST)
58
59 AM_INIT_AUTOMAKE(gmp, GMP_VERSION)
60-AM_CONFIG_HEADER(config.h:config.in)
61+AC_CONFIG_HEADERS([config.h:config.in])
62 AM_MAINTAINER_MODE
63
64
65@@ -201,7 +202,7 @@
66 # After GMP specific searches and tests, the standard autoconf AC_PROG_CC is
67 # called. User selections of CC etc are respected.
68 #
69-# Care is taken not to use macros like AC_TRY_COMPILE during the GMP
70+# Care is taken not to use macros like AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[]])],[],[]) during the GMP
71 # pre-testing, since they of course depend on AC_PROG_CC, and also some of
72 # them cache their results, which is not wanted.
73 #
74@@ -288,7 +289,7 @@
75 # FIXME: We'd like to prefer an ANSI compiler, perhaps by preferring
76 # c89 over cc here. But note that on HP-UX c89 provides a castrated
77 # environment, and would want to be excluded somehow. Maybe
78-# AC_PROG_CC_STDC already does enough to stick cc into ANSI mode and
79+# already does enough to stick cc into ANSI mode and
80 # we don't need to worry.
81 #
82 cclist="gcc cc"
83@@ -1010,7 +1011,7 @@
84 CFLAGS_or_unset=${CFLAGS-'(unset)'}
85 CPPFLAGS_or_unset=${CPPFLAGS-'(unset)'}
86
87-cat >&AC_FD_CC <<EOF
88+cat >&AS_MESSAGE_LOG_FD() <<EOF
89 configure:__line__: User:
90 ABI=$ABI
91 CC=$CC
92@@ -1322,18 +1323,18 @@
93
94 # The C compiler and preprocessor, put into ANSI mode if possible.
95 AC_PROG_CC
96-AC_PROG_CC_STDC
97+
98 AC_PROG_CPP
99 GMP_H_ANSI
100
101
102 # The C++ compiler, if desired.
103 want_cxx=no
104+AC_PROG_CXX
105 if test $enable_cxx != no; then
106 test_CXXFLAGS=${CXXFLAGS+set}
107- AC_PROG_CXX
108
109- echo "CXXFLAGS chosen by autoconf: $CXXFLAGS" >&AC_FD_CC
110+ echo "CXXFLAGS chosen by autoconf: $CXXFLAGS" >&AS_MESSAGE_LOG_FD()
111 cxxflags_ac_prog_cxx=$CXXFLAGS
112 cxxflags_list=ac_prog_cxx
113
114@@ -1409,7 +1410,7 @@
115 fi
116
117
118-cat >&AC_FD_CC <<EOF
119+cat >&AS_MESSAGE_LOG_FD() <<EOF
120 configure:__line__: Decided:
121 ABI=$ABI
122 CC=$CC
123@@ -1651,9 +1652,9 @@
124
125 # FIXME: Autoconf 2.52 AC_C_BIGENDIAN bombs when cross compiling, but in the
126 # future the probes will be better and this override can be removed.
127-if test "$cross_compiling" = yes; then
128- ac_cv_c_bigendian=unknown
129-fi
130+#if test "$cross_compiling" = yes; then
131+# ac_cv_c_bigendian=unknown
132+#fi
133 AC_C_BIGENDIAN
134 # Enhancement: In the future AC_C_BIGENDIAN will accept these actions as
135 # parameters.
136@@ -2094,7 +2095,7 @@
137
138 # Configs for demos/calc directory
139 #
140-# AC_SUBST is used here since with AM_CONFIG_HEADER automake would put
141+# AC_SUBST is used here since with AC_CONFIG_HEADERS([]) automake would put
142 # demos/calc in the default $(DEFAULT_INCLUDES) for every directory,
143 # which would look very strange. Likewise demos/expr below.
144 #
145@@ -2133,7 +2134,7 @@
146 # FIXME: Upcoming version of autoconf/automake may not like broken lines.
147 # Right now automake isn't accepting the new AC_CONFIG_FILES scheme.
148
149-AC_OUTPUT(Makefile \
150+AC_CONFIG_FILES([Makefile \
151 mpbsd/Makefile mpf/Makefile mpn/Makefile mpq/Makefile \
152 mpz/Makefile printf/Makefile scanf/Makefile cxx/Makefile \
153 tests/Makefile tests/devel/Makefile tests/mpbsd/Makefile \
154@@ -2143,4 +2144,5 @@
155 mpfr/Makefile mpfr/tests/Makefile \
156 tune/Makefile \
157 demos/Makefile demos/calc/Makefile demos/expr/Makefile \
158- gmp.h:gmp-h.in mp.h:mp-h.in)
159+ gmp.h:gmp-h.in mp.h:mp-h.in])
160+AC_OUTPUT
161--- gmp-4.1.2/acinclude.m4~configure 2002-09-07 20:02:19.000000000 -0400
162+++ gmp-4.1.2/acinclude.m4 2004-01-25 12:54:39.000000000 -0500
163@@ -21,10 +21,10 @@
164 dnl MA 02111-1307, USA.
165
166
167-define(X86_PATTERN,
168+define([X86_PATTERN],
169 [[i?86*-*-* | k[5-8]*-*-* | pentium*-*-* | athlon-*-*]])
170
171-define(POWERPC64_PATTERN,
172+define([POWERPC64_PATTERN],
173 [[powerpc64-*-* | powerpc64le-*-* | powerpc620-*-* | powerpc630-*-*]])
174
175
176@@ -32,7 +32,7 @@
177 dnl ----------------------
178 dnl Strip entries */subdir from $path.
179
180-define(GMP_STRIP_PATH,
181+define([GMP_STRIP_PATH],
182 [tmp_path=
183 for i in $path; do
184 case $i in
185@@ -53,7 +53,7 @@
186 dnl GMP_INCLUDE_GMP_H_BITS_PER_MP_LIMB starts as a dummy, but gets
187 dnl redefined in GMP_C_SIZES when the right value is known.
188
189-define(GMP_INCLUDE_GMP_H,
190+define([GMP_INCLUDE_GMP_H],
191 [[#define __GMP_WITHIN_CONFIGURE 1 /* ignore template stuff */
192 #define GMP_NAIL_BITS $GMP_NAIL_BITS]
193 GMP_INCLUDE_GMP_H_BITS_PER_MP_LIMB
194@@ -61,7 +61,7 @@
195 #include "$srcdir/gmp-h.in"]
196 ])
197
198-define(GMP_INCLUDE_GMP_H_BITS_PER_MP_LIMB,
199+define([GMP_INCLUDE_GMP_H_BITS_PER_MP_LIMB],
200 [[#define __GMP_BITS_PER_MP_LIMB 123 /* dummy for GMP_NUMB_BITS etc */
201 #define GMP_LIMB_BITS 123]])
202
203@@ -72,7 +72,7 @@
204 dnl FILE. The regexps here aren't very rugged, but are enough for gmp.
205 dnl /dev/null as a parameter prevents a hang if $2 is accidentally omitted.
206
207-define(GMP_HEADER_GETVAL,
208+define([GMP_HEADER_GETVAL],
209 [patsubst(patsubst(
210 esyscmd([grep "^#define $1 " $2 /dev/null 2>/dev/null]),
211 [^.*$1[ ]+],[]),
212@@ -86,7 +86,7 @@
213 dnl autoconf time. Two digits like 3.0 if patchlevel <= 0, or three digits
214 dnl like 3.0.1 if patchlevel > 0.
215
216-define(GMP_VERSION,
217+define([GMP_VERSION],
218 [GMP_HEADER_GETVAL(__GNU_MP_VERSION,gmp-h.in)[]dnl
219 .GMP_HEADER_GETVAL(__GNU_MP_VERSION_MINOR,gmp-h.in)[]dnl
220 ifelse(m4_eval(GMP_HEADER_GETVAL(__GNU_MP_VERSION_PATCHLEVEL,gmp-h.in) > 0),1,
221@@ -97,13 +97,13 @@
222 dnl ------------------------------
223 dnl Setup an AC_SUBST of HAVE_FUNC_01 for each argument.
224
225-AC_DEFUN(GMP_SUBST_CHECK_FUNCS,
226+AC_DEFUN([GMP_SUBST_CHECK_FUNCS],
227 [m4_if([$1],,,
228 [_GMP_SUBST_CHECK_FUNCS(ac_cv_func_[$1],HAVE_[]m4_translit([$1],[a-z],[A-Z])_01)
229 GMP_SUBST_CHECK_FUNCS(m4_shift($@))])])
230
231 dnl Called: _GMP_SUBST_CHECK_FUNCS(cachvar,substvar)
232-AC_DEFUN(_GMP_SUBST_CHECK_FUNCS,
233+AC_DEFUN([_GMP_SUBST_CHECK_FUNCS],
234 [case $[$1] in
235 yes) AC_SUBST([$2],1) ;;
236 no) [$2]=0 ;;
237@@ -115,14 +115,14 @@
238 dnl ----------------------------------
239 dnl Setup an AC_SUBST of HAVE_FOO_H_01 for each argument.
240
241-AC_DEFUN(GMP_SUBST_CHECK_HEADERS,
242+AC_DEFUN([GMP_SUBST_CHECK_HEADERS],
243 [m4_if([$1],,,
244 [_GMP_SUBST_CHECK_HEADERS(ac_cv_header_[]m4_translit([$1],[./],[__]),
245 HAVE_[]m4_translit([$1],[a-z./],[A-Z__])_01)
246 GMP_SUBST_CHECK_HEADERS(m4_shift($@))])])
247
248 dnl Called: _GMP_SUBST_CHECK_HEADERS(cachvar,substvar)
249-AC_DEFUN(_GMP_SUBST_CHECK_HEADERS,
250+AC_DEFUN([_GMP_SUBST_CHECK_HEADERS],
251 [case $[$1] in
252 yes) AC_SUBST([$2],1) ;;
253 no) [$2]=0 ;;
254@@ -145,12 +145,12 @@
255 dnl would test whether $major.$minor.$subminor is greater than or equal to
256 dnl 10.3.1.
257
258-AC_DEFUN(GMP_COMPARE_GE,
259+AC_DEFUN([GMP_COMPARE_GE],
260 [gmp_compare_ge=no
261 GMP_COMPARE_GE_INTERNAL($@)
262 ])
263
264-AC_DEFUN(GMP_COMPARE_GE_INTERNAL,
265+AC_DEFUN([GMP_COMPARE_GE_INTERNAL],
266 [ifelse(len([$3]),0,
267 [if test -n "$1" && test "$1" -ge $2; then
268 gmp_compare_ge=yes
269@@ -184,7 +184,7 @@
270 dnl for instance to random.o (and others) on vax-dec-ultrix4.5. Naturally
271 dnl a user-selected $AR_FLAGS is left unchanged.
272
273-AC_DEFUN(GMP_PROG_AR,
274+AC_DEFUN([GMP_PROG_AR],
275 [dnl Want to establish $AR before libtool initialization.
276 AC_BEFORE([$0],[AC_PROG_LIBTOOL])
277 gmp_user_AR=$AR
278@@ -212,7 +212,7 @@
279 dnl CC_FOR_BUILD is used without testing. CC_FOR_BUILD is the new name for
280 dnl a build system compiler, see configfsf.guess.
281
282-AC_DEFUN(GMP_PROG_HOST_CC,
283+AC_DEFUN([GMP_PROG_HOST_CC],
284 [AC_BEFORE([$0],[AC_PROG_LIBTOOL])
285 AC_REQUIRE([AC_PROG_CC])
286 AC_CACHE_CHECK([for HOST_CC build system compiler],
287@@ -255,7 +255,7 @@
288 dnl FIXME: This can be removed and just AM_PROG_LEX used, one that macro
289 dnl works properly.
290
291-AC_DEFUN(GMP_PROG_LEX,
292+AC_DEFUN([GMP_PROG_LEX],
293 [AC_REQUIRE([AC_PROG_LEX])
294 if test "$LEX" = :; then
295 LEX=${am_missing_run}flex
296@@ -273,7 +273,7 @@
297 dnl
298 dnl See mpn/asm-defs.m4 for details on the known bad m4s.
299
300-AC_DEFUN(GMP_PROG_M4,
301+AC_DEFUN([GMP_PROG_M4],
302 [AC_ARG_VAR(M4,[m4 macro processor])
303 AC_CACHE_CHECK([for suitable m4],
304 gmp_cv_prog_m4,
305@@ -340,7 +340,7 @@
306 dnl Enhancement: Maybe this could be in GMP_PROG_M4, and attempt to prefer
307 dnl an m4 with a working m4wrap, if it can be found.
308
309-AC_DEFUN(GMP_M4_M4WRAP_SPURIOUS,
310+AC_DEFUN([GMP_M4_M4WRAP_SPURIOUS],
311 [AC_REQUIRE([GMP_PROG_M4])
312 AC_CACHE_CHECK([if m4wrap produces spurious output],
313 gmp_cv_m4_m4wrap_spurious,
314@@ -374,7 +374,7 @@
315 dnl A user-selected $NM is always left unchanged. AC_PROG_NM is still run
316 dnl to get the "checking" message printed though.
317
318-AC_DEFUN(GMP_PROG_NM,
319+AC_DEFUN([GMP_PROG_NM],
320 [dnl Make sure we're the first to call AC_PROG_NM, so our extra flags are
321 dnl used by everyone.
322 AC_BEFORE([$0],[AC_PROG_NM])
323@@ -426,7 +426,7 @@
324 dnl will run is that a plain native "./configure" falls back on ABI=32, but
325 dnl ABI=64 is still available as a cross-compile.
326
327-AC_DEFUN(GMP_PROG_CC_WORKS,
328+AC_DEFUN([GMP_PROG_CC_WORKS],
329 [AC_MSG_CHECKING([compiler $1])
330 cat >conftest.c <<EOF
331
332@@ -481,7 +481,7 @@
333 dnl cache the result. The same "ifndef" style test is used, to avoid
334 dnl problems with syntax checking cpp's used on NeXT and Apple systems.
335
336-AC_DEFUN(GMP_PROG_CC_IS_GNU,
337+AC_DEFUN([GMP_PROG_CC_IS_GNU],
338 [cat >conftest.c <<EOF
339 #ifndef __GNUC__
340 choke me
341@@ -508,7 +508,7 @@
342 dnl there is one then it's well hidden in xlc 3.1 on AIX 4.3, so just grep
343 dnl the man page printed when xlc is invoked with no arguments.
344
345-AC_DEFUN(GMP_PROG_CC_IS_XLC,
346+AC_DEFUN([GMP_PROG_CC_IS_XLC],
347 [gmp_command="$1 2>&1 | grep xlc >/dev/null"
348 if AC_TRY_EVAL(gmp_command); then
349 AC_MSG_CHECKING([whether $1 is xlc])
350@@ -527,7 +527,7 @@
351 dnl This test might be repeated for different compilers, so the result is
352 dnl not cached.
353
354-AC_DEFUN(GMP_HPC_HPPA_2_0,
355+AC_DEFUN([GMP_HPC_HPPA_2_0],
356 [AC_MSG_CHECKING([whether HP compiler $1 is good for 64-bits])
357 # Bad compiler output:
358 # ccom: HP92453-01 G.10.32.05 HP C Compiler
359@@ -571,7 +571,7 @@
360 dnl
361 dnl There's no caching here, so that different CC's can be tested.
362
363-AC_DEFUN(GMP_GCC_VERSION_GE,
364+AC_DEFUN([GMP_GCC_VERSION_GE],
365 [tmp_version=`($1 --version) 2>&AC_FD_CC`
366 echo "$1 --version '$tmp_version'" >&AC_FD_CC
367
368@@ -608,7 +608,7 @@
369 dnl size==1 case in mpn/generic/mode1o.c, and this shows up in
370 dnl tests/mpz/t-jac.c as a wrong result from mpz_kronecker_ui.
371
372-AC_DEFUN(GMP_GCC_ARM_UMODSI,
373+AC_DEFUN([GMP_GCC_ARM_UMODSI],
374 [AC_MSG_CHECKING([whether ARM gcc unsigned division works])
375 tmp_version=`$1 --version`
376 echo "$tmp_version" >&AC_FD_CC
377@@ -635,7 +635,7 @@
378 dnl This macro is used only once, after finalizing a choice of CC, so the
379 dnl result is cached.
380
381-AC_DEFUN(GMP_GCC_MARCH_PENTIUMPRO,
382+AC_DEFUN([GMP_GCC_MARCH_PENTIUMPRO],
383 [AC_CACHE_CHECK([whether gcc -march=pentiumpro is good],
384 gmp_cv_gcc_march_pentiumpro,
385 [GMP_GCC_VERSION_GE([$1], 2,95,4)
386@@ -659,7 +659,7 @@
387 dnl gets rearranged or rewritten so the ICE doesn't happen then this can be
388 dnl removed.
389
390-AC_DEFUN(GMP_GCC_M68K_OPTIMIZE,
391+AC_DEFUN([GMP_GCC_M68K_OPTIMIZE],
392 [case $host in
393 m68*-*-*)
394 if test $1 = gcc; then
395@@ -681,7 +681,7 @@
396 dnl gcc 2.95 accepts -mabi=32 but it only works on irix5, on irix6 it gives
397 dnl "cc1: The -mabi=32 support does not work yet".
398
399-AC_DEFUN(GMP_GCC_MIPS_O32,
400+AC_DEFUN([GMP_GCC_MIPS_O32],
401 [AC_MSG_CHECKING([whether gcc supports o32])
402 echo 'int x;' >conftest.c
403 echo "$1 -mabi=32 -c conftest.c" >&AC_FD_CC
404@@ -716,7 +716,7 @@
405 dnl watch for that and decide against the option in that case, to avoid
406 dnl confusing the user.
407
408-AC_DEFUN(GMP_GCC_NO_CPP_PRECOMP,
409+AC_DEFUN([GMP_GCC_NO_CPP_PRECOMP],
410 [if test "$ccbase" = gcc; then
411 AC_MSG_CHECKING([compiler $2 $3 -no-cpp-precomp])
412 result=no
413@@ -752,7 +752,7 @@
414 dnl This is intended for use on alpha, since only recent versions of gas
415 dnl accept -mev67, but there's nothing here that's alpha specific.
416
417-AC_DEFUN(GMP_GCC_WA_MCPU,
418+AC_DEFUN([GMP_GCC_WA_MCPU],
419 [AC_MSG_CHECKING([assembler $1 $2])
420 result=no
421 cat >conftest.c <<EOF
422@@ -783,7 +783,7 @@
423 dnl This test is designed to be run repeatedly with different cxx/cxxflags
424 dnl selections, so the result is not cached.
425
426-AC_DEFUN(GMP_PROG_CXX_WORKS,
427+AC_DEFUN([GMP_PROG_CXX_WORKS],
428 [AC_MSG_CHECKING([C++ compiler $1])
429 cat >conftest.cc <<EOF
430 #include <iostream>
431@@ -817,7 +817,7 @@
432 dnl FIXME: The generated config.m4 doesn't get recreated by config.status.
433 dnl Maybe the relevant "echo"s should go through AC_CONFIG_COMMANDS.
434
435-AC_DEFUN(GMP_INIT,
436+AC_DEFUN([GMP_INIT],
437 [ifelse([$1], , gmp_configm4=config.m4, gmp_configm4="[$1]")
438 gmp_tmpconfigm4=cnfm4.tmp
439 gmp_tmpconfigm4i=cnfm4i.tmp
440@@ -834,7 +834,9 @@
441 echo ["define(<CONFIG_TOP_SRCDIR>,<\`$tmp'>)"] >>$gmp_tmpconfigm4
442
443 # All CPUs use asm-defs.m4
444-echo ["include(CONFIG_TOP_SRCDIR\`/mpn/asm-defs.m4')"] >>$gmp_tmpconfigm4i
445+echo -n ["include("] >>$gmp_tmpconfigm4i
446+echo -n ["CONFIG_TOP_SRCDIR\`/mpn/asm-defs.m4'"] >>$gmp_tmpconfigm4i
447+echo [")"] >>$gmp_tmpconfigm4i
448 ])
449
450
451@@ -855,7 +857,7 @@
452 dnl having a whole file as a macro argument would overflow the string space
453 dnl on BSD m4.
454
455-AC_DEFUN(GMP_FINISH,
456+AC_DEFUN([GMP_FINISH],
457 [AC_REQUIRE([GMP_INIT])
458 echo "creating $gmp_configm4"
459 echo ["d""nl $gmp_configm4. Generated automatically by configure."] > $gmp_configm4
460@@ -889,7 +891,7 @@
461 dnl GMP_INCLUDE_MPN(`x86/x86-defs.m4')
462 dnl
463
464-AC_DEFUN(GMP_INCLUDE_MPN,
465+AC_DEFUN([GMP_INCLUDE_MPN],
466 [AC_REQUIRE([GMP_INIT])
467 echo ["include_mpn(\`$1')"] >> $gmp_tmpconfigm4i
468 ])
469@@ -905,7 +907,7 @@
470 dnl create file config.m4. config.m4 uses `<' and '>' as quote characters
471 dnl for all defines.
472
473-AC_DEFUN(GMP_DEFINE,
474+AC_DEFUN([GMP_DEFINE],
475 [AC_REQUIRE([GMP_INIT])
476 echo ['define(<$1>, <$2>)'] >>ifelse([$3], [POST],
477 $gmp_tmpconfigm4p, $gmp_tmpconfigm4)
478@@ -920,7 +922,7 @@
479 dnl directives inserted by GMP_INCLUDE. Don't forget to invoke GMP_FINISH
480 dnl to create file config.m4.
481
482-AC_DEFUN(GMP_DEFINE_RAW,
483+AC_DEFUN([GMP_DEFINE_RAW],
484 [AC_REQUIRE([GMP_INIT])
485 echo [$1] >> ifelse([$2], [POST], $gmp_tmpconfigm4p, $gmp_tmpconfigm4)
486 ])
487@@ -938,7 +940,7 @@
488 dnl This is not unlike AC_TRY_COMPILE, but there's no default includes or
489 dnl anything in "asm-code", everything wanted must be given explicitly.
490
491-AC_DEFUN(GMP_TRY_ASSEMBLE,
492+AC_DEFUN([GMP_TRY_ASSEMBLE],
493 [cat >conftest.s <<EOF
494 [$1]
495 EOF
496@@ -960,7 +962,7 @@
497 dnl --------------------
498 dnl Should a label have a colon or not?
499
500-AC_DEFUN(GMP_ASM_LABEL_SUFFIX,
501+AC_DEFUN([GMP_ASM_LABEL_SUFFIX],
502 [AC_CACHE_CHECK([what assembly label suffix to use],
503 gmp_cv_asm_label_suffix,
504 [case $host in
505@@ -984,7 +986,7 @@
506 dnl in particular that grepping doesn't work with SunOS 4 native grep since
507 dnl that grep seems to have trouble with '\0's in files.
508
509-AC_DEFUN(GMP_ASM_UNDERSCORE,
510+AC_DEFUN([GMP_ASM_UNDERSCORE],
511 [AC_REQUIRE([GMP_ASM_TEXT])
512 AC_REQUIRE([GMP_ASM_GLOBL])
513 AC_REQUIRE([GMP_ASM_LABEL_SUFFIX])
514@@ -1045,7 +1047,7 @@
515 dnl -----------------
516 dnl Is parameter to `.align' logarithmic?
517
518-AC_DEFUN(GMP_ASM_ALIGN_LOG,
519+AC_DEFUN([GMP_ASM_ALIGN_LOG],
520 [AC_REQUIRE([GMP_ASM_GLOBL])
521 AC_REQUIRE([GMP_ASM_DATA])
522 AC_REQUIRE([GMP_ASM_LABEL_SUFFIX])
523@@ -1103,7 +1105,7 @@
524 dnl The warning from solaris 2.8 is supressed to stop anyone worrying that
525 dnl something might be wrong.
526
527-AC_DEFUN(GMP_ASM_ALIGN_FILL_0x90,
528+AC_DEFUN([GMP_ASM_ALIGN_FILL_0x90],
529 [AC_REQUIRE([GMP_ASM_TEXT])
530 AC_CACHE_CHECK([if the .align directive accepts an 0x90 fill in .text],
531 gmp_cv_asm_align_fill_0x90,
532@@ -1127,7 +1129,7 @@
533 dnl GMP_ASM_TEXT
534 dnl ------------
535
536-AC_DEFUN(GMP_ASM_TEXT,
537+AC_DEFUN([GMP_ASM_TEXT],
538 [AC_CACHE_CHECK([how to switch to text section],
539 gmp_cv_asm_text,
540 [case $host in
541@@ -1144,7 +1146,7 @@
542 dnl ------------
543 dnl Can we say `.data'?
544
545-AC_DEFUN(GMP_ASM_DATA,
546+AC_DEFUN([GMP_ASM_DATA],
547 [AC_CACHE_CHECK([how to switch to data section],
548 gmp_cv_asm_data,
549 [case $host in
550@@ -1172,7 +1174,7 @@
551 dnl where foo is the object file. Might need to check for that if we use
552 dnl RODATA there.
553
554-AC_DEFUN(GMP_ASM_RODATA,
555+AC_DEFUN([GMP_ASM_RODATA],
556 [AC_REQUIRE([GMP_ASM_TEXT])
557 AC_REQUIRE([GMP_ASM_DATA])
558 AC_REQUIRE([GMP_ASM_LABEL_SUFFIX])
559@@ -1229,7 +1231,7 @@
560 dnl -------------
561 dnl Can we say `.global'?
562
563-AC_DEFUN(GMP_ASM_GLOBL,
564+AC_DEFUN([GMP_ASM_GLOBL],
565 [AC_CACHE_CHECK([how to export a symbol],
566 gmp_cv_asm_globl,
567 [case $host in
568@@ -1245,7 +1247,7 @@
569 dnl ------------------
570 dnl Do we need something after `.global symbol'?
571
572-AC_DEFUN(GMP_ASM_GLOBL_ATTR,
573+AC_DEFUN([GMP_ASM_GLOBL_ATTR],
574 [AC_CACHE_CHECK([if the export directive needs an attribute],
575 gmp_cv_asm_globl_attr,
576 [case $host in
577@@ -1276,7 +1278,7 @@
578 dnl letting the problem go unnoticed. tests/mpn/t-asmtype.c aims to check
579 dnl for it.
580
581-AC_DEFUN(GMP_ASM_TYPE,
582+AC_DEFUN([GMP_ASM_TYPE],
583 [AC_CACHE_CHECK([for assembler .type directive],
584 gmp_cv_asm_type,
585 [gmp_cv_asm_type=
586@@ -1298,7 +1300,7 @@
587 dnl ------------
588 dnl Can we say `.size'?
589
590-AC_DEFUN(GMP_ASM_SIZE,
591+AC_DEFUN([GMP_ASM_SIZE],
592 [AC_CACHE_CHECK([for assembler .size directive],
593 gmp_cv_asm_size,
594 [gmp_cv_asm_size=
595@@ -1341,7 +1343,7 @@
596 dnl HP-UX nm prints an error message (though seems to give a 0 exit) if
597 dnl there's no symbols at all in an object file, hence the use of "dummy".
598
599-AC_DEFUN(GMP_ASM_LSYM_PREFIX,
600+AC_DEFUN([GMP_ASM_LSYM_PREFIX],
601 [AC_REQUIRE([GMP_ASM_LABEL_SUFFIX])
602 AC_REQUIRE([GMP_PROG_NM])
603 AC_CACHE_CHECK([what prefix to use for a local label],
604@@ -1386,7 +1388,7 @@
605 dnl -----------
606 dnl How to define a 32-bit word.
607
608-AC_DEFUN(GMP_ASM_W32,
609+AC_DEFUN([GMP_ASM_W32],
610 [AC_REQUIRE([GMP_ASM_DATA])
611 AC_REQUIRE([GMP_ASM_GLOBL])
612 AC_REQUIRE([GMP_ASM_LABEL_SUFFIX])
613@@ -1443,7 +1445,7 @@
614 dnl %mm1, %mm0"). It seems more trouble than it's worth to work around
615 dnl this in the code, so just detect and reject.
616
617-AC_DEFUN(GMP_ASM_X86_MMX,
618+AC_DEFUN([GMP_ASM_X86_MMX],
619 [AC_CACHE_CHECK([if the assembler knows about MMX instructions],
620 gmp_cv_asm_x86_mmx,
621 [GMP_TRY_ASSEMBLE(
622@@ -1495,7 +1497,7 @@
623 dnl GMP_ASM_X86_SHLDL_CL
624 dnl --------------------
625
626-AC_DEFUN(GMP_ASM_X86_SHLDL_CL,
627+AC_DEFUN([GMP_ASM_X86_SHLDL_CL],
628 [AC_REQUIRE([GMP_ASM_TEXT])
629 AC_CACHE_CHECK([if the assembler takes cl with shldl],
630 gmp_cv_asm_x86_shldl_cl,
631@@ -1522,7 +1524,7 @@
632 dnl it's all GMP_ASM_TEXT gives currently. Actually ".text" probably isn't
633 dnl needed at all, at least for just checking instruction syntax.
634
635-AC_DEFUN(GMP_ASM_X86_SSE2,
636+AC_DEFUN([GMP_ASM_X86_SSE2],
637 [AC_CACHE_CHECK([if the assembler knows about SSE2 instructions],
638 gmp_cv_asm_x86_sse2,
639 [GMP_TRY_ASSEMBLE(
640@@ -1585,7 +1587,7 @@
641 dnl to get two variables (mcount_nonpic_reg and mcount_nonpic_call say) set
642 dnl from one block of commands?
643
644-AC_DEFUN(GMP_ASM_X86_MCOUNT,
645+AC_DEFUN([GMP_ASM_X86_MCOUNT],
646 [AC_REQUIRE([AC_ENABLE_SHARED])
647 AC_REQUIRE([AC_PROG_LIBTOOL])
648 AC_MSG_CHECKING([how to call x86 mcount])
649@@ -1655,7 +1657,7 @@
650 dnl instruction. It takes registers without "%", but a single operand
651 dnl "clrl %d0" only gives a warning, not an error.
652
653-AC_DEFUN(GMP_ASM_M68K_INSTRUCTION,
654+AC_DEFUN([GMP_ASM_M68K_INSTRUCTION],
655 [AC_REQUIRE([GMP_ASM_TEXT])
656 AC_CACHE_CHECK([assembler instruction and register style],
657 gmp_cv_asm_m68k_instruction,
658@@ -1684,7 +1686,7 @@
659 dnl GMP_ASM_M68K_ADDRESSING
660 dnl -----------------------
661
662-AC_DEFUN(GMP_ASM_M68K_ADDRESSING,
663+AC_DEFUN([GMP_ASM_M68K_ADDRESSING],
664 [AC_REQUIRE([GMP_ASM_TEXT])
665 AC_REQUIRE([GMP_ASM_M68K_INSTRUCTION])
666 AC_CACHE_CHECK([assembler addressing style],
667@@ -1721,7 +1723,7 @@
668 dnl 16-bits. This applies to the conditional branches "bcc" etc too.
669 dnl However "dbcc" etc on gas are already only as big as they need to be.
670
671-AC_DEFUN(GMP_ASM_M68K_BRANCHES,
672+AC_DEFUN([GMP_ASM_M68K_BRANCHES],
673 [AC_REQUIRE([GMP_ASM_TEXT])
674 AC_CACHE_CHECK([assembler shortest branches],
675 gmp_cv_asm_m68k_branches,
676@@ -1752,7 +1754,7 @@
677 dnl See also mpn/powerpc32/powerpc-defs.m4 which uses the result of this
678 dnl test.
679
680-AC_DEFUN(GMP_ASM_POWERPC_R_REGISTERS,
681+AC_DEFUN([GMP_ASM_POWERPC_R_REGISTERS],
682 [AC_REQUIRE([GMP_ASM_TEXT])
683 AC_CACHE_CHECK([if the assembler needs r on registers],
684 gmp_cv_asm_powerpc_r_registers,
685@@ -1777,7 +1779,7 @@
686 dnl
687 dnl See also mpn/sparc32/sparc-defs.m4 which uses the result of this test.
688
689-AC_DEFUN(GMP_ASM_SPARC_REGISTER,
690+AC_DEFUN([GMP_ASM_SPARC_REGISTER],
691 [AC_REQUIRE([GMP_ASM_TEXT])
692 AC_CACHE_CHECK([if the assembler accepts ".register"],
693 gmp_cv_asm_sparc_register,
694@@ -1795,7 +1797,7 @@
695 dnl GMP_C_ATTRIBUTE_CONST
696 dnl ---------------------
697
698-AC_DEFUN(GMP_C_ATTRIBUTE_CONST,
699+AC_DEFUN([GMP_C_ATTRIBUTE_CONST],
700 [AC_CACHE_CHECK([whether gcc __attribute__ ((const)) works],
701 gmp_cv_c_attribute_const,
702 [AC_TRY_COMPILE([int foo (int x) __attribute__ ((const));], ,
703@@ -1814,7 +1816,7 @@
704 dnl it's ignored. Pretend it doesn't exist in this case, to avoid that
705 dnl warning.
706
707-AC_DEFUN(GMP_C_ATTRIBUTE_MALLOC,
708+AC_DEFUN([GMP_C_ATTRIBUTE_MALLOC],
709 [AC_CACHE_CHECK([whether gcc __attribute__ ((malloc)) works],
710 gmp_cv_c_attribute_malloc,
711 [cat >conftest.c <<EOF
712@@ -1844,7 +1846,7 @@
713 dnl --------------------
714 dnl Introduced in gcc 2.2, but perhaps not in all Apple derived versions.
715
716-AC_DEFUN(GMP_C_ATTRIBUTE_MODE,
717+AC_DEFUN([GMP_C_ATTRIBUTE_MODE],
718 [AC_CACHE_CHECK([whether gcc __attribute__ ((mode (XX))) works],
719 gmp_cv_c_attribute_mode,
720 [AC_TRY_COMPILE([typedef int SItype __attribute__ ((mode (SI)));], ,
721@@ -1860,7 +1862,7 @@
722 dnl GMP_C_ATTRIBUTE_NORETURN
723 dnl ------------------------
724
725-AC_DEFUN(GMP_C_ATTRIBUTE_NORETURN,
726+AC_DEFUN([GMP_C_ATTRIBUTE_NORETURN],
727 [AC_CACHE_CHECK([whether gcc __attribute__ ((noreturn)) works],
728 gmp_cv_c_attribute_noreturn,
729 [AC_TRY_COMPILE([void foo (int x) __attribute__ ((noreturn));], ,
730@@ -1887,7 +1889,7 @@
731 dnl used doesn't have functions or anything, so even an "old" awk should
732 dnl suffice.
733
734-AC_DEFUN(GMP_C_DOUBLE_FORMAT,
735+AC_DEFUN([GMP_C_DOUBLE_FORMAT],
736 [AC_REQUIRE([AC_PROG_CC])
737 AC_REQUIRE([AC_PROG_AWK])
738 AC_CACHE_CHECK([format of `double' floating point],
739@@ -2089,7 +2091,7 @@
740 dnl
741 dnl FIXME: Hopefully autoconf will do this extra itself one day.
742
743-AC_DEFUN(GMP_C_INLINE,
744+AC_DEFUN([GMP_C_INLINE],
745 [AC_CACHE_CHECK([for inline], gmp_cv_c_inline,
746 [gmp_cv_c_inline=no
747 for i in inline __inline__ __inline; do
748@@ -2129,7 +2131,7 @@
749 dnl "yes" is used in the cache variable if plain "restrict" works, to make
750 dnl the configure message look nicer.
751
752-AC_DEFUN(GMP_C_RESTRICT,
753+AC_DEFUN([GMP_C_RESTRICT],
754 [AC_CACHE_CHECK([for restrict], gmp_cv_c_restrict,
755 [gmp_cv_c_restrict=no
756 for r in restrict __restrict__ __restrict; do
757@@ -2178,7 +2180,7 @@
758 dnl ulongs with bits=8*sizeof, so it's academic. Strange systems can
759 dnl always have the right values put in gmp-mparam.h explicitly.
760
761-AC_DEFUN(GMP_C_SIZES,
762+AC_DEFUN([GMP_C_SIZES],
763 [BITS_PER_MP_LIMB=[`sed -n 's/^#define BITS_PER_MP_LIMB[ ][ ]*\([0-9]*\).*$/\1/p' $gmp_mparam_source`]
764 if test -n "$BITS_PER_MP_LIMB" \
765 && grep "^#define BYTES_PER_MP_LIMB" $gmp_mparam_source >/dev/null; then : ;
766@@ -2199,7 +2201,7 @@
767 fi
768 fi
769 AC_SUBST(BITS_PER_MP_LIMB)
770-define([GMP_INCLUDE_GMP_H_BITS_PER_MP_LIMB],
771+define([[GMP_INCLUDE_GMP_H_BITS_PER_MP_LIMB]],
772 [[#define __GMP_BITS_PER_MP_LIMB $BITS_PER_MP_LIMB
773 #define GMP_LIMB_BITS $BITS_PER_MP_LIMB]])
774
775@@ -2232,7 +2234,7 @@
776 dnl or very likely by the setups for _PROTO in gmp.h. On the other hand
777 dnl this test is nice and direct, being what we're going to actually use.
778
779-AC_DEFUN(GMP_C_STDARG,
780+AC_DEFUN([GMP_C_STDARG],
781 [AC_CACHE_CHECK([whether <stdarg.h> exists and works],
782 gmp_cv_c_stdarg,
783 [AC_TRY_COMPILE(
784@@ -2261,7 +2263,7 @@
785 dnl available, and also to use gmp-impl.h for the conditionals detecting
786 dnl compiler builtin alloca's.
787
788-AC_DEFUN(GMP_FUNC_ALLOCA,
789+AC_DEFUN([GMP_FUNC_ALLOCA],
790 [AC_REQUIRE([GMP_HEADER_ALLOCA])
791 AC_CACHE_CHECK([for alloca (via gmp-impl.h)],
792 gmp_cv_func_alloca,
793@@ -2278,7 +2280,7 @@
794 fi
795 ])
796
797-AC_DEFUN(GMP_HEADER_ALLOCA,
798+AC_DEFUN([GMP_HEADER_ALLOCA],
799 [# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
800 # for constant arguments. Useless!
801 AC_CACHE_CHECK([for working alloca.h],
802@@ -2299,7 +2301,7 @@
803 dnl Decide what to do about --enable-alloca from the user.
804 dnl This is a macro so it can require GMP_FUNC_ALLOCA.
805
806-AC_DEFUN(GMP_OPTION_ALLOCA,
807+AC_DEFUN([GMP_OPTION_ALLOCA],
808 [AC_REQUIRE([GMP_FUNC_ALLOCA])
809 AC_CACHE_CHECK([how to allocate temporary memory],
810 gmp_cv_option_alloca,
811@@ -2355,7 +2357,7 @@
812 dnl
813 dnl FIXME: Run a program to try this, when doing a native build.
814
815-AC_DEFUN(GMP_FUNC_SSCANF_WRITABLE_INPUT,
816+AC_DEFUN([GMP_FUNC_SSCANF_WRITABLE_INPUT],
817 [AC_CACHE_CHECK([whether sscanf needs writable input],
818 gmp_cv_func_sscanf_writable_input,
819 [case $host in
820@@ -2391,7 +2393,7 @@
821 dnl not sure which 2.0.x does which), but still puts the correct null
822 dnl terminated result into the buffer.
823
824-AC_DEFUN(GMP_FUNC_VSNPRINTF,
825+AC_DEFUN([GMP_FUNC_VSNPRINTF],
826 [AC_REQUIRE([GMP_C_STDARG])
827 AC_CHECK_FUNC(vsnprintf,
828 [gmp_vsnprintf_exists=yes],
829@@ -2472,7 +2474,7 @@
830 dnl ----------
831 dnl Check whether gmp.h recognises the compiler as ANSI capable.
832
833-AC_DEFUN(GMP_H_ANSI,
834+AC_DEFUN([GMP_H_ANSI],
835 [AC_REQUIRE([AC_PROG_CC_STDC])
836 case $ac_cv_prog_cc_stdc in
837 no)
838@@ -2495,7 +2497,7 @@
839 dnl If the compiler has an "inline" of some sort, check whether the
840 dnl #ifdef's in gmp.h recognise it.
841
842-AC_DEFUN(GMP_H_EXTERN_INLINE,
843+AC_DEFUN([GMP_H_EXTERN_INLINE],
844 [AC_REQUIRE([GMP_C_INLINE])
845 case $gmp_cv_c_inline in
846 no) ;;
847@@ -2522,7 +2524,7 @@
848 dnl Check whether the #ifdef's in gmp.h recognise when stdio.h has been
849 dnl included to get FILE.
850
851-AC_DEFUN(GMP_H_HAVE_FILE,
852+AC_DEFUN([GMP_H_HAVE_FILE],
853 [AC_TRY_COMPILE(
854 [#include <stdio.h>]
855 GMP_INCLUDE_GMP_H
856@@ -2539,7 +2541,7 @@
857 dnl Check whether the #ifdef's in gmp-impl.h recognise IEEE format and
858 dnl endianness.
859
860-AC_DEFUN(GMP_IMPL_H_IEEE_FLOATS,
861+AC_DEFUN([GMP_IMPL_H_IEEE_FLOATS],
862 [case $host in
863 vax*-*-*)
864 # not IEEE (neither D nor G formats are IEEE)
diff --git a/meta/packages/gmp/gmp-4.1.2/gcc-compile.patch b/meta/packages/gmp/gmp-4.1.2/gcc-compile.patch
deleted file mode 100644
index 4d880123e9..0000000000
--- a/meta/packages/gmp/gmp-4.1.2/gcc-compile.patch
+++ /dev/null
@@ -1,72 +0,0 @@
1 diff -Naur gmp-4.1.2.orig/mpf/ceilfloor.c gmp-4.1.2/mpf/ceilfloor.c
2 --- gmp-4.1.2.orig/mpf/ceilfloor.c 2001-05-10 22:31:13.000000000 +0000
3 +++ gmp-4.1.2/mpf/ceilfloor.c 2004-04-25 03:48:20.823016075 +0000
4 @@ -31,7 +31,7 @@
5 static void __gmpf_ceil_or_floor _PROTO ((REGPARM_2_1 (mpf_ptr r, mpf_srcptr u, int dir))) REGPARM_ATTR (1);
6 #define mpf_ceil_or_floor(r,u,dir) __gmpf_ceil_or_floor (REGPARM_2_1 (r, u, dir))
7
8 -static void
9 +REGPARM_ATTR (1) static void
10 mpf_ceil_or_floor (mpf_ptr r, mpf_srcptr u, int dir)
11 {
12 mp_ptr rp, up, p;
13 diff -Naur gmp-4.1.2.orig/mpq/aors.c gmp-4.1.2/mpq/aors.c
14 --- gmp-4.1.2.orig/mpq/aors.c 2001-09-01 22:41:02.000000000 +0000
15 +++ gmp-4.1.2/mpq/aors.c 2004-04-25 03:48:20.826015531 +0000
16 @@ -27,7 +27,7 @@
17 static void __gmpq_aors _PROTO ((REGPARM_3_1 (mpq_ptr w, mpq_srcptr x, mpq_srcptr y, void (*fun) _PROTO ((mpz_ptr, mpz_srcptr, mpz_srcptr))))) REGPARM_ATTR (1);
18 #define mpq_aors(w,x,y,fun) __gmpq_aors (REGPARM_3_1 (w, x, y, fun))
19
20 -static void
21 +REGPARM_ATTR (1) static void
22 mpq_aors (mpq_ptr rop, mpq_srcptr op1, mpq_srcptr op2,
23 void (*fun) _PROTO ((mpz_ptr, mpz_srcptr, mpz_srcptr)))
24 {
25 diff -Naur gmp-4.1.2.orig/mpz/aorsmul.c gmp-4.1.2/mpz/aorsmul.c
26 --- gmp-4.1.2.orig/mpz/aorsmul.c 2001-05-02 22:30:07.000000000 +0000
27 +++ gmp-4.1.2/mpz/aorsmul.c 2004-04-25 03:48:20.828015169 +0000
28 @@ -39,7 +39,7 @@
29 static void __gmpz_aorsmul _PROTO ((REGPARM_3_1 (mpz_ptr w, mpz_srcptr x, mpz_srcptr y, mp_size_t sub))) REGPARM_ATTR (1);
30 #define mpz_aorsmul(w,x,y,sub) __gmpz_aorsmul (REGPARM_3_1 (w, x, y, sub))
31
32 -static void
33 +REGPARM_ATTR (1) static void
34 mpz_aorsmul (mpz_ptr w, mpz_srcptr x, mpz_srcptr y, mp_size_t sub)
35 {
36 mp_size_t xsize, ysize, tsize, wsize, wsize_signed;
37 diff -Naur gmp-4.1.2.orig/mpz/aorsmul_i.c gmp-4.1.2/mpz/aorsmul_i.c
38 --- gmp-4.1.2.orig/mpz/aorsmul_i.c 2002-05-14 16:59:49.000000000 +0000
39 +++ gmp-4.1.2/mpz/aorsmul_i.c 2004-04-25 03:49:07.962471904 +0000
40 @@ -57,7 +57,7 @@
41 twos-complement negative y doesn't work, because it effectively adds an
42 extra x * 2^BITS_PER_MP_LIMB. */
43
44 -void
45 +REGPARM_ATTR (1) void
46 mpz_aorsmul_1 (mpz_ptr w, mpz_srcptr x, mp_limb_t y, mp_size_t sub)
47 {
48 mp_size_t xsize, wsize, wsize_signed, new_wsize, min_size, dsize;
49 diff -Naur gmp-4.1.2.orig/mpz/cfdiv_q_2exp.c gmp-4.1.2/mpz/cfdiv_q_2exp.c
50 --- gmp-4.1.2.orig/mpz/cfdiv_q_2exp.c 2002-02-08 21:55:17.000000000 +0000
51 +++ gmp-4.1.2/mpz/cfdiv_q_2exp.c 2004-04-25 03:48:20.830014806 +0000
52 @@ -29,7 +29,7 @@
53 static void __gmpz_cfdiv_q_2exp _PROTO ((REGPARM_3_1 (mpz_ptr w, mpz_srcptr u, unsigned long cnt, int dir))) REGPARM_ATTR (1);
54 #define cfdiv_q_2exp(w,u,cnt,dir) __gmpz_cfdiv_q_2exp (REGPARM_3_1 (w,u,cnt,dir))
55
56 -static void
57 +REGPARM_ATTR (1) static void
58 cfdiv_q_2exp (mpz_ptr w, mpz_srcptr u, unsigned long cnt, int dir)
59 {
60 mp_size_t wsize, usize, abs_usize, limb_cnt, i;
61 diff -Naur gmp-4.1.2.orig/mpz/cfdiv_r_2exp.c gmp-4.1.2/mpz/cfdiv_r_2exp.c
62 --- gmp-4.1.2.orig/mpz/cfdiv_r_2exp.c 2002-04-18 16:48:25.000000000 +0000
63 +++ gmp-4.1.2/mpz/cfdiv_r_2exp.c 2004-04-25 03:48:20.832014444 +0000
64 @@ -32,7 +32,7 @@
65 static void __gmpz_cfdiv_r_2exp _PROTO ((REGPARM_3_1 (mpz_ptr w, mpz_srcptr u, unsigned long cnt, int dir))) REGPARM_ATTR (1);
66 #define cfdiv_r_2exp(w,u,cnt,dir) __gmpz_cfdiv_r_2exp (REGPARM_3_1 (w, u, cnt, dir))
67
68 -static void
69 +REGPARM_ATTR (1) static void
70 cfdiv_r_2exp (mpz_ptr w, mpz_srcptr u, unsigned long cnt, int dir)
71 {
72 mp_size_t usize, abs_usize, limb_cnt, i;
diff --git a/meta/packages/gmp/gmp-4.1.4/configure.patch b/meta/packages/gmp/gmp-4.1.4/configure.patch
deleted file mode 100644
index 4b6c4ec636..0000000000
--- a/meta/packages/gmp/gmp-4.1.4/configure.patch
+++ /dev/null
@@ -1,837 +0,0 @@
1--- gmp-1.4.4/acinclude.m4.orig 2004-09-21 15:03:09.000000000 +0200
2+++ gmp-1.4.4/acinclude.m4 2005-07-18 01:09:00.000000000 +0200
3@@ -21,10 +21,10 @@
4 dnl MA 02111-1307, USA.
5
6
7-define(X86_PATTERN,
8+define([X86_PATTERN],
9 [[i?86*-*-* | k[5-8]*-*-* | pentium*-*-* | athlon-*-* | viac3*-*-*]])
10
11-define(POWERPC64_PATTERN,
12+define([POWERPC64_PATTERN],
13 [[powerpc64-*-* | powerpc64le-*-* | powerpc620-*-* | powerpc630-*-*]])
14
15
16@@ -32,7 +32,7 @@
17 dnl ----------------------
18 dnl Strip entries */subdir from $path.
19
20-define(GMP_STRIP_PATH,
21+define([GMP_STRIP_PATH],
22 [tmp_path=
23 for i in $path; do
24 case $i in
25@@ -53,7 +53,7 @@
26 dnl GMP_INCLUDE_GMP_H_BITS_PER_MP_LIMB starts as a dummy, but gets
27 dnl redefined in GMP_C_SIZES when the right value is known.
28
29-define(GMP_INCLUDE_GMP_H,
30+define([GMP_INCLUDE_GMP_H],
31 [[#define __GMP_WITHIN_CONFIGURE 1 /* ignore template stuff */
32 #define GMP_NAIL_BITS $GMP_NAIL_BITS]
33 GMP_INCLUDE_GMP_H_BITS_PER_MP_LIMB
34@@ -61,7 +61,7 @@
35 #include "$srcdir/gmp-h.in"]
36 ])
37
38-define(GMP_INCLUDE_GMP_H_BITS_PER_MP_LIMB,
39+define([GMP_INCLUDE_GMP_H_BITS_PER_MP_LIMB],
40 [[#define __GMP_BITS_PER_MP_LIMB 123 /* dummy for GMP_NUMB_BITS etc */
41 #define GMP_LIMB_BITS 123]])
42
43@@ -72,7 +72,7 @@
44 dnl FILE. The regexps here aren't very rugged, but are enough for gmp.
45 dnl /dev/null as a parameter prevents a hang if $2 is accidentally omitted.
46
47-define(GMP_HEADER_GETVAL,
48+define([GMP_HEADER_GETVAL],
49 [patsubst(patsubst(
50 esyscmd([grep "^#define $1 " $2 /dev/null 2>/dev/null]),
51 [^.*$1[ ]+],[]),
52@@ -86,7 +86,7 @@
53 dnl autoconf time. Two digits like 3.0 if patchlevel <= 0, or three digits
54 dnl like 3.0.1 if patchlevel > 0.
55
56-define(GMP_VERSION,
57+define([GMP_VERSION],
58 [GMP_HEADER_GETVAL(__GNU_MP_VERSION,gmp-h.in)[]dnl
59 .GMP_HEADER_GETVAL(__GNU_MP_VERSION_MINOR,gmp-h.in)[]dnl
60 ifelse(m4_eval(GMP_HEADER_GETVAL(__GNU_MP_VERSION_PATCHLEVEL,gmp-h.in) > 0),1,
61@@ -97,13 +97,13 @@
62 dnl ------------------------------
63 dnl Setup an AC_SUBST of HAVE_FUNC_01 for each argument.
64
65-AC_DEFUN(GMP_SUBST_CHECK_FUNCS,
66+AC_DEFUN([GMP_SUBST_CHECK_FUNCS],
67 [m4_if([$1],,,
68 [_GMP_SUBST_CHECK_FUNCS(ac_cv_func_[$1],HAVE_[]m4_translit([$1],[a-z],[A-Z])_01)
69 GMP_SUBST_CHECK_FUNCS(m4_shift($@))])])
70
71 dnl Called: _GMP_SUBST_CHECK_FUNCS(cachvar,substvar)
72-AC_DEFUN(_GMP_SUBST_CHECK_FUNCS,
73+AC_DEFUN([_GMP_SUBST_CHECK_FUNCS],
74 [case $[$1] in
75 yes) AC_SUBST([$2],1) ;;
76 no) [$2]=0 ;;
77@@ -115,14 +115,14 @@
78 dnl ----------------------------------
79 dnl Setup an AC_SUBST of HAVE_FOO_H_01 for each argument.
80
81-AC_DEFUN(GMP_SUBST_CHECK_HEADERS,
82+AC_DEFUN([GMP_SUBST_CHECK_HEADERS],
83 [m4_if([$1],,,
84 [_GMP_SUBST_CHECK_HEADERS(ac_cv_header_[]m4_translit([$1],[./],[__]),
85 HAVE_[]m4_translit([$1],[a-z./],[A-Z__])_01)
86 GMP_SUBST_CHECK_HEADERS(m4_shift($@))])])
87
88 dnl Called: _GMP_SUBST_CHECK_HEADERS(cachvar,substvar)
89-AC_DEFUN(_GMP_SUBST_CHECK_HEADERS,
90+AC_DEFUN([_GMP_SUBST_CHECK_HEADERS],
91 [case $[$1] in
92 yes) AC_SUBST([$2],1) ;;
93 no) [$2]=0 ;;
94@@ -145,12 +145,12 @@
95 dnl would test whether $major.$minor.$subminor is greater than or equal to
96 dnl 10.3.1.
97
98-AC_DEFUN(GMP_COMPARE_GE,
99+AC_DEFUN([GMP_COMPARE_GE],
100 [gmp_compare_ge=no
101 GMP_COMPARE_GE_INTERNAL($@)
102 ])
103
104-AC_DEFUN(GMP_COMPARE_GE_INTERNAL,
105+AC_DEFUN([GMP_COMPARE_GE_INTERNAL],
106 [ifelse(len([$3]),0,
107 [if test -n "$1" && test "$1" -ge $2; then
108 gmp_compare_ge=yes
109@@ -184,7 +184,7 @@
110 dnl for instance to random.o (and others) on vax-dec-ultrix4.5. Naturally
111 dnl a user-selected $AR_FLAGS is left unchanged.
112
113-AC_DEFUN(GMP_PROG_AR,
114+AC_DEFUN([GMP_PROG_AR],
115 [dnl Want to establish $AR before libtool initialization.
116 AC_BEFORE([$0],[AC_PROG_LIBTOOL])
117 gmp_user_AR=$AR
118@@ -212,7 +212,7 @@
119 dnl CC_FOR_BUILD is used without testing. CC_FOR_BUILD is the new name for
120 dnl a build system compiler, see configfsf.guess.
121
122-AC_DEFUN(GMP_PROG_HOST_CC,
123+AC_DEFUN([GMP_PROG_HOST_CC],
124 [AC_BEFORE([$0],[AC_PROG_LIBTOOL])
125 AC_REQUIRE([AC_PROG_CC])
126 AC_CACHE_CHECK([for HOST_CC build system compiler],
127@@ -255,7 +255,7 @@
128 dnl FIXME: This can be removed and just AM_PROG_LEX used, one that macro
129 dnl works properly.
130
131-AC_DEFUN(GMP_PROG_LEX,
132+AC_DEFUN([GMP_PROG_LEX],
133 [AC_REQUIRE([AC_PROG_LEX])
134 if test "$LEX" = :; then
135 LEX=${am_missing_run}flex
136@@ -273,7 +273,7 @@
137 dnl
138 dnl See mpn/asm-defs.m4 for details on the known bad m4s.
139
140-AC_DEFUN(GMP_PROG_M4,
141+AC_DEFUN([GMP_PROG_M4],
142 [AC_ARG_VAR(M4,[m4 macro processor])
143 AC_CACHE_CHECK([for suitable m4],
144 gmp_cv_prog_m4,
145@@ -340,7 +340,7 @@
146 dnl Enhancement: Maybe this could be in GMP_PROG_M4, and attempt to prefer
147 dnl an m4 with a working m4wrap, if it can be found.
148
149-AC_DEFUN(GMP_M4_M4WRAP_SPURIOUS,
150+AC_DEFUN([GMP_M4_M4WRAP_SPURIOUS],
151 [AC_REQUIRE([GMP_PROG_M4])
152 AC_CACHE_CHECK([if m4wrap produces spurious output],
153 gmp_cv_m4_m4wrap_spurious,
154@@ -374,7 +374,7 @@
155 dnl A user-selected $NM is always left unchanged. AC_PROG_NM is still run
156 dnl to get the "checking" message printed though.
157
158-AC_DEFUN(GMP_PROG_NM,
159+AC_DEFUN([GMP_PROG_NM],
160 [dnl Make sure we're the first to call AC_PROG_NM, so our extra flags are
161 dnl used by everyone.
162 AC_BEFORE([$0],[AC_PROG_NM])
163@@ -426,7 +426,7 @@
164 dnl will run is that a plain native "./configure" falls back on ABI=32, but
165 dnl ABI=64 is still available as a cross-compile.
166
167-AC_DEFUN(GMP_PROG_CC_WORKS,
168+AC_DEFUN([GMP_PROG_CC_WORKS],
169 [AC_MSG_CHECKING([compiler $1])
170 cat >conftest.c <<EOF
171
172@@ -481,7 +481,7 @@
173 dnl cache the result. The same "ifndef" style test is used, to avoid
174 dnl problems with syntax checking cpp's used on NeXT and Apple systems.
175
176-AC_DEFUN(GMP_PROG_CC_IS_GNU,
177+AC_DEFUN([GMP_PROG_CC_IS_GNU],
178 [cat >conftest.c <<EOF
179 #ifndef __GNUC__
180 choke me
181@@ -508,7 +508,7 @@
182 dnl there is one then it's well hidden in xlc 3.1 on AIX 4.3, so just grep
183 dnl the man page printed when xlc is invoked with no arguments.
184
185-AC_DEFUN(GMP_PROG_CC_IS_XLC,
186+AC_DEFUN([GMP_PROG_CC_IS_XLC],
187 [gmp_command="$1 2>&1 | grep xlc >/dev/null"
188 if AC_TRY_EVAL(gmp_command); then
189 AC_MSG_CHECKING([whether $1 is xlc])
190@@ -527,7 +527,7 @@
191 dnl This test might be repeated for different compilers, so the result is
192 dnl not cached.
193
194-AC_DEFUN(GMP_HPC_HPPA_2_0,
195+AC_DEFUN([GMP_HPC_HPPA_2_0],
196 [AC_MSG_CHECKING([whether HP compiler $1 is good for 64-bits])
197 # Bad compiler output:
198 # ccom: HP92453-01 G.10.32.05 HP C Compiler
199@@ -571,7 +571,7 @@
200 dnl
201 dnl There's no caching here, so that different CC's can be tested.
202
203-AC_DEFUN(GMP_GCC_VERSION_GE,
204+AC_DEFUN([GMP_GCC_VERSION_GE],
205 [tmp_version=`($1 --version) 2>&AC_FD_CC`
206 echo "$1 --version '$tmp_version'" >&AC_FD_CC
207
208@@ -608,7 +608,7 @@
209 dnl size==1 case in mpn/generic/mode1o.c, and this shows up in
210 dnl tests/mpz/t-jac.c as a wrong result from mpz_kronecker_ui.
211
212-AC_DEFUN(GMP_GCC_ARM_UMODSI,
213+AC_DEFUN([GMP_GCC_ARM_UMODSI],
214 [AC_MSG_CHECKING([whether ARM gcc unsigned division works])
215 tmp_version=`$1 --version`
216 echo "$tmp_version" >&AC_FD_CC
217@@ -635,7 +635,7 @@
218 dnl This macro is used only once, after finalizing a choice of CC, so the
219 dnl result is cached.
220
221-AC_DEFUN(GMP_GCC_MARCH_PENTIUMPRO,
222+AC_DEFUN([GMP_GCC_MARCH_PENTIUMPRO],
223 [AC_CACHE_CHECK([whether gcc -march=pentiumpro is good],
224 gmp_cv_gcc_march_pentiumpro,
225 [GMP_GCC_VERSION_GE([$1], 2,95,4)
226@@ -659,7 +659,7 @@
227 dnl gets rearranged or rewritten so the ICE doesn't happen then this can be
228 dnl removed.
229
230-AC_DEFUN(GMP_GCC_M68K_OPTIMIZE,
231+AC_DEFUN([GMP_GCC_M68K_OPTIMIZE],
232 [case $host in
233 m68*-*-*)
234 if test $1 = gcc; then
235@@ -681,7 +681,7 @@
236 dnl gcc 2.95 accepts -mabi=32 but it only works on irix5, on irix6 it gives
237 dnl "cc1: The -mabi=32 support does not work yet".
238
239-AC_DEFUN(GMP_GCC_MIPS_O32,
240+AC_DEFUN([GMP_GCC_MIPS_O32],
241 [AC_MSG_CHECKING([whether gcc supports o32])
242 echo 'int x;' >conftest.c
243 echo "$1 -mabi=32 -c conftest.c" >&AC_FD_CC
244@@ -716,7 +716,7 @@
245 dnl watch for that and decide against the option in that case, to avoid
246 dnl confusing the user.
247
248-AC_DEFUN(GMP_GCC_NO_CPP_PRECOMP,
249+AC_DEFUN([GMP_GCC_NO_CPP_PRECOMP],
250 [if test "$ccbase" = gcc; then
251 AC_MSG_CHECKING([compiler $2 $3 -no-cpp-precomp])
252 result=no
253@@ -752,7 +752,7 @@
254 dnl This is intended for use on alpha, since only recent versions of gas
255 dnl accept -mev67, but there's nothing here that's alpha specific.
256
257-AC_DEFUN(GMP_GCC_WA_MCPU,
258+AC_DEFUN([GMP_GCC_WA_MCPU],
259 [AC_MSG_CHECKING([assembler $1 $2])
260 result=no
261 cat >conftest.c <<EOF
262@@ -783,7 +783,7 @@
263 dnl This test is designed to be run repeatedly with different cxx/cxxflags
264 dnl selections, so the result is not cached.
265
266-AC_DEFUN(GMP_PROG_CXX_WORKS,
267+AC_DEFUN([GMP_PROG_CXX_WORKS],
268 [AC_MSG_CHECKING([C++ compiler $1])
269 cat >conftest.cc <<EOF
270 #include <iostream>
271@@ -817,7 +817,7 @@
272 dnl FIXME: The generated config.m4 doesn't get recreated by config.status.
273 dnl Maybe the relevant "echo"s should go through AC_CONFIG_COMMANDS.
274
275-AC_DEFUN(GMP_INIT,
276+AC_DEFUN([GMP_INIT],
277 [ifelse([$1], , gmp_configm4=config.m4, gmp_configm4="[$1]")
278 gmp_tmpconfigm4=cnfm4.tmp
279 gmp_tmpconfigm4i=cnfm4i.tmp
280@@ -834,7 +834,9 @@
281 echo ["define(<CONFIG_TOP_SRCDIR>,<\`$tmp'>)"] >>$gmp_tmpconfigm4
282
283 # All CPUs use asm-defs.m4
284-echo ["include(CONFIG_TOP_SRCDIR\`/mpn/asm-defs.m4')"] >>$gmp_tmpconfigm4i
285+echo -n ["include("] >>$gmp_tmpconfigm4i
286+echo -n ["CONFIG_TOP_SRCDIR\`/mpn/asm-defs.m4'"] >>$gmp_tmpconfigm4i
287+echo [")"] >>$gmp_tmpconfigm4i
288 ])
289
290
291@@ -855,7 +857,7 @@
292 dnl having a whole file as a macro argument would overflow the string space
293 dnl on BSD m4.
294
295-AC_DEFUN(GMP_FINISH,
296+AC_DEFUN([GMP_FINISH],
297 [AC_REQUIRE([GMP_INIT])
298 echo "creating $gmp_configm4"
299 echo ["d""nl $gmp_configm4. Generated automatically by configure."] > $gmp_configm4
300@@ -889,7 +891,7 @@
301 dnl GMP_INCLUDE_MPN(`x86/x86-defs.m4')
302 dnl
303
304-AC_DEFUN(GMP_INCLUDE_MPN,
305+AC_DEFUN([GMP_INCLUDE_MPN],
306 [AC_REQUIRE([GMP_INIT])
307 echo ["include_mpn(\`$1')"] >> $gmp_tmpconfigm4i
308 ])
309@@ -905,7 +907,7 @@
310 dnl create file config.m4. config.m4 uses `<' and '>' as quote characters
311 dnl for all defines.
312
313-AC_DEFUN(GMP_DEFINE,
314+AC_DEFUN([GMP_DEFINE],
315 [AC_REQUIRE([GMP_INIT])
316 echo ['define(<$1>, <$2>)'] >>ifelse([$3], [POST],
317 $gmp_tmpconfigm4p, $gmp_tmpconfigm4)
318@@ -920,7 +922,7 @@
319 dnl directives inserted by GMP_INCLUDE. Don't forget to invoke GMP_FINISH
320 dnl to create file config.m4.
321
322-AC_DEFUN(GMP_DEFINE_RAW,
323+AC_DEFUN([GMP_DEFINE_RAW],
324 [AC_REQUIRE([GMP_INIT])
325 echo [$1] >> ifelse([$2], [POST], $gmp_tmpconfigm4p, $gmp_tmpconfigm4)
326 ])
327@@ -938,7 +940,7 @@
328 dnl This is not unlike AC_TRY_COMPILE, but there's no default includes or
329 dnl anything in "asm-code", everything wanted must be given explicitly.
330
331-AC_DEFUN(GMP_TRY_ASSEMBLE,
332+AC_DEFUN([GMP_TRY_ASSEMBLE],
333 [cat >conftest.s <<EOF
334 [$1]
335 EOF
336@@ -960,7 +962,7 @@
337 dnl --------------------
338 dnl Should a label have a colon or not?
339
340-AC_DEFUN(GMP_ASM_LABEL_SUFFIX,
341+AC_DEFUN([GMP_ASM_LABEL_SUFFIX],
342 [AC_CACHE_CHECK([what assembly label suffix to use],
343 gmp_cv_asm_label_suffix,
344 [case $host in
345@@ -984,7 +986,7 @@
346 dnl in particular that grepping doesn't work with SunOS 4 native grep since
347 dnl that grep seems to have trouble with '\0's in files.
348
349-AC_DEFUN(GMP_ASM_UNDERSCORE,
350+AC_DEFUN([GMP_ASM_UNDERSCORE],
351 [AC_REQUIRE([GMP_ASM_TEXT])
352 AC_REQUIRE([GMP_ASM_GLOBL])
353 AC_REQUIRE([GMP_ASM_LABEL_SUFFIX])
354@@ -1045,7 +1047,7 @@
355 dnl -----------------
356 dnl Is parameter to `.align' logarithmic?
357
358-AC_DEFUN(GMP_ASM_ALIGN_LOG,
359+AC_DEFUN([GMP_ASM_ALIGN_LOG],
360 [AC_REQUIRE([GMP_ASM_GLOBL])
361 AC_REQUIRE([GMP_ASM_DATA])
362 AC_REQUIRE([GMP_ASM_LABEL_SUFFIX])
363@@ -1103,7 +1105,7 @@
364 dnl The warning from solaris 2.8 is supressed to stop anyone worrying that
365 dnl something might be wrong.
366
367-AC_DEFUN(GMP_ASM_ALIGN_FILL_0x90,
368+AC_DEFUN([GMP_ASM_ALIGN_FILL_0x90],
369 [AC_REQUIRE([GMP_ASM_TEXT])
370 AC_CACHE_CHECK([if the .align directive accepts an 0x90 fill in .text],
371 gmp_cv_asm_align_fill_0x90,
372@@ -1127,7 +1129,7 @@
373 dnl GMP_ASM_TEXT
374 dnl ------------
375
376-AC_DEFUN(GMP_ASM_TEXT,
377+AC_DEFUN([GMP_ASM_TEXT],
378 [AC_CACHE_CHECK([how to switch to text section],
379 gmp_cv_asm_text,
380 [case $host in
381@@ -1144,7 +1146,7 @@
382 dnl ------------
383 dnl Can we say `.data'?
384
385-AC_DEFUN(GMP_ASM_DATA,
386+AC_DEFUN([GMP_ASM_DATA],
387 [AC_CACHE_CHECK([how to switch to data section],
388 gmp_cv_asm_data,
389 [case $host in
390@@ -1172,7 +1174,7 @@
391 dnl where foo is the object file. Might need to check for that if we use
392 dnl RODATA there.
393
394-AC_DEFUN(GMP_ASM_RODATA,
395+AC_DEFUN([GMP_ASM_RODATA],
396 [AC_REQUIRE([GMP_ASM_TEXT])
397 AC_REQUIRE([GMP_ASM_DATA])
398 AC_REQUIRE([GMP_ASM_LABEL_SUFFIX])
399@@ -1229,7 +1231,7 @@
400 dnl -------------
401 dnl Can we say `.global'?
402
403-AC_DEFUN(GMP_ASM_GLOBL,
404+AC_DEFUN([GMP_ASM_GLOBL],
405 [AC_CACHE_CHECK([how to export a symbol],
406 gmp_cv_asm_globl,
407 [case $host in
408@@ -1245,7 +1247,7 @@
409 dnl ------------------
410 dnl Do we need something after `.global symbol'?
411
412-AC_DEFUN(GMP_ASM_GLOBL_ATTR,
413+AC_DEFUN([GMP_ASM_GLOBL_ATTR],
414 [AC_CACHE_CHECK([if the export directive needs an attribute],
415 gmp_cv_asm_globl_attr,
416 [case $host in
417@@ -1276,7 +1278,7 @@
418 dnl letting the problem go unnoticed. tests/mpn/t-asmtype.c aims to check
419 dnl for it.
420
421-AC_DEFUN(GMP_ASM_TYPE,
422+AC_DEFUN([GMP_ASM_TYPE],
423 [AC_CACHE_CHECK([for assembler .type directive],
424 gmp_cv_asm_type,
425 [gmp_cv_asm_type=
426@@ -1298,7 +1300,7 @@
427 dnl ------------
428 dnl Can we say `.size'?
429
430-AC_DEFUN(GMP_ASM_SIZE,
431+AC_DEFUN([GMP_ASM_SIZE],
432 [AC_CACHE_CHECK([for assembler .size directive],
433 gmp_cv_asm_size,
434 [gmp_cv_asm_size=
435@@ -1341,7 +1343,7 @@
436 dnl HP-UX nm prints an error message (though seems to give a 0 exit) if
437 dnl there's no symbols at all in an object file, hence the use of "dummy".
438
439-AC_DEFUN(GMP_ASM_LSYM_PREFIX,
440+AC_DEFUN([GMP_ASM_LSYM_PREFIX],
441 [AC_REQUIRE([GMP_ASM_LABEL_SUFFIX])
442 AC_REQUIRE([GMP_PROG_NM])
443 AC_CACHE_CHECK([what prefix to use for a local label],
444@@ -1386,7 +1388,7 @@
445 dnl -----------
446 dnl How to define a 32-bit word.
447
448-AC_DEFUN(GMP_ASM_W32,
449+AC_DEFUN([GMP_ASM_W32],
450 [AC_REQUIRE([GMP_ASM_DATA])
451 AC_REQUIRE([GMP_ASM_GLOBL])
452 AC_REQUIRE([GMP_ASM_LABEL_SUFFIX])
453@@ -1443,7 +1445,7 @@
454 dnl %mm1, %mm0"). It seems more trouble than it's worth to work around
455 dnl this in the code, so just detect and reject.
456
457-AC_DEFUN(GMP_ASM_X86_MMX,
458+AC_DEFUN([GMP_ASM_X86_MMX],
459 [AC_CACHE_CHECK([if the assembler knows about MMX instructions],
460 gmp_cv_asm_x86_mmx,
461 [GMP_TRY_ASSEMBLE(
462@@ -1495,7 +1497,7 @@
463 dnl GMP_ASM_X86_SHLDL_CL
464 dnl --------------------
465
466-AC_DEFUN(GMP_ASM_X86_SHLDL_CL,
467+AC_DEFUN([GMP_ASM_X86_SHLDL_CL],
468 [AC_REQUIRE([GMP_ASM_TEXT])
469 AC_CACHE_CHECK([if the assembler takes cl with shldl],
470 gmp_cv_asm_x86_shldl_cl,
471@@ -1522,7 +1524,7 @@
472 dnl it's all GMP_ASM_TEXT gives currently. Actually ".text" probably isn't
473 dnl needed at all, at least for just checking instruction syntax.
474
475-AC_DEFUN(GMP_ASM_X86_SSE2,
476+AC_DEFUN([GMP_ASM_X86_SSE2],
477 [AC_CACHE_CHECK([if the assembler knows about SSE2 instructions],
478 gmp_cv_asm_x86_sse2,
479 [GMP_TRY_ASSEMBLE(
480@@ -1585,7 +1587,7 @@
481 dnl to get two variables (mcount_nonpic_reg and mcount_nonpic_call say) set
482 dnl from one block of commands?
483
484-AC_DEFUN(GMP_ASM_X86_MCOUNT,
485+AC_DEFUN([GMP_ASM_X86_MCOUNT],
486 [AC_REQUIRE([AC_ENABLE_SHARED])
487 AC_REQUIRE([AC_PROG_LIBTOOL])
488 AC_MSG_CHECKING([how to call x86 mcount])
489@@ -1655,7 +1657,7 @@
490 dnl instruction. It takes registers without "%", but a single operand
491 dnl "clrl %d0" only gives a warning, not an error.
492
493-AC_DEFUN(GMP_ASM_M68K_INSTRUCTION,
494+AC_DEFUN([GMP_ASM_M68K_INSTRUCTION],
495 [AC_REQUIRE([GMP_ASM_TEXT])
496 AC_CACHE_CHECK([assembler instruction and register style],
497 gmp_cv_asm_m68k_instruction,
498@@ -1684,7 +1686,7 @@
499 dnl GMP_ASM_M68K_ADDRESSING
500 dnl -----------------------
501
502-AC_DEFUN(GMP_ASM_M68K_ADDRESSING,
503+AC_DEFUN([GMP_ASM_M68K_ADDRESSING],
504 [AC_REQUIRE([GMP_ASM_TEXT])
505 AC_REQUIRE([GMP_ASM_M68K_INSTRUCTION])
506 AC_CACHE_CHECK([assembler addressing style],
507@@ -1721,7 +1723,7 @@
508 dnl 16-bits. This applies to the conditional branches "bcc" etc too.
509 dnl However "dbcc" etc on gas are already only as big as they need to be.
510
511-AC_DEFUN(GMP_ASM_M68K_BRANCHES,
512+AC_DEFUN([GMP_ASM_M68K_BRANCHES],
513 [AC_REQUIRE([GMP_ASM_TEXT])
514 AC_CACHE_CHECK([assembler shortest branches],
515 gmp_cv_asm_m68k_branches,
516@@ -1752,7 +1754,7 @@
517 dnl See also mpn/powerpc32/powerpc-defs.m4 which uses the result of this
518 dnl test.
519
520-AC_DEFUN(GMP_ASM_POWERPC_R_REGISTERS,
521+AC_DEFUN([GMP_ASM_POWERPC_R_REGISTERS],
522 [AC_REQUIRE([GMP_ASM_TEXT])
523 AC_CACHE_CHECK([if the assembler needs r on registers],
524 gmp_cv_asm_powerpc_r_registers,
525@@ -1777,7 +1779,7 @@
526 dnl
527 dnl See also mpn/sparc32/sparc-defs.m4 which uses the result of this test.
528
529-AC_DEFUN(GMP_ASM_SPARC_REGISTER,
530+AC_DEFUN([GMP_ASM_SPARC_REGISTER],
531 [AC_REQUIRE([GMP_ASM_TEXT])
532 AC_CACHE_CHECK([if the assembler accepts ".register"],
533 gmp_cv_asm_sparc_register,
534@@ -1795,7 +1797,7 @@
535 dnl GMP_C_ATTRIBUTE_CONST
536 dnl ---------------------
537
538-AC_DEFUN(GMP_C_ATTRIBUTE_CONST,
539+AC_DEFUN([GMP_C_ATTRIBUTE_CONST],
540 [AC_CACHE_CHECK([whether gcc __attribute__ ((const)) works],
541 gmp_cv_c_attribute_const,
542 [AC_TRY_COMPILE([int foo (int x) __attribute__ ((const));], ,
543@@ -1814,7 +1816,7 @@
544 dnl it's ignored. Pretend it doesn't exist in this case, to avoid that
545 dnl warning.
546
547-AC_DEFUN(GMP_C_ATTRIBUTE_MALLOC,
548+AC_DEFUN([GMP_C_ATTRIBUTE_MALLOC],
549 [AC_CACHE_CHECK([whether gcc __attribute__ ((malloc)) works],
550 gmp_cv_c_attribute_malloc,
551 [cat >conftest.c <<EOF
552@@ -1844,7 +1846,7 @@
553 dnl --------------------
554 dnl Introduced in gcc 2.2, but perhaps not in all Apple derived versions.
555
556-AC_DEFUN(GMP_C_ATTRIBUTE_MODE,
557+AC_DEFUN([GMP_C_ATTRIBUTE_MODE],
558 [AC_CACHE_CHECK([whether gcc __attribute__ ((mode (XX))) works],
559 gmp_cv_c_attribute_mode,
560 [AC_TRY_COMPILE([typedef int SItype __attribute__ ((mode (SI)));], ,
561@@ -1860,7 +1862,7 @@
562 dnl GMP_C_ATTRIBUTE_NORETURN
563 dnl ------------------------
564
565-AC_DEFUN(GMP_C_ATTRIBUTE_NORETURN,
566+AC_DEFUN([GMP_C_ATTRIBUTE_NORETURN],
567 [AC_CACHE_CHECK([whether gcc __attribute__ ((noreturn)) works],
568 gmp_cv_c_attribute_noreturn,
569 [AC_TRY_COMPILE([void foo (int x) __attribute__ ((noreturn));], ,
570@@ -1887,7 +1889,7 @@
571 dnl used doesn't have functions or anything, so even an "old" awk should
572 dnl suffice.
573
574-AC_DEFUN(GMP_C_DOUBLE_FORMAT,
575+AC_DEFUN([GMP_C_DOUBLE_FORMAT],
576 [AC_REQUIRE([AC_PROG_CC])
577 AC_REQUIRE([AC_PROG_AWK])
578 AC_CACHE_CHECK([format of `double' floating point],
579@@ -2089,7 +2091,7 @@
580 dnl
581 dnl FIXME: Hopefully autoconf will do this extra itself one day.
582
583-AC_DEFUN(GMP_C_INLINE,
584+AC_DEFUN([GMP_C_INLINE],
585 [AC_CACHE_CHECK([for inline], gmp_cv_c_inline,
586 [gmp_cv_c_inline=no
587 for i in inline __inline__ __inline; do
588@@ -2129,7 +2131,7 @@
589 dnl "yes" is used in the cache variable if plain "restrict" works, to make
590 dnl the configure message look nicer.
591
592-AC_DEFUN(GMP_C_RESTRICT,
593+AC_DEFUN([GMP_C_RESTRICT],
594 [AC_CACHE_CHECK([for restrict], gmp_cv_c_restrict,
595 [gmp_cv_c_restrict=no
596 for r in restrict __restrict__ __restrict; do
597@@ -2178,7 +2180,7 @@
598 dnl ulongs with bits=8*sizeof, so it's academic. Strange systems can
599 dnl always have the right values put in gmp-mparam.h explicitly.
600
601-AC_DEFUN(GMP_C_SIZES,
602+AC_DEFUN([GMP_C_SIZES],
603 [BITS_PER_MP_LIMB=[`sed -n 's/^#define BITS_PER_MP_LIMB[ ][ ]*\([0-9]*\).*$/\1/p' $gmp_mparam_source`]
604 if test -n "$BITS_PER_MP_LIMB" \
605 && grep "^#define BYTES_PER_MP_LIMB" $gmp_mparam_source >/dev/null; then : ;
606@@ -2199,7 +2201,7 @@
607 fi
608 fi
609 AC_SUBST(BITS_PER_MP_LIMB)
610-define([GMP_INCLUDE_GMP_H_BITS_PER_MP_LIMB],
611+define([[GMP_INCLUDE_GMP_H_BITS_PER_MP_LIMB]],
612 [[#define __GMP_BITS_PER_MP_LIMB $BITS_PER_MP_LIMB
613 #define GMP_LIMB_BITS $BITS_PER_MP_LIMB]])
614
615@@ -2232,7 +2234,7 @@
616 dnl or very likely by the setups for _PROTO in gmp.h. On the other hand
617 dnl this test is nice and direct, being what we're going to actually use.
618
619-AC_DEFUN(GMP_C_STDARG,
620+AC_DEFUN([GMP_C_STDARG],
621 [AC_CACHE_CHECK([whether <stdarg.h> exists and works],
622 gmp_cv_c_stdarg,
623 [AC_TRY_COMPILE(
624@@ -2261,7 +2263,7 @@
625 dnl available, and also to use gmp-impl.h for the conditionals detecting
626 dnl compiler builtin alloca's.
627
628-AC_DEFUN(GMP_FUNC_ALLOCA,
629+AC_DEFUN([GMP_FUNC_ALLOCA],
630 [AC_REQUIRE([GMP_HEADER_ALLOCA])
631 AC_CACHE_CHECK([for alloca (via gmp-impl.h)],
632 gmp_cv_func_alloca,
633@@ -2278,7 +2280,7 @@
634 fi
635 ])
636
637-AC_DEFUN(GMP_HEADER_ALLOCA,
638+AC_DEFUN([GMP_HEADER_ALLOCA],
639 [# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
640 # for constant arguments. Useless!
641 AC_CACHE_CHECK([for working alloca.h],
642@@ -2299,7 +2301,7 @@
643 dnl Decide what to do about --enable-alloca from the user.
644 dnl This is a macro so it can require GMP_FUNC_ALLOCA.
645
646-AC_DEFUN(GMP_OPTION_ALLOCA,
647+AC_DEFUN([GMP_OPTION_ALLOCA],
648 [AC_REQUIRE([GMP_FUNC_ALLOCA])
649 AC_CACHE_CHECK([how to allocate temporary memory],
650 gmp_cv_option_alloca,
651@@ -2355,7 +2357,7 @@
652 dnl
653 dnl FIXME: Run a program to try this, when doing a native build.
654
655-AC_DEFUN(GMP_FUNC_SSCANF_WRITABLE_INPUT,
656+AC_DEFUN([GMP_FUNC_SSCANF_WRITABLE_INPUT],
657 [AC_CACHE_CHECK([whether sscanf needs writable input],
658 gmp_cv_func_sscanf_writable_input,
659 [case $host in
660@@ -2391,7 +2393,7 @@
661 dnl not sure which 2.0.x does which), but still puts the correct null
662 dnl terminated result into the buffer.
663
664-AC_DEFUN(GMP_FUNC_VSNPRINTF,
665+AC_DEFUN([GMP_FUNC_VSNPRINTF],
666 [AC_REQUIRE([GMP_C_STDARG])
667 AC_CHECK_FUNC(vsnprintf,
668 [gmp_vsnprintf_exists=yes],
669@@ -2472,7 +2474,7 @@
670 dnl ----------
671 dnl Check whether gmp.h recognises the compiler as ANSI capable.
672
673-AC_DEFUN(GMP_H_ANSI,
674+AC_DEFUN([GMP_H_ANSI],
675 [AC_REQUIRE([AC_PROG_CC_STDC])
676 case $ac_cv_prog_cc_stdc in
677 no)
678@@ -2495,7 +2497,7 @@
679 dnl If the compiler has an "inline" of some sort, check whether the
680 dnl #ifdef's in gmp.h recognise it.
681
682-AC_DEFUN(GMP_H_EXTERN_INLINE,
683+AC_DEFUN([GMP_H_EXTERN_INLINE],
684 [AC_REQUIRE([GMP_C_INLINE])
685 case $gmp_cv_c_inline in
686 no) ;;
687@@ -2522,7 +2524,7 @@
688 dnl Check whether the #ifdef's in gmp.h recognise when stdio.h has been
689 dnl included to get FILE.
690
691-AC_DEFUN(GMP_H_HAVE_FILE,
692+AC_DEFUN([GMP_H_HAVE_FILE],
693 [AC_TRY_COMPILE(
694 [#include <stdio.h>]
695 GMP_INCLUDE_GMP_H
696@@ -2539,7 +2541,7 @@
697 dnl Check whether the #ifdef's in gmp-impl.h recognise IEEE format and
698 dnl endianness.
699
700-AC_DEFUN(GMP_IMPL_H_IEEE_FLOATS,
701+AC_DEFUN([GMP_IMPL_H_IEEE_FLOATS],
702 [case $host in
703 vax*-*-*)
704 # not IEEE (neither D nor G formats are IEEE)
705--- gmp-1.4.4/configure.in.orig 2004-09-21 15:02:43.000000000 +0200
706+++ gmp-1.4.4/configure.in 2005-07-18 01:08:34.000000000 +0200
707@@ -26,15 +26,16 @@
708
709
710 AC_REVISION($Revision: 1.425.2.25 $)
711-AC_PREREQ(2.52)
712-AC_INIT(gmp-impl.h)
713-m4_pattern_forbid([^[ \t]*GMP_])
714-m4_pattern_forbid([^[ \t]*MPFR_CONFIGS])
715-m4_pattern_allow(GMP_LDFLAGS)
716-m4_pattern_allow(GMP_LIMB_BITS)
717-m4_pattern_allow(GMP_MPARAM_H_SUGGEST)
718-m4_pattern_allow(GMP_NAIL_BITS)
719-m4_pattern_allow(GMP_NUMB_BITS)
720+AC_PREREQ(2.57)
721+AC_INIT
722+AC_CONFIG_SRCDIR([gmp-impl.h])
723+
724+
725+
726+
727+
728+
729+
730
731 # If --target is not used then $target_alias is empty, but if say
732 # "./configure athlon-pc-freebsd3.5" is used, then all three of
733@@ -56,7 +57,7 @@
734 GMP_DEFINE_RAW("define_not_for_expansion(\`HAVE_HOST_CPU_$tmp_host')", POST)
735
736 AM_INIT_AUTOMAKE(gmp, GMP_VERSION)
737-AM_CONFIG_HEADER(config.h:config.in)
738+AC_CONFIG_HEADERS([config.h:config.in])
739 AM_MAINTAINER_MODE
740
741
742@@ -212,7 +213,7 @@
743 # After GMP specific searches and tests, the standard autoconf AC_PROG_CC is
744 # called. User selections of CC etc are respected.
745 #
746-# Care is taken not to use macros like AC_TRY_COMPILE during the GMP
747+# Care is taken not to use macros like AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[]])],[],[]) during the GMP
748 # pre-testing, since they of course depend on AC_PROG_CC, and also some of
749 # them cache their results, which is not wanted.
750 #
751@@ -299,7 +300,7 @@
752 # FIXME: We'd like to prefer an ANSI compiler, perhaps by preferring
753 # c89 over cc here. But note that on HP-UX c89 provides a castrated
754 # environment, and would want to be excluded somehow. Maybe
755-# AC_PROG_CC_STDC already does enough to stick cc into ANSI mode and
756+# already does enough to stick cc into ANSI mode and
757 # we don't need to worry.
758 #
759 cclist="gcc cc"
760@@ -1079,7 +1080,7 @@
761 CFLAGS_or_unset=${CFLAGS-'(unset)'}
762 CPPFLAGS_or_unset=${CPPFLAGS-'(unset)'}
763
764-cat >&AC_FD_CC <<EOF
765+cat >&AS_MESSAGE_LOG_FD() <<EOF
766 configure:__line__: User:
767 ABI=$ABI
768 CC=$CC
769@@ -1391,18 +1392,18 @@
770
771 # The C compiler and preprocessor, put into ANSI mode if possible.
772 AC_PROG_CC
773-AC_PROG_CC_STDC
774+
775 AC_PROG_CPP
776 GMP_H_ANSI
777
778
779 # The C++ compiler, if desired.
780 want_cxx=no
781+AC_PROG_CXX
782 if test $enable_cxx != no; then
783 test_CXXFLAGS=${CXXFLAGS+set}
784- AC_PROG_CXX
785
786- echo "CXXFLAGS chosen by autoconf: $CXXFLAGS" >&AC_FD_CC
787+ echo "CXXFLAGS chosen by autoconf: $CXXFLAGS" >&AS_MESSAGE_LOG_FD()
788 cxxflags_ac_prog_cxx=$CXXFLAGS
789 cxxflags_list=ac_prog_cxx
790
791@@ -1478,7 +1479,7 @@
792 fi
793
794
795-cat >&AC_FD_CC <<EOF
796+cat >&AS_MESSAGE_LOG_FD() <<EOF
797 configure:__line__: Decided:
798 ABI=$ABI
799 CC=$CC
800@@ -1720,9 +1721,9 @@
801
802 # FIXME: Autoconf 2.52 AC_C_BIGENDIAN bombs when cross compiling, but in the
803 # future the probes will be better and this override can be removed.
804-if test "$cross_compiling" = yes; then
805- ac_cv_c_bigendian=unknown
806-fi
807+#if test "$cross_compiling" = yes; then
808+# ac_cv_c_bigendian=unknown
809+#fi
810 AC_C_BIGENDIAN
811 # Enhancement: In the future AC_C_BIGENDIAN will accept these actions as
812 # parameters.
813@@ -2168,7 +2169,7 @@
814
815 # Configs for demos/calc directory
816 #
817-# AC_SUBST is used here since with AM_CONFIG_HEADER automake would put
818+# AC_SUBST is used here since with AC_CONFIG_HEADERS([]) automake would put
819 # demos/calc in the default $(DEFAULT_INCLUDES) for every directory,
820 # which would look very strange. Likewise demos/expr below.
821 #
822@@ -2207,7 +2208,7 @@
823 # FIXME: Upcoming version of autoconf/automake may not like broken lines.
824 # Right now automake isn't accepting the new AC_CONFIG_FILES scheme.
825
826-AC_OUTPUT(Makefile \
827+AC_CONFIG_FILES([Makefile \
828 mpbsd/Makefile mpf/Makefile mpn/Makefile mpq/Makefile \
829 mpz/Makefile printf/Makefile scanf/Makefile cxx/Makefile \
830 tests/Makefile tests/devel/Makefile tests/mpbsd/Makefile \
831@@ -2217,4 +2218,5 @@
832 mpfr/Makefile mpfr/tests/Makefile \
833 tune/Makefile \
834 demos/Makefile demos/calc/Makefile demos/expr/Makefile \
835- gmp.h:gmp-h.in mp.h:mp-h.in)
836+ gmp.h:gmp-h.in mp.h:mp-h.in])
837+AC_OUTPUT
diff --git a/meta/packages/gmp/gmp-4.1.4/amd64.patch b/meta/packages/gmp/gmp-4.2.1/amd64.patch
index 67be9dd350..67be9dd350 100644
--- a/meta/packages/gmp/gmp-4.1.4/amd64.patch
+++ b/meta/packages/gmp/gmp-4.2.1/amd64.patch
diff --git a/meta/packages/gmp/gmp-4.2.1/configure.patch b/meta/packages/gmp/gmp-4.2.1/configure.patch
new file mode 100644
index 0000000000..08f2172479
--- /dev/null
+++ b/meta/packages/gmp/gmp-4.2.1/configure.patch
@@ -0,0 +1,195 @@
1 acinclude.m4 | 26 ++++++++++++++------------
2 configure.in | 24 +++++++++---------------
3 2 files changed, 23 insertions(+), 27 deletions(-)
4
5Index: gmp-4.2.1/acinclude.m4
6===================================================================
7--- gmp-4.2.1.orig/acinclude.m4 2006-05-04 17:39:01.000000000 +0100
8+++ gmp-4.2.1/acinclude.m4 2006-11-06 20:36:14.000000000 +0000
9@@ -32,20 +32,20 @@ dnl a_out.exe - OpenVMS DEC C called
10 dnl conftest.exe - various DOS compilers
11
12
13-define(IA64_PATTERN,
14+define([IA64_PATTERN],
15 [[ia64*-*-* | itanium-*-* | itanium2-*-*]])
16
17 dnl Need to be careful not to match m6811, m6812, m68hc11 and m68hc12, all
18 dnl of which config.sub accepts. (Though none of which are likely to work
19 dnl with GMP.)
20 dnl
21-define(M68K_PATTERN,
22+define([M68K_PATTERN],
23 [[m68k-*-* | m68[0-9][0-9][0-9]-*-*]])
24
25-define(POWERPC64_PATTERN,
26+define([POWERPC64_PATTERN],
27 [[powerpc64-*-* | powerpc64le-*-* | powerpc620-*-* | powerpc630-*-* | powerpc970-*-* | power[3-9]-*-*]])
28
29-define(X86_PATTERN,
30+define([X86_PATTERN],
31 [[i?86*-*-* | k[5-8]*-*-* | pentium*-*-* | athlon-*-* | viac3*-*-*]])
32
33
34@@ -64,7 +64,7 @@ dnl x86 -> x86
35 dnl x86/k6 -> k6
36 dnl x86/k6/mmx -> k6_mmx
37
38-define(GMP_FAT_SUFFIX,
39+define([GMP_FAT_SUFFIX],
40 [[$1=`echo $2 | sed -e '/\//s:^[^/]*/::' -e 's:[\\/]:_:g'`]])
41
42
43@@ -73,7 +73,7 @@ dnl ----------------------------------
44 dnl Emit code to remove any occurance of ITEM from $LISTVAR. ITEM can be a
45 dnl shell expression like $foo if desired.
46
47-define(GMP_REMOVE_FROM_LIST,
48+define([GMP_REMOVE_FROM_LIST],
49 [remove_from_list_tmp=
50 for remove_from_list_i in $[][$1]; do
51 if test $remove_from_list_i = [$2]; then :;
52@@ -89,12 +89,12 @@ dnl GMP_STRIP_PATH(subdir)
53 dnl ----------------------
54 dnl Strip entries */subdir from $path and $fat_path.
55
56-define(GMP_STRIP_PATH,
57+define([GMP_STRIP_PATH],
58 [GMP_STRIP_PATH_VAR(path, [$1])
59 GMP_STRIP_PATH_VAR(fat_path, [$1])
60 ])
61
62-define(GMP_STRIP_PATH_VAR,
63+define([GMP_STRIP_PATH_VAR],
64 [tmp_path=
65 for i in $[][$1]; do
66 case $i in
67@@ -115,7 +115,7 @@ dnl
68 dnl Dummy values for __GMP_BITS_PER_MP_LIMB and GMP_LIMB_BITS are enough
69 dnl for all current configure-time uses of gmp.h.
70
71-define(GMP_INCLUDE_GMP_H,
72+define([GMP_INCLUDE_GMP_H],
73 [[#define __GMP_WITHIN_CONFIGURE 1 /* ignore template stuff */
74 #define GMP_NAIL_BITS $GMP_NAIL_BITS
75 #define __GMP_BITS_PER_MP_LIMB 123 /* dummy for GMP_NUMB_BITS etc */
76@@ -131,7 +131,7 @@ dnl Expand at autoconf time to the valu
77 dnl FILE. The regexps here aren't very rugged, but are enough for gmp.
78 dnl /dev/null as a parameter prevents a hang if $2 is accidentally omitted.
79
80-define(GMP_HEADER_GETVAL,
81+define([GMP_HEADER_GETVAL],
82 [patsubst(patsubst(
83 esyscmd([grep "^#define $1 " $2 /dev/null 2>/dev/null]),
84 [^.*$1[ ]+],[]),
85@@ -145,7 +145,7 @@ dnl The gmp version number, extracted f
86 dnl autoconf time. Two digits like 3.0 if patchlevel <= 0, or three digits
87 dnl like 3.0.1 if patchlevel > 0.
88
89-define(GMP_VERSION,
90+define([GMP_VERSION],
91 [GMP_HEADER_GETVAL(__GNU_MP_VERSION,gmp-h.in)[]dnl
92 .GMP_HEADER_GETVAL(__GNU_MP_VERSION_MINOR,gmp-h.in)[]dnl
93 ifelse(m4_eval(GMP_HEADER_GETVAL(__GNU_MP_VERSION_PATCHLEVEL,gmp-h.in) > 0),1,
94@@ -1491,7 +1491,9 @@ esac
95 echo ["define(<CONFIG_TOP_SRCDIR>,<\`$tmp'>)"] >>$gmp_tmpconfigm4
96
97 # All CPUs use asm-defs.m4
98-echo ["include][(CONFIG_TOP_SRCDIR\`/mpn/asm-defs.m4')"] >>$gmp_tmpconfigm4i
99+echo -n ["include("] >>$gmp_tmpconfigm4i
100+echo -n ["CONFIG_TOP_SRCDIR\`/mpn/asm-defs.m4'"] >>$gmp_tmpconfigm4i
101+echo [")"] >>$gmp_tmpconfigm4i
102 ])
103
104
105Index: gmp-4.2.1/configure.in
106===================================================================
107--- gmp-4.2.1.orig/configure.in 2006-04-30 00:31:08.000000000 +0100
108+++ gmp-4.2.1/configure.in 2006-11-06 20:39:17.000000000 +0000
109@@ -31,12 +31,6 @@ AC_REVISION($Revision: 1.11 $)
110 AC_PREREQ(2.59)
111 AC_INIT(GNU MP, GMP_VERSION, gmp-bugs@swox.com, gmp)
112 AC_CONFIG_SRCDIR(gmp-impl.h)
113-m4_pattern_forbid([^[ \t]*GMP_])
114-m4_pattern_allow(GMP_LDFLAGS)
115-m4_pattern_allow(GMP_LIMB_BITS)
116-m4_pattern_allow(GMP_MPARAM_H_SUGGEST)
117-m4_pattern_allow(GMP_NAIL_BITS)
118-m4_pattern_allow(GMP_NUMB_BITS)
119
120 # If --target is not used then $target_alias is empty, but if say
121 # "./configure athlon-pc-freebsd3.5" is used, then all three of
122@@ -277,7 +271,7 @@ AH_VERBATIM([HAVE_HOST_CPU_1],
123 # After GMP specific searches and tests, the standard autoconf AC_PROG_CC is
124 # called. User selections of CC etc are respected.
125 #
126-# Care is taken not to use macros like AC_TRY_COMPILE during the GMP
127+# Care is taken not to use macros like AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[]])],[],[]) during the GMP
128 # pre-testing, since they of course depend on AC_PROG_CC, and also some of
129 # them cache their results, which is not wanted.
130 #
131@@ -369,7 +363,7 @@ abilist="standard"
132 # FIXME: We'd like to prefer an ANSI compiler, perhaps by preferring
133 # c89 over cc here. But note that on HP-UX c89 provides a castrated
134 # environment, and would want to be excluded somehow. Maybe
135-# AC_PROG_CC_STDC already does enough to stick cc into ANSI mode and
136+# already does enough to stick cc into ANSI mode and
137 # we don't need to worry.
138 #
139 cclist="gcc cc"
140@@ -1498,7 +1492,7 @@ esac
141 CFLAGS_or_unset=${CFLAGS-'(unset)'}
142 CPPFLAGS_or_unset=${CPPFLAGS-'(unset)'}
143
144-cat >&AC_FD_CC <<EOF
145+cat >&AS_MESSAGE_LOG_FD() <<EOF
146 User:
147 ABI=$ABI
148 CC=$CC
149@@ -1869,7 +1863,6 @@ AC_SUBST(DEFN_LONG_LONG_LIMB)
150
151 # The C compiler and preprocessor, put into ANSI mode if possible.
152 AC_PROG_CC
153-AC_PROG_CC_STDC
154 AC_PROG_CPP
155 GMP_H_ANSI
156
157@@ -1892,11 +1885,11 @@ AC_SUBST(CCAS)
158
159 # The C++ compiler, if desired.
160 want_cxx=no
161+AC_PROG_CXX
162 if test $enable_cxx != no; then
163 test_CXXFLAGS=${CXXFLAGS+set}
164- AC_PROG_CXX
165
166- echo "CXXFLAGS chosen by autoconf: $CXXFLAGS" >&AC_FD_CC
167+ echo "CXXFLAGS chosen by autoconf: $CXXFLAGS" >&AS_MESSAGE_LOG_FD()
168 cxxflags_ac_prog_cxx=$CXXFLAGS
169 cxxflags_list=ac_prog_cxx
170
171@@ -2002,7 +1995,7 @@ case $host in
172 esac
173
174
175-cat >&AC_FD_CC <<EOF
176+cat >&AS_MESSAGE_LOG_FD() <<EOF
177 Decided:
178 ABI=$ABI
179 CC=$CC
180@@ -3175,7 +3168,7 @@ GMP_FINISH
181 # FIXME: Upcoming version of autoconf/automake may not like broken lines.
182 # Right now automake isn't accepting the new AC_CONFIG_FILES scheme.
183
184-AC_OUTPUT(Makefile \
185+AC_CONFIG_FILES([Makefile \
186 mpbsd/Makefile mpf/Makefile mpn/Makefile mpq/Makefile \
187 mpz/Makefile printf/Makefile scanf/Makefile cxx/Makefile \
188 tests/Makefile tests/devel/Makefile tests/mpbsd/Makefile \
189@@ -3184,4 +3177,5 @@ AC_OUTPUT(Makefile \
190 tests/cxx/Makefile \
191 doc/Makefile tune/Makefile \
192 demos/Makefile demos/calc/Makefile demos/expr/Makefile \
193- gmp.h:gmp-h.in mp.h:mp-h.in)
194+ gmp.h:gmp-h.in mp.h:mp-h.in])
195+AC_OUTPUT
diff --git a/meta/packages/gmp/gmp-4.1.4/sh4-asmfix.patch b/meta/packages/gmp/gmp-4.2.1/sh4-asmfix.patch
index 1a01f61533..1a01f61533 100644
--- a/meta/packages/gmp/gmp-4.1.4/sh4-asmfix.patch
+++ b/meta/packages/gmp/gmp-4.2.1/sh4-asmfix.patch
diff --git a/meta/packages/gmp/gmp-native.inc b/meta/packages/gmp/gmp-native.inc
new file mode 100644
index 0000000000..c3d36e0fdb
--- /dev/null
+++ b/meta/packages/gmp/gmp-native.inc
@@ -0,0 +1,23 @@
1require gmp_${PV}.bb
2
3FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/gmp-${PV}"
4S = "${WORKDIR}/gmp-${PV}"
5
6inherit native
7
8# darwin 'hacks'
9EXTRA_OECONF_build-darwin = " --enable-shared "
10OLD_STAGING := "${STAGING_BINDIR}"
11OLD_TARGET := "${TARGET_SYS}"
12OLD_HOST := "${HOST_SYS}"
13OLD_BUILD := "${BUILD_SYS}"
14
15PATH_prepend_build-darwin = "${OLD_STAGING}/${OLD_HOST}:${OLD_STAGING}:"
16
17TARGET_SYS_build-darwin = "none-apple-darwin"
18HOST_SYS_build-darwin = "none-apple-darwin"
19BUILD_SYS_build-darwin = "none-apple-darwin"
20
21do_compile_append_build-darwin() {
22 oe_runmake check
23}
diff --git a/meta/packages/gmp/gmp-native_4.1.2.bb b/meta/packages/gmp/gmp-native_4.1.2.bb
deleted file mode 100644
index c8160ca14e..0000000000
--- a/meta/packages/gmp/gmp-native_4.1.2.bb
+++ /dev/null
@@ -1,7 +0,0 @@
1require gmp_${PV}.bb
2
3FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/gmp-${PV}"
4S = "${WORKDIR}/gmp-${PV}"
5
6inherit native
7
diff --git a/meta/packages/gmp/gmp-native_4.2.1.bb b/meta/packages/gmp/gmp-native_4.2.1.bb
new file mode 100644
index 0000000000..8594f2cb0b
--- /dev/null
+++ b/meta/packages/gmp/gmp-native_4.2.1.bb
@@ -0,0 +1,2 @@
1PV = "4.2.1"
2require gmp-native.inc
diff --git a/meta/packages/gmp/gmp_4.1.4.bb b/meta/packages/gmp/gmp.inc
index d80e728dc4..ad179165f3 100644
--- a/meta/packages/gmp/gmp_4.1.4.bb
+++ b/meta/packages/gmp/gmp.inc
@@ -3,12 +3,9 @@ DESCRIPTION = "GNU multiprecision arithmetic library"
3HOMEPAGE = "http://www.swox.com/gmp/" 3HOMEPAGE = "http://www.swox.com/gmp/"
4LICENSE = "GPL LGPL" 4LICENSE = "GPL LGPL"
5 5
6PR = "r1"
7
8SRC_URI = "ftp://ftp.gnu.org/gnu/gmp/gmp-${PV}.tar.bz2 \ 6SRC_URI = "ftp://ftp.gnu.org/gnu/gmp/gmp-${PV}.tar.bz2 \
9 file://configure.patch;patch=1 \ 7 file://configure.patch;patch=1 \
10 file://amd64.patch;patch=1 \ 8 file://amd64.patch;patch=1"
11 file://sh4-asmfix.patch;patch=1"
12 9
13inherit autotools 10inherit autotools
14 11
diff --git a/meta/packages/gmp/gmp_4.1.2.bb b/meta/packages/gmp/gmp_4.1.2.bb
deleted file mode 100644
index d7456175a1..0000000000
--- a/meta/packages/gmp/gmp_4.1.2.bb
+++ /dev/null
@@ -1,18 +0,0 @@
1SECTION = "libs"
2DESCRIPTION = "GNU multiprecision arithmetic library"
3HOMEPAGE = "http://www.swox.com/gmp/"
4LICENSE = "GPL LGPL"
5
6SRC_URI = "ftp://mirrors.kernel.org/gnu/gmp/gmp-${PV}.tar.gz \
7 file://configure.patch;patch=1 \
8 file://amd64.patch;patch=1 \
9 file://gcc-compile.patch;patch=1 "
10
11inherit autotools
12
13acpaths = ""
14
15do_stage () {
16 oe_libinstall -so libgmp ${STAGING_LIBDIR}
17 install -m 0644 ${S}/gmp.h ${STAGING_INCDIR}/gmp.h
18}
diff --git a/meta/packages/gmp/gmp_4.2.1.bb b/meta/packages/gmp/gmp_4.2.1.bb
new file mode 100644
index 0000000000..6af2db66a4
--- /dev/null
+++ b/meta/packages/gmp/gmp_4.2.1.bb
@@ -0,0 +1,3 @@
1require gmp.inc
2
3SRC_URI += "file://sh4-asmfix.patch;patch=1" \ No newline at end of file