3
# Guess values for system-dependent variables and create Makefiles.
4
# Generated automatically using autoconf version 2.13
5
# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
7
# This configure script is free software; the Free Software Foundation
8
# gives unlimited permission to copy, distribute and modify it.
12
ac_default_prefix=/usr/local
13
# Any additions from configure.in:
15
--with-android-ndk=DIR
16
location where the Android NDK can be found"
18
--with-android-toolchain=DIR
19
location of the android toolchain, default NDK/build/prebuilt/HOST/arm-eabi-4.4.0"
21
--with-android-platform=DIR
22
location of platform dir, default NDK/build/platforms/android-5/arch-arm"
24
--with-dist-prefix=DIST_PREFIX
25
place build files in DIST_PREFIX [dist]"
27
--with-dist-bindir=DIR build execuatables in DIR [DIST_PREFIX/bin]"
29
--with-dist-includedir=DIR
30
build include files in DIR [DIST_PREFIX/include/nspr]"
32
--with-dist-libdir=DIR build library files in DIR [DIST_PREFIX/lib]"
34
--with-mozilla Compile NSPR with Mozilla support"
36
--enable-optimize[=OPT] Enable code optimizations (ie. -O2) "
38
--enable-debug[=DBG] Enable debugging (using compiler flags DBG)"
40
--enable-debug-symbols[=DBG] Enable debugging symbols
41
(using compiler flags DBG)"
43
--enable-win32-target=\$t
44
Specify win32 flavor. (WIN95 or WINNT)"
46
--enable-symbian-target=\$t
47
Specify symbian flavor. (WINSCW or GCCE)"
49
--enable-debug-rtl Use the MSVC debug runtime library"
51
--enable-n32 Enable n32 ABI support (IRIX only)"
53
--enable-64bit Enable 64-bit support (on certain platforms)"
55
--enable-mdupdate Enable use of certain compilers' mdupdate feature"
57
--enable-cplus Enable some c++ api routines"
59
--with-arm-kuser Use kuser helpers (Linux/ARM only)
60
(Requires kernel 2.6.13 or later)"
62
--with-macos-sdk=dir Location of platform SDK to use (Mac OS X only)"
64
--enable-macos-target=VER
65
Set the minimum MacOS version needed at runtime
66
[10.2 for ppc, 10.4 for x86]"
68
--disable-os2-high-mem Disable high-memory support on OS/2"
72
--with-thumb[[=yes|no|toolchain-default]]
73
Use Thumb instruction set (-mthumb)"
75
--with-thumb-interwork[[=yes|no|toolchain-default]]
76
Use Thumb/ARM instuctions interwork (-mthumb-interwork)"
78
--with-arch=[[type|toolchain-default]]
79
Use specific CPU features (-march=type)"
81
--with-fpu=[[type|toolchain-default]]
82
Use specific FPU type (-mfpu=type)"
84
--with-float-abi=[[type|toolchain-default]]
85
Use specific arm float ABI (-mfloat-abi=type)"
87
--with-soft-float[[=yes|no|toolchain-default]]
88
Use soft float library (-msoft-float)"
90
--with-symbian-sdk=SYMBIAN_SDK_DIR
91
The path to the Symbian SDK"
93
--with-ccache[=path/to/ccache]
94
Enable compiling with ccache"
96
--enable-strip Enable stripping of shared libs and programs"
98
--with-pthreads Use system pthreads library as thread subsystem"
100
--enable-user-pthreads Build using userland pthreads"
102
--enable-nspr-threads Build using classic nspr threads"
104
--with-bthreads Use system bthreads library as thread subsystem
107
--enable-ipv6 Compile ipv6 support"
109
--enable-wrap-malloc Wrap malloc calls (gnu linker only)"
111
--with-wrap-malloc=SHAREDLIB Location of malloc wrapper library"
113
# Initialize some variables set by options.
114
# The variables have the same names as the options, with
115
# dashes changed to underlines.
117
cache_file=./config.cache
126
program_transform_name=s,x,x,
134
bindir='${exec_prefix}/bin'
135
sbindir='${exec_prefix}/sbin'
136
libexecdir='${exec_prefix}/libexec'
137
datadir='${prefix}/share'
138
sysconfdir='${prefix}/etc'
139
sharedstatedir='${prefix}/com'
140
localstatedir='${prefix}/var'
141
libdir='${exec_prefix}/lib'
142
includedir='${prefix}/include'
143
oldincludedir='/usr/include'
144
infodir='${prefix}/info'
145
mandir='${prefix}/man'
147
# Initialize some other variables.
150
SHELL=${CONFIG_SHELL-/bin/sh}
151
# Maximum number of lines to put in a shell here document.
158
# If the previous option needs an argument, assign it.
159
if test -n "$ac_prev"; then
160
eval "$ac_prev=\$ac_option"
166
-*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
170
# Accept the important Cygnus configure options, so we can diagnose typos.
174
-bindir | --bindir | --bindi | --bind | --bin | --bi)
176
-bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
177
bindir="$ac_optarg" ;;
179
-build | --build | --buil | --bui | --bu)
181
-build=* | --build=* | --buil=* | --bui=* | --bu=*)
182
build="$ac_optarg" ;;
184
-cache-file | --cache-file | --cache-fil | --cache-fi \
185
| --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
186
ac_prev=cache_file ;;
187
-cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
188
| --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
189
cache_file="$ac_optarg" ;;
191
-datadir | --datadir | --datadi | --datad | --data | --dat | --da)
193
-datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
195
datadir="$ac_optarg" ;;
197
-disable-* | --disable-*)
198
ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
199
# Reject names that are not valid shell variable names.
200
if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
201
{ echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
203
ac_feature=`echo $ac_feature| sed 's/-/_/g'`
204
eval "enable_${ac_feature}=no" ;;
206
-enable-* | --enable-*)
207
ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
208
# Reject names that are not valid shell variable names.
209
if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
210
{ echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
212
ac_feature=`echo $ac_feature| sed 's/-/_/g'`
217
eval "enable_${ac_feature}='$ac_optarg'" ;;
219
-exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
220
| --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
221
| --exec | --exe | --ex)
222
ac_prev=exec_prefix ;;
223
-exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
224
| --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
225
| --exec=* | --exe=* | --ex=*)
226
exec_prefix="$ac_optarg" ;;
228
-gas | --gas | --ga | --g)
229
# Obsolete; use --with-gas.
232
-help | --help | --hel | --he)
233
# Omit some internal or obsolete options to make the list less imposing.
234
# This message is too long to be a string in the A/UX 3.1 sh.
236
Usage: configure [options] [host]
237
Options: [defaults in brackets after descriptions]
239
--cache-file=FILE cache test results in FILE
240
--help print this message
241
--no-create do not create output files
242
--quiet, --silent do not print \`checking...' messages
243
--version print the version of autoconf that created configure
244
Directory and file names:
245
--prefix=PREFIX install architecture-independent files in PREFIX
247
--exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
249
--bindir=DIR user executables in DIR [EPREFIX/bin]
250
--sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
251
--libexecdir=DIR program executables in DIR [EPREFIX/libexec]
252
--datadir=DIR read-only architecture-independent data in DIR
254
--sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
255
--sharedstatedir=DIR modifiable architecture-independent data in DIR
257
--localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
258
--libdir=DIR object code libraries in DIR [EPREFIX/lib]
259
--includedir=DIR C header files in DIR [PREFIX/include]
260
--oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
261
--infodir=DIR info documentation in DIR [PREFIX/info]
262
--mandir=DIR man documentation in DIR [PREFIX/man]
263
--srcdir=DIR find the sources in DIR [configure dir or ..]
264
--program-prefix=PREFIX prepend PREFIX to installed program names
265
--program-suffix=SUFFIX append SUFFIX to installed program names
266
--program-transform-name=PROGRAM
267
run sed PROGRAM on installed program names
271
--build=BUILD configure for building on BUILD [BUILD=HOST]
272
--host=HOST configure for HOST [guessed]
273
--target=TARGET configure for TARGET [TARGET=HOST]
274
Features and packages:
275
--disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
276
--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
277
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
278
--without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
279
--x-includes=DIR X include files are in DIR
280
--x-libraries=DIR X library files are in DIR
282
if test -n "$ac_help"; then
283
echo "--enable and --with options recognized:$ac_help"
287
-host | --host | --hos | --ho)
289
-host=* | --host=* | --hos=* | --ho=*)
292
-includedir | --includedir | --includedi | --included | --include \
293
| --includ | --inclu | --incl | --inc)
294
ac_prev=includedir ;;
295
-includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
296
| --includ=* | --inclu=* | --incl=* | --inc=*)
297
includedir="$ac_optarg" ;;
299
-infodir | --infodir | --infodi | --infod | --info | --inf)
301
-infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
302
infodir="$ac_optarg" ;;
304
-libdir | --libdir | --libdi | --libd)
306
-libdir=* | --libdir=* | --libdi=* | --libd=*)
307
libdir="$ac_optarg" ;;
309
-libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
310
| --libexe | --libex | --libe)
311
ac_prev=libexecdir ;;
312
-libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
313
| --libexe=* | --libex=* | --libe=*)
314
libexecdir="$ac_optarg" ;;
316
-localstatedir | --localstatedir | --localstatedi | --localstated \
317
| --localstate | --localstat | --localsta | --localst \
318
| --locals | --local | --loca | --loc | --lo)
319
ac_prev=localstatedir ;;
320
-localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
321
| --localstate=* | --localstat=* | --localsta=* | --localst=* \
322
| --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
323
localstatedir="$ac_optarg" ;;
325
-mandir | --mandir | --mandi | --mand | --man | --ma | --m)
327
-mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
328
mandir="$ac_optarg" ;;
331
# Obsolete; use --without-fp.
334
-no-create | --no-create | --no-creat | --no-crea | --no-cre \
338
-no-recursion | --no-recursion | --no-recursio | --no-recursi \
339
| --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
342
-oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
343
| --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
344
| --oldin | --oldi | --old | --ol | --o)
345
ac_prev=oldincludedir ;;
346
-oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
347
| --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
348
| --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
349
oldincludedir="$ac_optarg" ;;
351
-prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
353
-prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
354
prefix="$ac_optarg" ;;
356
-program-prefix | --program-prefix | --program-prefi | --program-pref \
357
| --program-pre | --program-pr | --program-p)
358
ac_prev=program_prefix ;;
359
-program-prefix=* | --program-prefix=* | --program-prefi=* \
360
| --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
361
program_prefix="$ac_optarg" ;;
363
-program-suffix | --program-suffix | --program-suffi | --program-suff \
364
| --program-suf | --program-su | --program-s)
365
ac_prev=program_suffix ;;
366
-program-suffix=* | --program-suffix=* | --program-suffi=* \
367
| --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
368
program_suffix="$ac_optarg" ;;
370
-program-transform-name | --program-transform-name \
371
| --program-transform-nam | --program-transform-na \
372
| --program-transform-n | --program-transform- \
373
| --program-transform | --program-transfor \
374
| --program-transfo | --program-transf \
375
| --program-trans | --program-tran \
376
| --progr-tra | --program-tr | --program-t)
377
ac_prev=program_transform_name ;;
378
-program-transform-name=* | --program-transform-name=* \
379
| --program-transform-nam=* | --program-transform-na=* \
380
| --program-transform-n=* | --program-transform-=* \
381
| --program-transform=* | --program-transfor=* \
382
| --program-transfo=* | --program-transf=* \
383
| --program-trans=* | --program-tran=* \
384
| --progr-tra=* | --program-tr=* | --program-t=*)
385
program_transform_name="$ac_optarg" ;;
387
-q | -quiet | --quiet | --quie | --qui | --qu | --q \
388
| -silent | --silent | --silen | --sile | --sil)
391
-sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
393
-sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
395
sbindir="$ac_optarg" ;;
397
-sharedstatedir | --sharedstatedir | --sharedstatedi \
398
| --sharedstated | --sharedstate | --sharedstat | --sharedsta \
399
| --sharedst | --shareds | --shared | --share | --shar \
401
ac_prev=sharedstatedir ;;
402
-sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
403
| --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
404
| --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
406
sharedstatedir="$ac_optarg" ;;
408
-site | --site | --sit)
410
-site=* | --site=* | --sit=*)
413
-srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
415
-srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
416
srcdir="$ac_optarg" ;;
418
-sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
419
| --syscon | --sysco | --sysc | --sys | --sy)
420
ac_prev=sysconfdir ;;
421
-sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
422
| --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
423
sysconfdir="$ac_optarg" ;;
425
-target | --target | --targe | --targ | --tar | --ta | --t)
427
-target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
428
target="$ac_optarg" ;;
430
-v | -verbose | --verbose | --verbos | --verbo | --verb)
433
-version | --version | --versio | --versi | --vers)
434
echo "configure generated by autoconf version 2.13"
438
ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
439
# Reject names that are not valid shell variable names.
440
if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
441
{ echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
443
ac_package=`echo $ac_package| sed 's/-/_/g'`
448
eval "with_${ac_package}='$ac_optarg'" ;;
450
-without-* | --without-*)
451
ac_package=`echo $ac_option|sed -e 's/-*without-//'`
452
# Reject names that are not valid shell variable names.
453
if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
454
{ echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
456
ac_package=`echo $ac_package| sed 's/-/_/g'`
457
eval "with_${ac_package}=no" ;;
460
# Obsolete; use --with-x.
463
-x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
464
| --x-incl | --x-inc | --x-in | --x-i)
465
ac_prev=x_includes ;;
466
-x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
467
| --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
468
x_includes="$ac_optarg" ;;
470
-x-libraries | --x-libraries | --x-librarie | --x-librari \
471
| --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
472
ac_prev=x_libraries ;;
473
-x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
474
| --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
475
x_libraries="$ac_optarg" ;;
477
-*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
481
if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
482
echo "configure: warning: $ac_option: invalid host type" 1>&2
484
if test "x$nonopt" != xNONE; then
485
{ echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
493
if test -n "$ac_prev"; then
494
{ echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
497
trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
499
# File descriptor usage:
502
# 2 errors and warnings
503
# 3 some systems may open it to /dev/tty
504
# 4 used on the Kubota Titan
505
# 6 checking for... messages and results
506
# 5 compiler messages saved in config.log
507
if test "$silent" = yes; then
515
This file contains any messages produced by compilers while
516
running configure, to aid debugging if configure makes a mistake.
519
# Strip out --no-create and --no-recursion so they do not pile up.
520
# Also quote any args containing shell metacharacters.
525
-no-create | --no-create | --no-creat | --no-crea | --no-cre \
526
| --no-cr | --no-c) ;;
527
-no-recursion | --no-recursion | --no-recursio | --no-recursi \
528
| --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
529
*" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
530
ac_configure_args="$ac_configure_args '$ac_arg'" ;;
531
*) ac_configure_args="$ac_configure_args $ac_arg" ;;
536
# Only set these to C if already set. These must not be set unconditionally
537
# because not all systems understand e.g. LANG=C (notably SCO).
538
# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
539
# Non-C LC_CTYPE values break the ctype check.
540
if test "${LANG+set}" = set; then LANG=C; export LANG; fi
541
if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
542
if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
543
if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
545
# confdefs.h avoids OS command line length limits that DEFS can exceed.
546
rm -rf conftest* confdefs.h
547
# AIX cpp loses on an empty file, so make sure it contains at least a newline.
550
# A filename unique to this package, relative to the directory that
551
# configure is in, which we can look for to find out if srcdir is correct.
552
ac_unique_file=config/libc_r.h
554
# Find the source files, if location was not specified.
555
if test -z "$srcdir"; then
556
ac_srcdir_defaulted=yes
557
# Try the directory containing this script, then its parent.
559
ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
560
test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
562
if test ! -r $srcdir/$ac_unique_file; then
566
ac_srcdir_defaulted=no
568
if test ! -r $srcdir/$ac_unique_file; then
569
if test "$ac_srcdir_defaulted" = yes; then
570
{ echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
572
{ echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
575
srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
577
# Prefer explicitly selected file to automatically selected ones.
578
if test -z "$CONFIG_SITE"; then
579
if test "x$prefix" != xNONE; then
580
CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
582
CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
585
for ac_site_file in $CONFIG_SITE; do
586
if test -r "$ac_site_file"; then
587
echo "loading site script $ac_site_file"
592
if test -r "$cache_file"; then
593
echo "loading cache $cache_file"
596
echo "creating cache $cache_file"
601
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
602
ac_cpp='$CPP $CPPFLAGS'
603
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
604
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
605
cross_compiling=$ac_cv_prog_cc_cross
609
if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
610
# Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
611
if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
618
ac_n= ac_c='\c' ac_t=
624
for ac_dir in ${srcdir}/build/autoconf $srcdir/${srcdir}/build/autoconf; do
625
if test -f $ac_dir/install-sh; then
627
ac_install_sh="$ac_aux_dir/install-sh -c"
629
elif test -f $ac_dir/install.sh; then
631
ac_install_sh="$ac_aux_dir/install.sh -c"
635
if test -z "$ac_aux_dir"; then
636
{ echo "configure: error: can not find install-sh or install.sh in ${srcdir}/build/autoconf $srcdir/${srcdir}/build/autoconf" 1>&2; exit 1; }
638
ac_config_guess=$ac_aux_dir/config.guess
639
ac_config_sub=$ac_aux_dir/config.sub
640
ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
643
# Do some error checking and defaulting for the host and target type.
645
# configure --host=HOST --target=TARGET --build=BUILD NONOPT
648
# 1. You are not allowed to specify --host, --target, and nonopt at the
650
# 2. Host defaults to nonopt.
651
# 3. If nonopt is not specified, then host defaults to the current host,
652
# as determined by config.guess.
653
# 4. Target and build default to nonopt.
654
# 5. If nonopt is not specified, then target and build default to host.
656
# The aliases save the names the user supplied, while $host etc.
657
# will get canonicalized.
658
case $host---$target---$nonopt in
659
NONE---*---* | *---NONE---* | *---*---NONE) ;;
660
*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
664
# Make sure we can run config.sub.
665
if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
666
else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
669
echo $ac_n "checking host system type""... $ac_c" 1>&6
670
echo "configure:671: checking host system type" >&5
673
case "$host_alias" in
677
if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
678
else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
680
*) host_alias=$nonopt ;;
684
host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
685
host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
686
host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
687
host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
688
echo "$ac_t""$host" 1>&6
690
echo $ac_n "checking target system type""... $ac_c" 1>&6
691
echo "configure:692: checking target system type" >&5
694
case "$target_alias" in
697
NONE) target_alias=$host_alias ;;
698
*) target_alias=$nonopt ;;
702
target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
703
target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
704
target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
705
target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
706
echo "$ac_t""$target" 1>&6
708
echo $ac_n "checking build system type""... $ac_c" 1>&6
709
echo "configure:710: checking build system type" >&5
712
case "$build_alias" in
715
NONE) build_alias=$host_alias ;;
716
*) build_alias=$nonopt ;;
720
build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
721
build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
722
build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
723
build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
724
echo "$ac_t""$build" 1>&6
726
test "$host_alias" != "$target_alias" &&
727
test "$program_prefix$program_suffix$program_transform_name" = \
729
program_prefix=${target_alias}-
745
_MACOSX_DEPLOYMENT_TARGET=
750
OBJDIR='$(OBJDIR_NAME)'
753
NSINSTALL='$(MOD_DEPTH)/config/$(OBJDIR_NAME)/nsinstall'
754
NOSUCHFILE=/no-such-file
755
LIBNSPR='-L$(dist_libdir) -lnspr$(MOD_MAJOR_VERSION)'
756
LIBPLC='-L$(dist_libdir) -lplc$(MOD_MAJOR_VERSION)'
761
MOZ_OS2_HIGH_MEMORY=1
767
RESOLVE_LINK_SYMBOLS=
770
CXXFLAGS="${CXXFLAGS=}"
771
LDFLAGS="${LDFLAGS=}"
772
DLLFLAGS="${DLLFLAGS=}"
773
HOST_CFLAGS="${HOST_CFLAGS=}"
774
HOST_LDFLAGS="${HOST_LDFLAGS=}"
778
# Check to see if we are really running in a msvc environemnt
782
# Extract the first word of "$ac_prog", so it can be a program name with args.
783
set dummy $ac_prog; ac_word=$2
784
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
785
echo "configure:786: checking for $ac_word" >&5
786
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
787
echo $ac_n "(cached) $ac_c" 1>&6
789
if test -n "$CC"; then
790
ac_cv_prog_CC="$CC" # Let the user override the test.
792
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
794
for ac_dir in $ac_dummy; do
795
test -z "$ac_dir" && ac_dir=.
796
if test -f $ac_dir/$ac_word; then
797
ac_cv_prog_CC="$ac_prog"
805
if test -n "$CC"; then
806
echo "$ac_t""$CC" 1>&6
808
echo "$ac_t""no" 1>&6
811
test -n "$CC" && break
814
if test "$CC" = "cl"; then
815
echo 'main() { return 0; }' > dummy.c
816
${CC} -o dummy dummy.c >/dev/null 2>&1
821
echo "configure: warning: $(CC) test failed. Using normal feature tests" 1>&2
823
rm -f dummy dummy.o dummy.obj dummy.exe dummy.c
834
if test -n "$_WIN32_MSVC"; then
836
SKIP_COMPILER_CHECKS=1
837
SKIP_LIBRARY_CHECKS=1
841
# Check whether --with-android-ndk or --without-android-ndk was given.
842
if test "${with_android_ndk+set}" = set; then
843
withval="$with_android_ndk"
848
# Check whether --with-android-toolchain or --without-android-toolchain was given.
849
if test "${with_android_toolchain+set}" = set; then
850
withval="$with_android_toolchain"
851
android_toolchain=$withval
855
# Check whether --with-android-platform or --without-android-platform was given.
856
if test "${with_android_platform+set}" = set; then
857
withval="$with_android_platform"
858
android_platform=$withval
863
arm-linux*-android*|*-linuxandroid*)
864
android_tool_prefix="arm-linux-androideabi"
867
android_tool_prefix="arm-eabi"
870
android_tool_prefix="$target_os"
875
*-android*|*-linuxandroid*)
876
if test -z "$android_ndk" ; then
877
{ echo "configure: error: You must specify --with-android-ndk=/path/to/ndk when targeting Android." 1>&2; exit 1; }
880
if test -z "$android_toolchain" ; then
881
android_toolchain="$android_ndk"/build/prebuilt/`uname -s | tr "[:upper:]" "[:lower:]"`-x86/arm-eabi-4.4.0
884
if test -z "$android_platform" ; then
885
android_platform="$android_ndk"/build/platforms/android-5/arch-arm
888
AS="$android_toolchain"/bin/"$android_tool_prefix"-as
889
CC="$android_toolchain"/bin/"$android_tool_prefix"-gcc
890
CXX="$android_toolchain"/bin/"$android_tool_prefix"-g++
891
CPP="$android_toolchain"/bin/"$android_tool_prefix"-cpp
892
LD="$android_toolchain"/bin/"$android_tool_prefix"-ld
893
AR="$android_toolchain"/bin/"$android_tool_prefix"-ar
894
RANLIB="$android_toolchain"/bin/"$android_tool_prefix"-ranlib
895
STRIP="$android_toolchain"/bin/"$android_tool_prefix"-strip
897
CPPFLAGS="-I$android_platform/usr/include $CPPFLAGS"
898
CFLAGS="-mandroid -I$android_platform/usr/include -msoft-float -fno-short-enums -fno-exceptions $CFLAGS"
899
CXXFLAGS="-mandroid -I$android_platform/usr/include -msoft-float -fpic -fno-short-enums -fno-exceptions $CXXFLAGS"
900
LDFLAGS="-mandroid -L$android_platform/usr/lib -Wl,-rpath-link=$android_platform/usr/lib --sysroot=$android_platform $LDFLAGS"
902
if test -z "$HOST_CPPFLAGS" ; then
905
if test -z "$HOST_CFLAGS" ; then
908
if test -z "$HOST_CXXFLAGS" ; then
911
if test -z "$HOST_LDFLAGS" ; then
915
WRAP_MALLOC_CFLAGS="-Wl,--wrap=dlopen -Wl,--wrap=dlclose -Wl,--wrap=dlerror -Wl,--wrap=dlsym -Wl,--wrap=dladdr"
917
cat >> confdefs.h <<\EOF
924
dist_prefix='${MOD_DEPTH}/dist'
925
dist_bindir='${dist_prefix}/bin'
926
dist_includedir='${dist_prefix}/include/nspr'
927
dist_libdir='${dist_prefix}/lib'
928
if test "${includedir}" = '${prefix}/include'; then
929
includedir='${prefix}/include/nspr'
932
# Check whether --with-dist-prefix or --without-dist-prefix was given.
933
if test "${with_dist_prefix+set}" = set; then
934
withval="$with_dist_prefix"
939
# Check whether --with-dist-bindir or --without-dist-bindir was given.
940
if test "${with_dist_bindir+set}" = set; then
941
withval="$with_dist_bindir"
946
# Check whether --with-dist-includedir or --without-dist-includedir was given.
947
if test "${with_dist_includedir+set}" = set; then
948
withval="$with_dist_includedir"
949
dist_includedir=$withval
953
# Check whether --with-dist-libdir or --without-dist-libdir was given.
954
if test "${with_dist_libdir+set}" = set; then
955
withval="$with_dist_libdir"
965
# Check whether --with-mozilla or --without-mozilla was given.
966
if test "${with_mozilla+set}" = set; then
967
withval="$with_mozilla"
968
if test "$withval" = "yes"; then
969
cat >> confdefs.h <<\EOF
970
#define MOZILLA_CLIENT 1
978
if test -n "$MOZILLA_CLIENT"; then
979
cat >> confdefs.h <<\EOF
980
#define MOZILLA_CLIENT 1
987
# Check whether --enable-optimize or --disable-optimize was given.
988
if test "${enable_optimize+set}" = set; then
989
enableval="$enable_optimize"
990
if test "$enableval" != "no"; then
992
if test -n "$enableval" -a "$enableval" != "yes"; then
993
_OPTIMIZE_FLAGS=`echo $enableval | sed -e 's|\\\ | |g'`
994
_SAVE_OPTIMIZE_FLAGS=$_OPTIMIZE_FLAGS
1002
# Check whether --enable-debug or --disable-debug was given.
1003
if test "${enable_debug+set}" = set; then
1004
enableval="$enable_debug"
1005
if test "$enableval" != "no"; then
1008
if test -n "$enableval" -a "$enableval" != "yes"; then
1009
_DEBUG_FLAGS=`echo $enableval | sed -e 's|\\\ | |g'`
1010
_SAVE_DEBUG_FLAGS=$_DEBUG_FLAGS
1020
# Check whether --enable-debug-symbols or --disable-debug-symbols was given.
1021
if test "${enable_debug_symbols+set}" = set; then
1022
enableval="$enable_debug_symbols"
1023
if test "$enableval" != "no"; then
1025
if test -n "$enableval" -a "$enableval" != "yes"; then
1026
if test -z "$_SAVE_DEBUG_FLAGS"; then
1027
_DEBUG_FLAGS=`echo $enableval | sed -e 's|\\\ | |g'`
1028
_SAVE_DEBUG_FLAGS=$_DEBUG_FLAGS
1030
{ echo "configure: error: --enable-debug-symbols flags cannot be used with --enable-debug flags" 1>&2; exit 1; }
1039
# Check whether --enable-win32-target or --disable-win32-target was given.
1040
if test "${enable_win32_target+set}" = set; then
1041
enableval="$enable_win32_target"
1042
OS_TARGET=`echo $enableval | tr a-z A-Z`
1046
# Check whether --enable-symbian-target or --disable-symbian-target was given.
1047
if test "${enable_symbian_target+set}" = set; then
1048
enableval="$enable_symbian_target"
1049
OS_TARGET=`echo $enableval | tr a-z A-Z`
1053
# Check whether --enable-debug-rtl or --disable-debug-rtl was given.
1054
if test "${enable_debug_rtl+set}" = set; then
1055
enableval="$enable_debug_rtl"
1056
if test "$enableval" = "yes"; then
1062
# Check whether --enable-n32 or --disable-n32 was given.
1063
if test "${enable_n32+set}" = set; then
1064
enableval="$enable_n32"
1065
if test "$enableval" = "yes"; then
1067
else if test "$enableval" = "no"; then
1074
# Check whether --enable-64bit or --disable-64bit was given.
1075
if test "${enable_64bit+set}" = set; then
1076
enableval="$enable_64bit"
1077
if test "$enableval" = "yes"; then
1083
# Check whether --enable-mdupdate or --disable-mdupdate was given.
1084
if test "${enable_mdupdate+set}" = set; then
1085
enableval="$enable_mdupdate"
1086
if test "$enableval" = "yes"; then
1092
# Check whether --enable-cplus or --disable-cplus was given.
1093
if test "${enable_cplus+set}" = set; then
1094
enableval="$enable_cplus"
1095
if test "$enableval" = "yes"; then
1101
# Check whether --with-arm-kuser or --without-arm-kuser was given.
1102
if test "${with_arm_kuser+set}" = set; then
1103
withval="$with_arm_kuser"
1104
if test "$withval" = "yes"; then
1105
cat >> confdefs.h <<\EOF
1106
#define _PR_ARM_KUSER 1
1113
# Check whether --with-macos-sdk or --without-macos-sdk was given.
1114
if test "${with_macos_sdk+set}" = set; then
1115
withval="$with_macos_sdk"
1116
MACOS_SDK_DIR=$withval
1120
# Check whether --enable-macos-target or --disable-macos-target was given.
1121
if test "${enable_macos_target+set}" = set; then
1122
enableval="$enable_macos_target"
1123
_MACOSX_DEPLOYMENT_TARGET=$enableval
1130
case "${target_os}" in
1142
if test -z "$CC"; then
1146
if test -z "$USE_NSPR_THREADS"; then
1172
if test -z "$CXX"; then
1176
if test -z "$USE_NSPR_THREADS"; then
1184
case "${target_os}" in
1212
if test -z "$SKIP_PATH_CHECKS"; then
1213
# Extract the first word of "$WHOAMI whoami", so it can be a program name with args.
1214
set dummy $WHOAMI whoami; ac_word=$2
1215
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1216
echo "configure:1217: checking for $ac_word" >&5
1217
if eval "test \"`echo '$''{'ac_cv_path_WHOAMI'+set}'`\" = set"; then
1218
echo $ac_n "(cached) $ac_c" 1>&6
1222
ac_cv_path_WHOAMI="$WHOAMI" # Let the user override the test with a path.
1225
ac_cv_path_WHOAMI="$WHOAMI" # Let the user override the test with a dos path.
1228
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1230
for ac_dir in $ac_dummy; do
1231
test -z "$ac_dir" && ac_dir=.
1232
if test -f $ac_dir/$ac_word; then
1233
ac_cv_path_WHOAMI="$ac_dir/$ac_word"
1238
test -z "$ac_cv_path_WHOAMI" && ac_cv_path_WHOAMI="echo not_whoami"
1242
WHOAMI="$ac_cv_path_WHOAMI"
1243
if test -n "$WHOAMI"; then
1244
echo "$ac_t""$WHOAMI" 1>&6
1246
echo "$ac_t""no" 1>&6
1251
if test -n "$MOZ_DEBUG"; then
1252
cat >> confdefs.h <<\EOF
1256
DEFINES="$DEFINES -UNDEBUG"
1258
case "${target_os}" in
1260
DEFINES="$DEFINES -DDEBUG_${USER}"
1262
msvc*|mks*|cygwin*|mingw*|wince*|winmo*|os2*)
1263
DEFINES="$DEFINES -DDEBUG_`echo ${USERNAME} | sed -e 's| |_|g'`"
1266
DEFINES="$DEFINES -DDEBUG_`$WHOAMI`"
1270
cat >> confdefs.h <<\EOF
1274
DEFINES="$DEFINES -UDEBUG"
1277
if test -z "$SKIP_COMPILER_CHECKS"; then
1278
if test "$target" != "$host"; then
1279
echo "cross compiling from $host to $target"
1283
_SAVE_CFLAGS="$CFLAGS"
1284
_SAVE_LDFLAGS="$LDFLAGS"
1286
echo $ac_n "checking for $host compiler""... $ac_c" 1>&6
1287
echo "configure:1288: checking for $host compiler" >&5
1288
for ac_prog in $HOST_CC gcc cc /usr/ucb/cc
1290
# Extract the first word of "$ac_prog", so it can be a program name with args.
1291
set dummy $ac_prog; ac_word=$2
1292
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1293
echo "configure:1294: checking for $ac_word" >&5
1294
if eval "test \"`echo '$''{'ac_cv_prog_HOST_CC'+set}'`\" = set"; then
1295
echo $ac_n "(cached) $ac_c" 1>&6
1297
if test -n "$HOST_CC"; then
1298
ac_cv_prog_HOST_CC="$HOST_CC" # Let the user override the test.
1300
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1302
for ac_dir in $ac_dummy; do
1303
test -z "$ac_dir" && ac_dir=.
1304
if test -f $ac_dir/$ac_word; then
1305
ac_cv_prog_HOST_CC="$ac_prog"
1312
HOST_CC="$ac_cv_prog_HOST_CC"
1313
if test -n "$HOST_CC"; then
1314
echo "$ac_t""$HOST_CC" 1>&6
1316
echo "$ac_t""no" 1>&6
1319
test -n "$HOST_CC" && break
1321
test -n "$HOST_CC" || HOST_CC=""""
1323
if test -z "$HOST_CC"; then
1324
{ echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
1326
echo "$ac_t""$HOST_CC" 1>&6
1327
if test -z "$HOST_CFLAGS"; then
1328
HOST_CFLAGS="$CFLAGS"
1330
if test -z "$HOST_LDFLAGS"; then
1331
HOST_LDFLAGS="$LDFLAGS"
1335
CFLAGS="$HOST_CFLAGS"
1336
LDFLAGS="$HOST_LDFLAGS"
1338
echo $ac_n "checking whether the $host compiler ($HOST_CC $HOST_CFLAGS $HOST_LDFLAGS) works""... $ac_c" 1>&6
1339
echo "configure:1340: checking whether the $host compiler ($HOST_CC $HOST_CFLAGS $HOST_LDFLAGS) works" >&5
1340
cat > conftest.$ac_ext <<EOF
1341
#line 1342 "configure"
1342
#include "confdefs.h"
1348
if { (eval echo configure:1349: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1350
ac_cv_prog_host_cc_works=1 echo "$ac_t""yes" 1>&6
1352
echo "configure: failed program was:" >&5
1353
cat conftest.$ac_ext >&5
1355
{ echo "configure: error: installation or configuration problem: $host compiler $HOST_CC cannot create executables." 1>&2; exit 1; }
1360
CFLAGS=$_SAVE_CFLAGS
1361
LDFLAGS=$_SAVE_LDFLAGS
1363
case "$build:$target" in
1364
powerpc-apple-darwin8*:i?86-apple-darwin*)
1365
_SAVE_CFLAGS=$CFLAGS
1366
_SAVE_CXXFLAGS=$CXXLAGS
1367
CFLAGS="-isysroot /Developer/SDKs/MacOSX10.4u.sdk $CFLAGS"
1368
CXXFLAGS="-isysroot /Developer/SDKs/MacOSX10.4u.sdk $CXXFLAGS"
1372
for ac_prog in $CC "${target_alias}-gcc" "${target}-gcc"
1374
# Extract the first word of "$ac_prog", so it can be a program name with args.
1375
set dummy $ac_prog; ac_word=$2
1376
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1377
echo "configure:1378: checking for $ac_word" >&5
1378
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1379
echo $ac_n "(cached) $ac_c" 1>&6
1381
if test -n "$CC"; then
1382
ac_cv_prog_CC="$CC" # Let the user override the test.
1384
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1386
for ac_dir in $ac_dummy; do
1387
test -z "$ac_dir" && ac_dir=.
1388
if test -f $ac_dir/$ac_word; then
1389
ac_cv_prog_CC="$ac_prog"
1397
if test -n "$CC"; then
1398
echo "$ac_t""$CC" 1>&6
1400
echo "$ac_t""no" 1>&6
1403
test -n "$CC" && break
1405
test -n "$CC" || CC="echo"
1408
# Extract the first word of "gcc", so it can be a program name with args.
1409
set dummy gcc; ac_word=$2
1410
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1411
echo "configure:1412: checking for $ac_word" >&5
1412
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1413
echo $ac_n "(cached) $ac_c" 1>&6
1415
if test -n "$CC"; then
1416
ac_cv_prog_CC="$CC" # Let the user override the test.
1418
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1420
for ac_dir in $ac_dummy; do
1421
test -z "$ac_dir" && ac_dir=.
1422
if test -f $ac_dir/$ac_word; then
1431
if test -n "$CC"; then
1432
echo "$ac_t""$CC" 1>&6
1434
echo "$ac_t""no" 1>&6
1437
if test -z "$CC"; then
1438
# Extract the first word of "cc", so it can be a program name with args.
1439
set dummy cc; ac_word=$2
1440
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1441
echo "configure:1442: checking for $ac_word" >&5
1442
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1443
echo $ac_n "(cached) $ac_c" 1>&6
1445
if test -n "$CC"; then
1446
ac_cv_prog_CC="$CC" # Let the user override the test.
1448
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1451
for ac_dir in $ac_dummy; do
1452
test -z "$ac_dir" && ac_dir=.
1453
if test -f $ac_dir/$ac_word; then
1454
if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1455
ac_prog_rejected=yes
1463
if test $ac_prog_rejected = yes; then
1464
# We found a bogon in the path, so make sure we never use it.
1465
set dummy $ac_cv_prog_CC
1467
if test $# -gt 0; then
1468
# We chose a different compiler from the bogus one.
1469
# However, it has the same basename, so the bogon will be chosen
1470
# first if we set CC to just the basename; use the full file name.
1472
set dummy "$ac_dir/$ac_word" "$@"
1480
if test -n "$CC"; then
1481
echo "$ac_t""$CC" 1>&6
1483
echo "$ac_t""no" 1>&6
1486
if test -z "$CC"; then
1487
case "`uname -s`" in
1489
# Extract the first word of "cl", so it can be a program name with args.
1490
set dummy cl; ac_word=$2
1491
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1492
echo "configure:1493: checking for $ac_word" >&5
1493
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1494
echo $ac_n "(cached) $ac_c" 1>&6
1496
if test -n "$CC"; then
1497
ac_cv_prog_CC="$CC" # Let the user override the test.
1499
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1501
for ac_dir in $ac_dummy; do
1502
test -z "$ac_dir" && ac_dir=.
1503
if test -f $ac_dir/$ac_word; then
1512
if test -n "$CC"; then
1513
echo "$ac_t""$CC" 1>&6
1515
echo "$ac_t""no" 1>&6
1520
test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
1523
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
1524
echo "configure:1525: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
1527
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1528
ac_cpp='$CPP $CPPFLAGS'
1529
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1530
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1531
cross_compiling=$ac_cv_prog_cc_cross
1533
cat > conftest.$ac_ext << EOF
1535
#line 1536 "configure"
1536
#include "confdefs.h"
1540
if { (eval echo configure:1541: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1541
ac_cv_prog_cc_works=yes
1542
# If we can't run a trivial program, we are probably using a cross compiler.
1543
if (./conftest; exit) 2>/dev/null; then
1544
ac_cv_prog_cc_cross=no
1546
ac_cv_prog_cc_cross=yes
1549
echo "configure: failed program was:" >&5
1550
cat conftest.$ac_ext >&5
1551
ac_cv_prog_cc_works=no
1555
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1556
ac_cpp='$CPP $CPPFLAGS'
1557
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1558
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1559
cross_compiling=$ac_cv_prog_cc_cross
1561
echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
1562
if test $ac_cv_prog_cc_works = no; then
1563
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
1565
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
1566
echo "configure:1567: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
1567
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
1568
cross_compiling=$ac_cv_prog_cc_cross
1570
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
1571
echo "configure:1572: checking whether we are using GNU C" >&5
1572
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
1573
echo $ac_n "(cached) $ac_c" 1>&6
1575
cat > conftest.c <<EOF
1580
if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1581: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
1587
echo "$ac_t""$ac_cv_prog_gcc" 1>&6
1589
if test $ac_cv_prog_gcc = yes; then
1595
ac_test_CFLAGS="${CFLAGS+set}"
1596
ac_save_CFLAGS="$CFLAGS"
1598
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
1599
echo "configure:1600: checking whether ${CC-cc} accepts -g" >&5
1600
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
1601
echo $ac_n "(cached) $ac_c" 1>&6
1603
echo 'void f(){}' > conftest.c
1604
if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
1613
echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
1614
if test "$ac_test_CFLAGS" = set; then
1615
CFLAGS="$ac_save_CFLAGS"
1616
elif test $ac_cv_prog_cc_g = yes; then
1617
if test "$GCC" = yes; then
1623
if test "$GCC" = yes; then
1630
if test -n "$USE_CPLUS"; then
1631
for ac_prog in $CXX "${target_alias}-g++" "${target}-g++"
1633
# Extract the first word of "$ac_prog", so it can be a program name with args.
1634
set dummy $ac_prog; ac_word=$2
1635
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1636
echo "configure:1637: checking for $ac_word" >&5
1637
if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then
1638
echo $ac_n "(cached) $ac_c" 1>&6
1640
if test -n "$CXX"; then
1641
ac_cv_prog_CXX="$CXX" # Let the user override the test.
1643
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1645
for ac_dir in $ac_dummy; do
1646
test -z "$ac_dir" && ac_dir=.
1647
if test -f $ac_dir/$ac_word; then
1648
ac_cv_prog_CXX="$ac_prog"
1655
CXX="$ac_cv_prog_CXX"
1656
if test -n "$CXX"; then
1657
echo "$ac_t""$CXX" 1>&6
1659
echo "$ac_t""no" 1>&6
1662
test -n "$CXX" && break
1664
test -n "$CXX" || CXX="echo"
1666
unset ac_cv_prog_CXX
1667
for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
1669
# Extract the first word of "$ac_prog", so it can be a program name with args.
1670
set dummy $ac_prog; ac_word=$2
1671
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1672
echo "configure:1673: checking for $ac_word" >&5
1673
if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then
1674
echo $ac_n "(cached) $ac_c" 1>&6
1676
if test -n "$CXX"; then
1677
ac_cv_prog_CXX="$CXX" # Let the user override the test.
1679
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1681
for ac_dir in $ac_dummy; do
1682
test -z "$ac_dir" && ac_dir=.
1683
if test -f $ac_dir/$ac_word; then
1684
ac_cv_prog_CXX="$ac_prog"
1691
CXX="$ac_cv_prog_CXX"
1692
if test -n "$CXX"; then
1693
echo "$ac_t""$CXX" 1>&6
1695
echo "$ac_t""no" 1>&6
1698
test -n "$CXX" && break
1700
test -n "$CXX" || CXX="gcc"
1703
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
1704
echo "configure:1705: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
1707
# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1708
ac_cpp='$CXXCPP $CPPFLAGS'
1709
ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1710
ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1711
cross_compiling=$ac_cv_prog_cxx_cross
1713
cat > conftest.$ac_ext << EOF
1715
#line 1716 "configure"
1716
#include "confdefs.h"
1718
int main(){return(0);}
1720
if { (eval echo configure:1721: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1721
ac_cv_prog_cxx_works=yes
1722
# If we can't run a trivial program, we are probably using a cross compiler.
1723
if (./conftest; exit) 2>/dev/null; then
1724
ac_cv_prog_cxx_cross=no
1726
ac_cv_prog_cxx_cross=yes
1729
echo "configure: failed program was:" >&5
1730
cat conftest.$ac_ext >&5
1731
ac_cv_prog_cxx_works=no
1735
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1736
ac_cpp='$CPP $CPPFLAGS'
1737
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1738
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1739
cross_compiling=$ac_cv_prog_cc_cross
1741
echo "$ac_t""$ac_cv_prog_cxx_works" 1>&6
1742
if test $ac_cv_prog_cxx_works = no; then
1743
{ echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
1745
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
1746
echo "configure:1747: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
1747
echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
1748
cross_compiling=$ac_cv_prog_cxx_cross
1750
echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
1751
echo "configure:1752: checking whether we are using GNU C++" >&5
1752
if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
1753
echo $ac_n "(cached) $ac_c" 1>&6
1755
cat > conftest.C <<EOF
1760
if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1761: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
1767
echo "$ac_t""$ac_cv_prog_gxx" 1>&6
1769
if test $ac_cv_prog_gxx = yes; then
1775
ac_test_CXXFLAGS="${CXXFLAGS+set}"
1776
ac_save_CXXFLAGS="$CXXFLAGS"
1778
echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
1779
echo "configure:1780: checking whether ${CXX-g++} accepts -g" >&5
1780
if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
1781
echo $ac_n "(cached) $ac_c" 1>&6
1783
echo 'void f(){}' > conftest.cc
1784
if test -z "`${CXX-g++} -g -c conftest.cc 2>&1`"; then
1785
ac_cv_prog_cxx_g=yes
1793
echo "$ac_t""$ac_cv_prog_cxx_g" 1>&6
1794
if test "$ac_test_CXXFLAGS" = set; then
1795
CXXFLAGS="$ac_save_CXXFLAGS"
1796
elif test $ac_cv_prog_cxx_g = yes; then
1797
if test "$GXX" = yes; then
1803
if test "$GXX" = yes; then
1812
case "$build:$target" in
1813
powerpc-apple-darwin8*:i?86-apple-darwin*)
1814
CFLAGS=$_SAVE_CFLAGS
1815
CXXFLAGS=$_SAVE_CXXFLAGS
1819
for ac_prog in $RANLIB "${target_alias}-ranlib" "${target}-ranlib"
1821
# Extract the first word of "$ac_prog", so it can be a program name with args.
1822
set dummy $ac_prog; ac_word=$2
1823
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1824
echo "configure:1825: checking for $ac_word" >&5
1825
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1826
echo $ac_n "(cached) $ac_c" 1>&6
1828
if test -n "$RANLIB"; then
1829
ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1831
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1833
for ac_dir in $ac_dummy; do
1834
test -z "$ac_dir" && ac_dir=.
1835
if test -f $ac_dir/$ac_word; then
1836
ac_cv_prog_RANLIB="$ac_prog"
1843
RANLIB="$ac_cv_prog_RANLIB"
1844
if test -n "$RANLIB"; then
1845
echo "$ac_t""$RANLIB" 1>&6
1847
echo "$ac_t""no" 1>&6
1850
test -n "$RANLIB" && break
1852
test -n "$RANLIB" || RANLIB="echo"
1854
for ac_prog in $AR "${target_alias}-ar" "${target}-ar"
1856
# Extract the first word of "$ac_prog", so it can be a program name with args.
1857
set dummy $ac_prog; ac_word=$2
1858
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1859
echo "configure:1860: checking for $ac_word" >&5
1860
if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
1861
echo $ac_n "(cached) $ac_c" 1>&6
1863
if test -n "$AR"; then
1864
ac_cv_prog_AR="$AR" # Let the user override the test.
1866
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1868
for ac_dir in $ac_dummy; do
1869
test -z "$ac_dir" && ac_dir=.
1870
if test -f $ac_dir/$ac_word; then
1871
ac_cv_prog_AR="$ac_prog"
1879
if test -n "$AR"; then
1880
echo "$ac_t""$AR" 1>&6
1882
echo "$ac_t""no" 1>&6
1885
test -n "$AR" && break
1887
test -n "$AR" || AR="echo"
1889
for ac_prog in $AS "${target_alias}-as" "${target}-as"
1891
# Extract the first word of "$ac_prog", so it can be a program name with args.
1892
set dummy $ac_prog; ac_word=$2
1893
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1894
echo "configure:1895: checking for $ac_word" >&5
1895
if eval "test \"`echo '$''{'ac_cv_prog_AS'+set}'`\" = set"; then
1896
echo $ac_n "(cached) $ac_c" 1>&6
1898
if test -n "$AS"; then
1899
ac_cv_prog_AS="$AS" # Let the user override the test.
1901
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1903
for ac_dir in $ac_dummy; do
1904
test -z "$ac_dir" && ac_dir=.
1905
if test -f $ac_dir/$ac_word; then
1906
ac_cv_prog_AS="$ac_prog"
1914
if test -n "$AS"; then
1915
echo "$ac_t""$AS" 1>&6
1917
echo "$ac_t""no" 1>&6
1920
test -n "$AS" && break
1922
test -n "$AS" || AS="echo"
1924
for ac_prog in $LD "${target_alias}-ld" "${target}-ld"
1926
# Extract the first word of "$ac_prog", so it can be a program name with args.
1927
set dummy $ac_prog; ac_word=$2
1928
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1929
echo "configure:1930: checking for $ac_word" >&5
1930
if eval "test \"`echo '$''{'ac_cv_prog_LD'+set}'`\" = set"; then
1931
echo $ac_n "(cached) $ac_c" 1>&6
1933
if test -n "$LD"; then
1934
ac_cv_prog_LD="$LD" # Let the user override the test.
1936
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1938
for ac_dir in $ac_dummy; do
1939
test -z "$ac_dir" && ac_dir=.
1940
if test -f $ac_dir/$ac_word; then
1941
ac_cv_prog_LD="$ac_prog"
1949
if test -n "$LD"; then
1950
echo "$ac_t""$LD" 1>&6
1952
echo "$ac_t""no" 1>&6
1955
test -n "$LD" && break
1957
test -n "$LD" || LD="echo"
1959
for ac_prog in $STRIP "${target_alias}-strip" "${target}-strip"
1961
# Extract the first word of "$ac_prog", so it can be a program name with args.
1962
set dummy $ac_prog; ac_word=$2
1963
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1964
echo "configure:1965: checking for $ac_word" >&5
1965
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
1966
echo $ac_n "(cached) $ac_c" 1>&6
1968
if test -n "$STRIP"; then
1969
ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
1971
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1973
for ac_dir in $ac_dummy; do
1974
test -z "$ac_dir" && ac_dir=.
1975
if test -f $ac_dir/$ac_word; then
1976
ac_cv_prog_STRIP="$ac_prog"
1983
STRIP="$ac_cv_prog_STRIP"
1984
if test -n "$STRIP"; then
1985
echo "$ac_t""$STRIP" 1>&6
1987
echo "$ac_t""no" 1>&6
1990
test -n "$STRIP" && break
1992
test -n "$STRIP" || STRIP="echo"
1994
for ac_prog in $WINDRES "${target_alias}-windres" "${target}-windres"
1996
# Extract the first word of "$ac_prog", so it can be a program name with args.
1997
set dummy $ac_prog; ac_word=$2
1998
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1999
echo "configure:2000: checking for $ac_word" >&5
2000
if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then
2001
echo $ac_n "(cached) $ac_c" 1>&6
2003
if test -n "$WINDRES"; then
2004
ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
2006
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2008
for ac_dir in $ac_dummy; do
2009
test -z "$ac_dir" && ac_dir=.
2010
if test -f $ac_dir/$ac_word; then
2011
ac_cv_prog_WINDRES="$ac_prog"
2018
WINDRES="$ac_cv_prog_WINDRES"
2019
if test -n "$WINDRES"; then
2020
echo "$ac_t""$WINDRES" 1>&6
2022
echo "$ac_t""no" 1>&6
2025
test -n "$WINDRES" && break
2027
test -n "$WINDRES" || WINDRES="echo"
2031
# Extract the first word of "gcc", so it can be a program name with args.
2032
set dummy gcc; ac_word=$2
2033
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2034
echo "configure:2035: checking for $ac_word" >&5
2035
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
2036
echo $ac_n "(cached) $ac_c" 1>&6
2038
if test -n "$CC"; then
2039
ac_cv_prog_CC="$CC" # Let the user override the test.
2041
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2043
for ac_dir in $ac_dummy; do
2044
test -z "$ac_dir" && ac_dir=.
2045
if test -f $ac_dir/$ac_word; then
2054
if test -n "$CC"; then
2055
echo "$ac_t""$CC" 1>&6
2057
echo "$ac_t""no" 1>&6
2060
if test -z "$CC"; then
2061
# Extract the first word of "cc", so it can be a program name with args.
2062
set dummy cc; ac_word=$2
2063
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2064
echo "configure:2065: checking for $ac_word" >&5
2065
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
2066
echo $ac_n "(cached) $ac_c" 1>&6
2068
if test -n "$CC"; then
2069
ac_cv_prog_CC="$CC" # Let the user override the test.
2071
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2074
for ac_dir in $ac_dummy; do
2075
test -z "$ac_dir" && ac_dir=.
2076
if test -f $ac_dir/$ac_word; then
2077
if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
2078
ac_prog_rejected=yes
2086
if test $ac_prog_rejected = yes; then
2087
# We found a bogon in the path, so make sure we never use it.
2088
set dummy $ac_cv_prog_CC
2090
if test $# -gt 0; then
2091
# We chose a different compiler from the bogus one.
2092
# However, it has the same basename, so the bogon will be chosen
2093
# first if we set CC to just the basename; use the full file name.
2095
set dummy "$ac_dir/$ac_word" "$@"
2103
if test -n "$CC"; then
2104
echo "$ac_t""$CC" 1>&6
2106
echo "$ac_t""no" 1>&6
2109
if test -z "$CC"; then
2110
case "`uname -s`" in
2112
# Extract the first word of "cl", so it can be a program name with args.
2113
set dummy cl; ac_word=$2
2114
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2115
echo "configure:2116: checking for $ac_word" >&5
2116
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
2117
echo $ac_n "(cached) $ac_c" 1>&6
2119
if test -n "$CC"; then
2120
ac_cv_prog_CC="$CC" # Let the user override the test.
2122
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2124
for ac_dir in $ac_dummy; do
2125
test -z "$ac_dir" && ac_dir=.
2126
if test -f $ac_dir/$ac_word; then
2135
if test -n "$CC"; then
2136
echo "$ac_t""$CC" 1>&6
2138
echo "$ac_t""no" 1>&6
2143
test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
2146
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
2147
echo "configure:2148: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
2150
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2151
ac_cpp='$CPP $CPPFLAGS'
2152
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2153
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2154
cross_compiling=$ac_cv_prog_cc_cross
2156
cat > conftest.$ac_ext << EOF
2158
#line 2159 "configure"
2159
#include "confdefs.h"
2163
if { (eval echo configure:2164: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2164
ac_cv_prog_cc_works=yes
2165
# If we can't run a trivial program, we are probably using a cross compiler.
2166
if (./conftest; exit) 2>/dev/null; then
2167
ac_cv_prog_cc_cross=no
2169
ac_cv_prog_cc_cross=yes
2172
echo "configure: failed program was:" >&5
2173
cat conftest.$ac_ext >&5
2174
ac_cv_prog_cc_works=no
2178
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2179
ac_cpp='$CPP $CPPFLAGS'
2180
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2181
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2182
cross_compiling=$ac_cv_prog_cc_cross
2184
echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
2185
if test $ac_cv_prog_cc_works = no; then
2186
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
2188
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
2189
echo "configure:2190: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
2190
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
2191
cross_compiling=$ac_cv_prog_cc_cross
2193
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
2194
echo "configure:2195: checking whether we are using GNU C" >&5
2195
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
2196
echo $ac_n "(cached) $ac_c" 1>&6
2198
cat > conftest.c <<EOF
2203
if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2204: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
2210
echo "$ac_t""$ac_cv_prog_gcc" 1>&6
2212
if test $ac_cv_prog_gcc = yes; then
2218
ac_test_CFLAGS="${CFLAGS+set}"
2219
ac_save_CFLAGS="$CFLAGS"
2221
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
2222
echo "configure:2223: checking whether ${CC-cc} accepts -g" >&5
2223
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
2224
echo $ac_n "(cached) $ac_c" 1>&6
2226
echo 'void f(){}' > conftest.c
2227
if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
2236
echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
2237
if test "$ac_test_CFLAGS" = set; then
2238
CFLAGS="$ac_save_CFLAGS"
2239
elif test $ac_cv_prog_cc_g = yes; then
2240
if test "$GCC" = yes; then
2246
if test "$GCC" = yes; then
2253
if test -n "$USE_CPLUS"; then
2254
if test "$CC" = "cl" -a -z "$CXX"; then
2257
for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
2259
# Extract the first word of "$ac_prog", so it can be a program name with args.
2260
set dummy $ac_prog; ac_word=$2
2261
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2262
echo "configure:2263: checking for $ac_word" >&5
2263
if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then
2264
echo $ac_n "(cached) $ac_c" 1>&6
2266
if test -n "$CXX"; then
2267
ac_cv_prog_CXX="$CXX" # Let the user override the test.
2269
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2271
for ac_dir in $ac_dummy; do
2272
test -z "$ac_dir" && ac_dir=.
2273
if test -f $ac_dir/$ac_word; then
2274
ac_cv_prog_CXX="$ac_prog"
2281
CXX="$ac_cv_prog_CXX"
2282
if test -n "$CXX"; then
2283
echo "$ac_t""$CXX" 1>&6
2285
echo "$ac_t""no" 1>&6
2288
test -n "$CXX" && break
2290
test -n "$CXX" || CXX="gcc"
2293
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
2294
echo "configure:2295: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
2297
# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2298
ac_cpp='$CXXCPP $CPPFLAGS'
2299
ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2300
ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2301
cross_compiling=$ac_cv_prog_cxx_cross
2303
cat > conftest.$ac_ext << EOF
2305
#line 2306 "configure"
2306
#include "confdefs.h"
2308
int main(){return(0);}
2310
if { (eval echo configure:2311: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2311
ac_cv_prog_cxx_works=yes
2312
# If we can't run a trivial program, we are probably using a cross compiler.
2313
if (./conftest; exit) 2>/dev/null; then
2314
ac_cv_prog_cxx_cross=no
2316
ac_cv_prog_cxx_cross=yes
2319
echo "configure: failed program was:" >&5
2320
cat conftest.$ac_ext >&5
2321
ac_cv_prog_cxx_works=no
2325
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2326
ac_cpp='$CPP $CPPFLAGS'
2327
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2328
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2329
cross_compiling=$ac_cv_prog_cc_cross
2331
echo "$ac_t""$ac_cv_prog_cxx_works" 1>&6
2332
if test $ac_cv_prog_cxx_works = no; then
2333
{ echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
2335
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
2336
echo "configure:2337: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
2337
echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
2338
cross_compiling=$ac_cv_prog_cxx_cross
2340
echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
2341
echo "configure:2342: checking whether we are using GNU C++" >&5
2342
if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
2343
echo $ac_n "(cached) $ac_c" 1>&6
2345
cat > conftest.C <<EOF
2350
if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:2351: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
2357
echo "$ac_t""$ac_cv_prog_gxx" 1>&6
2359
if test $ac_cv_prog_gxx = yes; then
2365
ac_test_CXXFLAGS="${CXXFLAGS+set}"
2366
ac_save_CXXFLAGS="$CXXFLAGS"
2368
echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
2369
echo "configure:2370: checking whether ${CXX-g++} accepts -g" >&5
2370
if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
2371
echo $ac_n "(cached) $ac_c" 1>&6
2373
echo 'void f(){}' > conftest.cc
2374
if test -z "`${CXX-g++} -g -c conftest.cc 2>&1`"; then
2375
ac_cv_prog_cxx_g=yes
2383
echo "$ac_t""$ac_cv_prog_cxx_g" 1>&6
2384
if test "$ac_test_CXXFLAGS" = set; then
2385
CXXFLAGS="$ac_save_CXXFLAGS"
2386
elif test $ac_cv_prog_cxx_g = yes; then
2387
if test "$GXX" = yes; then
2393
if test "$GXX" = yes; then
2402
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
2403
echo "configure:2404: checking how to run the C preprocessor" >&5
2404
# On Suns, sometimes $CPP names a directory.
2405
if test -n "$CPP" && test -d "$CPP"; then
2408
if test -z "$CPP"; then
2409
if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
2410
echo $ac_n "(cached) $ac_c" 1>&6
2412
# This must be in double quotes, not single quotes, because CPP may get
2413
# substituted into the Makefile and "${CC-cc}" will confuse make.
2415
# On the NeXT, cc -E runs the code through the compiler's parser,
2416
# not just through cpp.
2417
cat > conftest.$ac_ext <<EOF
2418
#line 2419 "configure"
2419
#include "confdefs.h"
2423
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2424
{ (eval echo configure:2425: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2425
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2426
if test -z "$ac_err"; then
2430
echo "configure: failed program was:" >&5
2431
cat conftest.$ac_ext >&5
2433
CPP="${CC-cc} -E -traditional-cpp"
2434
cat > conftest.$ac_ext <<EOF
2435
#line 2436 "configure"
2436
#include "confdefs.h"
2440
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2441
{ (eval echo configure:2442: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2442
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2443
if test -z "$ac_err"; then
2447
echo "configure: failed program was:" >&5
2448
cat conftest.$ac_ext >&5
2450
CPP="${CC-cc} -nologo -E"
2451
cat > conftest.$ac_ext <<EOF
2452
#line 2453 "configure"
2453
#include "confdefs.h"
2457
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2458
{ (eval echo configure:2459: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2459
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2460
if test -z "$ac_err"; then
2464
echo "configure: failed program was:" >&5
2465
cat conftest.$ac_ext >&5
2474
ac_cv_prog_CPP="$CPP"
2476
CPP="$ac_cv_prog_CPP"
2478
ac_cv_prog_CPP="$CPP"
2480
echo "$ac_t""$CPP" 1>&6
2482
# Extract the first word of "ranlib", so it can be a program name with args.
2483
set dummy ranlib; ac_word=$2
2484
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2485
echo "configure:2486: checking for $ac_word" >&5
2486
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
2487
echo $ac_n "(cached) $ac_c" 1>&6
2489
if test -n "$RANLIB"; then
2490
ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
2492
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2494
for ac_dir in $ac_dummy; do
2495
test -z "$ac_dir" && ac_dir=.
2496
if test -f $ac_dir/$ac_word; then
2497
ac_cv_prog_RANLIB="ranlib"
2502
test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
2505
RANLIB="$ac_cv_prog_RANLIB"
2506
if test -n "$RANLIB"; then
2507
echo "$ac_t""$RANLIB" 1>&6
2509
echo "$ac_t""no" 1>&6
2514
# Extract the first word of "$ac_prog", so it can be a program name with args.
2515
set dummy $ac_prog; ac_word=$2
2516
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2517
echo "configure:2518: checking for $ac_word" >&5
2518
if eval "test \"`echo '$''{'ac_cv_path_AS'+set}'`\" = set"; then
2519
echo $ac_n "(cached) $ac_c" 1>&6
2523
ac_cv_path_AS="$AS" # Let the user override the test with a path.
2526
ac_cv_path_AS="$AS" # Let the user override the test with a dos path.
2529
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2531
for ac_dir in $ac_dummy; do
2532
test -z "$ac_dir" && ac_dir=.
2533
if test -f $ac_dir/$ac_word; then
2534
ac_cv_path_AS="$ac_dir/$ac_word"
2543
if test -n "$AS"; then
2544
echo "$ac_t""$AS" 1>&6
2546
echo "$ac_t""no" 1>&6
2549
test -n "$AS" && break
2551
test -n "$AS" || AS="$CC"
2555
# Extract the first word of "$ac_prog", so it can be a program name with args.
2556
set dummy $ac_prog; ac_word=$2
2557
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2558
echo "configure:2559: checking for $ac_word" >&5
2559
if eval "test \"`echo '$''{'ac_cv_path_AR'+set}'`\" = set"; then
2560
echo $ac_n "(cached) $ac_c" 1>&6
2564
ac_cv_path_AR="$AR" # Let the user override the test with a path.
2567
ac_cv_path_AR="$AR" # Let the user override the test with a dos path.
2570
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2572
for ac_dir in $ac_dummy; do
2573
test -z "$ac_dir" && ac_dir=.
2574
if test -f $ac_dir/$ac_word; then
2575
ac_cv_path_AR="$ac_dir/$ac_word"
2584
if test -n "$AR"; then
2585
echo "$ac_t""$AR" 1>&6
2587
echo "$ac_t""no" 1>&6
2590
test -n "$AR" && break
2592
test -n "$AR" || AR="echo not_ar"
2594
for ac_prog in ld link
2596
# Extract the first word of "$ac_prog", so it can be a program name with args.
2597
set dummy $ac_prog; ac_word=$2
2598
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2599
echo "configure:2600: checking for $ac_word" >&5
2600
if eval "test \"`echo '$''{'ac_cv_path_LD'+set}'`\" = set"; then
2601
echo $ac_n "(cached) $ac_c" 1>&6
2605
ac_cv_path_LD="$LD" # Let the user override the test with a path.
2608
ac_cv_path_LD="$LD" # Let the user override the test with a dos path.
2611
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2613
for ac_dir in $ac_dummy; do
2614
test -z "$ac_dir" && ac_dir=.
2615
if test -f $ac_dir/$ac_word; then
2616
ac_cv_path_LD="$ac_dir/$ac_word"
2625
if test -n "$LD"; then
2626
echo "$ac_t""$LD" 1>&6
2628
echo "$ac_t""no" 1>&6
2631
test -n "$LD" && break
2633
test -n "$LD" || LD="echo not_ld"
2635
for ac_prog in strip
2637
# Extract the first word of "$ac_prog", so it can be a program name with args.
2638
set dummy $ac_prog; ac_word=$2
2639
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2640
echo "configure:2641: checking for $ac_word" >&5
2641
if eval "test \"`echo '$''{'ac_cv_path_STRIP'+set}'`\" = set"; then
2642
echo $ac_n "(cached) $ac_c" 1>&6
2646
ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
2649
ac_cv_path_STRIP="$STRIP" # Let the user override the test with a dos path.
2652
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2654
for ac_dir in $ac_dummy; do
2655
test -z "$ac_dir" && ac_dir=.
2656
if test -f $ac_dir/$ac_word; then
2657
ac_cv_path_STRIP="$ac_dir/$ac_word"
2665
STRIP="$ac_cv_path_STRIP"
2666
if test -n "$STRIP"; then
2667
echo "$ac_t""$STRIP" 1>&6
2669
echo "$ac_t""no" 1>&6
2672
test -n "$STRIP" && break
2674
test -n "$STRIP" || STRIP="echo not_strip"
2676
for ac_prog in windres
2678
# Extract the first word of "$ac_prog", so it can be a program name with args.
2679
set dummy $ac_prog; ac_word=$2
2680
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2681
echo "configure:2682: checking for $ac_word" >&5
2682
if eval "test \"`echo '$''{'ac_cv_path_WINDRES'+set}'`\" = set"; then
2683
echo $ac_n "(cached) $ac_c" 1>&6
2687
ac_cv_path_WINDRES="$WINDRES" # Let the user override the test with a path.
2690
ac_cv_path_WINDRES="$WINDRES" # Let the user override the test with a dos path.
2693
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2695
for ac_dir in $ac_dummy; do
2696
test -z "$ac_dir" && ac_dir=.
2697
if test -f $ac_dir/$ac_word; then
2698
ac_cv_path_WINDRES="$ac_dir/$ac_word"
2706
WINDRES="$ac_cv_path_WINDRES"
2707
if test -n "$WINDRES"; then
2708
echo "$ac_t""$WINDRES" 1>&6
2710
echo "$ac_t""no" 1>&6
2713
test -n "$WINDRES" && break
2715
test -n "$WINDRES" || WINDRES="echo not_windres"
2717
if test -z "$HOST_CC"; then
2720
if test -z "$HOST_CFLAGS"; then
2721
HOST_CFLAGS="$CFLAGS"
2725
if test "$GCC" = "yes"; then
2728
if test "$GXX" = "yes"; then
2731
if test "`echo | $AS -v 2>&1 | grep -c GNU`" != "0"; then
2736
case "$build:$target" in
2737
i?86-apple-darwin*:powerpc-apple-darwin*)
2742
if test "$cross_compiling" = "yes"; then
2748
echo $ac_n "checking for gcc -pipe support""... $ac_c" 1>&6
2749
echo "configure:2750: checking for gcc -pipe support" >&5
2750
if test -n "$GNU_CC" && test -n "$GNU_CXX" && test -n "$GNU_AS"; then
2751
echo '#include <stdio.h>' > dummy-hello.c
2752
echo 'int main() { printf("Hello World\n"); return 0; }' >> dummy-hello.c
2753
${CC} -S dummy-hello.c -o dummy-hello.s 2>&5
2754
cat dummy-hello.s | ${AS} -o dummy-hello.S - 2>&5
2755
if test $? = 0; then
2760
if test "$_res_as_stdin" = "yes"; then
2761
_SAVE_CFLAGS=$CFLAGS
2762
CFLAGS="$CFLAGS -pipe"
2763
cat > conftest.$ac_ext <<EOF
2764
#line 2765 "configure"
2765
#include "confdefs.h"
2768
printf("Hello World\n");
2771
if { (eval echo configure:2772: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2775
echo "configure: failed program was:" >&5
2776
cat conftest.$ac_ext >&5
2781
CFLAGS=$_SAVE_CFLAGS
2783
if test "$_res_as_stdin" = "yes" && test "$_res_gcc_pipe" = "yes"; then
2785
CFLAGS="$CFLAGS -pipe"
2786
CXXFLAGS="$CXXFLAGS -pipe"
2790
rm -f dummy-hello.c dummy-hello.s dummy-hello.S dummy-hello a.out
2791
echo "$ac_t""$_res" 1>&6
2793
echo "$ac_t""no" 1>&6
2797
_SAVE_CFLAGS="$CFLAGS"
2798
CFLAGS="$CFLAGS -fprofile-generate -fprofile-correction"
2800
echo $ac_n "checking whether C compiler supports -fprofile-generate""... $ac_c" 1>&6
2801
echo "configure:2802: checking whether C compiler supports -fprofile-generate" >&5
2802
cat > conftest.$ac_ext <<EOF
2803
#line 2804 "configure"
2804
#include "confdefs.h"
2810
if { (eval echo configure:2811: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2812
PROFILE_GEN_CFLAGS="-fprofile-generate"
2815
echo "configure: failed program was:" >&5
2816
cat conftest.$ac_ext >&5
2821
echo "$ac_t""$result" 1>&6
2823
if test $result = "yes"; then
2824
PROFILE_GEN_LDFLAGS="-fprofile-generate"
2825
PROFILE_USE_CFLAGS="-fprofile-use -fprofile-correction -Wcoverage-mismatch"
2826
PROFILE_USE_LDFLAGS="-fprofile-use"
2829
CFLAGS="$_SAVE_CFLAGS"
2831
if test "$GNU_CC"; then
2832
echo $ac_n "checking for visibility(hidden) attribute""... $ac_c" 1>&6
2833
echo "configure:2834: checking for visibility(hidden) attribute" >&5
2834
if eval "test \"`echo '$''{'ac_cv_visibility_hidden'+set}'`\" = set"; then
2835
echo $ac_n "(cached) $ac_c" 1>&6
2837
cat > conftest.c <<EOF
2838
int foo __attribute__ ((visibility ("hidden"))) = 1;
2840
ac_cv_visibility_hidden=no
2841
if ${CC-cc} -Werror -S conftest.c -o conftest.s >/dev/null 2>&1; then
2842
if grep '\.hidden.*foo' conftest.s >/dev/null; then
2843
ac_cv_visibility_hidden=yes
2850
echo "$ac_t""$ac_cv_visibility_hidden" 1>&6
2851
if test "$ac_cv_visibility_hidden" = "yes"; then
2852
cat >> confdefs.h <<\EOF
2853
#define HAVE_VISIBILITY_HIDDEN_ATTRIBUTE 1
2856
echo $ac_n "checking for visibility pragma support""... $ac_c" 1>&6
2857
echo "configure:2858: checking for visibility pragma support" >&5
2858
if eval "test \"`echo '$''{'ac_cv_visibility_pragma'+set}'`\" = set"; then
2859
echo $ac_n "(cached) $ac_c" 1>&6
2861
cat > conftest.c <<EOF
2862
#pragma GCC visibility push(hidden)
2864
#pragma GCC visibility push(default)
2865
int foo_default = 1;
2867
ac_cv_visibility_pragma=no
2868
if ${CC-cc} -Werror -S conftest.c -o conftest.s >/dev/null 2>&1; then
2869
if grep '\.hidden.*foo_hidden' conftest.s >/dev/null; then
2870
if ! grep '\.hidden.*foo_default' conftest.s > /dev/null; then
2871
ac_cv_visibility_pragma=yes
2879
echo "$ac_t""$ac_cv_visibility_pragma" 1>&6
2880
if test "$ac_cv_visibility_pragma" = "yes"; then
2881
cat >> confdefs.h <<\EOF
2882
#define HAVE_VISIBILITY_PRAGMA 1
2885
# To work around a build problem on Linux x86-64 (Bugzilla bug
2886
# 293438), we use the -fvisibility=hidden flag. This flag is less
2887
# optimal than #pragma GCC visibility push(hidden) because the flag
2888
# assumes that symbols defined outside the current source file have
2889
# the default visibility. This has the advantage that we don't need
2890
# to wrap system header files, but has the disadvantage that calls
2891
# to hidden symbols defined in other source files cannot be
2892
# optimized by the compiler. The -fvisibility=hidden flag does
2893
# hide and export symbols correctly.
2894
#VISIBILITY_FLAGS='-I$(dist_includedir)/system_wrappers -include $(topsrcdir)/config/gcc_hidden.h'
2895
#WRAP_SYSTEM_INCLUDES=1
2896
VISIBILITY_FLAGS="-fvisibility=hidden"
2897
WRAP_SYSTEM_INCLUDES=
2902
fi # SKIP_COMPILER_CHECKS
2904
if test -z "$SKIP_PATH_CHECKS"; then
2905
for ac_prog in perl5 perl
2907
# Extract the first word of "$ac_prog", so it can be a program name with args.
2908
set dummy $ac_prog; ac_word=$2
2909
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2910
echo "configure:2911: checking for $ac_word" >&5
2911
if eval "test \"`echo '$''{'ac_cv_path_PERL'+set}'`\" = set"; then
2912
echo $ac_n "(cached) $ac_c" 1>&6
2916
ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
2919
ac_cv_path_PERL="$PERL" # Let the user override the test with a dos path.
2922
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2924
for ac_dir in $ac_dummy; do
2925
test -z "$ac_dir" && ac_dir=.
2926
if test -f $ac_dir/$ac_word; then
2927
ac_cv_path_PERL="$ac_dir/$ac_word"
2935
PERL="$ac_cv_path_PERL"
2936
if test -n "$PERL"; then
2937
echo "$ac_t""$PERL" 1>&6
2939
echo "$ac_t""no" 1>&6
2942
test -n "$PERL" && break
2944
test -n "$PERL" || PERL="echo not_perl"
2946
elif test -z "$PERL"; then
2954
MKSHLIB='$(LD) $(DSO_LDOPTS) -o $@'
2962
if test -n "$CROSS_COMPILE"; then
2963
OS_ARCH=`echo $target_os | sed -e 's|/|_|g'`
2965
OS_TEST="${target_cpu}"
2966
case "${target_os}" in
2967
linux*) OS_ARCH=Linux ;;
2968
solaris*) OS_ARCH=SunOS OS_RELEASE=5 ;;
2969
mingw*) OS_ARCH=WINNT ;;
2970
wince*) OS_ARCH=WINCE ;;
2971
winmo*) OS_ARCH=WINCE ;;
2972
darwin*) OS_ARCH=Darwin ;;
2973
riscos*) OS_ARCH=RISCOS ;;
2976
OS_ARCH=`uname -s | sed -e 's|/|_|g'`
2977
OS_RELEASE=`uname -r`
2981
if test "$OS_ARCH" = "IRIX64"; then
2985
if test "$OS_ARCH" = "AIX"; then
2986
OS_RELEASE=`uname -v`.`uname -r`
2989
if test "$OS_ARCH" = "FreeBSD"; then
2990
OS_RELEASE=`echo $OS_RELEASE | sed 's/-.*//'`
2993
if test "$OS_ARCH" = "Linux"; then
2994
OS_RELEASE=`echo $OS_RELEASE | sed 's/-.*//'`
2995
OS_RELEASE=`echo $OS_RELEASE | awk -F\. '{ print $1 "." $2 }'`
2998
#######################################################################
2999
# Master "Core Components" macros for getting the OS target #
3000
#######################################################################
3003
# Note: OS_TARGET should be specified on the command line for gmake.
3004
# When OS_TARGET=WIN95 is specified, then a Windows 95 target is built.
3005
# The difference between the Win95 target and the WinNT target is that
3006
# the WinNT target uses Windows NT specific features not available
3007
# in Windows 95. The Win95 target will run on Windows NT, but (supposedly)
3008
# at lesser performance (the Win95 target uses threads; the WinNT target
3011
# If OS_TARGET is not specified, it defaults to $(OS_ARCH), i.e., no
3012
# cross-compilation.
3016
# The following hack allows one to build on a WIN95 machine (as if
3017
# s/he were cross-compiling on a WINNT host for a WIN95 target).
3018
# It also accomodates for MKS's uname.exe. If you never intend
3019
# to do development on a WIN95 machine, you don't need this hack.
3034
CYGWIN_9*|CYGWIN_ME*)
3035
OS_ARCH='CYGWIN_NT-4.0'
3045
# On WIN32, we also define the variable CPU_ARCH.
3051
if test "$CPU_ARCH" = "I386"; then
3057
# If uname -s returns "Windows_NT", we assume that we are using
3058
# the uname.exe in MKS toolkit.
3060
# The -r option of MKS uname only returns the major version number.
3061
# So we need to use its -v option to get the minor version number.
3062
# Moreover, it doesn't have the -p option, so we need to use uname -m.
3065
OS_MINOR_RELEASE=`uname -v`
3066
if test "$OS_MINOR_RELEASE" = "00"; then
3069
OS_RELEASE="${OS_RELEASE}.${OS_MINOR_RELEASE}"
3072
# MKS's uname -m returns "586" on a Pentium machine.
3074
if echo "$CPU_ARCH" | grep -c 86 >/dev/null; then
3078
CYGWIN_NT*|MINGW*_NT*)
3080
# If uname -s returns "CYGWIN_NT-4.0", we assume that we are using
3081
# the uname.exe in the Cygwin tools.
3082
# If uname -s returns MINGW32_NT-5.1, we assume that we are using
3083
# the uname.exe in the MSYS tools.
3085
OS_RELEASE=`expr $OS_ARCH : '.*NT-\(.*\)'`
3089
# Cygwin's uname -m returns "i686" on a Pentium Pro machine.
3091
if echo "$CPU_ARCH" | grep -c 86 >/dev/null; then
3097
if test -n "$MOZILLA_CLIENT" && test "$OS_ARCH" = "WINNT"; then
3099
if test -n "$MOZ_DEBUG"; then
3103
if test -z "$OS_TARGET"; then
3106
if test "$OS_TARGET" = "WIN95"; then
3109
OS_CONFIG="${OS_TARGET}${OS_RELEASE}"
3111
# Check whether --enable-os2-high-mem or --disable-os2-high-mem was given.
3112
if test "${enable_os2_high_mem+set}" = set; then
3113
enableval="$enable_os2_high_mem"
3114
if test "$enableval" = "no"; then
3115
MOZ_OS2_HIGH_MEMORY=
3117
MOZ_OS2_HIGH_MEMORY=1
3123
case "${CPU_ARCH}-${OS_TARGET}" in
3128
MOZ_FLOAT_ABI=softfp
3131
if test -n "$MOZ_PLATFORM_MAEMO"; then
3134
MOZ_FLOAT_ABI=softfp
3136
if test "$MOZ_PLATFORM_MAEMO" = 6; then
3142
# Check whether --enable-thumb2 or --disable-thumb2 was given.
3143
if test "${enable_thumb2+set}" = set; then
3144
enableval="$enable_thumb2"
3145
MOZ_THUMB=$enableval
3149
# Check whether --with-thumb or --without-thumb was given.
3150
if test "${with_thumb+set}" = set; then
3151
withval="$with_thumb"
3152
if test -z "$GNU_CC"; then
3153
{ echo "configure: error: --with-thumb is not supported on non-GNU toolchain-defaults" 1>&2; exit 1; }
3159
# Check whether --with-thumb-interwork or --without-thumb-interwork was given.
3160
if test "${with_thumb_interwork+set}" = set; then
3161
withval="$with_thumb_interwork"
3162
if test -z "$GNU_CC"; then
3163
{ echo "configure: error: --with-thumb-interwork is not supported on non-GNU toolchain-defaults" 1>&2; exit 1; }
3165
MOZ_THUMB_INTERWORK=$withval
3169
# Check whether --with-arch or --without-arch was given.
3170
if test "${with_arch+set}" = set; then
3171
withval="$with_arch"
3172
if test -z "$GNU_CC"; then
3173
{ echo "configure: error: --with-arch is not supported on non-GNU toolchain-defaults" 1>&2; exit 1; }
3179
# Check whether --with-fpu or --without-fpu was given.
3180
if test "${with_fpu+set}" = set; then
3182
if test -z "$GNU_CC"; then
3183
{ echo "configure: error: --with-fpu is not supported on non-GNU toolchain-defaults" 1>&2; exit 1; }
3189
# Check whether --with-float-abi or --without-float-abi was given.
3190
if test "${with_float_abi+set}" = set; then
3191
withval="$with_float_abi"
3192
if test -z "$GNU_CC"; then
3193
{ echo "configure: error: --with-float-abi is not supported on non-GNU toolchain-defaults" 1>&2; exit 1; }
3195
MOZ_FLOAT_ABI=$withval
3199
# Check whether --with-soft-float or --without-soft-float was given.
3200
if test "${with_soft_float+set}" = set; then
3201
withval="$with_soft_float"
3202
if test -z "$GNU_CC"; then
3203
{ echo "configure: error: --with-soft-float is not supported on non-GNU toolchain-defaults" 1>&2; exit 1; }
3205
MOZ_SOFT_FLOAT=$withval
3210
toolchain-default|"")
3214
arch_flag="-march=$MOZ_ARCH"
3218
case "$MOZ_THUMB" in
3221
thumb_flag="-mthumb"
3228
_SAVE_CFLAGS="$CFLAGS"
3230
cat > conftest.$ac_ext <<EOF
3231
#line 3232 "configure"
3232
#include "confdefs.h"
3235
return sizeof(__thumb2__);
3238
if { (eval echo configure:3239: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3242
echo "configure: failed program was:" >&5
3243
cat conftest.$ac_ext >&5
3248
CFLAGS="$_SAVE_CFLAGS"
3253
case "$MOZ_THUMB_INTERWORK" in
3255
thumb_interwork_flag="-mthumb-interwork"
3258
thumb_interwork_flag="-mno-thumb-interwork"
3260
*) # toolchain-default
3261
thumb_interwork_flag=""
3266
toolchain-default|"")
3270
fpu_flag="-mfpu=$MOZ_FPU"
3274
case "$MOZ_FLOAT_ABI" in
3275
toolchain-default|"")
3279
float_abi_flag="-mfloat-abi=$MOZ_FLOAT_ABI"
3283
case "$MOZ_SOFT_FLOAT" in
3285
soft_float_flag="-msoft-float"
3288
soft_float_flag="-mno-soft-float"
3290
*) # toolchain-default
3295
all_flags=`echo $arch_flag $thumb_flag $thumb_interwork_flag $fpu_flag $float_abi_flag $soft_float_flag`
3296
if test -n "$all_flags"; then
3297
_SAVE_CFLAGS="$CFLAGS"
3299
echo $ac_n "checking whether the chosen combination of compiler flags ($all_flags) works""... $ac_c" 1>&6
3300
echo "configure:3301: checking whether the chosen combination of compiler flags ($all_flags) works" >&5
3301
cat > conftest.$ac_ext <<EOF
3302
#line 3303 "configure"
3303
#include "confdefs.h"
3309
if { (eval echo configure:3310: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3311
echo "$ac_t""yes" 1>&6
3313
echo "configure: failed program was:" >&5
3314
cat conftest.$ac_ext >&5
3316
{ echo "configure: error: no" 1>&2; exit 1; }
3320
CFLAGS="$_SAVE_CFLAGS $all_flags"
3321
CXXFLAGS="$CXXFLAGS $all_flags"
3322
ASFLAGS="$ASFLAGS $all_flags"
3323
if test -n "$thumb_flag"; then
3324
LDFLAGS="$LDFLAGS $thumb_flag"
3332
*-cygwin*|*-msvc*|*-mks*|*-wince*|*-winmo*)
3333
NSINSTALL='$(CYGWIN_WRAPPER) nsinstall'
3334
if test `echo "${PATH}" | grep -c \;` = 0; then
3335
CYGWIN_WRAPPER='sh $(topsrcdir)/build/cygwin-wrapper'
3339
HOST_CFLAGS="$HOST_CFLAGS -DXP_BEOS -DBeOS -DBEOS -D_POSIX_SOURCE"
3344
HOST_CFLAGS="$HOST_CFLAGS -DXP_UNIX"
3351
cat >> confdefs.h <<\EOF
3355
cat >> confdefs.h <<\EOF
3359
cat >> confdefs.h <<\EOF
3363
DSO_LDOPTS='-brtl -bnortllib -bM:SRE -bnoentry -bexpall -blibpath:/usr/lib:/lib'
3364
ac_safe=`echo "sys/atomic_op.h" | sed 'y%./+-%__p_%'`
3365
echo $ac_n "checking for sys/atomic_op.h""... $ac_c" 1>&6
3366
echo "configure:3367: checking for sys/atomic_op.h" >&5
3367
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3368
echo $ac_n "(cached) $ac_c" 1>&6
3370
cat > conftest.$ac_ext <<EOF
3371
#line 3372 "configure"
3372
#include "confdefs.h"
3373
#include <sys/atomic_op.h>
3375
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3376
{ (eval echo configure:3377: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3377
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3378
if test -z "$ac_err"; then
3380
eval "ac_cv_header_$ac_safe=yes"
3383
echo "configure: failed program was:" >&5
3384
cat conftest.$ac_ext >&5
3386
eval "ac_cv_header_$ac_safe=no"
3390
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3391
echo "$ac_t""yes" 1>&6
3392
cat >> confdefs.h <<\EOF
3393
#define AIX_HAVE_ATOMIC_OP_H 1
3397
echo "$ac_t""no" 1>&6
3400
case "${target_os}" in
3402
cat >> confdefs.h <<\EOF
3403
#define AIX_RENAME_SELECT 1
3406
cat >> confdefs.h <<\EOF
3407
#define _PR_NO_LARGE_FILES 1
3410
AIX_LINK_OPTS='-bnso -berok'
3411
PR_MD_ASFILES=os_AIX.s
3414
cat >> confdefs.h <<\EOF
3415
#define AIX_TIMERS 1
3418
cat >> confdefs.h <<\EOF
3419
#define _PR_NO_LARGE_FILES 1
3422
cat >> confdefs.h <<\EOF
3428
AIX_LINK_OPTS='-bnso -berok'
3429
LIBNSPR='-L$(dist_libdir) -lnspr$(MOD_MAJOR_VERSION)_shr'
3430
LIBPLC='-L$(dist_libdir) -lplc$(MOD_MAJOR_VERSION)_shr'
3433
cat >> confdefs.h <<\EOF
3434
#define AIX_TIMERS 1
3437
cat >> confdefs.h <<\EOF
3438
#define _PR_HAVE_OFF64_T 1
3441
AIX_LINK_OPTS='-brtl -bnso -berok'
3444
cat >> confdefs.h <<\EOF
3445
#define AIX_TIMERS 1
3448
cat >> confdefs.h <<\EOF
3449
#define _PR_HAVE_OFF64_T 1
3452
cat >> confdefs.h <<\EOF
3453
#define AIX4_3_PLUS 1
3456
cat >> confdefs.h <<\EOF
3457
#define HAVE_SOCKLEN_T 1
3460
cat >> confdefs.h <<\EOF
3461
#define HAVE_FCNTL_FILE_LOCKING 1
3465
AIX_LINK_OPTS='-brtl -bnso -berok'
3468
cat >> confdefs.h <<\EOF
3469
#define AIX_TIMERS 1
3472
cat >> confdefs.h <<\EOF
3473
#define _PR_HAVE_OFF64_T 1
3476
cat >> confdefs.h <<\EOF
3477
#define AIX4_3_PLUS 1
3480
cat >> confdefs.h <<\EOF
3481
#define HAVE_SOCKLEN_T 1
3484
cat >> confdefs.h <<\EOF
3485
#define HAVE_FCNTL_FILE_LOCKING 1
3489
AIX_LINK_OPTS='-brtl -bnso -berok'
3492
CFLAGS="$CFLAGS -qro -qroconst"
3493
AIX_WRAP='$(DIST)/lib/aixwrap.o'
3494
AIX_TMP='./_aix_tmp.o'
3495
if test -n "$USE_64"; then
3496
MDCPUCFG_H=_aix64.cfg
3499
MDCPUCFG_H=_aix32.cfg
3502
RESOLVE_LINK_SYMBOLS=1
3505
*-android*|*-linuxandroid*)
3506
if test -z "$USE_NSPR_THREADS"; then
3510
cat >> confdefs.h <<\EOF
3514
cat >> confdefs.h <<\EOF
3515
#define _GNU_SOURCE 1
3518
cat >> confdefs.h <<\EOF
3519
#define HAVE_FCNTL_FILE_LOCKING 1
3522
cat >> confdefs.h <<\EOF
3526
CFLAGS="$CFLAGS -Wall"
3527
CXXFLAGS="$CXXFLAGS -Wall"
3528
MDCPUCFG_H=_linux.cfg
3530
MKSHLIB='$(CC) $(DSO_LDOPTS) $(WRAP_MALLOC_LIB) -o $@'
3532
DSO_LDOPTS='-shared -Wl,-soname -Wl,$(notdir $@)'
3534
_DEBUG_FLAGS="-g -fno-inline" # most people on linux use gcc/gdb, and that
3535
# combo is not yet good at debugging inlined
3536
# functions (even when using DWARF2 as the
3545
cat >> confdefs.h <<\EOF
3549
cat >> confdefs.h <<\EOF
3553
cat >> confdefs.h <<\EOF
3557
cat >> confdefs.h <<\EOF
3558
#define _POSIX_SOURCE 1
3562
MDCPUCFG_H=_beos.cfg
3565
RESOLVE_LINK_SYMBOLS=1
3566
case "${target_cpu}" in
3569
_DEBUG_FLAGS='-gdwarf-2 -O0'
3570
MKSHLIB='$(CCC) $(DSO_LDOPTS) -o $@'
3571
echo $ac_n "checking for gethostbyaddr in -lbind""... $ac_c" 1>&6
3572
echo "configure:3573: checking for gethostbyaddr in -lbind" >&5
3573
ac_lib_var=`echo bind'_'gethostbyaddr | sed 'y%./+-%__p_%'`
3574
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3575
echo $ac_n "(cached) $ac_c" 1>&6
3577
ac_save_LIBS="$LIBS"
3579
cat > conftest.$ac_ext <<EOF
3580
#line 3581 "configure"
3581
#include "confdefs.h"
3582
/* Override any gcc2 internal prototype to avoid an error. */
3583
/* We use char because int might match the return type of a gcc2
3584
builtin and then its argument prototype would still apply. */
3585
char gethostbyaddr();
3591
if { (eval echo configure:3592: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3593
eval "ac_cv_lib_$ac_lib_var=yes"
3595
echo "configure: failed program was:" >&5
3596
cat conftest.$ac_ext >&5
3598
eval "ac_cv_lib_$ac_lib_var=no"
3601
LIBS="$ac_save_LIBS"
3604
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3605
echo "$ac_t""yes" 1>&6
3606
OS_LIBS="$OS_LIBS -lbind -lsocket"
3608
echo "$ac_t""no" 1>&6
3616
DSO_LDOPTS='-xms -export pragma -init _init_routine_ -term _term_routine_ -lroot -lnet /boot/develop/lib/ppc/glue-noinit.a /boot/develop/lib/ppc/init_term_dyn.o /boot/develop/lib/ppc/start_dyn.o'
3618
_DEBUG_FLAGS='-g -O0'
3624
cat >> confdefs.h <<\EOF
3628
cat >> confdefs.h <<\EOF
3632
cat >> confdefs.h <<\EOF
3633
#define NEED_BSDREGEX 1
3637
CFLAGS="$CFLAGS -Wall -Wno-format"
3638
CXXFLAGS="$CXXFLAGS -Wall -Wno-format"
3640
if echo "$OS_TEST" | grep -c 86 >/dev/null; then
3642
elif echo "$OS_TEST" | grep -c sparc >/dev/null; then
3646
MDCPUCFG_H=_bsdi.cfg
3651
case "$target_os" in
3653
cat >> confdefs.h <<\EOF
3654
#define _PR_BSDI_JMPBUF_IS_ARRAY 1
3657
cat >> confdefs.h <<\EOF
3658
#define _PR_STAT_HAS_ONLY_ST_ATIME 1
3661
cat >> confdefs.h <<\EOF
3662
#define _PR_NEED_H_ERRNO 1
3671
cat >> confdefs.h <<\EOF
3672
#define _PR_TIMESPEC_HAS_TS_SEC 1
3675
cat >> confdefs.h <<\EOF
3676
#define _PR_BSDI_JMPBUF_IS_ARRAY 1
3679
cat >> confdefs.h <<\EOF
3683
cat >> confdefs.h <<\EOF
3687
cat >> confdefs.h <<\EOF
3688
#define _PR_STAT_HAS_ST_ATIMESPEC 1
3691
PR_MD_ASFILES=os_BSD_OS_386_2.s
3695
cat >> confdefs.h <<\EOF
3696
#define _PR_SELECT_CONST_TIMEVAL 1
3699
cat >> confdefs.h <<\EOF
3700
#define _PR_BSDI_JMPBUF_IS_STRUCT 1
3703
cat >> confdefs.h <<\EOF
3707
cat >> confdefs.h <<\EOF
3711
cat >> confdefs.h <<\EOF
3712
#define _PR_STAT_HAS_ST_ATIMESPEC 1
3715
MKSHLIB='$(CC) -o $@ $(DSO_LDOPTS)'
3717
DSO_LDOPTS='-shared -Wl,-soname,$(@:$(OBJDIR)/%.so=%.so)'
3719
case "$target_os" in
3720
bsdi4.2* | bsdi4.3* | bsdi5.*)
3721
cat >> confdefs.h <<\EOF
3722
#define _PR_HAVE_GETPROTO_R 1
3725
cat >> confdefs.h <<\EOF
3726
#define _PR_HAVE_GETPROTO_R_POINTER 1
3733
cat >> confdefs.h <<\EOF
3734
#define _PR_SELECT_CONST_TIMEVAL 1
3737
cat >> confdefs.h <<\EOF
3738
#define _PR_BSDI_JMPBUF_IS_STRUCT 1
3741
cat >> confdefs.h <<\EOF
3745
cat >> confdefs.h <<\EOF
3749
cat >> confdefs.h <<\EOF
3750
#define _PR_STAT_HAS_ST_ATIMESPEC 1
3759
cat >> confdefs.h <<\EOF
3763
cat >> confdefs.h <<\EOF
3767
cat >> confdefs.h <<\EOF
3768
#define HAVE_BSD_FLOCK 1
3771
cat >> confdefs.h <<\EOF
3772
#define HAVE_SOCKLEN_T 1
3775
AS='$(CC) -x assembler-with-cpp'
3776
CFLAGS="$CFLAGS -Wall -fno-common"
3777
case "${target_cpu}" in
3779
if test -n "$USE_64"; then
3789
if test "`echo $CC | grep -c '\-arch '`" = "0"; then
3790
CC="$CC -arch $CPU_ARCH"
3793
DSO_LDOPTS='-dynamiclib -compatibility_version 1 -current_version 1 -all_load -install_name @executable_path/$@ -headerpad_max_install_names'
3795
MKSHLIB='$(CC) $(DSO_LDOPTS) -o $@'
3796
STRIP="$STRIP -x -S"
3799
MDCPUCFG_H=_darwin.cfg
3800
PR_MD_CSRCS=darwin.c
3801
PR_MD_ASFILES=os_Darwin.s
3803
# Add Mac OS X support for loading CFM & CFBundle plugins
3804
if test -f "${MACOS_SDK_DIR}/System/Library/Frameworks/Carbon.framework/Carbon"; then
3805
cat >> confdefs.h <<\EOF
3811
if test -n "$_MACOSX_DEPLOYMENT_TARGET" ; then
3812
export MACOSX_DEPLOYMENT_TARGET=$_MACOSX_DEPLOYMENT_TARGET
3813
elif test -z "$MACOSX_DEPLOYMENT_TARGET" ; then
3814
case "${target_cpu}" in
3816
export MACOSX_DEPLOYMENT_TARGET=10.2
3819
export MACOSX_DEPLOYMENT_TARGET=10.4
3825
if test "$MACOS_SDK_DIR"; then
3827
if test ! -d "$MACOS_SDK_DIR"; then
3828
{ echo "configure: error: SDK not found. When using --with-macos-sdk, you must
3829
specify a valid SDK. SDKs are installed when the optional cross-development
3830
tools are selected during the Xcode/Developer Tools installation." 1>&2; exit 1; }
3834
CC_VERSION=`$CC -v 2>&1 | grep 'gcc version'`
3835
GCC_VERSION_FULL=`echo $CC_VERSION | $PERL -pe 's/^.*gcc version ([^ ]*).*/$1/'`
3836
GCC_VERSION=`echo $GCC_VERSION_FULL | $PERL -pe '(split(/\./))[0]>=4&&s/(^\d*\.\d*).*/$1/;'`
3838
GCC_VERSION_MAJOR=`echo $GCC_VERSION_FULL | $PERL -pe 's/(^\d*).*/$1/;'`
3839
if test "$GCC_VERSION_MAJOR" -lt "4" ; then
3840
SDK_C_FRAMEWORK="-F${MACOS_SDK_DIR}/System/Library/Frameworks"
3841
if test -d "${MACOS_SDK_DIR}/Library/Frameworks" ; then
3842
SDK_C_FRAMEWORK="$SDK_C_FRAMEWORK -F${MACOS_SDK_DIR}/Library/Frameworks"
3845
SDK_C_INCLUDE="-isystem ${MACOS_SDK_DIR}/usr/include/gcc/darwin/${GCC_VERSION} -isystem ${MACOS_SDK_DIR}/usr/include ${SDK_C_FRAMEWORK}"
3847
CFLAGS="$CFLAGS -nostdinc ${SDK_C_INCLUDE}"
3849
CPP="$CPP -nostdinc ${SDK_C_INCLUDE}"
3852
HOST_DARWIN_MAJOR=`echo "$build_os" | sed -E -e 's/^darwin([0-9]+).*$/\1/'`
3854
if test "$HOST_DARWIN_MAJOR" -lt 9 ; then
3855
MACOS_SDK_LIBS="-L${MACOS_SDK_DIR}/usr/lib/gcc/darwin -L${MACOS_SDK_DIR}/usr/lib/gcc/darwin/${GCC_VERSION_FULL} -L${MACOS_SDK_DIR}/usr/lib ${SDK_C_FRAMEWORK}"
3857
MACOS_SDK_LIBS="-Wl,-syslibroot,${MACOS_SDK_DIR}"
3860
LDFLAGS="${MACOS_SDK_LIBS} $LDFLAGS"
3861
export NEXT_ROOT=$MACOS_SDK_DIR
3863
if test -n "$CROSS_COMPILE" ; then
3864
HOST_CC="NEXT_ROOT= $HOST_CC"
3865
HOST_CXX="NEXT_ROOT= $HOST_CXX"
3868
CFLAGS="$CFLAGS -isysroot ${MACOS_SDK_DIR}"
3870
CPP="$CPP -isysroot ${MACOS_SDK_DIR}"
3872
if test "$GCC_VERSION_FULL" != "4.0.0" ; then
3873
LDFLAGS="$LDFLAGS -isysroot ${MACOS_SDK_DIR}"
3875
LDFLAGS="$LDFLAGS -Wl,-syslibroot,${MACOS_SDK_DIR}"
3883
cat >> confdefs.h <<\EOF
3887
cat >> confdefs.h <<\EOF
3888
#define _PR_LOCAL_THREADS_ONLY 1
3891
cat >> confdefs.h <<\EOF
3895
cat >> confdefs.h <<\EOF
3899
cat >> confdefs.h <<\EOF
3903
cat >> confdefs.h <<\EOF
3904
#define _DGUX_SOURCE 1
3907
cat >> confdefs.h <<\EOF
3908
#define _POSIX4A_DRAFT6_SOURCE 1
3914
MDCPUCFG_H=_dgux.cfg
3919
if test -z "$USE_NSPR_THREADS"; then
3922
cat >> confdefs.h <<\EOF
3926
cat >> confdefs.h <<\EOF
3930
cat >> confdefs.h <<\EOF
3931
#define HAVE_BSD_FLOCK 1
3934
cat >> confdefs.h <<\EOF
3935
#define HAVE_SOCKLEN_T 1
3938
CFLAGS="$CFLAGS $(DSO_CFLAGS) -ansi -Wall"
3939
MOZ_OBJFORMAT=`test -x /usr/bin/objformat && /usr/bin/objformat || echo elf`
3940
if test "$MOZ_OBJFORMAT" = "elf"; then
3945
MKSHLIB='$(CC) $(DSO_LDOPTS) -o $@'
3947
DSO_LDOPTS='-shared -Wl,-soname -Wl,$(notdir $@)'
3948
MDCPUCFG_H=_freebsd.cfg
3949
PR_MD_CSRCS=freebsd.c
3953
cat >> confdefs.h <<\EOF
3957
cat >> confdefs.h <<\EOF
3961
cat >> confdefs.h <<\EOF
3962
#define _HPUX_SOURCE 1
3965
# OSF1 and HPUX report the POLLHUP event for a socket when the
3966
# shutdown(SHUT_WR) operation is called for the remote end, even though
3967
# the socket is still writeable. Use select(), instead of poll(), to
3968
# workaround this problem.
3969
cat >> confdefs.h <<\EOF
3970
#define _PR_POLL_WITH_SELECT 1
3973
cat >> confdefs.h <<\EOF
3974
#define _USE_BIG_FDS 1
3977
DSO_LDOPTS='-b +h $(notdir $@)'
3979
if test "$OS_TEST" = "ia64"; then
3981
DSO_LDOPTS="$DSO_LDOPTS +b '\$\$ORIGIN'"
3982
CPU_ARCH_TAG=_$OS_TEST
3983
if test -z "$USE_64"; then
3986
PR_MD_ASFILES=os_HPUX_ia64.s
3988
cat >> confdefs.h <<\EOF
3993
PR_MD_ASFILES=os_HPUX.s
3995
if test -n "$USE_64"; then
3996
MDCPUCFG_H=_hpux64.cfg
3998
MDCPUCFG_H=_hpux32.cfg
4000
if test -z "$GNU_CC"; then
4006
ASFLAGS="$ASFLAGS -x assembler-with-cpp"
4009
if test -n "$MOZILLA_CLIENT"; then
4010
DEFAULT_IMPL_STRATEGY=_EMU
4013
if echo "$OS_RELEASE" | grep ^A.09 >/dev/null; then
4014
cat >> confdefs.h <<\EOF
4015
#define _PR_NEED_H_ERRNO 1
4018
cat >> confdefs.h <<\EOF
4022
DEFAULT_IMPL_STRATEGY=_EMU
4026
if echo "$OS_RELEASE" | egrep '^(A.09|B.10)' >/dev/null; then
4027
cat >> confdefs.h <<\EOF
4028
#define _PR_NO_LARGE_FILES 1
4033
if echo "$OS_RELEASE" | egrep '^(B.10.10|B.10.20)' >/dev/null; then
4034
cat >> confdefs.h <<\EOF
4035
#define _PR_NEED_H_ERRNO 1
4040
if echo "$OS_RELEASE" | egrep '^(B.10.10|B.10.20)' >/dev/null; then
4041
cat >> confdefs.h <<\EOF
4042
#define HAVE_INT_LOCALTIME_R 1
4047
if echo "$OS_RELEASE" | egrep '^(B.10.30|B.11)' >/dev/null; then
4048
cat >> confdefs.h <<\EOF
4049
#define HAVE_POINTER_LOCALTIME_R 1
4054
# HP-UX 11i v2 (B.11.23) or higher
4056
case "$OS_RELEASE" in
4057
[C-Z]*|B.[2-9]*|B.1[2-9]*|B.11.[3-9]*|B.11.2[3-9]*)
4063
if test "$OS_RELEASE" = "B.10.01"; then
4064
cat >> confdefs.h <<\EOF
4068
DEFAULT_IMPL_STRATEGY=_EMU
4071
if test "$OS_RELEASE" = "B.10.10"; then
4072
cat >> confdefs.h <<\EOF
4076
cat >> confdefs.h <<\EOF
4080
DEFAULT_IMPL_STRATEGY=_PTH
4083
if test "$OS_RELEASE" = "B.10.20"; then
4084
cat >> confdefs.h <<\EOF
4088
cat >> confdefs.h <<\EOF
4092
if test -z "$GNU_CC"; then
4093
CFLAGS="$CFLAGS +DAportable +DS1.1"
4094
CXXFLAGS="$CXXFLAGS +DAportable +DS1.1"
4096
DEFAULT_IMPL_STRATEGY=_PTH
4099
if test "$OS_RELEASE" = "B.10.30"; then
4100
cat >> confdefs.h <<\EOF
4104
cat >> confdefs.h <<\EOF
4108
if test -z "$GNU_CC"; then
4109
CFLAGS="$CFLAGS +DAportable +DS1.1"
4110
CXXFLAGS="$CXXFLAGS +DAportable +DS1.1"
4112
DEFAULT_IMPL_STRATEGY=_PTH
4115
if echo "$OS_RELEASE" | grep ^B.11 >/dev/null; then
4116
cat >> confdefs.h <<\EOF
4120
cat >> confdefs.h <<\EOF
4124
cat >> confdefs.h <<\EOF
4125
#define _LARGEFILE64_SOURCE 1
4128
cat >> confdefs.h <<\EOF
4129
#define _PR_HAVE_OFF64_T 1
4132
cat >> confdefs.h <<\EOF
4133
#define HAVE_FCNTL_FILE_LOCKING 1
4136
if test -z "$GNU_CC"; then
4137
if test -z "$USE_64"; then
4138
if test "$OS_TEST" = "ia64"; then
4139
CFLAGS="$CFLAGS +DD32"
4140
CXXFLAGS="$CXXFLAGS +DD32"
4142
CFLAGS="$CFLAGS +DAportable +DS2.0"
4143
CXXFLAGS="$CXXFLAGS +DAportable +DS2.0"
4146
if test "$OS_TEST" = "ia64"; then
4147
CFLAGS="$CFLAGS +DD64"
4148
CXXFLAGS="$CXXFLAGS +DD64"
4150
CFLAGS="$CFLAGS +DA2.0W +DS2.0"
4151
CXXFLAGS="$CXXFLAGS +DA2.0W +DS2.0"
4155
DEFAULT_IMPL_STRATEGY=_PTH
4158
if test "$DEFAULT_IMPL_STRATEGY" = "_EMU"; then
4162
elif test "$DEFAULT_IMPL_STRATEGY" = "_PTH"; then
4164
if test "$USE_NSPR_THREADS"; then
4167
if test "$USE_USER_PTHREADS"; then
4174
cat >> confdefs.h <<\EOF
4178
cat >> confdefs.h <<\EOF
4182
cat >> confdefs.h <<\EOF
4186
cat >> confdefs.h <<\EOF
4187
#define _SGI_MP_SOURCE 1
4190
cat >> confdefs.h <<\EOF
4191
#define HAVE_FCNTL_FILE_LOCKING 1
4195
PR_MD_ASFILES=os_Irix.s
4196
MKSHLIB='$(LD) $(DSO_LDOPTS) -rdata_shared -shared -soname $(notdir $@) -o $@'
4198
RESOLVE_LINK_SYMBOLS=1
4199
if test -n "$USE_64"; then
4200
MDCPUCFG_H=_irix64.cfg
4202
MDCPUCFG_H=_irix32.cfg
4204
case "${target_os}" in
4206
cat >> confdefs.h <<\EOF
4216
cat >> confdefs.h <<\EOF
4227
if test "$GNU_CC"; then
4228
AS='$(CC) -Wp,-P -x assembler-with-cpp -D_ASM -mips2 $(INCLUDES)'
4229
CFLAGS="$CFLAGS -Wall -Wno-format"
4230
_OPTIMIZE_FLAGS="-O6"
4232
if test -n "$USE_N32"; then
4233
AS='as -D_ASM $(INCLUDES) -n32'
4235
AS='as -D_ASM $(INCLUDES)'
4237
CFLAGS="$CFLAGS -fullwarn -xansi"
4238
if test "$USE_N32"; then
4239
_OPTIMIZE_FLAGS="-O -OPT:Olimit=4000"
4241
_OPTIMIZE_FLAGS="-O -Olimit 4000"
4243
if test "$USE_MDUPDATE"; then
4244
CFLAGS="$CFLAGS -MDupdate \$(DEPENDENCIES)"
4248
CFLAGS="$CFLAGS -multigot"
4249
DSO_LDOPTS="-no_unresolved"
4250
if test "$USE_N32"; then
4251
CFLAGS="$CFLAGS -n32 -woff 1209"
4252
DSO_LDOPTS="$DSO_LDOPTS -n32"
4254
if test "$USE_64"; then
4255
CFLAGS="$CFLAGS -64"
4257
CFLAGS="$CFLAGS -32"
4262
CFLAGS="$CFLAGS -xgot"
4266
if test "${target_os}" = "irix5.3"; then
4267
cat >> confdefs.h <<\EOF
4272
case "${target_os}" in
4274
if test -z "$GNU_CC"; then
4275
CFLAGS="$CFLAGS -mips3"
4277
cat >> confdefs.h <<\EOF
4278
#define _PR_HAVE_GETPROTO_R 1
4281
cat >> confdefs.h <<\EOF
4282
#define _PR_HAVE_GETPROTO_R_POINTER 1
4285
cat >> confdefs.h <<\EOF
4286
#define _PR_HAVE_SGI_PRDA_PROCMASK 1
4293
cat >> confdefs.h <<\EOF
4294
#define _PR_HAVE_SGI_PRDA_PROCMASK 1
4301
*-linux*|*-gnu*|*-k*bsd*-gnu)
4302
if test -z "$USE_NSPR_THREADS"; then
4306
cat >> confdefs.h <<\EOF
4310
cat >> confdefs.h <<\EOF
4311
#define _GNU_SOURCE 1
4314
cat >> confdefs.h <<\EOF
4315
#define HAVE_FCNTL_FILE_LOCKING 1
4318
case "${target_os}" in
4320
cat >> confdefs.h <<\EOF
4326
CFLAGS="$CFLAGS -Wall"
4327
CXXFLAGS="$CXXFLAGS -Wall"
4328
MDCPUCFG_H=_linux.cfg
4330
MKSHLIB='$(CC) $(DSO_LDOPTS) $(WRAP_MALLOC_LIB) -o $@'
4332
DSO_LDOPTS='-shared -Wl,-soname -Wl,$(notdir $@)'
4334
_DEBUG_FLAGS="-g -fno-inline" # most people on linux use gcc/gdb, and that
4335
# combo is not yet good at debugging inlined
4336
# functions (even when using DWARF2 as the
4339
if echo "$OS_TEST" | grep -c 86 >/dev/null; then
4344
CPU_ARCH_TAG=_${CPU_ARCH}
4345
case "${target_cpu}" in
4347
cat >> confdefs.h <<\EOF
4351
cat >> confdefs.h <<\EOF
4355
CFLAGS="$CFLAGS -mieee"
4356
CXXFLAGS="$CXXFLAGS -mieee"
4359
cat >> confdefs.h <<\EOF
4363
PR_MD_ASFILES=os_Linux_x86.s
4366
PR_MD_ASFILES=os_Linux_ia64.s
4369
if test -n "$USE_64"; then
4370
PR_MD_ASFILES=os_Linux_x86_64.s
4372
cat >> confdefs.h <<\EOF
4376
PR_MD_ASFILES=os_Linux_x86.s
4382
PR_MD_ASFILES=os_Linux_ppc.s
4385
if test -n "$USE_64"; then
4389
PR_MD_ASFILES=os_Linux_ppc.s
4393
CFLAGS="$CFLAGS -m68020-60"
4394
CXXFLAGS="$CXXFLAGS -m68020-60"
4399
*-mingw*|*-cygwin*|*-msvc*|*-mks*)
4400
cat >> confdefs.h <<\EOF
4404
cat >> confdefs.h <<\EOF
4408
PR_MD_ARCH_DIR=windows
4409
RESOLVE_LINK_SYMBOLS=1
4411
if test -n "$GNU_CC"; then
4413
CXX="$CXX -mwindows"
4415
MKSHLIB='$(CC) -shared -Wl,--export-all-symbols -Wl,--out-implib -Wl,$(IMPORT_LIBRARY) $(DLLBASE) -o $(subst $(OBJDIR)/,,$(SHARED_LIBRARY))'
4417
# Use temp file for windres (bug 213281)
4418
RCFLAGS='-O coff --use-temp-file'
4423
AR='lib -NOLOGO -OUT:"$@"'
4425
RANLIB='echo not_ranlib'
4426
STRIP='echo not_strip'
4428
GARBAGE='$(OBJDIR)/vc20.pdb $(OBJDIR)/vc40.pdb'
4433
# Determine compiler version
4435
_MSVC_VER_FILTER='s|.* \([0-9]\+\.[0-9]\+\.[0-9]\+\(\.[0-9]\+\)\?\).*|\1|p'
4437
CC_VERSION=`"${CC}" -v 2>&1 | sed -ne "$_MSVC_VER_FILTER"`
4438
_CC_MAJOR_VERSION=`echo ${CC_VERSION} | awk -F\. '{ print $1 }'`
4439
_CC_MINOR_VERSION=`echo ${CC_VERSION} | awk -F\. '{ print $2 }'`
4440
_CC_RELEASE=`echo ${CC_VERSION} | awk -F\. '{ print $3 }'`
4441
_CC_BUILD=`echo ${CC_VERSION} | awk -F\. '{ print $4 }'`
4442
MSC_VER=${_CC_MAJOR_VERSION}${_CC_MINOR_VERSION}
4444
if test "$_CC_MAJOR_VERSION" -eq "14"; then
4445
if test $_CC_RELEASE -gt 50727; then
4447
elif test $_CC_BUILD -ge 762; then
4450
cat >> confdefs.h <<\EOF
4451
#define _CRT_SECURE_NO_DEPRECATE 1
4454
cat >> confdefs.h <<\EOF
4455
#define _CRT_NONSTDC_NO_DEPRECATE 1
4458
elif test $_CC_MAJOR_VERSION -ge 15; then
4460
cat >> confdefs.h <<\EOF
4461
#define _CRT_SECURE_NO_WARNINGS 1
4464
cat >> confdefs.h <<\EOF
4465
#define _CRT_NONSTDC_NO_WARNINGS 1
4470
if test -n "$_USE_DYNAMICBASE"; then
4471
DLLFLAGS="$DLLFLAGS -DYNAMICBASE"
4474
# Ensure that mt is Microsoft (R) Manifest Tool and not magnetic
4475
# tape manipulation utility (or something else)
4476
if test "$MSC_VER" -ge "1400"; then
4478
_MSMT_VER_FILTER='s|.* \([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*|\1|p'
4481
MSMT_TOOL=`mt 2>&1|grep 'Microsoft (R) Manifest Tool'`
4482
if test -n "$MSMT_TOOL"; then
4483
MSMANIFEST_TOOL_VERSION=`echo ${MSMT_TOOL}|sed -ne "$_MSMT_VER_FILTER"`
4484
if test -z "$MSMANIFEST_TOOL_VERSION"; then
4485
echo "configure: warning: Unknown version of the Microsoft (R) Manifest Tool." 1>&2
4490
{ echo "configure: error: Microsoft (R) Manifest Tool must be in your \$PATH." 1>&2; exit 1; }
4494
CFLAGS="$CFLAGS -W3 -nologo -GF -Gy"
4495
DLLFLAGS="$DLLFLAGS -OUT:\"\$@\""
4499
PROFILE_GEN_CFLAGS="-GL"
4500
PROFILE_GEN_LDFLAGS="-LTCG:PGINSTRUMENT"
4501
PROFILE_USE_CFLAGS="-GL -wd4624 -wd4952"
4502
PROFILE_USE_LDFLAGS="-LTCG:PGUPDATE"
4504
if test -z "$MOZ_OPTIMIZE"; then
4505
CFLAGS="$CFLAGS -Od"
4508
if test -n "$USE_DEBUG_RTL"; then
4509
CFLAGS="$CFLAGS -MDd"
4511
CFLAGS="$CFLAGS -MD"
4514
if test -n "$MOZ_DEBUG"; then
4515
cat >> confdefs.h <<\EOF
4520
DEFINES="$DEFINES -U_DEBUG"
4523
if test -n "$MOZ_DEBUG_SYMBOLS"; then
4524
if test -n "$MOZ_OPTIMIZE"; then
4525
DLLFLAGS="$DLLFLAGS -DEBUG -OPT:REF"
4526
LDFLAGS="$LDFLAGS -DEBUG -OPT:REF"
4528
DLLFLAGS="$DLLFLAGS -DEBUG"
4529
LDFLAGS="$LDFLAGS -DEBUG"
4533
OS_DLLFLAGS="-nologo -DLL -SUBSYSTEM:WINDOWS"
4534
if test "$MSC_VER" -le "1200" -a -z "$MOZ_DEBUG_SYMBOLS"; then
4535
OS_DLLFLAGS="$OS_DLLFLAGS -PDB:NONE"
4538
if test "$OS_TARGET" = "WINNT"; then
4539
CFLAGS="$CFLAGS -GT"
4540
LIBNSPR='$(dist_libdir)/libnspr$(MOD_MAJOR_VERSION).$(LIB_SUFFIX)'
4541
LIBPLC='$(dist_libdir)/libplc$(MOD_MAJOR_VERSION).$(LIB_SUFFIX)'
4543
LIBNSPR='$(dist_libdir)/nspr$(MOD_MAJOR_VERSION).$(LIB_SUFFIX)'
4544
LIBPLC='$(dist_libdir)/plc$(MOD_MAJOR_VERSION).$(LIB_SUFFIX)'
4548
if test -n "$USE_STATIC_TLS"; then
4549
cat >> confdefs.h <<\EOF
4550
#define _PR_USE_STATIC_TLS 1
4555
if test "$OS_TARGET" = "WINNT"; then
4556
cat >> confdefs.h <<\EOF
4561
cat >> confdefs.h <<\EOF
4565
# undefine WINNT as some versions of mingw gcc define it by default
4566
DEFINES="$DEFINES -UWINNT"
4567
cat >> confdefs.h <<\EOF
4568
#define _PR_GLOBAL_THREADS_ONLY 1
4573
if test "$CPU_ARCH" = "x86"; then
4576
CPU_ARCH_TAG=$CPU_ARCH
4579
if test -n "$USE_DEBUG_RTL"; then
4583
case "$OS_TARGET" in
4585
MDCPUCFG_H=_winnt.cfg
4588
MDCPUCFG_H=_win95.cfg
4591
{ echo "configure: error: Missing OS_TARGET for ${target}. Use --enable-win32-target to set." 1>&2; exit 1; }
4595
case "$target_cpu" in
4597
if test -n "$USE_64"; then
4598
cat >> confdefs.h <<\EOF
4603
cat >> confdefs.h <<\EOF
4610
cat >> confdefs.h <<\EOF
4617
cat >> confdefs.h <<\EOF
4624
cat >> confdefs.h <<\EOF
4625
#define _CPU_ARCH_NOT_DEFINED 1
4633
cat >> confdefs.h <<\EOF
4637
cat >> confdefs.h <<\EOF
4641
cat >> confdefs.h <<\EOF
4645
cat >> confdefs.h <<\EOF
4646
#define _PR_GLOBAL_THREADS_ONLY 1
4650
AR_FLAGS='-NOLOGO -OUT:"$@"'
4655
MKSHLIB='$(LD) -DLL $(DSO_LDOPTS) -OUT:$@'
4657
PR_MD_ARCH_DIR=windows
4658
RESOLVE_LINK_SYMBOLS=1
4660
MDCPUCFG_H=_win95.cfg
4661
LIBNSPR='$(dist_libdir)/nspr$(MOD_MAJOR_VERSION).$(LIB_SUFFIX)'
4662
LIBPLC='$(dist_libdir)/plc$(MOD_MAJOR_VERSION).$(LIB_SUFFIX)'
4664
DLLFLAGS='-OUT:"$@"'
4665
if test -n "$MOZ_DEBUG_SYMBOLS"; then
4666
OS_LDFLAGS='-DEBUG -DEBUGTYPE:CV'
4667
OS_DLLFLAGS='-DEBUG -DEBUGTYPE:CV'
4668
DSO_LDOPTS='-DEBUG -DEBUGTYPE:CV'
4675
cat >> confdefs.h <<\EOF
4679
cat >> confdefs.h <<\EOF
4683
cat >> confdefs.h <<\EOF
4687
cat >> confdefs.h <<\EOF
4692
if test "$OS_RELEASE" = "2.03"; then
4693
cat >> confdefs.h <<\EOF
4694
#define _PR_STAT_HAS_ST_ATIM 1
4698
cat >> confdefs.h <<\EOF
4699
#define _PR_STAT_HAS_ST_ATIM_UNION 1
4704
if test -z "$GNU_CC"; then
4705
CFLAGS="$CFLAGS -Hnocopyr"
4706
CXXFLAGS="$CXXFLAGS -Hnocopyr"
4708
CFLAGS="$CFLAGS -fPIC -Wall"
4709
CXXFLAGS="$CXXFLAGS -fPIC -Wall"
4717
cat >> confdefs.h <<\EOF
4721
cat >> confdefs.h <<\EOF
4725
cat >> confdefs.h <<\EOF
4729
cat >> confdefs.h <<\EOF
4733
cat >> confdefs.h <<\EOF
4738
if test -z "$GNU_CC"; then
4739
CC='$(NSDEPTH)/build/hcc cc -Xa -KGnum=0 -KOlimit=4000'
4742
OS_LIBS="$OS_LIBS -lsocket -lnsl -ldl"
4749
cat >> confdefs.h <<\EOF
4753
cat >> confdefs.h <<\EOF
4757
cat >> confdefs.h <<\EOF
4758
#define HAVE_BSD_FLOCK 1
4761
if test -z "$USE_NSPR_THREADS"; then
4764
MDCPUCFG_H=_netbsd.cfg
4765
PR_MD_CSRCS=netbsd.c
4767
DSO_CFLAGS='-fPIC -DPIC'
4768
CFLAGS="$CFLAGS -ansi -Wall"
4769
CXXFLAGS="$CXXFLAGS -ansi -Wall"
4770
MKSHLIB='$(CC) -o $@ $(DSO_LDOPTS)'
4772
if test -z "$OBJECT_FMT"; then
4773
if echo __ELF__ | ${CC-cc} -E - | grep -q __ELF__ 2>/dev/null; then
4776
DSO_LDOPTS='-shared'
4780
DSO_LDOPTS='-shared -Wl,-soname,$(notdir $@)'
4784
if test "$LIBRUNPATH"; then
4785
DSO_LDOPTS="$DSO_LDOPTS -Wl,-R$LIBRUNPATH"
4790
cat >> confdefs.h <<\EOF
4794
cat >> confdefs.h <<\EOF
4798
cat >> confdefs.h <<\EOF
4802
cat >> confdefs.h <<\EOF
4806
cat >> confdefs.h <<\EOF
4810
cat >> confdefs.h <<\EOF
4814
cat >> confdefs.h <<\EOF
4815
#define HAVE_SVID_GETTOD 1
4819
CFLAGS="$CFLAGS -Xa -fullwarn"
4820
CXXFLAGS="$CXXFLAGS -Xa -fullwarn"
4822
MDCPUCFG_H=_sony.cfg
4826
*-nextstep*|*-openstep*)
4827
cat >> confdefs.h <<\EOF
4831
cat >> confdefs.h <<\EOF
4835
cat >> confdefs.h <<\EOF
4836
#define HAVE_BSD_FLOCK 1
4839
cat >> confdefs.h <<\EOF
4840
#define _POSIX_SOURCE 1
4843
CFLAGS="$CFLAGS -Wall -fno-common -traditional-cpp -posix"
4844
CXXFLAGS="$CXXFLAGS -Wall -fno-common -traditional-cpp -posix"
4847
MDCPUCFG_H=_nextstep.cfg
4848
PR_MD_CSRCS=nextstep.c
4853
cat >> confdefs.h <<\EOF
4857
cat >> confdefs.h <<\EOF
4861
cat >> confdefs.h <<\EOF
4862
#define _QNX_SOURCE 1
4865
cat >> confdefs.h <<\EOF
4866
#define HAVE_POINTER_LOCALTIME_R 1
4871
MKSHLIB='$(CC) $(DSO_LDOPTS) -Wl,-soname -Wl,$(notdir $@) -o $@'
4874
OS_LIBS="$OS_LIBS -lsocket"
4875
_OPTIMIZE_FLAGS="-O1"
4876
_DEBUG_FLAGS="-gstabs"
4880
cat >> confdefs.h <<\EOF
4884
cat >> confdefs.h <<\EOF
4888
cat >> confdefs.h <<\EOF
4889
#define HAVE_BSD_FLOCK 1
4892
cat >> confdefs.h <<\EOF
4893
#define HAVE_SOCKLEN_T 1
4896
CFLAGS="$CFLAGS -ansi -Wall"
4897
CXXFLAGS="$CXXFLAGS -ansi -Wall"
4900
MDCPUCFG_H=_openbsd.cfg
4901
PR_MD_CSRCS=openbsd.c
4903
if test -z "$USE_NSPR_THREADS"; then
4906
DSO_LDOPTS='-shared -fPIC'
4907
MKSHLIB='$(CC) $(DSO_LDOPTS) -o $@'
4911
SHELL_OVERRIDE="SHELL = /usr/bin/ksh"
4912
cat >> confdefs.h <<\EOF
4916
cat >> confdefs.h <<\EOF
4920
cat >> confdefs.h <<\EOF
4921
#define _REENTRANT 1
4924
# OSF1 and HPUX report the POLLHUP event for a socket when the
4925
# shutdown(SHUT_WR) operation is called for the remote end, even though
4926
# the socket is still writeable. Use select(), instead of poll(), to
4927
# workaround this problem.
4928
cat >> confdefs.h <<\EOF
4929
#define _PR_POLL_WITH_SELECT 1
4933
if echo "$OS_RELEASE" | egrep -c '(V2.0|V3.2)' 2>/dev/null ; then
4937
if test -z "$GNU_CC"; then
4938
CC="$CC -std1 -ieee_with_inexact"
4939
if test "$OS_RELEASE" != "V2.0"; then
4940
CC="$CC -readonly_strings"
4942
_OPTIMIZE_FLAGS="$_OPTIMIZE_FLAGS -Olimit 4000"
4943
ac_safe=`echo "machine/builtins.h" | sed 'y%./+-%__p_%'`
4944
echo $ac_n "checking for machine/builtins.h""... $ac_c" 1>&6
4945
echo "configure:4946: checking for machine/builtins.h" >&5
4946
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4947
echo $ac_n "(cached) $ac_c" 1>&6
4949
cat > conftest.$ac_ext <<EOF
4950
#line 4951 "configure"
4951
#include "confdefs.h"
4952
#include <machine/builtins.h>
4954
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4955
{ (eval echo configure:4956: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4956
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4957
if test -z "$ac_err"; then
4959
eval "ac_cv_header_$ac_safe=yes"
4962
echo "configure: failed program was:" >&5
4963
cat conftest.$ac_ext >&5
4965
eval "ac_cv_header_$ac_safe=no"
4969
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4970
echo "$ac_t""yes" 1>&6
4971
cat >> confdefs.h <<\EOF
4972
#define OSF1_HAVE_MACHINE_BUILTINS_H 1
4976
echo "$ac_t""no" 1>&6
4980
CFLAGS="$CFLAGS -mieee"
4981
CXXFLAGS="$CXXFLAGS -mieee"
4984
if echo $OS_RELEASE | egrep -c '(V2.0|V3.2)' 2>/dev/null; then
4985
cat >> confdefs.h <<\EOF
4986
#define HAVE_INT_LOCALTIME_R 1
4990
cat >> confdefs.h <<\EOF
4991
#define HAVE_FCNTL_FILE_LOCKING 1
4994
cat >> confdefs.h <<\EOF
4995
#define HAVE_POINTER_LOCALTIME_R 1
4999
if echo $OS_RELEASE | grep -c V4.0 >/dev/null; then
5000
cat >> confdefs.h <<\EOF
5001
#define OSF1V4_MAP_PRIVATE_BUG 1
5005
DSO_LDOPTS='-shared -all -expect_unresolved "*" -soname $(notdir $@)'
5006
MDCPUCFG_H=_osf1.cfg
5011
cat >> confdefs.h <<\EOF
5015
cat >> confdefs.h <<\EOF
5019
cat >> confdefs.h <<\EOF
5020
#define _PR_NEED_H_ERRNO 1
5029
cat >> confdefs.h <<\EOF
5033
cat >> confdefs.h <<\EOF
5037
cat >> confdefs.h <<\EOF
5038
#define _PR_NEED_H_ERRNO 1
5042
MDCPUCFG_H=_riscos.cfg
5043
PR_MD_CSRCS=riscos.c
5045
DSO_LDOPTS='-shared -Wl,-soname -Wl,$(notdir $@)'
5046
MKSHLIB='$(CC) $(DSO_LDOPTS) -o $@'
5050
cat >> confdefs.h <<\EOF
5054
cat >> confdefs.h <<\EOF
5058
cat >> confdefs.h <<\EOF
5062
cat >> confdefs.h <<\EOF
5066
cat >> confdefs.h <<\EOF
5070
cat >> confdefs.h <<\EOF
5071
#define _PR_NEED_H_ERRNO 1
5074
CC='cc -b elf -KPIC'
5075
CXX='$(NSDEPTH)/build/hcpp CC +.cpp +w'
5078
DSO_LDOPTS='-b elf -G'
5079
MDCPUCFG_H=_scoos.cfg
5084
cat >> confdefs.h <<\EOF
5088
cat >> confdefs.h <<\EOF
5092
cat >> confdefs.h <<\EOF
5096
cat >> confdefs.h <<\EOF
5097
#define RELIANTUNIX 1
5100
cat >> confdefs.h <<\EOF
5104
cat >> confdefs.h <<\EOF
5105
#define HAVE_SVID_GETTOD 1
5108
if echo "$OS_TEST" | grep -c 86 2>/dev/null; then
5109
cat >> confdefs.h <<\EOF
5118
if test "$GNU_CC"; then
5119
AS='$(CC) -x assembler-with-cpp'
5120
if test "$CPU_ARCH" = "mips"; then
5123
CFLAGS="$CFLAGS -Wall -Wno-format"
5126
_OPTIMIZE_FLAGS='-O -F Olimit,4000'
5129
DSO_LDOPTS='-G -z defs -h $(@:$(OBJDIR)/%.so=%.so)'
5131
if test "$OS_RELEASE" = "5.43"; then
5132
cat >> confdefs.h <<\EOF
5133
#define IP_MULTICAST 1
5138
OS_LIBS="$OS_LIBS -lsocket -lnsl -lresolv -ldl -lc"
5140
MDCPUCFG_H=_reliantunix.cfg
5141
PR_MD_CSRCS=reliantunix.c
5142
if test "${OS_ARCH}" = "mips"; then
5143
PR_MD_ASFILES=os_ReliantUNIX.s
5148
cat >> confdefs.h <<\EOF
5152
cat >> confdefs.h <<\EOF
5156
CFLAGS="$CFLAGS -Wall -Wno-format"
5157
if test "$USE_MDUPDATE"; then
5158
CFLAGS="$CFLAGS -MDupdate \$(DEPENDENCIES)"
5165
if test "$OS_RELEASE" = "4.1.3_U1"; then
5167
OS_LIBS="$OS_LIBS -lm"
5169
MDCPUCFG_H=_sunos4.cfg
5170
PR_MD_CSRCS=sunos4.c
5174
if test -z "$USE_NSPR_THREADS"; then
5177
cat >> confdefs.h <<\EOF
5181
cat >> confdefs.h <<\EOF
5185
cat >> confdefs.h <<\EOF
5189
cat >> confdefs.h <<\EOF
5193
cat >> confdefs.h <<\EOF
5197
cat >> confdefs.h <<\EOF
5201
cat >> confdefs.h <<\EOF
5202
#define HAVE_FCNTL_FILE_LOCKING 1
5206
MDCPUCFG_H=_solaris.cfg
5207
PR_MD_CSRCS=solaris.c
5209
MKSHLIB='$(CC) $(DSO_LDOPTS) -o $@'
5210
RESOLVE_LINK_SYMBOLS=1
5211
case "${OS_RELEASE}" in
5215
# It is safe to use the -Bdirect linker flag on Solaris 10 or later.
5219
if test -n "$GNU_CC"; then
5221
if `$CC -print-prog-name=ld` -v 2>&1 | grep -c GNU >/dev/null; then
5224
DSO_LDOPTS='-shared -Wl,-h,$(notdir $@),-z,combreloc,-z,defs,-z,ignore'
5225
if test -n "$USE_B_DIRECT"; then
5226
DSO_LDOPTS="$DSO_LDOPTS,-Bdirect"
5230
DSO_LDOPTS='-G -h $(notdir $@) -z combreloc -z defs -z ignore'
5231
if test -n "$USE_B_DIRECT"; then
5232
DSO_LDOPTS="$DSO_LDOPTS -Bdirect"
5235
if test -n "$GNU_CC"; then
5236
CFLAGS="$CFLAGS -Wall"
5237
CXXFLAGS="$CXXFLAGS -Wall"
5238
if test -n "$USE_MDUPDATE"; then
5239
CFLAGS="$CFLAGS -MDupdate \$(DEPENDENCIES)"
5240
CXXFLAGS="$CXXFLAGS -MDupdate \$(DEPENDENCIES)"
5242
GCC_AS=`$CC -print-prog-name=as`
5243
if test "`echo | $GCC_AS -v 2>&1 | grep -c GNU`" != "0"; then
5247
CFLAGS="$CFLAGS -xstrconst"
5248
CXXFLAGS="$CXXFLAGS -Qoption cg -xstrconst -features=tmplife"
5249
if test -z "$MOZ_OPTIMIZE"; then
5250
CFLAGS="$CFLAGS -xs"
5251
CXXFLAGS="$CXXFLAGS -xs"
5253
_OPTIMIZE_FLAGS=-xO4
5255
if test -z "$GNU_AS"; then
5256
ASFLAGS="$ASFLAGS -Wa,-P"
5258
if test -n "$USE_64"; then
5259
if test -n "$GNU_CC"; then
5263
if test "$OS_TEST" = "i86pc"; then
5264
CC="$CC -xarch=amd64"
5265
CXX="$CXX -xarch=amd64"
5268
CXX="$CXX -xarch=v9"
5272
if test "$OS_TEST" = "i86pc"; then
5273
if test -z "$USE_64"; then
5274
cat >> confdefs.h <<\EOF
5279
CPU_ARCH_TAG=_$OS_TEST
5280
# The default debug format, DWARF (-g), is not supported by gcc
5281
# on i386-ANY-sysv4/solaris, but the stabs format is. It is
5282
# assumed that the Solaris assembler /usr/ccs/bin/as is used.
5283
# If your gcc uses GNU as, you do not need the -Wa,-s option.
5284
if test -n "$MOZ_DEBUG" && test -n "$GNU_CC"; then
5285
_DEBUG_FLAGS=-gstabs
5286
if test -z "$GNU_AS"; then
5287
_DEBUG_FLAGS="$_DEBUG_FLAGS -Wa,-s"
5291
case "${target_os}" in
5293
cat >> confdefs.h <<\EOF
5294
#define _PR_NO_LARGE_FILES 1
5299
cat >> confdefs.h <<\EOF
5300
#define _PR_NO_LARGE_FILES 1
5305
cat >> confdefs.h <<\EOF
5306
#define SOLARIS2_5 1
5311
cat >> confdefs.h <<\EOF
5312
#define _PR_HAVE_OFF64_T 1
5315
# The lfcompile64(5) man page on Solaris 2.6 says:
5316
# For applications that do not wish to conform to the POSIX or
5317
# X/Open specifications, the 64-bit transitional interfaces
5318
# are available by default. No compile-time flags need to be
5320
# But gcc 2.7.2.x fails to define _LARGEFILE64_SOURCE by default.
5321
# The native compiler, gcc 2.8.x, and egcs don't have this problem.
5322
if test -n "$GNU_CC"; then
5323
cat >> confdefs.h <<\EOF
5324
#define _LARGEFILE64_SOURCE 1
5330
case "${target_os}" in
5342
# Solaris 8 or higher has IPv6.
5343
cat >> confdefs.h <<\EOF
5349
if test "$CPU_ARCH" = "sparc"; then
5350
# 64-bit Solaris SPARC requires V9 architecture, so the following
5352
if test -z "$USE_64"; then
5353
ULTRASPARC_LIBRARY=nspr_flt
5356
# Purify requires that binaries linked against nspr also
5357
# be linked against -lrt (or -lposix4) so add it to OS_LIBS
5359
_librt=`echo $_rev 5.6 | awk '{ if ($1 > $2) print "-lrt"; else print "-lposix4" }'`
5360
OS_LIBS="$OS_LIBS $_librt"
5364
cat >> confdefs.h <<\EOF
5368
cat >> confdefs.h <<\EOF
5372
cat >> confdefs.h <<\EOF
5376
cat >> confdefs.h <<\EOF
5381
if echo $OS_RELEASE | grep -c 2.1 2>/dev/null; then
5382
cat >> confdefs.h <<\EOF
5383
#define _PR_NO_LARGE_FILES 1
5386
CC='$(NSDEPTH)/build/hcc cc'
5387
CXX='$(NSDEPTH)/build/hcpp CC'
5388
MDCPUCFG_H=_unixware.cfg
5390
cat >> confdefs.h <<\EOF
5391
#define _LARGEFILE64_SOURCE 1
5394
cat >> confdefs.h <<\EOF
5395
#define _PR_HAVE_OFF64_T 1
5398
cat >> confdefs.h <<\EOF
5399
#define _PR_HAVE_SOCKADDR_LEN 1
5402
MDCPUCFG_H=_unixware7.cfg
5404
PR_MD_CSRCS=unixware.c
5410
# Check whether --with-symbian-sdk or --without-symbian-sdk was given.
5411
if test "${with_symbian_sdk+set}" = set; then
5412
withval="$with_symbian_sdk"
5413
SYMBIAN_SDK_DIR=$withval
5417
echo -----------------------------------------------------------------------------
5418
echo Building with Symbian SDK in: $SYMBIAN_SDK_DIR
5419
echo -----------------------------------------------------------------------------
5421
cat >> confdefs.h <<\EOF
5425
cat >> confdefs.h <<\EOF
5429
cat >> confdefs.h <<\EOF
5433
cat >> confdefs.h <<\EOF
5434
#define __SYMBIAN32__ 1
5437
cat >> confdefs.h <<\EOF
5441
cat >> confdefs.h <<\EOF
5445
cat >> confdefs.h <<\EOF
5446
#define __SUPPORT_CPP_EXCEPTIONS__ 1
5449
cat >> confdefs.h <<\EOF
5450
#define MOZ_STDERR_TO_STDOUT 1
5453
cat >> confdefs.h <<\EOF
5454
#define HAVE_FCNTL_FILE_LOCKING 1
5457
cat >> confdefs.h <<\EOF
5458
#define HAVE_SOCKLEN_T 1
5468
MDCPUCFG_H=_symbian.cfg
5469
PR_MD_CSRCS=symbian.c
5471
RANLIB='echo no ranlib '
5474
OS_EXE_CFLAGS="$OS_EXE_CFLAGS -D__EXE__"
5475
CFLAGS="$CFLAGS -MD -nostdinc"
5476
SYMBIAN_SYS_INCLUDE="-I$SYMBIAN_SDK_DIR/Epoc32/include/variant -I$SYMBIAN_SDK_DIR/Epoc32/include -I$SYMBIAN_SDK_DIR/Epoc32/include/stdapis"
5477
echo -------------------------------------------------------
5478
echo SYMBIAN_SYS_INCLUDE is: $SYMBIAN_SYS_INCLUDE
5479
echo -------------------------------------------------------
5480
case "$OS_TARGET" in
5486
WINSCW_LD_DIR="\$(SYMBIAN_SDK_DIR)/EPOC32/RELEASE/WINSCW/UDEB"
5487
CFLAGS="$CFLAGS -O0 -inline off -wchar_t off -align 4 -warnings on -w nohidevirtual,nounusedexpr -msgstyle gcc -enum int -str pool -exc ms -trigraphs on -nostderr -gccdep -cwd source -i- -I\$(VPATH)"
5488
SYMBIAN_SYS_INCLUDE="$SYMBIAN_SYS_INCLUDE -include Symbian_OS_v9.2.hrh"
5489
AR_FLAGS="-library -msgstyle gcc -stdlib -subsystem windows -noimplib -o \$@"
5490
cat >> confdefs.h <<\EOF
5494
cat >> confdefs.h <<\EOF
5498
cat >> confdefs.h <<\EOF
5502
cat >> confdefs.h <<\EOF
5503
#define __WINSCW__ 1
5506
DEFINES="$DEFINES -U_WIN32"
5509
CFLAGS="$CFLAGS -Wall -Wno-unknown-pragmas -fexceptions -march=armv5t -mapcs -pipe -x c -msoft-float"
5510
CXXFLAGS="$CXXFLAGS $CFLAGS -Wno-ctor-dtor-privacy"
5511
SYMBIAN_SYS_INCLUDE="$SYMBIAN_SYS_INCLUDE -include $SYMBIAN_SDK_DIR/EPOC32/INCLUDE/GCCE/GCCE.h"
5512
cat >> confdefs.h <<\EOF
5516
cat >> confdefs.h <<\EOF
5520
DEFINES="$DEFINES -D__PRODUCT_INCLUDE__=$SYMBIAN_SDK_DIR/Epoc32/include/variant/Symbian_OS_v9.2.hrh"
5523
{ echo "configure: error: Missing OS_TARGET for ${target}. Set --enable-symbian-target to with 'WINSCW' or 'GCCE'." 1>&2; exit 1; }
5526
CFLAGS="$CFLAGS ${SYMBIAN_SYS_INCLUDE}"
5530
cat >> confdefs.h <<\EOF
5534
cat >> confdefs.h <<\EOF
5538
cat >> confdefs.h <<\EOF
5539
#define BSD_SELECT 1
5542
cat >> confdefs.h <<\EOF
5543
#define TCPV40HDRS 1
5553
RESOLVE_LINK_SYMBOLS=1
5555
cat >> confdefs.h <<\EOF
5561
CFLAGS="$CFLAGS -Wall -Zomf"
5562
CXXFLAGS="$CFLAGS -Wall -Zomf"
5563
MKSHLIB='$(CC) $(DSO_LDOPTS) -o $@'
5565
DSO_LDOPTS='-Zomf -Zdll'
5567
_OPTIMIZE_FLAGS="-O2 -s"
5568
_DEBUG_FLAGS="-g -fno-inline"
5569
if test -n "$MOZ_OPTIMIZE"; then
5570
DSO_LDOPTS="$DSO_LDOPTS -Zlinker /EXEPACK:2 -Zlinker /PACKCODE -Zlinker /PACKDATA"
5574
if test -n "$MOZ_OS2_HIGH_MEMORY"; then
5575
LDFLAGS="$LDFLAGS -Zhigh-mem"
5576
cat >> confdefs.h <<\EOF
5577
#define MOZ_OS2_HIGH_MEMORY 1
5582
# GCC for OS/2 currently predefines these, but we don't want them
5583
DEFINES="$DEFINES -Uunix -U__unix -U__unix__"
5587
cat >> confdefs.h <<\EOF
5595
if test -z "$SKIP_LIBRARY_CHECKS"; then
5600
*-darwin*|*-beos*|*-os2*)
5603
echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
5604
echo "configure:5605: checking for dlopen in -ldl" >&5
5605
ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
5606
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
5607
echo $ac_n "(cached) $ac_c" 1>&6
5609
ac_save_LIBS="$LIBS"
5611
cat > conftest.$ac_ext <<EOF
5612
#line 5613 "configure"
5613
#include "confdefs.h"
5614
/* Override any gcc2 internal prototype to avoid an error. */
5615
/* We use char because int might match the return type of a gcc2
5616
builtin and then its argument prototype would still apply. */
5623
if { (eval echo configure:5624: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5625
eval "ac_cv_lib_$ac_lib_var=yes"
5627
echo "configure: failed program was:" >&5
5628
cat conftest.$ac_ext >&5
5630
eval "ac_cv_lib_$ac_lib_var=no"
5633
LIBS="$ac_save_LIBS"
5636
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5637
echo "$ac_t""yes" 1>&6
5638
ac_safe=`echo "dlfcn.h" | sed 'y%./+-%__p_%'`
5639
echo $ac_n "checking for dlfcn.h""... $ac_c" 1>&6
5640
echo "configure:5641: checking for dlfcn.h" >&5
5641
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5642
echo $ac_n "(cached) $ac_c" 1>&6
5644
cat > conftest.$ac_ext <<EOF
5645
#line 5646 "configure"
5646
#include "confdefs.h"
5649
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5650
{ (eval echo configure:5651: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5651
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5652
if test -z "$ac_err"; then
5654
eval "ac_cv_header_$ac_safe=yes"
5657
echo "configure: failed program was:" >&5
5658
cat conftest.$ac_ext >&5
5660
eval "ac_cv_header_$ac_safe=no"
5664
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5665
echo "$ac_t""yes" 1>&6
5666
OS_LIBS="-ldl $OS_LIBS"
5668
echo "$ac_t""no" 1>&6
5672
echo "$ac_t""no" 1>&6
5681
if test $ac_cv_prog_gcc = yes; then
5682
echo $ac_n "checking whether ${CC-cc} needs -traditional""... $ac_c" 1>&6
5683
echo "configure:5684: checking whether ${CC-cc} needs -traditional" >&5
5684
if eval "test \"`echo '$''{'ac_cv_prog_gcc_traditional'+set}'`\" = set"; then
5685
echo $ac_n "(cached) $ac_c" 1>&6
5687
ac_pattern="Autoconf.*'x'"
5688
cat > conftest.$ac_ext <<EOF
5689
#line 5690 "configure"
5690
#include "confdefs.h"
5694
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5695
egrep "$ac_pattern" >/dev/null 2>&1; then
5697
ac_cv_prog_gcc_traditional=yes
5700
ac_cv_prog_gcc_traditional=no
5705
if test $ac_cv_prog_gcc_traditional = no; then
5706
cat > conftest.$ac_ext <<EOF
5707
#line 5708 "configure"
5708
#include "confdefs.h"
5712
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5713
egrep "$ac_pattern" >/dev/null 2>&1; then
5715
ac_cv_prog_gcc_traditional=yes
5722
echo "$ac_t""$ac_cv_prog_gcc_traditional" 1>&6
5723
if test $ac_cv_prog_gcc_traditional = yes; then
5724
CC="$CC -traditional"
5728
for ac_func in lchown strerror
5730
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5731
echo "configure:5732: checking for $ac_func" >&5
5732
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5733
echo $ac_n "(cached) $ac_c" 1>&6
5735
cat > conftest.$ac_ext <<EOF
5736
#line 5737 "configure"
5737
#include "confdefs.h"
5738
/* System header to define __stub macros and hopefully few prototypes,
5739
which can conflict with char $ac_func(); below. */
5741
/* Override any gcc2 internal prototype to avoid an error. */
5742
/* We use char because int might match the return type of a gcc2
5743
builtin and then its argument prototype would still apply. */
5748
/* The GNU C library defines this for functions which it implements
5749
to always fail with ENOSYS. Some functions are actually named
5750
something starting with __ and the normal name is an alias. */
5751
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5759
if { (eval echo configure:5760: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5761
eval "ac_cv_func_$ac_func=yes"
5763
echo "configure: failed program was:" >&5
5764
cat conftest.$ac_ext >&5
5766
eval "ac_cv_func_$ac_func=no"
5771
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5772
echo "$ac_t""yes" 1>&6
5773
ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5774
cat >> confdefs.h <<EOF
5775
#define $ac_tr_func 1
5779
echo "$ac_t""no" 1>&6
5786
# Check whether --with-ccache or --without-ccache was given.
5787
if test "${with_ccache+set}" = set; then
5788
withval="$with_ccache"
5795
if test "$CCACHE" != "no"; then
5796
if test -n "$CCACHE"; then
5797
if test "$CCACHE" = "yes"; then
5800
if test ! -e "$CCACHE"; then
5801
{ echo "configure: error: $CCACHE not found" 1>&2; exit 1; }
5805
for ac_prog in $CCACHE ccache
5807
# Extract the first word of "$ac_prog", so it can be a program name with args.
5808
set dummy $ac_prog; ac_word=$2
5809
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5810
echo "configure:5811: checking for $ac_word" >&5
5811
if eval "test \"`echo '$''{'ac_cv_path_CCACHE'+set}'`\" = set"; then
5812
echo $ac_n "(cached) $ac_c" 1>&6
5816
ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
5819
ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a dos path.
5822
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5824
for ac_dir in $ac_dummy; do
5825
test -z "$ac_dir" && ac_dir=.
5826
if test -f $ac_dir/$ac_word; then
5827
ac_cv_path_CCACHE="$ac_dir/$ac_word"
5835
CCACHE="$ac_cv_path_CCACHE"
5836
if test -n "$CCACHE"; then
5837
echo "$ac_t""$CCACHE" 1>&6
5839
echo "$ac_t""no" 1>&6
5842
test -n "$CCACHE" && break
5845
if test -z "$CCACHE" -o "$CCACHE" = ":"; then
5846
{ echo "configure: error: ccache not found" 1>&2; exit 1; }
5847
elif test -x "$CCACHE"; then
5851
{ echo "configure: error: $CCACHE is not executable" 1>&2; exit 1; }
5855
# Check whether --enable-strip or --disable-strip was given.
5856
if test "${enable_strip+set}" = set; then
5857
enableval="$enable_strip"
5858
if test "$enableval" = "yes"; then
5864
case "${target_os}" in
5866
if test -z "$GNU_CC"; then
5868
echo $ac_n "checking for +Olit support""... $ac_c" 1>&6
5869
echo "configure:5870: checking for +Olit support" >&5
5870
if eval "test \"`echo '$''{'ac_cv_hpux_usable_olit_option'+set}'`\" = set"; then
5871
echo $ac_n "(cached) $ac_c" 1>&6
5873
ac_cv_hpux_usable_olit_option=no
5875
echo 'int main() { return 0; }' | cat > conftest.c
5876
${CC-cc} ${CFLAGS} +Olit=all -o conftest conftest.c > conftest.out 2>&1
5877
if test $? -eq 0; then
5878
if test -z "`egrep -i '(unrecognize|unknown)' conftest.out`"; then
5879
ac_cv_hpux_usable_olit_option=yes
5886
echo "$ac_t""$ac_cv_hpux_usable_olit_option" 1>&6
5888
if test "$ac_cv_hpux_usable_olit_option" = "yes"; then
5889
CFLAGS="$CFLAGS +Olit=all"
5890
CXXFLAGS="$CXXFLAGS +Olit=all"
5892
CFLAGS="$CFLAGS +ESlit"
5893
CXXFLAGS="$CXXFLAGS +ESlit"
5901
case "$target_os" in
5910
echo $ac_n "checking for pthread_create in -lpthreads""... $ac_c" 1>&6
5911
echo "configure:5912: checking for pthread_create in -lpthreads" >&5
5913
#include <pthread.h>
5914
void *foo(void *v) { return v; }
5917
if (!pthread_create(&t, 0, &foo, 0)) {
5922
echo "${CC-cc} -o dummy${ac_exeext} dummy.c $CFLAGS $CPPFLAGS -lpthreads $LDFLAGS $LIBS" 1>&5;
5923
${CC-cc} -o dummy${ac_exeext} dummy.c $CFLAGS $CPPFLAGS -lpthreads $LDFLAGS $LIBS 2>&5;
5925
rm -f dummy.c dummy${ac_exeext} ;
5926
if test "$_res" = "0"; then
5927
echo "$ac_t""yes" 1>&6
5928
_HAVE_PTHREADS=1 _PTHREAD_LDFLAGS="-lpthreads"
5930
echo "$ac_t""no" 1>&6
5932
echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6
5933
echo "configure:5934: checking for pthread_create in -lpthread" >&5
5935
#include <pthread.h>
5936
void *foo(void *v) { return v; }
5939
if (!pthread_create(&t, 0, &foo, 0)) {
5944
echo "${CC-cc} -o dummy${ac_exeext} dummy.c $CFLAGS $CPPFLAGS -lpthread $LDFLAGS $LIBS" 1>&5;
5945
${CC-cc} -o dummy${ac_exeext} dummy.c $CFLAGS $CPPFLAGS -lpthread $LDFLAGS $LIBS 2>&5;
5947
rm -f dummy.c dummy${ac_exeext} ;
5948
if test "$_res" = "0"; then
5949
echo "$ac_t""yes" 1>&6
5950
_HAVE_PTHREADS=1 _PTHREAD_LDFLAGS="-lpthread"
5952
echo "$ac_t""no" 1>&6
5954
echo $ac_n "checking for pthread_create in -lc_r""... $ac_c" 1>&6
5955
echo "configure:5956: checking for pthread_create in -lc_r" >&5
5957
#include <pthread.h>
5958
void *foo(void *v) { return v; }
5961
if (!pthread_create(&t, 0, &foo, 0)) {
5966
echo "${CC-cc} -o dummy${ac_exeext} dummy.c $CFLAGS $CPPFLAGS -lc_r $LDFLAGS $LIBS" 1>&5;
5967
${CC-cc} -o dummy${ac_exeext} dummy.c $CFLAGS $CPPFLAGS -lc_r $LDFLAGS $LIBS 2>&5;
5969
rm -f dummy.c dummy${ac_exeext} ;
5970
if test "$_res" = "0"; then
5971
echo "$ac_t""yes" 1>&6
5972
_HAVE_PTHREADS=1 _PTHREAD_LDFLAGS="-lc_r"
5974
echo "$ac_t""no" 1>&6
5976
echo $ac_n "checking for pthread_create in -lc""... $ac_c" 1>&6
5977
echo "configure:5978: checking for pthread_create in -lc" >&5
5979
#include <pthread.h>
5980
void *foo(void *v) { return v; }
5983
if (!pthread_create(&t, 0, &foo, 0)) {
5988
echo "${CC-cc} -o dummy${ac_exeext} dummy.c $CFLAGS $CPPFLAGS -lc $LDFLAGS $LIBS" 1>&5;
5989
${CC-cc} -o dummy${ac_exeext} dummy.c $CFLAGS $CPPFLAGS -lc $LDFLAGS $LIBS 2>&5;
5991
rm -f dummy.c dummy${ac_exeext} ;
5992
if test "$_res" = "0"; then
5993
echo "$ac_t""yes" 1>&6
5997
echo "$ac_t""no" 1>&6
6013
# Check whether --with-pthreads or --without-pthreads was given.
6014
if test "${with_pthreads+set}" = set; then
6015
withval="$with_pthreads"
6016
if test "$withval" = "yes"; then
6017
if test -n "$_HAVE_PTHREADS"; then
6022
{ echo "configure: error: --with-pthreads specified for a system without pthread support " 1>&2; exit 1; };
6029
if test -n "$_HAVE_PTHREADS" && test -z "$USE_USER_PTHREADS" && test -z "$USE_NSPR_THREADS"; then
6037
# Check whether --enable-user-pthreads or --disable-user-pthreads was given.
6038
if test "${enable_user_pthreads+set}" = set; then
6039
enableval="$enable_user_pthreads"
6040
if test "$enableval" = "yes"; then
6041
if test -n "$_HAVE_PTHREADS"; then
6046
{ echo "configure: error: --enable-user-pthreads specified for a system without pthread support " 1>&2; exit 1; };
6052
# Check whether --enable-nspr-threads or --disable-nspr-threads was given.
6053
if test "${enable_nspr_threads+set}" = set; then
6054
enableval="$enable_nspr_threads"
6055
if test "$enableval" = "yes"; then
6065
# Check whether --with-bthreads or --without-bthreads was given.
6066
if test "${with_bthreads+set}" = set; then
6067
withval="$with_bthreads"
6068
if test "$withval" = "yes"; then
6078
fi # SKIP_LIBRARY_CHECKS
6080
# Check whether --enable-ipv6 or --disable-ipv6 was given.
6081
if test "${enable_ipv6+set}" = set; then
6082
enableval="$enable_ipv6"
6083
if test "$enableval" = "yes"; then
6091
if test -n "$USE_PTHREADS"; then
6093
ac_cv_have_dash_pthread=no
6094
echo $ac_n "checking whether ${CC-cc} accepts -pthread""... $ac_c" 1>&6
6095
echo "configure:6096: checking whether ${CC-cc} accepts -pthread" >&5
6096
echo 'int main() { return 0; }' | cat > conftest.c
6097
${CC-cc} -pthread -o conftest conftest.c > conftest.out 2>&1
6098
if test $? -eq 0; then
6099
if test -z "`egrep -i '(unrecognize|unknown)' conftest.out | grep pthread`" && test -z "`egrep -i '(error|incorrect)' conftest.out`" ; then
6100
ac_cv_have_dash_pthread=yes
6101
case "$target_os" in
6103
# Freebsd doesn't use -pthread for compiles, it uses them for linking
6106
CFLAGS="$CFLAGS -pthread"
6107
CXXFLAGS="$CXXFLAGS -pthread"
6113
echo "$ac_t""$ac_cv_have_dash_pthread" 1>&6
6115
ac_cv_have_dash_pthreads=no
6116
if test "$ac_cv_have_dash_pthread" = "no"; then
6117
echo $ac_n "checking whether ${CC-cc} accepts -pthreads""... $ac_c" 1>&6
6118
echo "configure:6119: checking whether ${CC-cc} accepts -pthreads" >&5
6119
echo 'int main() { return 0; }' | cat > conftest.c
6120
${CC-cc} -pthreads -o conftest conftest.c > conftest.out 2>&1
6121
if test $? -eq 0; then
6122
if test -z "`egrep -i '(unrecognize|unknown)' conftest.out | grep pthreads`" && test -z "`egrep -i '(error|incorrect)' conftest.out`" ; then
6123
ac_cv_have_dash_pthreads=yes
6124
CFLAGS="$CFLAGS -pthreads"
6125
CXXFLAGS="$CXXFLAGS -pthreads"
6129
echo "$ac_t""$ac_cv_have_dash_pthreads" 1>&6
6134
if test "$ac_cv_have_dash_pthreads" = "yes"; then
6139
cat >> confdefs.h <<\EOF
6140
#define _REENTRANT 1
6143
cat >> confdefs.h <<\EOF
6144
#define _THREAD_SAFE 1
6147
if test "$ac_cv_have_dash_pthread" = "yes"; then
6148
_PTHREAD_LDFLAGS="-pthread"
6150
_PTHREAD_LDFLAGS="-lc_r"
6154
if test "$ac_cv_have_dash_pthread" = "yes"; then
6155
_PTHREAD_LDFLAGS="-pthread"
6159
cat >> confdefs.h <<\EOF
6160
#define _THREAD_SAFE 1
6163
if test "$ac_cv_have_dash_pthread" = "yes"; then
6168
if test "$ac_cv_have_dash_pthread" = "yes"; then
6169
_PTHREAD_LDFLAGS=-pthread
6172
*-linux*|*-gnu*|*-k*bsd*-gnu)
6173
cat >> confdefs.h <<\EOF
6174
#define _REENTRANT 1
6181
if test -n "$USE_USER_PTHREADS"; then
6191
if test -n "$USE_NSPR_THREADS"; then
6192
cat >> confdefs.h <<\EOF
6193
#define _PR_LOCAL_THREADS_ONLY 1
6197
case "$target_os" in
6199
if test -z "$USE_PTHREADS"; then
6200
cat >> confdefs.h <<\EOF
6201
#define AIX_RENAME_SELECT 1
6207
if test -z "$USE_NSPR_THREADS"; then
6208
cat >> confdefs.h <<\EOF
6209
#define HAVE_POINTER_LOCALTIME_R 1
6215
if test -z "$USE_NSPR_THREADS"; then
6216
cat >> confdefs.h <<\EOF
6217
#define HAVE_POINTER_LOCALTIME_R 1
6221
if test -n "$USE_PTHREADS"; then
6222
cat >> confdefs.h <<\EOF
6223
#define _PR_HAVE_THREADSAFE_GETHOST 1
6229
if test -z "$USE_NSPR_THREADS"; then
6230
cat >> confdefs.h <<\EOF
6231
#define HAVE_POINTER_LOCALTIME_R 1
6235
if test -n "$USE_PTHREADS"; then
6236
cat >> confdefs.h <<\EOF
6237
#define _PR_HAVE_THREADSAFE_GETHOST 1
6245
if test -n "$USE_PTHREADS"; then
6246
cat >> confdefs.h <<\EOF
6247
#define _PR_NEED_PTHREAD_INIT 1
6253
if test -n "$USE_NSPR_THREADS"; then
6254
cat >> confdefs.h <<\EOF
6255
#define _PR_LOCAL_THREADS_ONLY 1
6261
if test -n "$USE_NSPR_THREADS"; then
6262
cat >> confdefs.h <<\EOF
6263
#define _PR_LOCAL_THREADS_ONLY 1
6267
if test "$USE_PTHREADS"; then
6268
if echo "$OS_RELEASE" | egrep '^(B.10.10|B.10.20)' >/dev/null; then
6269
cat >> confdefs.h <<\EOF
6270
#define _REENTRANT 1
6273
cat >> confdefs.h <<\EOF
6274
#define _PR_DCETHREADS 1
6278
cat >> confdefs.h <<EOF
6279
#define _POSIX_C_SOURCE 199506L
6282
cat >> confdefs.h <<\EOF
6283
#define _PR_HAVE_THREADSAFE_GETHOST 1
6288
if test "$USE_USER_PTHREADS"; then
6289
cat >> confdefs.h <<EOF
6290
#define _POSIX_C_SOURCE 199506L
6296
if test "${target_os}" = "irix6.5"; then
6297
if test -n "$USE_PTHREADS"; then
6298
cat >> confdefs.h <<\EOF
6299
#define _PR_HAVE_GETHOST_R 1
6302
cat >> confdefs.h <<\EOF
6303
#define _PR_HAVE_GETHOST_R_POINTER 1
6309
*-linux*|*-gnu*|*-k*bsd*-gnu)
6310
if test -n "$USE_NSPR_THREADS"; then
6311
cat >> confdefs.h <<\EOF
6312
#define _PR_LOCAL_THREADS_ONLY 1
6317
*-mingw*|*-cygwin*|*-msvc*|*-mks*|*-wince*|*-winmo*|*-os2*|*-beos*)
6322
*-netbsd*|*-openbsd*)
6323
if test -n "$USE_NSPR_THREADS"; then
6324
cat >> confdefs.h <<\EOF
6325
#define _PR_LOCAL_THREADS_ONLY 1
6331
if test -n "$USE_NSPR_THREADS"; then
6332
cat >> confdefs.h <<\EOF
6333
#define _PR_LOCAL_THREADS_ONLY 1
6337
if test -n "$USE_PTHREADS"; then
6338
if echo $OS_RELEASE | egrep -c '(V2.0|V3.2)' 2>/dev/null; then
6341
cat >> confdefs.h <<\EOF
6342
#define _PR_HAVE_THREADSAFE_GETHOST 1
6349
if test -n "$USE_NSPR_THREADS"; then
6350
cat >> confdefs.h <<\EOF
6351
#define _PR_LOCAL_THREADS_ONLY 1
6355
if test -n "$USE_PTHREADS"; then
6356
cat >> confdefs.h <<\EOF
6357
#define _REENTRANT 1
6360
cat >> confdefs.h <<\EOF
6361
#define HAVE_POINTER_LOCALTIME_R 1
6364
if test "$OS_TEST" = "i86pc"; then
6365
if test -n "$USE_64"; then
6366
PR_MD_ASFILES=os_SunOS_x86_64.s
6368
PR_MD_ASFILES=os_SunOS_x86.s
6371
if test -n "$USE_64"; then
6372
PR_MD_ASFILES=os_SunOS_sparcv9.s
6378
if test -n "$USE_PTHREADS"; then
6379
cat >> confdefs.h <<\EOF
6380
#define _PR_HAVE_GETHOST_R 1
6383
cat >> confdefs.h <<\EOF
6384
#define _PR_HAVE_GETHOST_R_POINTER 1
6391
OS_LIBS="$_PTHREAD_LDFLAGS $OS_LIBS"
6393
if test -n "$_SAVE_OPTIMIZE_FLAGS"; then
6394
_OPTIMIZE_FLAGS="$_SAVE_OPTIMIZE_FLAGS"
6397
if test -n "$_SAVE_DEBUG_FLAGS"; then
6398
_DEBUG_FLAGS="$_SAVE_DEBUG_FLAGS"
6401
if test -n "$MOZ_OPTIMIZE"; then
6402
CFLAGS="$CFLAGS $_OPTIMIZE_FLAGS"
6403
CXXFLAGS="$CXXFLAGS $_OPTIMIZE_FLAGS"
6406
if test -n "$MOZ_DEBUG_SYMBOLS"; then
6407
CFLAGS="$CFLAGS $_DEBUG_FLAGS"
6408
CXXFLAGS="$CXXFLAGS $_DEBUG_FLAGS"
6411
if test -n "$MOZ_OPTIMIZE"; then
6417
if test -n "$USE_64"; then
6421
RELEASE_OBJDIR_NAME="${OS_CONFIG}${CPU_ARCH_TAG}${COMPILER_TAG}${IMPL_STRATEGY}${OBJDIR_TAG}.${OBJDIR_SUFFIX}"
6423
case "$target_os" in
6425
CC="\$(CYGWIN_WRAPPER) $CC"
6426
CXX="\$(CYGWIN_WRAPPER) $CXX"
6427
RC="\$(CYGWIN_WRAPPER) $RC"
6431
# Check whether --enable-wrap-malloc or --disable-wrap-malloc was given.
6432
if test "${enable_wrap_malloc+set}" = set; then
6433
enableval="$enable_wrap_malloc"
6434
if test "$enableval" = "yes"; then
6440
if test -n "$_WRAP_MALLOC"; then
6441
if test "$GNU_CC"; then
6442
WRAP_MALLOC_CFLAGS="${LDFLAGS} ${WRAP_MALLOC_CFLAGS} -Wl,--wrap -Wl,malloc -Wl,--wrap -Wl,calloc -Wl,--wrap -Wl,valloc -Wl,--wrap -Wl,free -Wl,--wrap -Wl,realloc -Wl,--wrap -Wl,memalign -Wl,--wrap -Wl,__builtin_new -Wl,--wrap -Wl,__builtin_vec_new -Wl,--wrap -Wl,__builtin_delete -Wl,--wrap -Wl,__builtin_vec_delete -Wl,--wrap -Wl,PR_Free -Wl,--wrap -Wl,PR_Malloc -Wl,--wrap -Wl,PR_Calloc -Wl,--wrap -Wl,PR_Realloc -Wl,--wrap -Wl,strdup -Wl,--wrap -Wl,strndup -Wl,--wrap -Wl,posix_memalign"
6443
DSO_LDOPTS="$DSO_LDOPTS $WRAP_MALLOC_CFLAGS"
6445
{ echo "configure: error: --enable-wrap-malloc is not supported for non-GNU toolchains" 1>&2; exit 1; }
6449
# Check whether --with-wrap-malloc or --without-wrap-malloc was given.
6450
if test "${with_wrap_malloc+set}" = set; then
6451
withval="$with_wrap_malloc"
6452
WRAP_MALLOC_LIB=$withval
6571
lib/libc/include/Makefile
6572
lib/libc/src/Makefile
6576
pkg/solaris/Makefile
6577
pkg/solaris/SUNWpr/Makefile
6578
pkg/solaris/SUNWprd/Makefile
6581
pr/include/md/Makefile
6582
pr/include/obsolete/Makefile
6583
pr/include/private/Makefile
6586
pr/src/linking/Makefile
6587
pr/src/malloc/Makefile
6589
pr/src/md/${PR_MD_ARCH_DIR}/Makefile
6590
pr/src/memory/Makefile
6591
pr/src/misc/Makefile
6592
pr/src/threads/Makefile
6594
pr/tests/dll/Makefile
6598
if test -z "$USE_PTHREADS" && test -z "$USE_BTHREADS"; then
6599
MAKEFILES="$MAKEFILES pr/src/threads/combined/Makefile"
6600
elif test -n "$USE_PTHREADS"; then
6601
MAKEFILES="$MAKEFILES pr/src/pthreads/Makefile"
6602
elif test -n "$USE_BTHREADS"; then
6603
MAKEFILES="$MAKEFILES pr/src/bthreads/Makefile"
6606
if test -n "$USE_CPLUS"; then
6607
MAKEFILES="$MAKEFILES pr/src/cplus/Makefile pr/src/cplus/tests/Makefile"
6610
echo $MAKEFILES > unallmakefiles
6613
cat > confcache <<\EOF
6614
# This file is a shell script that caches the results of configure
6615
# tests run on this system so they can be shared between configure
6616
# scripts and configure runs. It is not useful on other systems.
6617
# If it contains results you don't want to keep, you may remove or edit it.
6619
# By default, configure uses ./config.cache as the cache file,
6620
# creating it if it does not exist already. You can give configure
6621
# the --cache-file=FILE option to use a different cache file; that is
6622
# what configure does when it calls configure scripts in
6623
# subdirectories, so they share the cache.
6624
# Giving --cache-file=/dev/null disables caching, for debugging configure.
6625
# config.status only pays attention to the cache file if you give it the
6626
# --recheck option to rerun configure.
6629
# The following way of writing the cache mishandles newlines in values,
6630
# but we know of no workaround that is simple, portable, and efficient.
6631
# So, don't put newlines in cache variables' values.
6632
# Ultrix sh set writes to stderr and can't be redirected directly,
6633
# and sets the high bit in the cache file unless we assign to the vars.
6635
case `(ac_space=' '; set | grep ac_space) 2>&1` in
6637
# `set' does not quote correctly, so add quotes (double-quote substitution
6638
# turns \\\\ into \\, and sed turns \\ into \).
6640
-e "s/'/'\\\\''/g" \
6641
-e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
6644
# `set' quotes correctly as required by POSIX, so do not add quotes.
6645
sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
6648
if cmp -s $cache_file confcache; then
6651
if test -w $cache_file; then
6652
echo "updating cache $cache_file"
6653
cat confcache > $cache_file
6655
echo "not updating unwritable cache $cache_file"
6660
trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
6662
test "x$prefix" = xNONE && prefix=$ac_default_prefix
6663
# Let make expand exec_prefix.
6664
test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6666
# Any assignment to VPATH causes Sun make to only execute
6667
# the first set of double-colon rules, so remove it if not needed.
6668
# If there is a colon in the path, we need to keep it.
6669
if test "x$srcdir" = x.; then
6670
ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
6673
trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
6675
# Transform confdefs.h into DEFS.
6676
# Protect against shell expansion while executing Makefile rules.
6677
# Protect against Makefile macro expansion.
6678
cat > conftest.defs <<\EOF
6679
s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g
6680
s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g
6685
DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' ' | tr '\015' ' '` # Manually modified for MKS support.
6689
# Without the "./", some shells look in PATH for config.status.
6690
: ${CONFIG_STATUS=./config.status}
6692
echo creating $CONFIG_STATUS
6693
rm -f $CONFIG_STATUS
6694
cat > $CONFIG_STATUS <<EOF
6696
# Generated automatically by configure.
6697
# Run this file to recreate the current configuration.
6698
# This directory was configured as follows,
6699
# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
6701
# $0 $ac_configure_args
6703
# Compiler output produced by configure, useful for debugging
6704
# configure, is in ./config.log if it exists.
6706
ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
6709
case "\$ac_option" in
6710
-recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
6711
echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
6712
exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
6713
-version | --version | --versio | --versi | --vers | --ver | --ve | --v)
6714
echo "$CONFIG_STATUS generated by autoconf version 2.13"
6716
-help | --help | --hel | --he | --h)
6717
echo "\$ac_cs_usage"; exit 0 ;;
6718
*) echo "\$ac_cs_usage"; exit 1 ;;
6722
ac_given_srcdir=$srcdir
6724
trap 'rm -fr `echo "$MAKEFILES" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
6726
cat >> $CONFIG_STATUS <<EOF
6730
# Protect against being on the right side of a sed subst in config.status.
6731
sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
6732
s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
6736
s%@CFLAGS@%$CFLAGS%g
6737
s%@CPPFLAGS@%$CPPFLAGS%g
6738
s%@CXXFLAGS@%$CXXFLAGS%g
6739
s%@FFLAGS@%$FFLAGS%g
6741
s%@LDFLAGS@%$LDFLAGS%g
6743
s%@exec_prefix@%$exec_prefix%g
6744
s%@prefix@%$prefix%g
6745
s%@program_transform_name@%$program_transform_name%g
6746
s%@bindir@%$bindir%g
6747
s%@sbindir@%$sbindir%g
6748
s%@libexecdir@%$libexecdir%g
6749
s%@datadir@%$datadir%g
6750
s%@sysconfdir@%$sysconfdir%g
6751
s%@sharedstatedir@%$sharedstatedir%g
6752
s%@localstatedir@%$localstatedir%g
6753
s%@libdir@%$libdir%g
6754
s%@includedir@%$includedir%g
6755
s%@oldincludedir@%$oldincludedir%g
6756
s%@infodir@%$infodir%g
6757
s%@mandir@%$mandir%g
6759
s%@host_alias@%$host_alias%g
6760
s%@host_cpu@%$host_cpu%g
6761
s%@host_vendor@%$host_vendor%g
6762
s%@host_os@%$host_os%g
6763
s%@target@%$target%g
6764
s%@target_alias@%$target_alias%g
6765
s%@target_cpu@%$target_cpu%g
6766
s%@target_vendor@%$target_vendor%g
6767
s%@target_os@%$target_os%g
6769
s%@build_alias@%$build_alias%g
6770
s%@build_cpu@%$build_cpu%g
6771
s%@build_vendor@%$build_vendor%g
6772
s%@build_os@%$build_os%g
6774
s%@dist_prefix@%$dist_prefix%g
6775
s%@dist_bindir@%$dist_bindir%g
6776
s%@dist_includedir@%$dist_includedir%g
6777
s%@dist_libdir@%$dist_libdir%g
6778
s%@WHOAMI@%$WHOAMI%g
6779
s%@HOST_CC@%$HOST_CC%g
6781
s%@RANLIB@%$RANLIB%g
6786
s%@WINDRES@%$WINDRES%g
6789
s%@CCACHE@%$CCACHE%g
6790
s%@SHELL_OVERRIDE@%$SHELL_OVERRIDE%g
6791
s%@MOZILLA_CLIENT@%$MOZILLA_CLIENT%g
6792
s%@HOST_CFLAGS@%$HOST_CFLAGS%g
6793
s%@HOST_LDFLAGS@%$HOST_LDFLAGS%g
6794
s%@GNU_CC@%$GNU_CC%g
6795
s%@GCC_USE_GNU_LD@%$GCC_USE_GNU_LD%g
6796
s%@MSC_VER@%$MSC_VER%g
6797
s%@CROSS_COMPILE@%$CROSS_COMPILE%g
6798
s%@MOZ_OPTIMIZE@%$MOZ_OPTIMIZE%g
6799
s%@MOZ_DEBUG@%$MOZ_DEBUG%g
6800
s%@MOZ_DEBUG_SYMBOLS@%$MOZ_DEBUG_SYMBOLS%g
6801
s%@USE_CPLUS@%$USE_CPLUS%g
6802
s%@USE_IPV6@%$USE_IPV6%g
6803
s%@USE_N32@%$USE_N32%g
6804
s%@USE_64@%$USE_64%g
6805
s%@OBJECT_MODE@%$OBJECT_MODE%g
6806
s%@ENABLE_STRIP@%$ENABLE_STRIP%g
6807
s%@USE_PTHREADS@%$USE_PTHREADS%g
6808
s%@USE_BTHREADS@%$USE_BTHREADS%g
6809
s%@USE_USER_PTHREADS@%$USE_USER_PTHREADS%g
6810
s%@USE_NSPR_THREADS@%$USE_NSPR_THREADS%g
6811
s%@LIBNSPR@%$LIBNSPR%g
6812
s%@LIBPLC@%$LIBPLC%g
6813
s%@MOD_MAJOR_VERSION@%$MOD_MAJOR_VERSION%g
6814
s%@MOD_MINOR_VERSION@%$MOD_MINOR_VERSION%g
6815
s%@MOD_PATCH_VERSION@%$MOD_PATCH_VERSION%g
6816
s%@NSPR_MODNAME@%$NSPR_MODNAME%g
6817
s%@MDCPUCFG_H@%$MDCPUCFG_H%g
6818
s%@PR_MD_CSRCS@%$PR_MD_CSRCS%g
6819
s%@PR_MD_ASFILES@%$PR_MD_ASFILES%g
6820
s%@PR_MD_ARCH_DIR@%$PR_MD_ARCH_DIR%g
6821
s%@CPU_ARCH@%$CPU_ARCH%g
6822
s%@OBJ_SUFFIX@%$OBJ_SUFFIX%g
6823
s%@LIB_SUFFIX@%$LIB_SUFFIX%g
6824
s%@DLL_SUFFIX@%$DLL_SUFFIX%g
6825
s%@ASM_SUFFIX@%$ASM_SUFFIX%g
6826
s%@WRAP_MALLOC_CFLAGS@%$WRAP_MALLOC_CFLAGS%g
6827
s%@WRAP_MALLOC_LIB@%$WRAP_MALLOC_LIB%g
6828
s%@MKSHLIB@%$MKSHLIB%g
6829
s%@DSO_CFLAGS@%$DSO_CFLAGS%g
6830
s%@DSO_LDOPTS@%$DSO_LDOPTS%g
6831
s%@OS_TARGET@%$OS_TARGET%g
6832
s%@OS_ARCH@%$OS_ARCH%g
6833
s%@OS_RELEASE@%$OS_RELEASE%g
6834
s%@OS_TEST@%$OS_TEST%g
6835
s%@MACOSX_DEPLOYMENT_TARGET@%$MACOSX_DEPLOYMENT_TARGET%g
6836
s%@DEFINES@%$DEFINES%g
6837
s%@AR_FLAGS@%$AR_FLAGS%g
6838
s%@ASFLAGS@%$ASFLAGS%g
6839
s%@FILTER@%$FILTER%g
6840
s%@IMPLIB@%$IMPLIB%g
6841
s%@PROFILE_GEN_CFLAGS@%$PROFILE_GEN_CFLAGS%g
6842
s%@PROFILE_GEN_LDFLAGS@%$PROFILE_GEN_LDFLAGS%g
6843
s%@PROFILE_USE_CFLAGS@%$PROFILE_USE_CFLAGS%g
6844
s%@PROFILE_USE_LDFLAGS@%$PROFILE_USE_LDFLAGS%g
6845
s%@OS_LIBS@%$OS_LIBS%g
6846
s%@RESOLVE_LINK_SYMBOLS@%$RESOLVE_LINK_SYMBOLS%g
6847
s%@AIX_LINK_OPTS@%$AIX_LINK_OPTS%g
6848
s%@NOSUCHFILE@%$NOSUCHFILE%g
6849
s%@MOZ_OBJFORMAT@%$MOZ_OBJFORMAT%g
6850
s%@ULTRASPARC_LIBRARY@%$ULTRASPARC_LIBRARY%g
6851
s%@OBJDIR@%$OBJDIR%g
6852
s%@OBJDIR_NAME@%$OBJDIR_NAME%g
6853
s%@RELEASE_OBJDIR_NAME@%$RELEASE_OBJDIR_NAME%g
6854
s%@NSINSTALL@%$NSINSTALL%g
6855
s%@OPTIMIZER@%$OPTIMIZER%g
6857
s%@RCFLAGS@%$RCFLAGS%g
6858
s%@DLLFLAGS@%$DLLFLAGS%g
6859
s%@EXEFLAGS@%$EXEFLAGS%g
6860
s%@OS_DLLFLAGS@%$OS_DLLFLAGS%g
6861
s%@CYGWIN_WRAPPER@%$CYGWIN_WRAPPER%g
6862
s%@VISIBILITY_FLAGS@%$VISIBILITY_FLAGS%g
6863
s%@WRAP_SYSTEM_INCLUDES@%$WRAP_SYSTEM_INCLUDES%g
6864
s%@MACOS_SDK_DIR@%$MACOS_SDK_DIR%g
6865
s%@SYMBIAN_SDK_DIR@%$SYMBIAN_SDK_DIR%g
6866
s%@NEXT_ROOT@%$NEXT_ROOT%g
6872
cat >> $CONFIG_STATUS <<\EOF
6874
# Split the substitutions into bite-sized pieces for seds with
6875
# small command number limits, like on Digital OSF/1 and HP-UX.
6876
ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
6877
ac_file=1 # Number of current file.
6878
ac_beg=1 # First line for current file.
6879
ac_end=$ac_max_sed_cmds # Line after last line for current file.
6882
while $ac_more_lines; do
6883
if test $ac_beg -gt 1; then
6884
sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
6886
sed "${ac_end}q" conftest.subs > conftest.s$ac_file
6888
if test ! -s conftest.s$ac_file; then
6890
rm -f conftest.s$ac_file
6892
if test -z "$ac_sed_cmds"; then
6893
ac_sed_cmds="sed -f conftest.s$ac_file"
6895
ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
6897
ac_file=`expr $ac_file + 1`
6899
ac_end=`expr $ac_end + $ac_max_sed_cmds`
6902
if test -z "$ac_sed_cmds"; then
6907
cat >> $CONFIG_STATUS <<EOF
6909
CONFIG_FILES=\${CONFIG_FILES-"$MAKEFILES"}
6911
cat >> $CONFIG_STATUS <<\EOF
6912
for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
6913
# Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
6915
*:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
6916
ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
6917
*) ac_file_in="${ac_file}.in" ;;
6920
# Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
6922
# Remove last slash and all that follows it. Not all systems have dirname.
6923
ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
6924
if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
6925
# The file is in a subdirectory.
6926
test ! -d "$ac_dir" && mkdir "$ac_dir"
6927
ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
6928
# A "../" for each directory in $ac_dir_suffix.
6929
ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
6931
ac_dir_suffix= ac_dots=
6934
case "$ac_given_srcdir" in
6936
if test -z "$ac_dots"; then top_srcdir=.
6937
else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
6938
/* | ?:/*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
6940
srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
6941
top_srcdir="$ac_dots$ac_given_srcdir" ;;
6945
echo creating "$ac_file"
6947
configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
6949
*Makefile*) ac_comsub="1i\\
6950
# $configure_input" ;;
6954
ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" `
6956
s%@configure_input@%$configure_input%g
6957
s%@srcdir@%$srcdir%g
6958
s%@top_srcdir@%$top_srcdir%g
6959
" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
6966
cat >> $CONFIG_STATUS <<EOF
6969
cat >> $CONFIG_STATUS <<\EOF
6970
chmod +x config/nspr-config
6973
chmod +x $CONFIG_STATUS
6974
rm -fr confdefs* $ac_clean_files
6975
test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1