]>
Commit | Line | Data |
---|---|---|
4f965b81 MM |
1 | #! /bin/sh |
2 | ||
3 | # Guess values for system-dependent variables and create Makefiles. | |
4b935ed4 | 4 | # Generated automatically using autoconf version 2.4 |
4f965b81 MM |
5 | # Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc. |
6 | # | |
7 | # This configure script is free software; the Free Software Foundation | |
8 | # gives unlimited permission to copy, distribute and modify it. | |
9 | ||
10 | # Defaults: | |
11 | ac_help= | |
12 | ac_default_prefix=/usr/local | |
13 | # Any additions from configure.in: | |
c494cadd | 14 | ac_help="$ac_help |
73c4941b | 15 | --enable-sim-cflags=opts Extra CFLAGS for use in building simulator" |
c494cadd | 16 | ac_help="$ac_help |
73c4941b | 17 | --enable-sim-warnings=opts Extra CFLAGS for turning on compiler warnings" |
c494cadd | 18 | ac_help="$ac_help |
73c4941b | 19 | --enable-sim-config=file Override default config file" |
c494cadd | 20 | ac_help="$ac_help |
73c4941b | 21 | --enable-sim-opcode=which Override default opcode lookup." |
c494cadd | 22 | ac_help="$ac_help |
73c4941b | 23 | --enable-sim-switch Use a switch instead of a table for instruction call." |
c494cadd | 24 | ac_help="$ac_help |
73c4941b | 25 | --enable-sim-duplicate Expand (duplicate) semantic functions." |
c494cadd | 26 | ac_help="$ac_help |
73c4941b | 27 | --enable-sim-filter=rule Specify filter rules." |
c494cadd | 28 | ac_help="$ac_help |
73c4941b | 29 | --enable-sim-icache=size Specify instruction cache size." |
c494cadd | 30 | ac_help="$ac_help |
73c4941b | 31 | --enable-sim-inline=inlines Specify which functions should be inlined." |
c494cadd | 32 | ac_help="$ac_help |
73c4941b | 33 | --enable-sim-bswap Use the BSWAP instruction on Intel 486s and Pentiums." |
c494cadd | 34 | ac_help="$ac_help |
73c4941b | 35 | --enable-sim-endian=endian Specify target byte endian orientation." |
c494cadd | 36 | ac_help="$ac_help |
73c4941b | 37 | --enable-sim-hostendain=end Specify host byte endian orientation." |
c494cadd | 38 | ac_help="$ac_help |
73c4941b | 39 | --enable-sim-smp=n Specify number of processors to configure for." |
c494cadd | 40 | ac_help="$ac_help |
73c4941b | 41 | --enable-sim-bitsize=n Specify target bitsize (32 or 64)." |
c494cadd | 42 | ac_help="$ac_help |
73c4941b | 43 | --enable-sim-hostbitsize=n Specify host bitsize (32 or 64)." |
c494cadd | 44 | ac_help="$ac_help |
73c4941b | 45 | --enable-sim-env=env Specify target environment (operating, virtual, user)." |
c494cadd | 46 | ac_help="$ac_help |
73c4941b MM |
47 | --enable-sim-timebase Specify whether the PPC timebase is supported." |
48 | ac_help="$ac_help | |
49 | --enable-sim-alignment=align Specify strict or nonstrict alignment." | |
50 | ac_help="$ac_help | |
51 | --enable-sim-trace Specify whether tracing is supported." | |
52 | ac_help="$ac_help | |
53 | --enable-sim-assert Specify whether to perform random assertions." | |
c494cadd | 54 | ac_help="$ac_help |
73c4941b | 55 | --enable-sim-float Specify whether to use host floating point or simulate." |
c494cadd | 56 | ac_help="$ac_help |
73c4941b | 57 | --enable-sim-monitor=mon Specify whether to enable monitoring events." |
c494cadd | 58 | ac_help="$ac_help |
73c4941b | 59 | --enable-sim-function-unit Specify whether detailed functional unit support is built." |
c494cadd | 60 | ac_help="$ac_help |
73c4941b MM |
61 | --enable-sim-model=which Specify PowerPC to model." |
62 | ac_help="$ac_help | |
63 | --enable-sim-default-model=which Specify default PowerPC to model." | |
4f965b81 MM |
64 | |
65 | # Initialize some variables set by options. | |
66 | # The variables have the same names as the options, with | |
67 | # dashes changed to underlines. | |
68 | build=NONE | |
69 | cache_file=./config.cache | |
70 | exec_prefix=NONE | |
71 | host=NONE | |
72 | no_create= | |
73 | nonopt=NONE | |
74 | no_recursion= | |
75 | prefix=NONE | |
76 | program_prefix=NONE | |
77 | program_suffix=NONE | |
78 | program_transform_name=s,x,x, | |
79 | silent= | |
80 | site= | |
81 | srcdir= | |
82 | target=NONE | |
83 | verbose= | |
84 | x_includes=NONE | |
85 | x_libraries=NONE | |
86 | ||
87 | # Initialize some other variables. | |
88 | subdirs= | |
89 | ||
90 | ac_prev= | |
91 | for ac_option | |
92 | do | |
93 | ||
94 | # If the previous option needs an argument, assign it. | |
95 | if test -n "$ac_prev"; then | |
96 | eval "$ac_prev=\$ac_option" | |
97 | ac_prev= | |
98 | continue | |
99 | fi | |
100 | ||
101 | case "$ac_option" in | |
102 | -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; | |
103 | *) ac_optarg= ;; | |
104 | esac | |
105 | ||
106 | # Accept the important Cygnus configure options, so we can diagnose typos. | |
107 | ||
108 | case "$ac_option" in | |
109 | ||
110 | -build | --build | --buil | --bui | --bu | --b) | |
111 | ac_prev=build ;; | |
112 | -build=* | --build=* | --buil=* | --bui=* | --bu=* | --b=*) | |
113 | build="$ac_optarg" ;; | |
114 | ||
115 | -cache-file | --cache-file | --cache-fil | --cache-fi \ | |
116 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) | |
117 | ac_prev=cache_file ;; | |
118 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | |
119 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) | |
120 | cache_file="$ac_optarg" ;; | |
121 | ||
122 | -disable-* | --disable-*) | |
123 | ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` | |
124 | # Reject names that are not valid shell variable names. | |
125 | if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then | |
126 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } | |
127 | fi | |
128 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` | |
129 | eval "enable_${ac_feature}=no" ;; | |
130 | ||
131 | -enable-* | --enable-*) | |
132 | ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` | |
133 | # Reject names that are not valid shell variable names. | |
134 | if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then | |
135 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } | |
136 | fi | |
137 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` | |
138 | case "$ac_option" in | |
139 | *=*) ;; | |
140 | *) ac_optarg=yes ;; | |
141 | esac | |
142 | eval "enable_${ac_feature}='$ac_optarg'" ;; | |
143 | ||
144 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | |
145 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | |
146 | | --exec | --exe | --ex) | |
147 | ac_prev=exec_prefix ;; | |
148 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | |
149 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | |
150 | | --exec=* | --exe=* | --ex=*) | |
151 | exec_prefix="$ac_optarg" ;; | |
152 | ||
153 | -gas | --gas | --ga | --g) | |
154 | # Obsolete; use --with-gas. | |
155 | with_gas=yes ;; | |
156 | ||
157 | -help | --help | --hel | --he) | |
158 | # Omit some internal or obsolete options to make the list less imposing. | |
159 | # This message is too long to be a string in the A/UX 3.1 sh. | |
160 | cat << EOF | |
161 | Usage: configure [options] [host] | |
162 | Options: [defaults in brackets after descriptions] | |
163 | Configuration: | |
164 | --cache-file=FILE cache test results in FILE | |
165 | --help print this message | |
166 | --no-create do not create output files | |
167 | --quiet, --silent do not print \`checking...' messages | |
168 | --version print the version of autoconf that created configure | |
169 | Directory and file names: | |
170 | --prefix=PREFIX install architecture-independent files in PREFIX | |
171 | [$ac_default_prefix] | |
172 | --exec-prefix=PREFIX install architecture-dependent files in PREFIX | |
173 | [same as prefix] | |
174 | --srcdir=DIR find the sources in DIR [configure dir or ..] | |
175 | --program-prefix=PREFIX prepend PREFIX to installed program names | |
176 | --program-suffix=SUFFIX append SUFFIX to installed program names | |
177 | --program-transform-name=PROGRAM run sed PROGRAM on installed program names | |
178 | Host type: | |
179 | --build=BUILD configure for building on BUILD [BUILD=HOST] | |
180 | --host=HOST configure for HOST [guessed] | |
181 | --target=TARGET configure for TARGET [TARGET=HOST] | |
182 | Features and packages: | |
183 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) | |
184 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] | |
185 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] | |
186 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) | |
187 | --x-includes=DIR X include files are in DIR | |
188 | --x-libraries=DIR X library files are in DIR | |
189 | --enable and --with options recognized:$ac_help | |
190 | EOF | |
191 | exit 0 ;; | |
192 | ||
193 | -host | --host | --hos | --ho) | |
194 | ac_prev=host ;; | |
195 | -host=* | --host=* | --hos=* | --ho=*) | |
196 | host="$ac_optarg" ;; | |
197 | ||
198 | -nfp | --nfp | --nf) | |
199 | # Obsolete; use --without-fp. | |
200 | with_fp=no ;; | |
201 | ||
202 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | |
203 | | --no-cr | --no-c) | |
204 | no_create=yes ;; | |
205 | ||
206 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | |
207 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) | |
208 | no_recursion=yes ;; | |
209 | ||
210 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) | |
211 | ac_prev=prefix ;; | |
212 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) | |
213 | prefix="$ac_optarg" ;; | |
214 | ||
215 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ | |
216 | | --program-pre | --program-pr | --program-p) | |
217 | ac_prev=program_prefix ;; | |
218 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ | |
219 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) | |
220 | program_prefix="$ac_optarg" ;; | |
221 | ||
222 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ | |
223 | | --program-suf | --program-su | --program-s) | |
224 | ac_prev=program_suffix ;; | |
225 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ | |
226 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) | |
227 | program_suffix="$ac_optarg" ;; | |
228 | ||
229 | -program-transform-name | --program-transform-name \ | |
230 | | --program-transform-nam | --program-transform-na \ | |
231 | | --program-transform-n | --program-transform- \ | |
232 | | --program-transform | --program-transfor \ | |
233 | | --program-transfo | --program-transf \ | |
234 | | --program-trans | --program-tran \ | |
235 | | --progr-tra | --program-tr | --program-t) | |
236 | ac_prev=program_transform_name ;; | |
237 | -program-transform-name=* | --program-transform-name=* \ | |
238 | | --program-transform-nam=* | --program-transform-na=* \ | |
239 | | --program-transform-n=* | --program-transform-=* \ | |
240 | | --program-transform=* | --program-transfor=* \ | |
241 | | --program-transfo=* | --program-transf=* \ | |
242 | | --program-trans=* | --program-tran=* \ | |
243 | | --progr-tra=* | --program-tr=* | --program-t=*) | |
244 | program_transform_name="$ac_optarg" ;; | |
245 | ||
246 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | |
247 | | -silent | --silent | --silen | --sile | --sil) | |
248 | silent=yes ;; | |
249 | ||
250 | -site | --site | --sit) | |
251 | ac_prev=site ;; | |
252 | -site=* | --site=* | --sit=*) | |
253 | site="$ac_optarg" ;; | |
254 | ||
255 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) | |
256 | ac_prev=srcdir ;; | |
257 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) | |
258 | srcdir="$ac_optarg" ;; | |
259 | ||
260 | -target | --target | --targe | --targ | --tar | --ta | --t) | |
261 | ac_prev=target ;; | |
262 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) | |
263 | target="$ac_optarg" ;; | |
264 | ||
265 | -v | -verbose | --verbose | --verbos | --verbo | --verb) | |
266 | verbose=yes ;; | |
267 | ||
268 | -version | --version | --versio | --versi | --vers) | |
4b935ed4 | 269 | echo "configure generated by autoconf version 2.4" |
4f965b81 MM |
270 | exit 0 ;; |
271 | ||
272 | -with-* | --with-*) | |
273 | ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` | |
274 | # Reject names that are not valid shell variable names. | |
275 | if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then | |
276 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } | |
277 | fi | |
278 | ac_package=`echo $ac_package| sed 's/-/_/g'` | |
279 | case "$ac_option" in | |
280 | *=*) ;; | |
281 | *) ac_optarg=yes ;; | |
282 | esac | |
283 | eval "with_${ac_package}='$ac_optarg'" ;; | |
284 | ||
285 | -without-* | --without-*) | |
286 | ac_package=`echo $ac_option|sed -e 's/-*without-//'` | |
287 | # Reject names that are not valid shell variable names. | |
288 | if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then | |
289 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } | |
290 | fi | |
291 | ac_package=`echo $ac_package| sed 's/-/_/g'` | |
292 | eval "with_${ac_package}=no" ;; | |
293 | ||
294 | --x) | |
295 | # Obsolete; use --with-x. | |
296 | with_x=yes ;; | |
297 | ||
298 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | |
299 | | --x-incl | --x-inc | --x-in | --x-i) | |
300 | ac_prev=x_includes ;; | |
301 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | |
302 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) | |
303 | x_includes="$ac_optarg" ;; | |
304 | ||
305 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ | |
306 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) | |
307 | ac_prev=x_libraries ;; | |
308 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | |
309 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) | |
310 | x_libraries="$ac_optarg" ;; | |
311 | ||
312 | -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; } | |
313 | ;; | |
314 | ||
315 | *) | |
316 | if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then | |
317 | echo "configure: warning: $ac_option: invalid host type" 1>&2 | |
318 | fi | |
319 | if test "x$nonopt" != xNONE; then | |
320 | { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } | |
321 | fi | |
322 | nonopt="$ac_option" | |
323 | ;; | |
324 | ||
325 | esac | |
326 | done | |
327 | ||
328 | if test -n "$ac_prev"; then | |
329 | { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; } | |
330 | fi | |
331 | ||
332 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 | |
333 | ||
334 | # File descriptor usage: | |
335 | # 0 standard input | |
336 | # 1 file creation | |
337 | # 2 errors and warnings | |
338 | # 3 some systems may open it to /dev/tty | |
339 | # 4 used on the Kubota Titan | |
340 | # 6 checking for... messages and results | |
341 | # 5 compiler messages saved in config.log | |
342 | if test "$silent" = yes; then | |
343 | exec 6>/dev/null | |
344 | else | |
345 | exec 6>&1 | |
346 | fi | |
347 | exec 5>./config.log | |
348 | ||
349 | echo "\ | |
350 | This file contains any messages produced by compilers while | |
351 | running configure, to aid debugging if configure makes a mistake. | |
352 | " 1>&5 | |
353 | ||
354 | # Strip out --no-create and --no-recursion so they do not pile up. | |
355 | # Also quote any args containing shell metacharacters. | |
356 | ac_configure_args= | |
357 | for ac_arg | |
358 | do | |
359 | case "$ac_arg" in | |
360 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | |
361 | | --no-cr | --no-c) ;; | |
362 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | |
363 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; | |
364 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) | |
365 | ac_configure_args="$ac_configure_args '$ac_arg'" ;; | |
366 | *) ac_configure_args="$ac_configure_args $ac_arg" ;; | |
367 | esac | |
368 | done | |
369 | ||
370 | # NLS nuisances. | |
371 | # Only set LANG and LC_ALL to C if already set. | |
372 | # These must not be set unconditionally because not all systems understand | |
373 | # e.g. LANG=C (notably SCO). | |
374 | if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi | |
375 | if test "${LANG+set}" = set; then LANG=C; export LANG; fi | |
376 | ||
377 | # confdefs.h avoids OS command line length limits that DEFS can exceed. | |
378 | rm -rf conftest* confdefs.h | |
379 | # AIX cpp loses on an empty file, so make sure it contains at least a newline. | |
380 | echo > confdefs.h | |
381 | ||
382 | # A filename unique to this package, relative to the directory that | |
383 | # configure is in, which we can look for to find out if srcdir is correct. | |
384 | ac_unique_file=Makefile.in | |
385 | ||
386 | # Find the source files, if location was not specified. | |
387 | if test -z "$srcdir"; then | |
388 | ac_srcdir_defaulted=yes | |
389 | # Try the directory containing this script, then its parent. | |
390 | ac_prog=$0 | |
391 | ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` | |
392 | test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. | |
393 | srcdir=$ac_confdir | |
394 | if test ! -r $srcdir/$ac_unique_file; then | |
395 | srcdir=.. | |
396 | fi | |
397 | else | |
398 | ac_srcdir_defaulted=no | |
399 | fi | |
400 | if test ! -r $srcdir/$ac_unique_file; then | |
401 | if test "$ac_srcdir_defaulted" = yes; then | |
402 | { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; } | |
403 | else | |
404 | { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; } | |
405 | fi | |
406 | fi | |
407 | srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` | |
408 | ||
409 | # Prefer explicitly selected file to automatically selected ones. | |
410 | if test -z "$CONFIG_SITE"; then | |
411 | if test "x$prefix" != xNONE; then | |
412 | CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" | |
413 | else | |
414 | CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" | |
415 | fi | |
416 | fi | |
417 | for ac_site_file in $CONFIG_SITE; do | |
418 | if test -r "$ac_site_file"; then | |
419 | echo "loading site script $ac_site_file" | |
420 | . "$ac_site_file" | |
421 | fi | |
422 | done | |
423 | ||
424 | if test -r "$cache_file"; then | |
425 | echo "loading cache $cache_file" | |
426 | . $cache_file | |
427 | else | |
428 | echo "creating cache $cache_file" | |
429 | > $cache_file | |
430 | fi | |
431 | ||
432 | ac_ext=c | |
433 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
434 | ac_cpp='$CPP $CPPFLAGS' | |
435 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5 2>&5' | |
436 | ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5 2>&5' | |
437 | ||
438 | if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then | |
439 | # Stardent Vistra SVR4 grep lacks -e, says [email protected]. | |
440 | if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then | |
441 | ac_n= ac_c=' | |
442 | ' ac_t=' ' | |
443 | else | |
444 | ac_n=-n ac_c= ac_t= | |
445 | fi | |
446 | else | |
447 | ac_n= ac_c='\c' ac_t= | |
448 | fi | |
449 | ||
450 | ||
451 | ||
c494cadd MM |
452 | # Check whether --enable-sim-cflags or --disable-sim-cflags was given. |
453 | enableval="$enable_sim_cflags" | |
454 | if test -n "$enableval"; then | |
455 | case "${enableval}" in | |
456 | yes) sim_cflags="-O2 -fomit-frame-pointer";; | |
457 | no) sim_cflags="";; | |
b3737d33 | 458 | *) sim_cflags=`echo "${enableval}" | sed -e "s/,/ /g"`;; |
c494cadd MM |
459 | esac |
460 | else | |
461 | sim_cflags="" | |
462 | fi | |
463 | ||
73c4941b MM |
464 | # Check whether --enable-sim-warnings or --disable-sim-warnings was given. |
465 | enableval="$enable_sim_warnings" | |
466 | if test -n "$enableval"; then | |
467 | case "${enableval}" in | |
468 | yes) sim_warnings="-Wall";; | |
469 | no) sim_warnings="-w";; | |
470 | *) sim_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;; | |
471 | esac | |
472 | else | |
473 | sim_warnings="" | |
474 | fi | |
475 | ||
c494cadd MM |
476 | # Check whether --enable-sim-config or --disable-sim-config was given. |
477 | enableval="$enable_sim_config" | |
478 | if test -n "$enableval"; then | |
479 | case "${enableval}" in | |
480 | yes) sim_config="std-config.h";; | |
481 | no) sim_config="std-config.h";; | |
482 | *) sim_config="${enableval}";; | |
483 | esac | |
484 | else | |
485 | sim_config="std-config.h" | |
486 | fi | |
487 | ||
488 | # Check whether --enable-sim-opcode or --disable-sim-opcode was given. | |
489 | enableval="$enable_sim_opcode" | |
490 | if test -n "$enableval"; then | |
491 | case "${enableval}" in | |
492 | yes) sim_opcode="ppc-opcode-simple";; | |
493 | no) sim_opcode="ppc-opcode-simple";; | |
494 | *) sim_opcode="ppc-opcode-${enableval}";; | |
495 | esac | |
496 | else | |
497 | sim_opcode="ppc-opcode-simple" | |
498 | fi | |
499 | ||
500 | # Check whether --enable-sim-switch or --disable-sim-switch was given. | |
501 | enableval="$enable_sim_switch" | |
502 | if test -n "$enableval"; then | |
503 | case "${enableval}" in | |
504 | yes) sim_switch="-s";; | |
505 | *) sim_switch="";; | |
506 | esac | |
507 | else | |
508 | sim_switch="" | |
509 | fi | |
510 | ||
511 | # Check whether --enable-sim-duplicate or --disable-sim-duplicate was given. | |
512 | enableval="$enable_sim_duplicate" | |
513 | if test -n "$enableval"; then | |
514 | case "${enableval}" in | |
515 | yes) sim_dup="-e";; | |
516 | *) sim_dup="";; | |
517 | esac | |
518 | else | |
519 | sim_dup="" | |
520 | fi | |
521 | ||
522 | # Check whether --enable-sim-filter or --disable-sim-filter was given. | |
523 | enableval="$enable_sim_filter" | |
524 | if test -n "$enableval"; then | |
525 | case "${enableval}" in | |
526 | yes) sim_filter="";; | |
527 | *) sim_filter="-f $enableval";; | |
528 | esac | |
529 | else | |
530 | sim_filter="-f 64" | |
531 | fi | |
532 | ||
533 | # Check whether --enable-sim-icache or --disable-sim-icache was given. | |
534 | enableval="$enable_sim_icache" | |
535 | if test -n "$enableval"; then | |
536 | case "${enableval}" in | |
537 | yes) sim_icache="-r 1024";; | |
538 | *) sim_icache="";; | |
539 | esac | |
540 | else | |
541 | sim_icache="" | |
542 | fi | |
543 | ||
544 | # Check whether --enable-sim-inline or --disable-sim-inline was given. | |
545 | enableval="$enable_sim_inline" | |
546 | if test -n "$enableval"; then | |
547 | sim_inline="" | |
548 | case "$enableval" in | |
b3737d33 MM |
549 | no) sim_inline="";; |
550 | 0) sim_inline="-DDEFAULT_INLINE=0";; | |
551 | yes | 2) sim_inline="-DDEFAULT_INLINE=2";; | |
552 | 1) sim_inline="-DDEFAULT_INLINE=1";; | |
c494cadd MM |
553 | *) for x in `echo "$enableval" | sed -e "s/,/ /g"`; do |
554 | new_flag="" | |
555 | case "$x" in | |
556 | *_INLINE=*) new_flag="-D$x";; | |
557 | *_INLINE) new_flag="-D$x=2";; | |
558 | *=*) new_flag=`sed -e "s/=/_INLINE=/" -e "s/^/-D/"`;; | |
559 | *) new_flag="-D$x""_INLINE=2";; | |
560 | esac | |
561 | if x"$sim_inline" = x""; then | |
562 | sim_inline="$new_flag" | |
563 | else | |
564 | sim_inline="$flags $new_flag" | |
565 | fi | |
566 | done;; | |
567 | esac | |
568 | else | |
569 | sim_inline="" | |
570 | fi | |
571 | ||
572 | # Check whether --enable-sim-bswap or --disable-sim-bswap was given. | |
573 | enableval="$enable_sim_bswap" | |
574 | if test -n "$enableval"; then | |
575 | case "${enableval}" in | |
576 | yes) sim_bswap="-DWITH_BSWAP=1";; | |
577 | no) sim_bswap="-DWITH_BSWAP=0";; | |
578 | *) sim_bswap="";; | |
579 | esac | |
580 | else | |
581 | sim_bswap="" | |
582 | fi | |
583 | ||
584 | # Check whether --enable-sim-endian or --disable-sim-endian was given. | |
585 | enableval="$enable_sim_endian" | |
586 | if test -n "$enableval"; then | |
587 | case "${enableval}" in | |
588 | yes) case "$target" in | |
589 | *powerpc-*) sim_endian="-DWITH_TARGET_BYTE_ORDER=BIG_ENDIAN";; | |
590 | *powerpcle-*) sim_endian="-DWITH_TARGET_BYTE_ORDER=LITTLE_ENDIAN";; | |
591 | *) echo "Unknown target $target" 1>&6; sim_endian="-DWITH_TARGET_BYTE_ORDER=0";; | |
592 | esac;; | |
593 | no) sim_endian="-DWITH_TARGET_BYTE_ORDER=0";; | |
594 | b*|B*) sim_endian="-DWITH_TARGET_BYTE_ORDER=BIG_ENDIAN";; | |
595 | l*|L*) sim_endian="-DWITH_TARGET_BYTE_ORDER=LITTLE_ENDIAN";; | |
596 | *) sim_endian="";; | |
597 | esac | |
598 | else | |
599 | sim_endian="" | |
600 | fi | |
601 | ||
602 | # Check whether --enable-sim-hostendian or --disable-sim-hostendian was given. | |
603 | enableval="$enable_sim_hostendian" | |
604 | if test -n "$enableval"; then | |
605 | case "${enableval}" in | |
606 | no) sim_hostendian="-DWITH_HOST_BYTE_ORDER=0";; | |
607 | b*|B*) sim_hostendian="-DWITH_HOST_BYTE_ORDER=BIG_ENDIAN";; | |
608 | l*|L*) sim_hostendian="-DWITH_HOST_BYTE_ORDER=LITTLE_ENDIAN";; | |
609 | *) sim_hostendian="";; | |
610 | esac | |
611 | else | |
612 | sim_hostendian="" | |
613 | fi | |
614 | ||
615 | # Check whether --enable-sim-smp or --disable-sim-smp was given. | |
616 | enableval="$enable_sim_smp" | |
617 | if test -n "$enableval"; then | |
618 | case "${enableval}" in | |
619 | yes) sim_smp="-DWITH_SMP=2";; | |
620 | no) sim_smp="-DWITH_SMP=0";; | |
621 | *) sim_smp="-DWITH_SMP=$enableval";; | |
622 | esac | |
623 | else | |
624 | sim_smp="" | |
625 | fi | |
626 | ||
627 | # Check whether --enable-sim-bitsize or --disable-sim-bitsize was given. | |
628 | enableval="$enable_sim_bitsize" | |
629 | if test -n "$enableval"; then | |
630 | case "${enableval}" in | |
631 | yes) sim_bitsize="";; | |
632 | no) sim_bitsize="";; | |
633 | *) sim_bitsize="-DWITH_TARGET_WORD_BITSIZE=$enableval";; | |
634 | esac | |
635 | else | |
636 | sim_bitsize="" | |
637 | fi | |
638 | ||
639 | # Check whether --enable-sim-hostbitsize or --disable-sim-hostbitsize was given. | |
640 | enableval="$enable_sim_hostbitsize" | |
641 | if test -n "$enableval"; then | |
642 | case "${enableval}" in | |
643 | yes) sim_hostbitsize="";; | |
644 | no) sim_hostbitsize="";; | |
645 | *) sim_hostbitsize="-DWITH_HOST_WORD_BITSIZE=$enableval";; | |
646 | esac | |
647 | else | |
648 | sim_hostbitsize="" | |
649 | fi | |
650 | ||
651 | # Check whether --enable-sim-env or --disable-sim-env was given. | |
652 | enableval="$enable_sim_env" | |
653 | if test -n "$enableval"; then | |
654 | case "${enableval}" in | |
655 | operating | os | oea) sim_env="-DWITH_ENVIRONMENT=OPERATING_ENVIRONMENT";; | |
656 | virtual | vea) sim_env="-DWITH_ENVIRONMENT=VIRTUAL_ENVIRONMENT";; | |
657 | user | uea) sim_env="-DWITH_ENVIRONMENT=USER_ENVIRONMENT";; | |
658 | *) sim_env="";; | |
659 | esac | |
660 | else | |
661 | sim_env="" | |
662 | fi | |
663 | ||
664 | # Check whether --enable-sim-timebase or --disable-sim-timebase was given. | |
665 | enableval="$enable_sim_timebase" | |
666 | if test -n "$enableval"; then | |
667 | case "${enableval}" in | |
668 | yes) sim_timebase="-DWITH_TIME_BASE=1";; | |
669 | no) sim_timebase="-DWITH_TIME_BASE=0";; | |
670 | *) sim_timebase="";; | |
671 | esac | |
672 | else | |
673 | sim_timebase="" | |
674 | fi | |
675 | ||
676 | # Check whether --enable-sim-alignment or --disable-sim-alignment was given. | |
677 | enableval="$enable_sim_alignment" | |
678 | if test -n "$enableval"; then | |
73c4941b MM |
679 | case "${enableval}" in |
680 | yes | strict | STRICT) sim_alignment="-DWITH_ALIGNMENT=STRICT_ALIGNMENT";; | |
681 | no | nonstrict | NONSTRICT) sim_alignment="-DWITH_ALIGNMENT=NOSTRICT_ALIGNMENT";; | |
682 | *) sim_alignment="-DWITH_ALIGNMENT=$enableval";; | |
683 | esac | |
684 | else | |
c494cadd MM |
685 | sim_alignment="" |
686 | fi | |
687 | ||
688 | # Check whether --enable-sim-trace or --disable-sim-trace was given. | |
689 | enableval="$enable_sim_trace" | |
690 | if test -n "$enableval"; then | |
691 | case "${enableval}" in | |
692 | yes) sim_trace="-DWITH_TRACE=1";; | |
693 | no) sim_trace="-DWITH_TRACE=0";; | |
694 | *) sim_trace="";; | |
695 | esac | |
696 | else | |
697 | sim_trace="" | |
698 | fi | |
699 | ||
700 | # Check whether --enable-sim-assert or --disable-sim-assert was given. | |
701 | enableval="$enable_sim_assert" | |
702 | if test -n "$enableval"; then | |
703 | case "${enableval}" in | |
704 | yes) sim_assert="-DWITH_ASSERT=1";; | |
705 | no) sim_assert="-DWITH_ASSERT=0";; | |
706 | *) sim_assert="";; | |
707 | esac | |
708 | else | |
709 | sim_assert="" | |
710 | fi | |
711 | ||
712 | # Check whether --enable-sim-float or --disable-sim-float was given. | |
713 | enableval="$enable_sim_float" | |
714 | if test -n "$enableval"; then | |
715 | case "${enableval}" in | |
716 | yes | hard) sim_float="-DWITH_FLOATING_POINT=HARD_FLOATING_POINT";; | |
717 | no | soft) sim_float="-DWITH_FLOATING_POINT=SOFT_FLOATING_POINT";; | |
718 | *) sim_float="";; | |
719 | esac | |
720 | else | |
721 | sim_float="" | |
722 | fi | |
723 | ||
724 | # Check whether --enable-sim-monitor or --disable-sim-monitor was given. | |
725 | enableval="$enable_sim_monitor" | |
726 | if test -n "$enableval"; then | |
727 | case "${enableval}" in | |
728 | yes) sim_mon="-DWITH_MON='MONITOR_INSTRUCTION_ISSUE | MONITOR_LOAD_STORE_UNIT'";; | |
729 | no) sim_mon="-DWITH_MON=0";; | |
730 | instruction) sim_mon="-DWITH_MON=MONITOR_INSTRUCTION_ISSUE";; | |
731 | memory) sim_mon="-DWITH_MON=MONITOR_LOAD_STORE_UNIT";; | |
732 | *) sim_mon="-DWITH_MON='$enableval'";; | |
733 | esac | |
734 | else | |
735 | sim_float="" | |
736 | fi | |
737 | ||
73c4941b MM |
738 | # Check whether --enable-sim-function-unit or --disable-sim-function-unit was given. |
739 | enableval="$enable_sim_function_unit" | |
740 | if test -n "$enableval"; then | |
741 | case "${enableval}" in | |
742 | yes) sim_func="-DWITH_FUNCTION_UNIT=1";; | |
743 | no) sim_func="-DWITH_FUNCTION_UNIT=0";; | |
744 | *) sim_func="";; | |
745 | esac | |
746 | else | |
747 | sim_func="" | |
748 | fi | |
749 | ||
750 | # Check whether --enable-sim-model or --disable-sim-model was given. | |
751 | enableval="$enable_sim_model" | |
752 | if test -n "$enableval"; then | |
753 | case "${enableval}" in | |
754 | yes) sim_model="";; | |
755 | no) sim_model="";; | |
756 | *) sim_model="-DWITH_PPC_MODEL=${enableval}";; | |
757 | esac | |
758 | else | |
759 | sim_model="" | |
760 | fi | |
761 | ||
762 | # Check whether --enable-sim-default-model or --disable-sim-default-model was given. | |
763 | enableval="$enable_sim_default_model" | |
764 | if test -n "$enableval"; then | |
765 | case "${enableval}" in | |
766 | yes) sim_default_model="";; | |
767 | no) sim_default_model="";; | |
768 | *) sim_default_model="-DWITH_DEFAULT_PPC_MODEL=${enableval}";; | |
769 | esac | |
770 | else | |
771 | sim_model="" | |
772 | fi | |
773 | ||
4b935ed4 MM |
774 | |
775 | ||
4f965b81 MM |
776 | ac_aux_dir= |
777 | for ac_dir in `cd $srcdir;pwd`/../.. $srcdir/`cd $srcdir;pwd`/../..; do | |
778 | if test -f $ac_dir/install-sh; then | |
779 | ac_aux_dir=$ac_dir | |
780 | ac_install_sh="$ac_aux_dir/install-sh -c" | |
781 | break | |
782 | elif test -f $ac_dir/install.sh; then | |
783 | ac_aux_dir=$ac_dir | |
784 | ac_install_sh="$ac_aux_dir/install.sh -c" | |
785 | break | |
786 | fi | |
787 | done | |
788 | if test -z "$ac_aux_dir"; then | |
789 | { echo "configure: error: can not find install-sh or install.sh in `cd $srcdir;pwd`/../.. $srcdir/`cd $srcdir;pwd`/../.." 1>&2; exit 1; } | |
790 | fi | |
791 | ac_config_guess=$ac_aux_dir/config.guess | |
792 | ac_config_sub=$ac_aux_dir/config.sub | |
793 | ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. | |
794 | ||
795 | ||
796 | # Do some error checking and defaulting for the host and target type. | |
797 | # The inputs are: | |
798 | # configure --host=HOST --target=TARGET --build=BUILD NONOPT | |
799 | # | |
800 | # The rules are: | |
801 | # 1. You are not allowed to specify --host, --target, and nonopt at the | |
802 | # same time. | |
803 | # 2. Host defaults to nonopt. | |
804 | # 3. If nonopt is not specified, then host defaults to the current host, | |
805 | # as determined by config.guess. | |
806 | # 4. Target and build default to nonopt. | |
807 | # 5. If nonopt is not specified, then target and build default to host. | |
808 | ||
809 | # The aliases save the names the user supplied, while $host etc. | |
810 | # will get canonicalized. | |
811 | case $host---$target---$nonopt in | |
812 | NONE---*---* | *---NONE---* | *---*---NONE) ;; | |
813 | *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;; | |
814 | esac | |
815 | ||
816 | ||
817 | # Make sure we can run config.sub. | |
818 | if $ac_config_sub sun4 >/dev/null 2>&1; then : | |
819 | else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; } | |
820 | fi | |
821 | ||
822 | echo $ac_n "checking host system type""... $ac_c" 1>&6 | |
823 | ||
824 | host_alias=$host | |
825 | case "$host_alias" in | |
826 | NONE) | |
827 | case $nonopt in | |
828 | NONE) | |
829 | if host_alias=`$ac_config_guess`; then : | |
830 | else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; } | |
831 | fi ;; | |
832 | *) host_alias=$nonopt ;; | |
833 | esac ;; | |
834 | esac | |
835 | ||
836 | host=`$ac_config_sub $host_alias` | |
837 | host_cpu=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'` | |
838 | host_vendor=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'` | |
839 | host_os=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'` | |
840 | echo "$ac_t""$host" 1>&6 | |
841 | ||
842 | echo $ac_n "checking target system type""... $ac_c" 1>&6 | |
843 | ||
844 | target_alias=$target | |
845 | case "$target_alias" in | |
846 | NONE) | |
847 | case $nonopt in | |
848 | NONE) target_alias=$host_alias ;; | |
849 | *) target_alias=$nonopt ;; | |
850 | esac ;; | |
851 | esac | |
852 | ||
853 | target=`$ac_config_sub $target_alias` | |
854 | target_cpu=`echo $target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'` | |
855 | target_vendor=`echo $target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'` | |
856 | target_os=`echo $target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'` | |
857 | echo "$ac_t""$target" 1>&6 | |
858 | ||
859 | echo $ac_n "checking build system type""... $ac_c" 1>&6 | |
860 | ||
861 | build_alias=$build | |
862 | case "$build_alias" in | |
863 | NONE) | |
864 | case $nonopt in | |
865 | NONE) build_alias=$host_alias ;; | |
866 | *) build_alias=$nonopt ;; | |
867 | esac ;; | |
868 | esac | |
869 | ||
870 | build=`$ac_config_sub $build_alias` | |
871 | build_cpu=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'` | |
872 | build_vendor=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'` | |
873 | build_os=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'` | |
874 | echo "$ac_t""$build" 1>&6 | |
875 | ||
876 | test "$host_alias" != "$target_alias" && | |
877 | test "$program_prefix$program_suffix$program_transform_name" = \ | |
878 | NONENONEs,x,x, && | |
879 | program_prefix=${target_alias}- | |
880 | ||
881 | if test "$program_transform_name" = s,x,x,; then | |
882 | program_transform_name= | |
883 | else | |
884 | # Double any \ or $. | |
885 | echo 's,\\,\\\\,g; s,\$,$$,g' > conftestsed | |
886 | program_transform_name="`echo $program_transform_name|sed -f conftestsed`" | |
887 | rm -f conftestsed | |
888 | fi | |
889 | test "$program_prefix" != NONE && | |
890 | program_transform_name="s,^,${program_prefix},; $program_transform_name" | |
891 | # Use a double $ so make ignores it. | |
892 | test "$program_suffix" != NONE && | |
893 | program_transform_name="s,\$\$,${program_suffix},; $program_transform_name" | |
894 | ||
895 | # sed with no file args requires a program. | |
896 | test "$program_transform_name" = "" && program_transform_name="s,x,x," | |
897 | ||
898 | ||
899 | . ${srcdir}/../../bfd/configure.host | |
900 | ||
4b935ed4 MM |
901 | # Extract the first word of "gcc", so it can be a program name with args. |
902 | set dummy gcc; ac_word=$2 | |
903 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
904 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then | |
905 | echo $ac_n "(cached) $ac_c" 1>&6 | |
906 | else | |
907 | if test -n "$CC"; then | |
908 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
909 | else | |
910 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
911 | for ac_dir in $PATH; do | |
912 | test -z "$ac_dir" && ac_dir=. | |
913 | if test -f $ac_dir/$ac_word; then | |
914 | ac_cv_prog_CC="gcc" | |
915 | break | |
916 | fi | |
917 | done | |
918 | IFS="$ac_save_ifs" | |
919 | test -z "$ac_cv_prog_CC" && ac_cv_prog_CC="cc" | |
920 | fi | |
921 | fi | |
922 | CC="$ac_cv_prog_CC" | |
923 | if test -n "$CC"; then | |
924 | echo "$ac_t""$CC" 1>&6 | |
925 | else | |
926 | echo "$ac_t""no" 1>&6 | |
927 | fi | |
928 | ||
929 | ||
930 | echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 | |
931 | if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then | |
932 | echo $ac_n "(cached) $ac_c" 1>&6 | |
933 | else | |
934 | cat > conftest.c <<EOF | |
935 | #ifdef __GNUC__ | |
936 | yes; | |
937 | #endif | |
938 | EOF | |
939 | if ${CC-cc} -E conftest.c 2>&5 | egrep yes >/dev/null 2>&1; then | |
940 | ac_cv_prog_gcc=yes | |
941 | else | |
942 | ac_cv_prog_gcc=no | |
943 | fi | |
944 | fi | |
945 | echo "$ac_t""$ac_cv_prog_gcc" 1>&6 | |
946 | if test $ac_cv_prog_gcc = yes; then | |
947 | GCC=yes | |
948 | if test "${CFLAGS+set}" != set; then | |
949 | echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 | |
950 | if eval "test \"`echo '$''{'ac_cv_prog_gcc_g'+set}'`\" = set"; then | |
951 | echo $ac_n "(cached) $ac_c" 1>&6 | |
952 | else | |
953 | echo 'void f(){}' > conftest.c | |
954 | if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then | |
955 | ac_cv_prog_gcc_g=yes | |
956 | else | |
957 | ac_cv_prog_gcc_g=no | |
958 | fi | |
959 | rm -f conftest* | |
960 | ||
961 | fi | |
962 | echo "$ac_t""$ac_cv_prog_gcc_g" 1>&6 | |
963 | if test $ac_cv_prog_gcc_g = yes; then | |
964 | CFLAGS="-g -O" | |
965 | else | |
966 | CFLAGS="-O" | |
967 | fi | |
968 | fi | |
969 | else | |
970 | GCC= | |
971 | test "${CFLAGS+set}" = set || CFLAGS="-g" | |
972 | fi | |
973 | ||
974 | ||
975 | ||
976 | AR=${AR-ar} | |
977 | ||
978 | # Extract the first word of "ranlib", so it can be a program name with args. | |
979 | set dummy ranlib; ac_word=$2 | |
980 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
981 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then | |
982 | echo $ac_n "(cached) $ac_c" 1>&6 | |
983 | else | |
984 | if test -n "$RANLIB"; then | |
985 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
986 | else | |
987 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
988 | for ac_dir in $PATH; do | |
989 | test -z "$ac_dir" && ac_dir=. | |
990 | if test -f $ac_dir/$ac_word; then | |
991 | ac_cv_prog_RANLIB="ranlib" | |
992 | break | |
993 | fi | |
994 | done | |
995 | IFS="$ac_save_ifs" | |
996 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" | |
997 | fi | |
998 | fi | |
999 | RANLIB="$ac_cv_prog_RANLIB" | |
1000 | if test -n "$RANLIB"; then | |
1001 | echo "$ac_t""$RANLIB" 1>&6 | |
1002 | else | |
1003 | echo "$ac_t""no" 1>&6 | |
1004 | fi | |
1005 | ||
1006 | ||
c494cadd MM |
1007 | |
1008 | ||
1009 | ||
1010 | ||
1011 | ||
1012 | ||
1013 | ||
1014 | ||
1015 | ||
1016 | ||
1017 | ||
1018 | ||
1019 | ||
1020 | ||
1021 | ||
1022 | ||
73c4941b MM |
1023 | |
1024 | ||
1025 | ||
1026 | ||
c494cadd MM |
1027 | |
1028 | ||
1029 | ||
1030 | ||
1031 | ||
1032 | for ac_func in getrusage | |
1033 | do | |
1034 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
1035 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then | |
1036 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1037 | else | |
1038 | cat > conftest.$ac_ext <<EOF | |
73c4941b | 1039 | #line 1040 "configure" |
c494cadd MM |
1040 | #include "confdefs.h" |
1041 | /* System header to define __stub macros and hopefully few prototypes, | |
1042 | which can conflict with char $ac_func(); below. */ | |
1043 | #include <assert.h> | |
1044 | /* Override any gcc2 internal prototype to avoid an error. */ | |
1045 | char $ac_func(); | |
1046 | ||
1047 | int main() { return 0; } | |
1048 | int t() { | |
1049 | ||
1050 | /* The GNU C library defines this for functions which it implements | |
1051 | to always fail with ENOSYS. Some functions are actually named | |
1052 | something starting with __ and the normal name is an alias. */ | |
1053 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
1054 | choke me | |
1055 | #else | |
1056 | $ac_func(); | |
1057 | #endif | |
1058 | ||
1059 | ; return 0; } | |
1060 | EOF | |
1061 | if eval $ac_link; then | |
1062 | rm -rf conftest* | |
1063 | eval "ac_cv_func_$ac_func=yes" | |
1064 | else | |
1065 | rm -rf conftest* | |
1066 | eval "ac_cv_func_$ac_func=no" | |
1067 | fi | |
1068 | rm -f conftest* | |
1069 | ||
1070 | fi | |
1071 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
1072 | echo "$ac_t""yes" 1>&6 | |
1073 | ac_tr_func=HAVE_`echo $ac_func | tr '[a-z]' '[A-Z]'` | |
1074 | cat >> confdefs.h <<EOF | |
1075 | #define $ac_tr_func 1 | |
1076 | EOF | |
1077 | ||
1078 | else | |
1079 | echo "$ac_t""no" 1>&6 | |
1080 | fi | |
1081 | done | |
1082 | ||
1083 | ||
4b935ed4 MM |
1084 | # Put a plausible default for CC_FOR_BUILD in Makefile. |
1085 | # If we cannot run a trivial program, we must be cross compiling. | |
1086 | echo $ac_n "checking whether cross-compiling""... $ac_c" 1>&6 | |
1087 | if eval "test \"`echo '$''{'ac_cv_c_cross'+set}'`\" = set"; then | |
1088 | echo $ac_n "(cached) $ac_c" 1>&6 | |
4f965b81 | 1089 | else |
4b935ed4 MM |
1090 | if test "$cross_compiling" = yes; then |
1091 | ac_cv_c_cross=yes | |
1092 | else | |
1093 | cat > conftest.$ac_ext <<EOF | |
73c4941b | 1094 | #line 1095 "configure" |
4b935ed4 MM |
1095 | #include "confdefs.h" |
1096 | main(){return(0);} | |
1097 | EOF | |
1098 | eval $ac_link | |
1099 | if test -s conftest && (./conftest; exit) 2>/dev/null; then | |
1100 | ac_cv_c_cross=no | |
1101 | else | |
1102 | ac_cv_c_cross=yes | |
1103 | fi | |
4f965b81 | 1104 | fi |
4b935ed4 MM |
1105 | rm -fr conftest* |
1106 | fi | |
1107 | cross_compiling=$ac_cv_c_cross | |
1108 | echo "$ac_t""$ac_cv_c_cross" 1>&6 | |
4f965b81 | 1109 | |
4b935ed4 MM |
1110 | if test "x$cross_compiling" = "xno"; then |
1111 | CC_FOR_BUILD='$(CC)' | |
1112 | else | |
1113 | CC_FOR_BUILD=gcc | |
4f965b81 MM |
1114 | fi |
1115 | ||
1116 | ||
4b935ed4 MM |
1117 | echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 |
1118 | # On Suns, sometimes $CPP names a directory. | |
1119 | if test -n "$CPP" && test -d "$CPP"; then | |
1120 | CPP= | |
1121 | fi | |
1122 | if test -z "$CPP"; then | |
1123 | if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then | |
1124 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1125 | else | |
1126 | # This must be in double quotes, not single quotes, because CPP may get | |
1127 | # substituted into the Makefile and "${CC-cc}" will confuse make. | |
1128 | CPP="${CC-cc} -E" | |
1129 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
1130 | # not just through cpp. | |
1131 | cat > conftest.$ac_ext <<EOF | |
73c4941b | 1132 | #line 1133 "configure" |
4b935ed4 MM |
1133 | #include "confdefs.h" |
1134 | #include <assert.h> | |
1135 | Syntax Error | |
1136 | EOF | |
1137 | eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
1138 | ac_err=`grep -v '^ *+' conftest.out` | |
1139 | if test -z "$ac_err"; then | |
1140 | : | |
1141 | else | |
1142 | echo "$ac_err" >&5 | |
1143 | rm -rf conftest* | |
1144 | CPP="${CC-cc} -E -traditional-cpp" | |
1145 | cat > conftest.$ac_ext <<EOF | |
73c4941b | 1146 | #line 1147 "configure" |
4b935ed4 MM |
1147 | #include "confdefs.h" |
1148 | #include <assert.h> | |
1149 | Syntax Error | |
1150 | EOF | |
1151 | eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
1152 | ac_err=`grep -v '^ *+' conftest.out` | |
1153 | if test -z "$ac_err"; then | |
1154 | : | |
1155 | else | |
1156 | echo "$ac_err" >&5 | |
1157 | rm -rf conftest* | |
1158 | CPP=/lib/cpp | |
1159 | fi | |
1160 | rm -f conftest* | |
1161 | fi | |
1162 | rm -f conftest* | |
1163 | ac_cv_prog_CPP="$CPP" | |
1164 | fi | |
1165 | CPP="$ac_cv_prog_CPP" | |
1166 | else | |
1167 | ac_cv_prog_CPP="$CPP" | |
1168 | fi | |
1169 | echo "$ac_t""$CPP" 1>&6 | |
1170 | ||
c494cadd | 1171 | for ac_hdr in string.h strings.h stdlib.h time.h sys/times.h unistd.h sys/resource.h |
4b935ed4 MM |
1172 | do |
1173 | ac_safe=`echo "$ac_hdr" | tr './\055' '___'` | |
1174 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
1175 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then | |
1176 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1177 | else | |
1178 | cat > conftest.$ac_ext <<EOF | |
73c4941b | 1179 | #line 1180 "configure" |
4b935ed4 MM |
1180 | #include "confdefs.h" |
1181 | #include <$ac_hdr> | |
1182 | EOF | |
1183 | eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
1184 | ac_err=`grep -v '^ *+' conftest.out` | |
1185 | if test -z "$ac_err"; then | |
1186 | rm -rf conftest* | |
1187 | eval "ac_cv_header_$ac_safe=yes" | |
1188 | else | |
1189 | echo "$ac_err" >&5 | |
1190 | rm -rf conftest* | |
1191 | eval "ac_cv_header_$ac_safe=no" | |
1192 | fi | |
1193 | rm -f conftest* | |
1194 | fi | |
1195 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
1196 | echo "$ac_t""yes" 1>&6 | |
1197 | ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./\055' '[A-Z]___'` | |
1198 | cat >> confdefs.h <<EOF | |
1199 | #define $ac_tr_hdr 1 | |
1200 | EOF | |
1201 | ||
1202 | else | |
1203 | echo "$ac_t""no" 1>&6 | |
1204 | fi | |
1205 | done | |
1206 | ||
4f965b81 MM |
1207 | |
1208 | trap '' 1 2 15 | |
1209 | cat > confcache <<\EOF | |
1210 | # This file is a shell script that caches the results of configure | |
1211 | # tests run on this system so they can be shared between configure | |
1212 | # scripts and configure runs. It is not useful on other systems. | |
1213 | # If it contains results you don't want to keep, you may remove or edit it. | |
1214 | # | |
1215 | # By default, configure uses ./config.cache as the cache file, | |
1216 | # creating it if it does not exist already. You can give configure | |
1217 | # the --cache-file=FILE option to use a different cache file; that is | |
1218 | # what configure does when it calls configure scripts in | |
1219 | # subdirectories, so they share the cache. | |
1220 | # Giving --cache-file=/dev/null disables caching, for debugging configure. | |
1221 | # config.status only pays attention to the cache file if you give it the | |
1222 | # --recheck option to rerun configure. | |
1223 | # | |
1224 | EOF | |
1225 | # Ultrix sh set writes to stderr and can't be redirected directly, | |
1226 | # and sets the high bit in the cache file unless we assign to the vars. | |
1227 | (set) 2>&1 | | |
1228 | sed -n "s/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=\${\1='\2'}/p" \ | |
1229 | >> confcache | |
1230 | if cmp -s $cache_file confcache; then | |
1231 | : | |
1232 | else | |
1233 | if test -w $cache_file; then | |
1234 | echo "updating cache $cache_file" | |
1235 | cat confcache > $cache_file | |
1236 | else | |
1237 | echo "not updating unwritable cache $cache_file" | |
1238 | fi | |
1239 | fi | |
1240 | rm -f confcache | |
1241 | ||
1242 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 | |
1243 | ||
1244 | test "x$prefix" = xNONE && prefix=$ac_default_prefix | |
1245 | # Let make expand exec_prefix. | |
1246 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' | |
1247 | ||
1248 | # Any assignment to VPATH causes Sun make to only execute | |
1249 | # the first set of double-colon rules, so remove it if not needed. | |
1250 | # If there is a colon in the path, we need to keep it. | |
1251 | if test "x$srcdir" = x.; then | |
1252 | ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' | |
1253 | fi | |
1254 | ||
1255 | trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 | |
1256 | ||
4b935ed4 | 1257 | DEFS=-DHAVE_CONFIG_H |
4f965b81 MM |
1258 | |
1259 | # Without the "./", some shells look in PATH for config.status. | |
1260 | : ${CONFIG_STATUS=./config.status} | |
1261 | ||
1262 | echo creating $CONFIG_STATUS | |
1263 | rm -f $CONFIG_STATUS | |
1264 | cat > $CONFIG_STATUS <<EOF | |
1265 | #! /bin/sh | |
1266 | # Generated automatically by configure. | |
1267 | # Run this file to recreate the current configuration. | |
1268 | # This directory was configured as follows, | |
1269 | # on host `(hostname || uname -n) 2>/dev/null | sed 1q`: | |
1270 | # | |
1271 | # $0 $ac_configure_args | |
1272 | # | |
1273 | # Compiler output produced by configure, useful for debugging | |
1274 | # configure, is in ./config.log if it exists. | |
1275 | ||
1276 | ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" | |
1277 | for ac_option | |
1278 | do | |
1279 | case "\$ac_option" in | |
1280 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) | |
1281 | echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" | |
1282 | exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;; | |
1283 | -version | --version | --versio | --versi | --vers | --ver | --ve | --v) | |
4b935ed4 | 1284 | echo "$CONFIG_STATUS generated by autoconf version 2.4" |
4f965b81 MM |
1285 | exit 0 ;; |
1286 | -help | --help | --hel | --he | --h) | |
1287 | echo "\$ac_cs_usage"; exit 0 ;; | |
1288 | *) echo "\$ac_cs_usage"; exit 1 ;; | |
1289 | esac | |
1290 | done | |
1291 | ||
1292 | ac_given_srcdir=$srcdir | |
1293 | ||
4b935ed4 | 1294 | trap 'rm -fr `echo "Makefile config.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 |
4f965b81 MM |
1295 | |
1296 | # Protect against being on the right side of a sed subst in config.status. | |
1297 | sed 's/%@/@@/; s/@%/@@/; s/%g$/@g/; /@g$/s/[\\\\&%]/\\\\&/g; | |
1298 | s/@@/%@/; s/@@/@%/; s/@g$/%g/' > conftest.subs <<\CEOF | |
1299 | $ac_vpsub | |
1300 | $extrasub | |
1301 | s%@CFLAGS@%$CFLAGS%g | |
1302 | s%@CPPFLAGS@%$CPPFLAGS%g | |
1303 | s%@CXXFLAGS@%$CXXFLAGS%g | |
1304 | s%@DEFS@%$DEFS%g | |
1305 | s%@LDFLAGS@%$LDFLAGS%g | |
1306 | s%@LIBS@%$LIBS%g | |
1307 | s%@exec_prefix@%$exec_prefix%g | |
1308 | s%@prefix@%$prefix%g | |
1309 | s%@program_transform_name@%$program_transform_name%g | |
1310 | s%@host@%$host%g | |
1311 | s%@host_alias@%$host_alias%g | |
1312 | s%@host_cpu@%$host_cpu%g | |
1313 | s%@host_vendor@%$host_vendor%g | |
1314 | s%@host_os@%$host_os%g | |
1315 | s%@target@%$target%g | |
1316 | s%@target_alias@%$target_alias%g | |
1317 | s%@target_cpu@%$target_cpu%g | |
1318 | s%@target_vendor@%$target_vendor%g | |
1319 | s%@target_os@%$target_os%g | |
1320 | s%@build@%$build%g | |
1321 | s%@build_alias@%$build_alias%g | |
1322 | s%@build_cpu@%$build_cpu%g | |
1323 | s%@build_vendor@%$build_vendor%g | |
1324 | s%@build_os@%$build_os%g | |
4b935ed4 MM |
1325 | s%@CC@%$CC%g |
1326 | s%@HDEFINES@%$HDEFINES%g | |
1327 | s%@AR@%$AR%g | |
1328 | s%@RANLIB@%$RANLIB%g | |
c494cadd | 1329 | s%@sim_cflags@%$sim_cflags%g |
73c4941b | 1330 | s%@sim_warnings@%$sim_warnings%g |
c494cadd MM |
1331 | s%@sim_config@%$sim_config%g |
1332 | s%@sim_opcode@%$sim_opcode%g | |
1333 | s%@sim_switch@%$sim_switch%g | |
1334 | s%@sim_dup@%$sim_dup%g | |
1335 | s%@sim_filter@%$sim_filter%g | |
1336 | s%@sim_icache@%$sim_icache%g | |
1337 | s%@sim_inline@%$sim_inline%g | |
1338 | s%@sim_bswap@%$sim_bswap%g | |
1339 | s%@sim_endian@%$sim_endian%g | |
1340 | s%@sim_hostendian@%$sim_hostendian%g | |
1341 | s%@sim_smp@%$sim_smp%g | |
1342 | s%@sim_bitsize@%$sim_bitsize%g | |
1343 | s%@sim_hostbitsize@%$sim_hostbitsize%g | |
1344 | s%@sim_env@%$sim_env%g | |
1345 | s%@sim_timebase@%$sim_timebase%g | |
1346 | s%@sim_alignment@%$sim_alignment%g | |
1347 | s%@sim_float@%$sim_float%g | |
1348 | s%@sim_trace@%$sim_trace%g | |
1349 | s%@sim_assert@%$sim_assert%g | |
1350 | s%@sim_monitor@%$sim_monitor%g | |
73c4941b MM |
1351 | s%@sim_func@%$sim_func%g |
1352 | s%@sim_model@%$sim_model%g | |
1353 | s%@sim_default_model@%$sim_default_model%g | |
4b935ed4 MM |
1354 | s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g |
1355 | s%@CPP@%$CPP%g | |
4f965b81 MM |
1356 | |
1357 | CEOF | |
1358 | EOF | |
1359 | cat >> $CONFIG_STATUS <<EOF | |
1360 | ||
1361 | CONFIG_FILES=\${CONFIG_FILES-"Makefile"} | |
1362 | EOF | |
1363 | cat >> $CONFIG_STATUS <<\EOF | |
1364 | for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then | |
1365 | # Support "outfile[:infile]", defaulting infile="outfile.in". | |
1366 | case "$ac_file" in | |
1367 | *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'` | |
1368 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; | |
1369 | *) ac_file_in="${ac_file}.in" ;; | |
1370 | esac | |
1371 | ||
1372 | # Adjust relative srcdir, etc. for subdirectories. | |
1373 | ||
1374 | # Remove last slash and all that follows it. Not all systems have dirname. | |
1375 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` | |
1376 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then | |
1377 | # The file is in a subdirectory. | |
1378 | test ! -d "$ac_dir" && mkdir "$ac_dir" | |
1379 | ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" | |
1380 | # A "../" for each directory in $ac_dir_suffix. | |
1381 | ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` | |
1382 | else | |
1383 | ac_dir_suffix= ac_dots= | |
1384 | fi | |
1385 | ||
1386 | case "$ac_given_srcdir" in | |
1387 | .) srcdir=. | |
1388 | if test -z "$ac_dots"; then top_srcdir=. | |
1389 | else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; | |
1390 | /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; | |
1391 | *) # Relative path. | |
1392 | srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" | |
1393 | top_srcdir="$ac_dots$ac_given_srcdir" ;; | |
1394 | esac | |
1395 | ||
1396 | echo creating "$ac_file" | |
1397 | rm -f "$ac_file" | |
1398 | configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." | |
1399 | case "$ac_file" in | |
1400 | *Makefile*) ac_comsub="1i\\ | |
1401 | # $configure_input" ;; | |
1402 | *) ac_comsub= ;; | |
1403 | esac | |
1404 | sed -e "$ac_comsub | |
1405 | s%@configure_input@%$configure_input%g | |
1406 | s%@srcdir@%$srcdir%g | |
1407 | s%@top_srcdir@%$top_srcdir%g | |
1408 | " -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file | |
1409 | fi; done | |
1410 | rm -f conftest.subs | |
1411 | ||
4b935ed4 MM |
1412 | # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where |
1413 | # NAME is the cpp macro being defined and VALUE is the value it is being given. | |
1414 | # | |
1415 | # ac_d sets the value in "#define NAME VALUE" lines. | |
1416 | ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' | |
1417 | ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' | |
1418 | ac_dC='\3' | |
1419 | ac_dD='%g' | |
1420 | # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE". | |
1421 | ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' | |
1422 | ac_uB='\([ ]\)%\1#\2define\3' | |
1423 | ac_uC=' ' | |
1424 | ac_uD='\4%g' | |
1425 | # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE". | |
1426 | ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' | |
1427 | ac_eB='$%\1#\2define\3' | |
1428 | ac_eC=' ' | |
1429 | ac_eD='%g' | |
1430 | ||
1431 | CONFIG_HEADERS=${CONFIG_HEADERS-"config.h:config.in"} | |
1432 | for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then | |
1433 | # Support "outfile[:infile]", defaulting infile="outfile.in". | |
1434 | case "$ac_file" in | |
1435 | *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'` | |
1436 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; | |
1437 | *) ac_file_in="${ac_file}.in" ;; | |
1438 | esac | |
1439 | ||
1440 | echo creating $ac_file | |
4f965b81 | 1441 | |
4b935ed4 MM |
1442 | rm -f conftest.frag conftest.in conftest.out |
1443 | cp $ac_given_srcdir/$ac_file_in conftest.in | |
4f965b81 | 1444 | |
4b935ed4 MM |
1445 | EOF |
1446 | ||
1447 | # Transform confdefs.h into a sed script conftest.vals that substitutes | |
1448 | # the proper values into config.h.in to produce config.h. And first: | |
1449 | # Protect against being on the right side of a sed subst in config.status. | |
1450 | # Protect against being in an unquoted here document in config.status. | |
1451 | rm -f conftest.vals | |
1452 | cat > conftest.hdr <<\EOF | |
1453 | s/[\\&%]/\\&/g | |
1454 | s%[\\$`]%\\&%g | |
1455 | s%#define \([A-Za-z_][A-Za-z0-9_]*\) \(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp | |
1456 | s%ac_d%ac_u%gp | |
1457 | s%ac_u%ac_e%gp | |
1458 | EOF | |
1459 | sed -n -f conftest.hdr confdefs.h > conftest.vals | |
1460 | rm -f conftest.hdr | |
1461 | ||
1462 | # This sed command replaces #undef with comments. This is necessary, for | |
1463 | # example, in the case of _POSIX_SOURCE, which is predefined and required | |
1464 | # on some systems where configure will not decide to define it. | |
1465 | cat >> conftest.vals <<\EOF | |
1466 | s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% | |
1467 | EOF | |
1468 | ||
1469 | # Break up conftest.vals because some shells have a limit on | |
1470 | # the size of here documents, and old seds have small limits too. | |
1471 | # Maximum number of lines to put in a single here document. | |
1472 | ac_max_here_lines=12 | |
1473 | ||
1474 | rm -f conftest.tail | |
1475 | while : | |
1476 | do | |
1477 | ac_lines=`grep -c . conftest.vals` | |
1478 | # grep -c gives empty output for an empty file on some AIX systems. | |
1479 | if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi | |
1480 | # Write a limited-size here document to conftest.frag. | |
1481 | echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS | |
1482 | sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS | |
1483 | echo 'CEOF | |
1484 | sed -f conftest.frag conftest.in > conftest.out | |
1485 | rm -f conftest.in | |
1486 | mv conftest.out conftest.in | |
1487 | ' >> $CONFIG_STATUS | |
1488 | sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail | |
1489 | rm -f conftest.vals | |
1490 | mv conftest.tail conftest.vals | |
1491 | done | |
1492 | rm -f conftest.vals | |
1493 | ||
1494 | cat >> $CONFIG_STATUS <<\EOF | |
1495 | rm -f conftest.frag conftest.h | |
1496 | echo "/* $ac_file. Generated automatically by configure. */" > conftest.h | |
1497 | cat conftest.in >> conftest.h | |
1498 | rm -f conftest.in | |
1499 | if cmp -s $ac_file conftest.h 2>/dev/null; then | |
1500 | echo "$ac_file is unchanged" | |
1501 | rm -f conftest.h | |
1502 | else | |
1503 | rm -f $ac_file | |
1504 | mv conftest.h $ac_file | |
1505 | fi | |
1506 | fi; done | |
1507 | ||
1508 | ||
1509 | case x$CONFIG_HEADERS in xconfig.h:config.in) echo > stamp-h ;; esac | |
4f965b81 MM |
1510 | exit 0 |
1511 | EOF | |
1512 | chmod +x $CONFIG_STATUS | |
1513 | rm -fr confdefs* $ac_clean_files | |
1514 | test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 | |
1515 |