]> git.pld-linux.org Git - packages/gmp.git/blob - gmp-cpu.patch
- updated to 5.1.1
[packages/gmp.git] / gmp-cpu.patch
1 --- gmp-5.1.1/configure.ac.orig 2013-02-11 16:29:14.000000000 +0100
2 +++ gmp-5.1.1/configure.ac      2013-02-12 21:08:17.609046451 +0100
3 @@ -247,8 +247,12 @@
4    AC_MSG_ERROR([when doing a fat build, disabling assembly will not work])
5  fi
6  
7 -
8 -tmp_host=`echo $host_cpu | sed 's/\./_/'`
9 +AC_ARG_WITH(cpu,
10 +AC_HELP_STRING([--with-cpu],
11 +              [specify CPU type [[default=host_cpu]]]),
12 +[gmp_cpu=$withval], [gmp_cpu=$host_cpu])
13
14 +tmp_host=`echo $gmp_cpu | sed 's/\./_/'`
15  AC_DEFINE_UNQUOTED(HAVE_HOST_CPU_$tmp_host)
16  GMP_DEFINE_RAW("define_not_for_expansion(\`HAVE_HOST_CPU_$tmp_host')", POST)
17  
18 @@ -431,7 +435,7 @@
19  
20    alpha*-*-*)
21      AC_DEFINE(HAVE_HOST_CPU_FAMILY_alpha)
22 -    case $host_cpu in
23 +    case $gmp_cpu in
24        alphaev5* | alphapca5*)
25         path="alpha/ev5 alpha" ;;
26        alphaev67 | alphaev68 | alphaev7*)
27 @@ -455,7 +459,7 @@
28      # compiler errors too easily and is rejected by GMP_PROG_CC_WORKS.  Each
29      # -mcpu=ev6 below has a fallback to -mcpu=ev56 for this reason.
30      #
31 -    case $host_cpu in
32 +    case $gmp_cpu in
33        alpha)        gcc_cflags_cpu="-mcpu=ev4" ;;
34        alphaev5)     gcc_cflags_cpu="-mcpu=ev5" ;;
35        alphaev56)    gcc_cflags_cpu="-mcpu=ev56" ;;
36 @@ -488,7 +492,7 @@
37      # Insns like ctlz which were never available as macros are always
38      # accepted and always generate their plain code.
39      #
40 -    case $host_cpu in
41 +    case $gmp_cpu in
42        alpha)        gcc_cflags_asm="-Wa,-arch,ev4 -Wa,-mev4" ;;
43        alphaev5)     gcc_cflags_asm="-Wa,-arch,ev5 -Wa,-mev5" ;;
44        alphaev56)    gcc_cflags_asm="-Wa,-arch,ev56 -Wa,-mev56" ;;
45 @@ -523,7 +527,7 @@
46         # DEC C V5.9-005 knows ev4, ev5, ev56, pca56, ev6.
47         # Compaq C V6.3-029 adds ev67.
48         #
49 -       case $host_cpu in
50 +       case $gmp_cpu in
51           alpha)       cc_cflags_cpu="-arch~ev4~-tune~ev4" ;;
52           alphaev5)    cc_cflags_cpu="-arch~ev5~-tune~ev5" ;;
53           alphaev56)   cc_cflags_cpu="-arch~ev56~-tune~ev56" ;;
54 @@ -640,7 +644,7 @@
55      # (Can't remember why this isn't done already, have to check what .asm
56      # files are available in each and how they run on a typical 2.0 cpu.)
57      #
58 -    case $host_cpu in
59 +    case $gmp_cpu in
60        hppa1.0*)    path="pa32" ;;
61        hppa7000*)   path="pa32/hppa1_1 pa32" ;;
62        hppa2.0* | hppa64)
63 @@ -658,13 +662,13 @@
64      # probably be safe, but let's not take the chance.  In any case, a
65      # configuration like --host=hppa2.0 ABI=1.0 is far from optimal.
66      #
67 -    case $host_cpu in
68 +    case $gmp_cpu in
69        hppa1.0*)           gcc_cflags_arch="-mpa-risc-1-0" ;;
70        *)                  # default to 7100
71                            gcc_cflags_arch="-mpa-risc-1-1" ;;
72      esac
73  
74 -    case $host_cpu in
75 +    case $gmp_cpu in
76        hppa1.0*)    cc_cflags="+O2" ;;
77        *)           # default to 7100
78                     cc_cflags="+DA1.1 +O2" ;;
79 @@ -731,7 +735,7 @@
80      SPEED_CYCLECOUNTER_OBJ=ia64.lo
81      any_32_testlist="sizeof-long-4"
82  
83 -    case $host_cpu in
84 +    case $gmp_cpu in
85        itanium)   path="ia64/itanium  ia64" ;;
86        itanium2)  path="ia64/itanium2 ia64" ;;
87        *)         path="ia64" ;;
88 @@ -741,7 +745,7 @@
89      gcc_32_cflags_optlist=$gcc_64_cflags_optlist
90  
91      # gcc pre-release 3.4 adds -mtune itanium and itanium2
92 -    case $host_cpu in
93 +    case $gmp_cpu in
94        itanium)   gcc_cflags_tune="-mtune=itanium" ;;
95        itanium2)  gcc_cflags_tune="-mtune=itanium2" ;;
96      esac
97 @@ -803,7 +807,7 @@
98      # gcc 2.95 adds -mcpu32, -m68060.
99      # FIXME: Maybe "-m68020 -mnobitfield" would suit cpu32 on 2.7.2.
100      #
101 -    case $host_cpu in
102 +    case $gmp_cpu in
103      m68020)  gcc_cflags_arch="-m68020" ;;
104      m68030)  gcc_cflags_arch="-m68030" ;;
105      m68040)  gcc_cflags_arch="-m68040" ;;
106 @@ -815,7 +819,7 @@
107      # FIXME: m68k/mc68020 looks like it's ok for cpu32, but this wants to be
108      # tested.  Will need to introduce an m68k/cpu32 if m68k/mc68020 ever uses
109      # the bitfield instructions.
110 -    case $host_cpu in
111 +    case $gmp_cpu in
112      [m680[234]0 | m68360])  path="m68k/mc68020 m68k" ;;
113      *)                      path="m68k" ;;
114      esac
115 @@ -922,7 +926,7 @@
116      SPEED_CYCLECOUNTER_OBJ=powerpc.lo
117      cyclecounter_size=0
118  
119 -    case $host_cpu in
120 +    case $gmp_cpu in
121        powerpc740 | powerpc750)
122          path="powerpc32/750 powerpc32" ;;
123        powerpc7400 | powerpc7410)
124 @@ -933,7 +937,7 @@
125          path="powerpc32" ;;
126      esac
127  
128 -    case $host_cpu in
129 +    case $gmp_cpu in
130        powerpc401)   gcc_cflags_cpu="-mcpu=401" ;;
131        powerpc403)   gcc_cflags_cpu="-mcpu=403"
132                     xlc_cflags_arch="-qarch=403 -qarch=ppc" ;;
133 @@ -1251,7 +1255,7 @@
134      any_testlist="sizeof-long-4"
135      GMP_INCLUDE_MPN(sparc32/sparc-defs.m4)
136  
137 -    case $host_cpu in
138 +    case $gmp_cpu in
139        sparcv8 | microsparc | turbosparc)
140          path="sparc32/v8 sparc32" ;;
141        supersparc)
142 @@ -1278,7 +1282,7 @@
143      # latter would be used in the 64-bit ABI on systems like "*bsd" where
144      # abilist="64" only.
145      #
146 -    case $host_cpu in
147 +    case $gmp_cpu in
148        sparc64 | sparcv9* | ultrasparc*)
149          gcc_32_cflags="$gcc_cflags -Wa,-xarch=v8plus" ;;
150      esac
151 @@ -1294,7 +1298,7 @@
152      # gcc 3.2 adds nothing.
153      # gcc 3.3 adds ultrasparc3.
154      #
155 -    case $host_cpu in
156 +    case $gmp_cpu in
157        supersparc)           gcc_cflags_cpu="-mcpu=supersparc -msupersparc" ;;
158        sparcv8 | microsparc | turbosparc)
159                             gcc_cflags_cpu="-mcpu=v8 -mv8" ;;
160 @@ -1316,7 +1320,7 @@
161  
162          # SunOS cc doesn't know -xarch, apparently always generating v7
163          # code, so make this optional
164 -       case $host_cpu in
165 +       case $gmp_cpu in
166           sparcv8 | microsparc | supersparc | turbosparc)
167                                               cc_cflags_arch="-xarch=v8" ;;
168           sparc64 | sparcv9* | ultrasparc*)   cc_cflags_arch="-xarch=v8plus" ;;
169 @@ -1331,7 +1335,7 @@
170         # FIXME: Which of ultra, ultra2 or ultra2i is the best fallback for
171         # ultrasparc3?
172         #
173 -       case $host_cpu in
174 +       case $gmp_cpu in
175           supersparc)   cc_cflags_cpu="-xchip=super" ;;
176           microsparc)   cc_cflags_cpu="-xchip=micro" ;;
177           turbosparc)   cc_cflags_cpu="-xchip=micro2" ;;
178 @@ -1343,7 +1347,7 @@
179         esac
180      esac
181  
182 -    case $host_cpu in
183 +    case $gmp_cpu in
184        sparc64 | sparcv9* | ultrasparc*)
185          case $host in
186            # Solaris 6 and earlier cannot run ABI=64 since it doesn't save
187 @@ -1370,7 +1374,7 @@
188            *) abilist="64 32" ;;
189          esac
190  
191 -       case $host_cpu in
192 +       case $gmp_cpu in
193           ultrasparc | ultrasparc2 | ultrasparc2i)
194             path_64="sparc64/ultrasparc1234 sparc64" ;;
195           [ultrasparc[34]])
196 @@ -1505,7 +1509,7 @@
197      # duplicate anything.
198      #
199      gcc_cflags_optlist="cpu arch"
200 -    case $host_cpu in
201 +    case $gmp_cpu in
202        i386*)
203         gcc_cflags_cpu="-mtune=i386 -mcpu=i386 -m386"
204         gcc_cflags_arch="-march=i386"
This page took 0.084717 seconds and 4 git commands to generate.