]> git.proxmox.com Git - rustc.git/blame - src/jemalloc/configure
Imported Upstream version 1.9.0+dfsg1
[rustc.git] / src / jemalloc / configure
CommitLineData
970d7e83
LB
1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
3# Generated by GNU Autoconf 2.69.
4#
5#
6# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
7#
8#
9# This configure script is free software; the Free Software Foundation
10# gives unlimited permission to copy, distribute and modify it.
11## -------------------- ##
12## M4sh Initialization. ##
13## -------------------- ##
14
15# Be more Bourne compatible
16DUALCASE=1; export DUALCASE # for MKS sh
17if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
18 emulate sh
19 NULLCMD=:
20 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
21 # is contrary to our usage. Disable this feature.
22 alias -g '${1+"$@"}'='"$@"'
23 setopt NO_GLOB_SUBST
24else
25 case `(set -o) 2>/dev/null` in #(
26 *posix*) :
27 set -o posix ;; #(
28 *) :
29 ;;
30esac
31fi
32
33
34as_nl='
35'
36export as_nl
37# Printing a long string crashes Solaris 7 /usr/bin/printf.
38as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
39as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
40as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
41# Prefer a ksh shell builtin over an external printf program on Solaris,
42# but without wasting forks for bash or zsh.
43if test -z "$BASH_VERSION$ZSH_VERSION" \
44 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
45 as_echo='print -r --'
46 as_echo_n='print -rn --'
47elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
48 as_echo='printf %s\n'
49 as_echo_n='printf %s'
50else
51 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
52 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
53 as_echo_n='/usr/ucb/echo -n'
54 else
55 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
56 as_echo_n_body='eval
57 arg=$1;
58 case $arg in #(
59 *"$as_nl"*)
60 expr "X$arg" : "X\\(.*\\)$as_nl";
61 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
62 esac;
63 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
64 '
65 export as_echo_n_body
66 as_echo_n='sh -c $as_echo_n_body as_echo'
67 fi
68 export as_echo_body
69 as_echo='sh -c $as_echo_body as_echo'
70fi
71
72# The user is always right.
73if test "${PATH_SEPARATOR+set}" != set; then
74 PATH_SEPARATOR=:
75 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
76 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
77 PATH_SEPARATOR=';'
78 }
79fi
80
81
82# IFS
83# We need space, tab and new line, in precisely that order. Quoting is
84# there to prevent editors from complaining about space-tab.
85# (If _AS_PATH_WALK were called with IFS unset, it would disable word
86# splitting by setting IFS to empty value.)
87IFS=" "" $as_nl"
88
89# Find who we are. Look in the path if we contain no directory separator.
90as_myself=
91case $0 in #((
92 *[\\/]* ) as_myself=$0 ;;
93 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
94for as_dir in $PATH
95do
96 IFS=$as_save_IFS
97 test -z "$as_dir" && as_dir=.
98 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
99 done
100IFS=$as_save_IFS
101
102 ;;
103esac
104# We did not find ourselves, most probably we were run as `sh COMMAND'
105# in which case we are not to be found in the path.
106if test "x$as_myself" = x; then
107 as_myself=$0
108fi
109if test ! -f "$as_myself"; then
110 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
111 exit 1
112fi
113
114# Unset variables that we do not need and which cause bugs (e.g. in
115# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
116# suppresses any "Segmentation fault" message there. '((' could
117# trigger a bug in pdksh 5.2.14.
118for as_var in BASH_ENV ENV MAIL MAILPATH
119do eval test x\${$as_var+set} = xset \
120 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
121done
122PS1='$ '
123PS2='> '
124PS4='+ '
125
126# NLS nuisances.
127LC_ALL=C
128export LC_ALL
129LANGUAGE=C
130export LANGUAGE
131
132# CDPATH.
133(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
134
135# Use a proper internal environment variable to ensure we don't fall
136 # into an infinite loop, continuously re-executing ourselves.
137 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
138 _as_can_reexec=no; export _as_can_reexec;
139 # We cannot yet assume a decent shell, so we have to provide a
140# neutralization value for shells without unset; and this also
141# works around shells that cannot unset nonexistent variables.
142# Preserve -v and -x to the replacement shell.
143BASH_ENV=/dev/null
144ENV=/dev/null
145(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
146case $- in # ((((
147 *v*x* | *x*v* ) as_opts=-vx ;;
148 *v* ) as_opts=-v ;;
149 *x* ) as_opts=-x ;;
150 * ) as_opts= ;;
151esac
152exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
153# Admittedly, this is quite paranoid, since all the known shells bail
154# out after a failed `exec'.
155$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
156as_fn_exit 255
157 fi
158 # We don't want this to propagate to other subprocesses.
159 { _as_can_reexec=; unset _as_can_reexec;}
160if test "x$CONFIG_SHELL" = x; then
161 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
162 emulate sh
163 NULLCMD=:
164 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
165 # is contrary to our usage. Disable this feature.
166 alias -g '\${1+\"\$@\"}'='\"\$@\"'
167 setopt NO_GLOB_SUBST
168else
169 case \`(set -o) 2>/dev/null\` in #(
170 *posix*) :
171 set -o posix ;; #(
172 *) :
173 ;;
174esac
175fi
176"
177 as_required="as_fn_return () { (exit \$1); }
178as_fn_success () { as_fn_return 0; }
179as_fn_failure () { as_fn_return 1; }
180as_fn_ret_success () { return 0; }
181as_fn_ret_failure () { return 1; }
182
183exitcode=0
184as_fn_success || { exitcode=1; echo as_fn_success failed.; }
185as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
186as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
187as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
188if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
189
190else
191 exitcode=1; echo positional parameters were not saved.
192fi
193test x\$exitcode = x0 || exit 1
194test -x / || exit 1"
195 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
196 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
197 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
198 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
199test \$(( 1 + 1 )) = 2 || exit 1"
200 if (eval "$as_required") 2>/dev/null; then :
201 as_have_required=yes
202else
203 as_have_required=no
204fi
205 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
206
207else
208 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
209as_found=false
210for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
211do
212 IFS=$as_save_IFS
213 test -z "$as_dir" && as_dir=.
214 as_found=:
215 case $as_dir in #(
216 /*)
217 for as_base in sh bash ksh sh5; do
218 # Try only shells that exist, to save several forks.
219 as_shell=$as_dir/$as_base
220 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
221 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
222 CONFIG_SHELL=$as_shell as_have_required=yes
223 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
224 break 2
225fi
226fi
227 done;;
228 esac
229 as_found=false
230done
231$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
232 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
233 CONFIG_SHELL=$SHELL as_have_required=yes
234fi; }
235IFS=$as_save_IFS
236
237
238 if test "x$CONFIG_SHELL" != x; then :
239 export CONFIG_SHELL
240 # We cannot yet assume a decent shell, so we have to provide a
241# neutralization value for shells without unset; and this also
242# works around shells that cannot unset nonexistent variables.
243# Preserve -v and -x to the replacement shell.
244BASH_ENV=/dev/null
245ENV=/dev/null
246(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
247case $- in # ((((
248 *v*x* | *x*v* ) as_opts=-vx ;;
249 *v* ) as_opts=-v ;;
250 *x* ) as_opts=-x ;;
251 * ) as_opts= ;;
252esac
253exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
254# Admittedly, this is quite paranoid, since all the known shells bail
255# out after a failed `exec'.
256$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
257exit 255
258fi
259
260 if test x$as_have_required = xno; then :
261 $as_echo "$0: This script requires a shell more modern than all"
262 $as_echo "$0: the shells that I found on your system."
263 if test x${ZSH_VERSION+set} = xset ; then
264 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
265 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
266 else
267 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
268$0: including any error possibly output before this
269$0: message. Then install a modern shell, or manually run
270$0: the script under such a shell if you do have one."
271 fi
272 exit 1
273fi
274fi
275fi
276SHELL=${CONFIG_SHELL-/bin/sh}
277export SHELL
278# Unset more variables known to interfere with behavior of common tools.
279CLICOLOR_FORCE= GREP_OPTIONS=
280unset CLICOLOR_FORCE GREP_OPTIONS
281
282## --------------------- ##
283## M4sh Shell Functions. ##
284## --------------------- ##
285# as_fn_unset VAR
286# ---------------
287# Portably unset VAR.
288as_fn_unset ()
289{
290 { eval $1=; unset $1;}
291}
292as_unset=as_fn_unset
293
294# as_fn_set_status STATUS
295# -----------------------
296# Set $? to STATUS, without forking.
297as_fn_set_status ()
298{
299 return $1
300} # as_fn_set_status
301
302# as_fn_exit STATUS
303# -----------------
304# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
305as_fn_exit ()
306{
307 set +e
308 as_fn_set_status $1
309 exit $1
310} # as_fn_exit
311
312# as_fn_mkdir_p
313# -------------
314# Create "$as_dir" as a directory, including parents if necessary.
315as_fn_mkdir_p ()
316{
317
318 case $as_dir in #(
319 -*) as_dir=./$as_dir;;
320 esac
321 test -d "$as_dir" || eval $as_mkdir_p || {
322 as_dirs=
323 while :; do
324 case $as_dir in #(
325 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
326 *) as_qdir=$as_dir;;
327 esac
328 as_dirs="'$as_qdir' $as_dirs"
329 as_dir=`$as_dirname -- "$as_dir" ||
330$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
331 X"$as_dir" : 'X\(//\)[^/]' \| \
332 X"$as_dir" : 'X\(//\)$' \| \
333 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
334$as_echo X"$as_dir" |
335 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
336 s//\1/
337 q
338 }
339 /^X\(\/\/\)[^/].*/{
340 s//\1/
341 q
342 }
343 /^X\(\/\/\)$/{
344 s//\1/
345 q
346 }
347 /^X\(\/\).*/{
348 s//\1/
349 q
350 }
351 s/.*/./; q'`
352 test -d "$as_dir" && break
353 done
354 test -z "$as_dirs" || eval "mkdir $as_dirs"
355 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
356
357
358} # as_fn_mkdir_p
359
360# as_fn_executable_p FILE
361# -----------------------
362# Test if FILE is an executable regular file.
363as_fn_executable_p ()
364{
365 test -f "$1" && test -x "$1"
366} # as_fn_executable_p
367# as_fn_append VAR VALUE
368# ----------------------
369# Append the text in VALUE to the end of the definition contained in VAR. Take
370# advantage of any shell optimizations that allow amortized linear growth over
371# repeated appends, instead of the typical quadratic growth present in naive
372# implementations.
373if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
374 eval 'as_fn_append ()
375 {
376 eval $1+=\$2
377 }'
378else
379 as_fn_append ()
380 {
381 eval $1=\$$1\$2
382 }
383fi # as_fn_append
384
385# as_fn_arith ARG...
386# ------------------
387# Perform arithmetic evaluation on the ARGs, and store the result in the
388# global $as_val. Take advantage of shells that can avoid forks. The arguments
389# must be portable across $(()) and expr.
390if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
391 eval 'as_fn_arith ()
392 {
393 as_val=$(( $* ))
394 }'
395else
396 as_fn_arith ()
397 {
398 as_val=`expr "$@" || test $? -eq 1`
399 }
400fi # as_fn_arith
401
402
403# as_fn_error STATUS ERROR [LINENO LOG_FD]
404# ----------------------------------------
405# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
406# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
407# script with STATUS, using 1 if that was 0.
408as_fn_error ()
409{
410 as_status=$1; test $as_status -eq 0 && as_status=1
411 if test "$4"; then
412 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
413 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
414 fi
415 $as_echo "$as_me: error: $2" >&2
416 as_fn_exit $as_status
417} # as_fn_error
418
419if expr a : '\(a\)' >/dev/null 2>&1 &&
420 test "X`expr 00001 : '.*\(...\)'`" = X001; then
421 as_expr=expr
422else
423 as_expr=false
424fi
425
426if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
427 as_basename=basename
428else
429 as_basename=false
430fi
431
432if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
433 as_dirname=dirname
434else
435 as_dirname=false
436fi
437
438as_me=`$as_basename -- "$0" ||
439$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
440 X"$0" : 'X\(//\)$' \| \
441 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
442$as_echo X/"$0" |
443 sed '/^.*\/\([^/][^/]*\)\/*$/{
444 s//\1/
445 q
446 }
447 /^X\/\(\/\/\)$/{
448 s//\1/
449 q
450 }
451 /^X\/\(\/\).*/{
452 s//\1/
453 q
454 }
455 s/.*/./; q'`
456
457# Avoid depending upon Character Ranges.
458as_cr_letters='abcdefghijklmnopqrstuvwxyz'
459as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
460as_cr_Letters=$as_cr_letters$as_cr_LETTERS
461as_cr_digits='0123456789'
462as_cr_alnum=$as_cr_Letters$as_cr_digits
463
464
465 as_lineno_1=$LINENO as_lineno_1a=$LINENO
466 as_lineno_2=$LINENO as_lineno_2a=$LINENO
467 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
468 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
469 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
470 sed -n '
471 p
472 /[$]LINENO/=
473 ' <$as_myself |
474 sed '
475 s/[$]LINENO.*/&-/
476 t lineno
477 b
478 :lineno
479 N
480 :loop
481 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
482 t loop
483 s/-\n.*//
484 ' >$as_me.lineno &&
485 chmod +x "$as_me.lineno" ||
486 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
487
488 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
489 # already done that, so ensure we don't try to do so again and fall
490 # in an infinite loop. This has already happened in practice.
491 _as_can_reexec=no; export _as_can_reexec
492 # Don't try to exec as it changes $[0], causing all sort of problems
493 # (the dirname of $[0] is not the place where we might find the
494 # original and so on. Autoconf is especially sensitive to this).
495 . "./$as_me.lineno"
496 # Exit status is that of the last command.
497 exit
498}
499
500ECHO_C= ECHO_N= ECHO_T=
501case `echo -n x` in #(((((
502-n*)
503 case `echo 'xy\c'` in
504 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
505 xy) ECHO_C='\c';;
506 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
507 ECHO_T=' ';;
508 esac;;
509*)
510 ECHO_N='-n';;
511esac
512
513rm -f conf$$ conf$$.exe conf$$.file
514if test -d conf$$.dir; then
515 rm -f conf$$.dir/conf$$.file
516else
517 rm -f conf$$.dir
518 mkdir conf$$.dir 2>/dev/null
519fi
520if (echo >conf$$.file) 2>/dev/null; then
521 if ln -s conf$$.file conf$$ 2>/dev/null; then
522 as_ln_s='ln -s'
523 # ... but there are two gotchas:
524 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
525 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
526 # In both cases, we have to default to `cp -pR'.
527 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
528 as_ln_s='cp -pR'
529 elif ln conf$$.file conf$$ 2>/dev/null; then
530 as_ln_s=ln
531 else
532 as_ln_s='cp -pR'
533 fi
534else
535 as_ln_s='cp -pR'
536fi
537rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
538rmdir conf$$.dir 2>/dev/null
539
540if mkdir -p . 2>/dev/null; then
541 as_mkdir_p='mkdir -p "$as_dir"'
542else
543 test -d ./-p && rmdir ./-p
544 as_mkdir_p=false
545fi
546
547as_test_x='test -x'
548as_executable_p=as_fn_executable_p
549
550# Sed expression to map a string onto a valid CPP name.
551as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
552
553# Sed expression to map a string onto a valid variable name.
554as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
555
556
557test -n "$DJDIR" || exec 7<&0 </dev/null
558exec 6>&1
559
560# Name of the host.
561# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
562# so uname gets run too.
563ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
564
565#
566# Initializations.
567#
568ac_default_prefix=/usr/local
569ac_clean_files=
570ac_config_libobj_dir=.
571LIBOBJS=
572cross_compiling=no
573subdirs=
574MFLAGS=
575MAKEFLAGS=
576
577# Identity of this package.
578PACKAGE_NAME=
579PACKAGE_TARNAME=
580PACKAGE_VERSION=
581PACKAGE_STRING=
582PACKAGE_BUGREPORT=
583PACKAGE_URL=
584
585ac_unique_file="Makefile.in"
586# Factoring default headers for most tests.
587ac_includes_default="\
588#include <stdio.h>
589#ifdef HAVE_SYS_TYPES_H
590# include <sys/types.h>
591#endif
592#ifdef HAVE_SYS_STAT_H
593# include <sys/stat.h>
594#endif
595#ifdef STDC_HEADERS
596# include <stdlib.h>
597# include <stddef.h>
598#else
599# ifdef HAVE_STDLIB_H
600# include <stdlib.h>
601# endif
602#endif
603#ifdef HAVE_STRING_H
604# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
605# include <memory.h>
606# endif
607# include <string.h>
608#endif
609#ifdef HAVE_STRINGS_H
610# include <strings.h>
611#endif
612#ifdef HAVE_INTTYPES_H
613# include <inttypes.h>
614#endif
615#ifdef HAVE_STDINT_H
616# include <stdint.h>
617#endif
618#ifdef HAVE_UNISTD_H
619# include <unistd.h>
620#endif"
621
622ac_subst_vars='LTLIBOBJS
623LIBOBJS
624cfgoutputs_out
625cfgoutputs_in
626cfghdrs_out
627cfghdrs_in
628enable_zone_allocator
629enable_tls
630enable_lazy_lock
54a0048b 631TESTLIBS
970d7e83
LB
632jemalloc_version_gid
633jemalloc_version_nrev
634jemalloc_version_bugfix
635jemalloc_version_minor
636jemalloc_version_major
637jemalloc_version
54a0048b 638enable_cache_oblivious
970d7e83
LB
639enable_xmalloc
640enable_valgrind
641enable_utrace
642enable_fill
970d7e83 643enable_munmap
970d7e83
LB
644enable_tcache
645enable_prof
646enable_stats
647enable_debug
1a4d82fc 648je_
970d7e83 649install_suffix
1a4d82fc 650private_namespace
54a0048b 651JEMALLOC_CPREFIX
1a4d82fc 652enable_code_coverage
970d7e83
LB
653AUTOCONF
654LD
970d7e83
LB
655RANLIB
656INSTALL_DATA
657INSTALL_SCRIPT
658INSTALL_PROGRAM
659enable_autogen
660RPATH_EXTRA
661CC_MM
1a4d82fc
JJ
662AROUT
663ARFLAGS
970d7e83
LB
664MKLIB
665LDTARGET
666CTARGET
667PIC_CFLAGS
668SOREV
669EXTRA_LDFLAGS
670DSO_LDFLAGS
671libprefix
672exe
673a
674o
675importlib
676so
677LD_PRELOAD_VAR
678RPATH
679abi
1a4d82fc 680AR
970d7e83
LB
681host_os
682host_vendor
683host_cpu
684host
685build_os
686build_vendor
687build_cpu
688build
689EGREP
690GREP
691CPP
692OBJEXT
693EXEEXT
694ac_ct_CC
695CPPFLAGS
696LDFLAGS
697CFLAGS
698CC
699XSLROOT
700XSLTPROC
701MANDIR
702DATADIR
703LIBDIR
704INCLUDEDIR
705BINDIR
706PREFIX
707abs_objroot
708objroot
709abs_srcroot
710srcroot
711rev
54a0048b 712CONFIG
970d7e83
LB
713target_alias
714host_alias
715build_alias
716LIBS
717ECHO_T
718ECHO_N
719ECHO_C
720DEFS
721mandir
722localedir
723libdir
724psdir
725pdfdir
726dvidir
727htmldir
728infodir
729docdir
730oldincludedir
731includedir
732localstatedir
733sharedstatedir
734sysconfdir
735datadir
736datarootdir
737libexecdir
738sbindir
739bindir
740program_transform_name
741prefix
742exec_prefix
743PACKAGE_URL
744PACKAGE_BUGREPORT
745PACKAGE_STRING
746PACKAGE_VERSION
747PACKAGE_TARNAME
748PACKAGE_NAME
749PATH_SEPARATOR
750SHELL'
751ac_subst_files=''
752ac_user_opts='
753enable_option_checking
754with_xslroot
755with_rpath
756enable_autogen
1a4d82fc 757enable_code_coverage
970d7e83
LB
758with_mangling
759with_jemalloc_prefix
760with_export
761with_private_namespace
762with_install_suffix
54a0048b 763with_malloc_conf
970d7e83
LB
764enable_cc_silence
765enable_debug
766enable_ivsalloc
767enable_stats
768enable_prof
769enable_prof_libunwind
770with_static_libunwind
771enable_prof_libgcc
772enable_prof_gcc
773enable_tcache
970d7e83 774enable_munmap
970d7e83
LB
775enable_fill
776enable_utrace
777enable_valgrind
778enable_xmalloc
54a0048b
SL
779enable_cache_oblivious
780with_lg_tiny_min
781with_lg_quantum
782with_lg_page
783with_lg_page_sizes
784with_lg_size_class_group
970d7e83
LB
785enable_lazy_lock
786enable_tls
787enable_zone_allocator
788'
789 ac_precious_vars='build_alias
790host_alias
791target_alias
792CC
793CFLAGS
794LDFLAGS
795LIBS
796CPPFLAGS
797CPP'
798
799
800# Initialize some variables set by options.
801ac_init_help=
802ac_init_version=false
803ac_unrecognized_opts=
804ac_unrecognized_sep=
805# The variables have the same names as the options, with
806# dashes changed to underlines.
807cache_file=/dev/null
808exec_prefix=NONE
809no_create=
810no_recursion=
811prefix=NONE
812program_prefix=NONE
813program_suffix=NONE
814program_transform_name=s,x,x,
815silent=
816site=
817srcdir=
818verbose=
819x_includes=NONE
820x_libraries=NONE
821
822# Installation directory options.
823# These are left unexpanded so users can "make install exec_prefix=/foo"
824# and all the variables that are supposed to be based on exec_prefix
825# by default will actually change.
826# Use braces instead of parens because sh, perl, etc. also accept them.
827# (The list follows the same order as the GNU Coding Standards.)
828bindir='${exec_prefix}/bin'
829sbindir='${exec_prefix}/sbin'
830libexecdir='${exec_prefix}/libexec'
831datarootdir='${prefix}/share'
832datadir='${datarootdir}'
833sysconfdir='${prefix}/etc'
834sharedstatedir='${prefix}/com'
835localstatedir='${prefix}/var'
836includedir='${prefix}/include'
837oldincludedir='/usr/include'
838docdir='${datarootdir}/doc/${PACKAGE}'
839infodir='${datarootdir}/info'
840htmldir='${docdir}'
841dvidir='${docdir}'
842pdfdir='${docdir}'
843psdir='${docdir}'
844libdir='${exec_prefix}/lib'
845localedir='${datarootdir}/locale'
846mandir='${datarootdir}/man'
847
848ac_prev=
849ac_dashdash=
850for ac_option
851do
852 # If the previous option needs an argument, assign it.
853 if test -n "$ac_prev"; then
854 eval $ac_prev=\$ac_option
855 ac_prev=
856 continue
857 fi
858
859 case $ac_option in
860 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
861 *=) ac_optarg= ;;
862 *) ac_optarg=yes ;;
863 esac
864
865 # Accept the important Cygnus configure options, so we can diagnose typos.
866
867 case $ac_dashdash$ac_option in
868 --)
869 ac_dashdash=yes ;;
870
871 -bindir | --bindir | --bindi | --bind | --bin | --bi)
872 ac_prev=bindir ;;
873 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
874 bindir=$ac_optarg ;;
875
876 -build | --build | --buil | --bui | --bu)
877 ac_prev=build_alias ;;
878 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
879 build_alias=$ac_optarg ;;
880
881 -cache-file | --cache-file | --cache-fil | --cache-fi \
882 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
883 ac_prev=cache_file ;;
884 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
885 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
886 cache_file=$ac_optarg ;;
887
888 --config-cache | -C)
889 cache_file=config.cache ;;
890
891 -datadir | --datadir | --datadi | --datad)
892 ac_prev=datadir ;;
893 -datadir=* | --datadir=* | --datadi=* | --datad=*)
894 datadir=$ac_optarg ;;
895
896 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
897 | --dataroo | --dataro | --datar)
898 ac_prev=datarootdir ;;
899 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
900 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
901 datarootdir=$ac_optarg ;;
902
903 -disable-* | --disable-*)
904 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
905 # Reject names that are not valid shell variable names.
906 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
907 as_fn_error $? "invalid feature name: $ac_useropt"
908 ac_useropt_orig=$ac_useropt
909 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
910 case $ac_user_opts in
911 *"
912"enable_$ac_useropt"
913"*) ;;
914 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
915 ac_unrecognized_sep=', ';;
916 esac
917 eval enable_$ac_useropt=no ;;
918
919 -docdir | --docdir | --docdi | --doc | --do)
920 ac_prev=docdir ;;
921 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
922 docdir=$ac_optarg ;;
923
924 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
925 ac_prev=dvidir ;;
926 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
927 dvidir=$ac_optarg ;;
928
929 -enable-* | --enable-*)
930 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
931 # Reject names that are not valid shell variable names.
932 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
933 as_fn_error $? "invalid feature name: $ac_useropt"
934 ac_useropt_orig=$ac_useropt
935 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
936 case $ac_user_opts in
937 *"
938"enable_$ac_useropt"
939"*) ;;
940 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
941 ac_unrecognized_sep=', ';;
942 esac
943 eval enable_$ac_useropt=\$ac_optarg ;;
944
945 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
946 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
947 | --exec | --exe | --ex)
948 ac_prev=exec_prefix ;;
949 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
950 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
951 | --exec=* | --exe=* | --ex=*)
952 exec_prefix=$ac_optarg ;;
953
954 -gas | --gas | --ga | --g)
955 # Obsolete; use --with-gas.
956 with_gas=yes ;;
957
958 -help | --help | --hel | --he | -h)
959 ac_init_help=long ;;
960 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
961 ac_init_help=recursive ;;
962 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
963 ac_init_help=short ;;
964
965 -host | --host | --hos | --ho)
966 ac_prev=host_alias ;;
967 -host=* | --host=* | --hos=* | --ho=*)
968 host_alias=$ac_optarg ;;
969
970 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
971 ac_prev=htmldir ;;
972 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
973 | --ht=*)
974 htmldir=$ac_optarg ;;
975
976 -includedir | --includedir | --includedi | --included | --include \
977 | --includ | --inclu | --incl | --inc)
978 ac_prev=includedir ;;
979 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
980 | --includ=* | --inclu=* | --incl=* | --inc=*)
981 includedir=$ac_optarg ;;
982
983 -infodir | --infodir | --infodi | --infod | --info | --inf)
984 ac_prev=infodir ;;
985 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
986 infodir=$ac_optarg ;;
987
988 -libdir | --libdir | --libdi | --libd)
989 ac_prev=libdir ;;
990 -libdir=* | --libdir=* | --libdi=* | --libd=*)
991 libdir=$ac_optarg ;;
992
993 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
994 | --libexe | --libex | --libe)
995 ac_prev=libexecdir ;;
996 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
997 | --libexe=* | --libex=* | --libe=*)
998 libexecdir=$ac_optarg ;;
999
1000 -localedir | --localedir | --localedi | --localed | --locale)
1001 ac_prev=localedir ;;
1002 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1003 localedir=$ac_optarg ;;
1004
1005 -localstatedir | --localstatedir | --localstatedi | --localstated \
1006 | --localstate | --localstat | --localsta | --localst | --locals)
1007 ac_prev=localstatedir ;;
1008 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1009 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1010 localstatedir=$ac_optarg ;;
1011
1012 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1013 ac_prev=mandir ;;
1014 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1015 mandir=$ac_optarg ;;
1016
1017 -nfp | --nfp | --nf)
1018 # Obsolete; use --without-fp.
1019 with_fp=no ;;
1020
1021 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1022 | --no-cr | --no-c | -n)
1023 no_create=yes ;;
1024
1025 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1026 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1027 no_recursion=yes ;;
1028
1029 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1030 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1031 | --oldin | --oldi | --old | --ol | --o)
1032 ac_prev=oldincludedir ;;
1033 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1034 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1035 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1036 oldincludedir=$ac_optarg ;;
1037
1038 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1039 ac_prev=prefix ;;
1040 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1041 prefix=$ac_optarg ;;
1042
1043 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1044 | --program-pre | --program-pr | --program-p)
1045 ac_prev=program_prefix ;;
1046 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1047 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1048 program_prefix=$ac_optarg ;;
1049
1050 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1051 | --program-suf | --program-su | --program-s)
1052 ac_prev=program_suffix ;;
1053 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1054 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1055 program_suffix=$ac_optarg ;;
1056
1057 -program-transform-name | --program-transform-name \
1058 | --program-transform-nam | --program-transform-na \
1059 | --program-transform-n | --program-transform- \
1060 | --program-transform | --program-transfor \
1061 | --program-transfo | --program-transf \
1062 | --program-trans | --program-tran \
1063 | --progr-tra | --program-tr | --program-t)
1064 ac_prev=program_transform_name ;;
1065 -program-transform-name=* | --program-transform-name=* \
1066 | --program-transform-nam=* | --program-transform-na=* \
1067 | --program-transform-n=* | --program-transform-=* \
1068 | --program-transform=* | --program-transfor=* \
1069 | --program-transfo=* | --program-transf=* \
1070 | --program-trans=* | --program-tran=* \
1071 | --progr-tra=* | --program-tr=* | --program-t=*)
1072 program_transform_name=$ac_optarg ;;
1073
1074 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1075 ac_prev=pdfdir ;;
1076 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1077 pdfdir=$ac_optarg ;;
1078
1079 -psdir | --psdir | --psdi | --psd | --ps)
1080 ac_prev=psdir ;;
1081 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1082 psdir=$ac_optarg ;;
1083
1084 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1085 | -silent | --silent | --silen | --sile | --sil)
1086 silent=yes ;;
1087
1088 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1089 ac_prev=sbindir ;;
1090 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1091 | --sbi=* | --sb=*)
1092 sbindir=$ac_optarg ;;
1093
1094 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1095 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1096 | --sharedst | --shareds | --shared | --share | --shar \
1097 | --sha | --sh)
1098 ac_prev=sharedstatedir ;;
1099 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1100 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1101 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1102 | --sha=* | --sh=*)
1103 sharedstatedir=$ac_optarg ;;
1104
1105 -site | --site | --sit)
1106 ac_prev=site ;;
1107 -site=* | --site=* | --sit=*)
1108 site=$ac_optarg ;;
1109
1110 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1111 ac_prev=srcdir ;;
1112 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1113 srcdir=$ac_optarg ;;
1114
1115 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1116 | --syscon | --sysco | --sysc | --sys | --sy)
1117 ac_prev=sysconfdir ;;
1118 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1119 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1120 sysconfdir=$ac_optarg ;;
1121
1122 -target | --target | --targe | --targ | --tar | --ta | --t)
1123 ac_prev=target_alias ;;
1124 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1125 target_alias=$ac_optarg ;;
1126
1127 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1128 verbose=yes ;;
1129
1130 -version | --version | --versio | --versi | --vers | -V)
1131 ac_init_version=: ;;
1132
1133 -with-* | --with-*)
1134 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1135 # Reject names that are not valid shell variable names.
1136 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1137 as_fn_error $? "invalid package name: $ac_useropt"
1138 ac_useropt_orig=$ac_useropt
1139 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1140 case $ac_user_opts in
1141 *"
1142"with_$ac_useropt"
1143"*) ;;
1144 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1145 ac_unrecognized_sep=', ';;
1146 esac
1147 eval with_$ac_useropt=\$ac_optarg ;;
1148
1149 -without-* | --without-*)
1150 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1151 # Reject names that are not valid shell variable names.
1152 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1153 as_fn_error $? "invalid package name: $ac_useropt"
1154 ac_useropt_orig=$ac_useropt
1155 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1156 case $ac_user_opts in
1157 *"
1158"with_$ac_useropt"
1159"*) ;;
1160 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1161 ac_unrecognized_sep=', ';;
1162 esac
1163 eval with_$ac_useropt=no ;;
1164
1165 --x)
1166 # Obsolete; use --with-x.
1167 with_x=yes ;;
1168
1169 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1170 | --x-incl | --x-inc | --x-in | --x-i)
1171 ac_prev=x_includes ;;
1172 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1173 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1174 x_includes=$ac_optarg ;;
1175
1176 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1177 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1178 ac_prev=x_libraries ;;
1179 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1180 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1181 x_libraries=$ac_optarg ;;
1182
1183 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1184Try \`$0 --help' for more information"
1185 ;;
1186
1187 *=*)
1188 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1189 # Reject names that are not valid shell variable names.
1190 case $ac_envvar in #(
1191 '' | [0-9]* | *[!_$as_cr_alnum]* )
1192 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1193 esac
1194 eval $ac_envvar=\$ac_optarg
1195 export $ac_envvar ;;
1196
1197 *)
1198 # FIXME: should be removed in autoconf 3.0.
1199 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1200 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1201 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1202 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1203 ;;
1204
1205 esac
1206done
1207
1208if test -n "$ac_prev"; then
1209 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1210 as_fn_error $? "missing argument to $ac_option"
1211fi
1212
1213if test -n "$ac_unrecognized_opts"; then
1214 case $enable_option_checking in
1215 no) ;;
1216 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1217 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1218 esac
1219fi
1220
1221# Check all directory arguments for consistency.
1222for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1223 datadir sysconfdir sharedstatedir localstatedir includedir \
1224 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1225 libdir localedir mandir
1226do
1227 eval ac_val=\$$ac_var
1228 # Remove trailing slashes.
1229 case $ac_val in
1230 */ )
1231 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1232 eval $ac_var=\$ac_val;;
1233 esac
1234 # Be sure to have absolute directory names.
1235 case $ac_val in
1236 [\\/$]* | ?:[\\/]* ) continue;;
1237 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1238 esac
1239 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1240done
1241
1242# There might be people who depend on the old broken behavior: `$host'
1243# used to hold the argument of --host etc.
1244# FIXME: To remove some day.
1245build=$build_alias
1246host=$host_alias
1247target=$target_alias
1248
1249# FIXME: To remove some day.
1250if test "x$host_alias" != x; then
1251 if test "x$build_alias" = x; then
1252 cross_compiling=maybe
1253 elif test "x$build_alias" != "x$host_alias"; then
1254 cross_compiling=yes
1255 fi
1256fi
1257
1258ac_tool_prefix=
1259test -n "$host_alias" && ac_tool_prefix=$host_alias-
1260
1261test "$silent" = yes && exec 6>/dev/null
1262
1263
1264ac_pwd=`pwd` && test -n "$ac_pwd" &&
1265ac_ls_di=`ls -di .` &&
1266ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1267 as_fn_error $? "working directory cannot be determined"
1268test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1269 as_fn_error $? "pwd does not report name of working directory"
1270
1271
1272# Find the source files, if location was not specified.
1273if test -z "$srcdir"; then
1274 ac_srcdir_defaulted=yes
1275 # Try the directory containing this script, then the parent directory.
1276 ac_confdir=`$as_dirname -- "$as_myself" ||
1277$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1278 X"$as_myself" : 'X\(//\)[^/]' \| \
1279 X"$as_myself" : 'X\(//\)$' \| \
1280 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1281$as_echo X"$as_myself" |
1282 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1283 s//\1/
1284 q
1285 }
1286 /^X\(\/\/\)[^/].*/{
1287 s//\1/
1288 q
1289 }
1290 /^X\(\/\/\)$/{
1291 s//\1/
1292 q
1293 }
1294 /^X\(\/\).*/{
1295 s//\1/
1296 q
1297 }
1298 s/.*/./; q'`
1299 srcdir=$ac_confdir
1300 if test ! -r "$srcdir/$ac_unique_file"; then
1301 srcdir=..
1302 fi
1303else
1304 ac_srcdir_defaulted=no
1305fi
1306if test ! -r "$srcdir/$ac_unique_file"; then
1307 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1308 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1309fi
1310ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1311ac_abs_confdir=`(
1312 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1313 pwd)`
1314# When building in place, set srcdir=.
1315if test "$ac_abs_confdir" = "$ac_pwd"; then
1316 srcdir=.
1317fi
1318# Remove unnecessary trailing slashes from srcdir.
1319# Double slashes in file names in object file debugging info
1320# mess up M-x gdb in Emacs.
1321case $srcdir in
1322*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1323esac
1324for ac_var in $ac_precious_vars; do
1325 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1326 eval ac_env_${ac_var}_value=\$${ac_var}
1327 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1328 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1329done
1330
1331#
1332# Report the --help message.
1333#
1334if test "$ac_init_help" = "long"; then
1335 # Omit some internal or obsolete options to make the list less imposing.
1336 # This message is too long to be a string in the A/UX 3.1 sh.
1337 cat <<_ACEOF
1338\`configure' configures this package to adapt to many kinds of systems.
1339
1340Usage: $0 [OPTION]... [VAR=VALUE]...
1341
1342To assign environment variables (e.g., CC, CFLAGS...), specify them as
1343VAR=VALUE. See below for descriptions of some of the useful variables.
1344
1345Defaults for the options are specified in brackets.
1346
1347Configuration:
1348 -h, --help display this help and exit
1349 --help=short display options specific to this package
1350 --help=recursive display the short help of all the included packages
1351 -V, --version display version information and exit
1352 -q, --quiet, --silent do not print \`checking ...' messages
1353 --cache-file=FILE cache test results in FILE [disabled]
1354 -C, --config-cache alias for \`--cache-file=config.cache'
1355 -n, --no-create do not create output files
1356 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1357
1358Installation directories:
1359 --prefix=PREFIX install architecture-independent files in PREFIX
1360 [$ac_default_prefix]
1361 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1362 [PREFIX]
1363
1364By default, \`make install' will install all the files in
1365\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1366an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1367for instance \`--prefix=\$HOME'.
1368
1369For better control, use the options below.
1370
1371Fine tuning of the installation directories:
1372 --bindir=DIR user executables [EPREFIX/bin]
1373 --sbindir=DIR system admin executables [EPREFIX/sbin]
1374 --libexecdir=DIR program executables [EPREFIX/libexec]
1375 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1376 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1377 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1378 --libdir=DIR object code libraries [EPREFIX/lib]
1379 --includedir=DIR C header files [PREFIX/include]
1380 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1381 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1382 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1383 --infodir=DIR info documentation [DATAROOTDIR/info]
1384 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1385 --mandir=DIR man documentation [DATAROOTDIR/man]
1386 --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE]
1387 --htmldir=DIR html documentation [DOCDIR]
1388 --dvidir=DIR dvi documentation [DOCDIR]
1389 --pdfdir=DIR pdf documentation [DOCDIR]
1390 --psdir=DIR ps documentation [DOCDIR]
1391_ACEOF
1392
1393 cat <<\_ACEOF
1394
1395System types:
1396 --build=BUILD configure for building on BUILD [guessed]
1397 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1398_ACEOF
1399fi
1400
1401if test -n "$ac_init_help"; then
1402
1403 cat <<\_ACEOF
1404
1405Optional Features:
1406 --disable-option-checking ignore unrecognized --enable/--with options
1407 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1408 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1409 --enable-autogen Automatically regenerate configure output
1a4d82fc
JJ
1410 --enable-code-coverage Enable code coverage
1411 --disable-cc-silence Do not silence irrelevant compiler warnings
970d7e83
LB
1412 --enable-debug Build debugging code (implies --enable-ivsalloc)
1413 --enable-ivsalloc Validate pointers passed through the public API
1414 --disable-stats Disable statistics calculation/reporting
1415 --enable-prof Enable allocation profiling
1416 --enable-prof-libunwind Use libunwind for backtracing
1417 --disable-prof-libgcc Do not use libgcc for backtracing
1418 --disable-prof-gcc Do not use gcc intrinsics for backtracing
1419 --disable-tcache Disable per thread caches
970d7e83 1420 --disable-munmap Disable VM deallocation via munmap(2)
970d7e83
LB
1421 --disable-fill Disable support for junk/zero filling, quarantine,
1422 and redzones
1423 --enable-utrace Enable utrace(2)-based tracing
1424 --disable-valgrind Disable support for Valgrind
1425 --enable-xmalloc Support xmalloc option
54a0048b
SL
1426 --disable-cache-oblivious
1427 Disable support for cache-oblivious allocation
1428 alignment
970d7e83
LB
1429 --enable-lazy-lock Enable lazy locking (only lock when multi-threaded)
1430 --disable-tls Disable thread-local storage (__thread keyword)
1431 --disable-zone-allocator
1432 Disable zone allocator for Darwin
1433
1434Optional Packages:
1435 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1436 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1437 --with-xslroot=<path> XSL stylesheet root path
1438 --with-rpath=<rpath> Colon-separated rpath (ELF systems only)
1439 --with-mangling=<map> Mangle symbols in <map>
1440 --with-jemalloc-prefix=<prefix>
1441 Prefix to prepend to all public APIs
1442 --without-export disable exporting jemalloc public APIs
1443 --with-private-namespace=<prefix>
1444 Prefix to prepend to all library-private APIs
1445 --with-install-suffix=<suffix>
1446 Suffix to append to all installed files
54a0048b
SL
1447 --with-malloc-conf=<malloc_conf>
1448 config.malloc_conf options string
970d7e83
LB
1449 --with-static-libunwind=<libunwind.a>
1450 Path to static libunwind library; use rather than
1451 dynamically linking
54a0048b
SL
1452 --with-lg-tiny-min=<lg-tiny-min>
1453 Base 2 log of minimum tiny size class to support
1454 --with-lg-quantum=<lg-quantum>
1455 Base 2 log of minimum allocation alignment
1456 --with-lg-page=<lg-page>
1457 Base 2 log of system page size
1458 --with-lg-page-sizes=<lg-page-sizes>
1459 Base 2 logs of system page sizes to support
1460 --with-lg-size-class-group=<lg-size-class-group>
1461 Base 2 log of size classes per doubling
970d7e83
LB
1462
1463Some influential environment variables:
1464 CC C compiler command
1465 CFLAGS C compiler flags
1466 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1467 nonstandard directory <lib dir>
1468 LIBS libraries to pass to the linker, e.g. -l<library>
1469 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1470 you have headers in a nonstandard directory <include dir>
1471 CPP C preprocessor
1472
1473Use these variables to override the choices made by `configure' or to help
1474it to find libraries and programs with nonstandard names/locations.
1475
1476Report bugs to the package provider.
1477_ACEOF
1478ac_status=$?
1479fi
1480
1481if test "$ac_init_help" = "recursive"; then
1482 # If there are subdirs, report their specific --help.
1483 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1484 test -d "$ac_dir" ||
1485 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1486 continue
1487 ac_builddir=.
1488
1489case "$ac_dir" in
1490.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1491*)
1492 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1493 # A ".." for each directory in $ac_dir_suffix.
1494 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1495 case $ac_top_builddir_sub in
1496 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1497 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1498 esac ;;
1499esac
1500ac_abs_top_builddir=$ac_pwd
1501ac_abs_builddir=$ac_pwd$ac_dir_suffix
1502# for backward compatibility:
1503ac_top_builddir=$ac_top_build_prefix
1504
1505case $srcdir in
1506 .) # We are building in place.
1507 ac_srcdir=.
1508 ac_top_srcdir=$ac_top_builddir_sub
1509 ac_abs_top_srcdir=$ac_pwd ;;
1510 [\\/]* | ?:[\\/]* ) # Absolute name.
1511 ac_srcdir=$srcdir$ac_dir_suffix;
1512 ac_top_srcdir=$srcdir
1513 ac_abs_top_srcdir=$srcdir ;;
1514 *) # Relative name.
1515 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1516 ac_top_srcdir=$ac_top_build_prefix$srcdir
1517 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1518esac
1519ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1520
1521 cd "$ac_dir" || { ac_status=$?; continue; }
1522 # Check for guested configure.
1523 if test -f "$ac_srcdir/configure.gnu"; then
1524 echo &&
1525 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1526 elif test -f "$ac_srcdir/configure"; then
1527 echo &&
1528 $SHELL "$ac_srcdir/configure" --help=recursive
1529 else
1530 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1531 fi || ac_status=$?
1532 cd "$ac_pwd" || { ac_status=$?; break; }
1533 done
1534fi
1535
1536test -n "$ac_init_help" && exit $ac_status
1537if $ac_init_version; then
1538 cat <<\_ACEOF
1539configure
1540generated by GNU Autoconf 2.69
1541
1542Copyright (C) 2012 Free Software Foundation, Inc.
1543This configure script is free software; the Free Software Foundation
1544gives unlimited permission to copy, distribute and modify it.
1545_ACEOF
1546 exit
1547fi
1548
1549## ------------------------ ##
1550## Autoconf initialization. ##
1551## ------------------------ ##
1552
1553# ac_fn_c_try_compile LINENO
1554# --------------------------
1555# Try to compile conftest.$ac_ext, and return whether this succeeded.
1556ac_fn_c_try_compile ()
1557{
1558 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1559 rm -f conftest.$ac_objext
1560 if { { ac_try="$ac_compile"
1561case "(($ac_try" in
1562 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1563 *) ac_try_echo=$ac_try;;
1564esac
1565eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1566$as_echo "$ac_try_echo"; } >&5
1567 (eval "$ac_compile") 2>conftest.err
1568 ac_status=$?
1569 if test -s conftest.err; then
1570 grep -v '^ *+' conftest.err >conftest.er1
1571 cat conftest.er1 >&5
1572 mv -f conftest.er1 conftest.err
1573 fi
1574 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1575 test $ac_status = 0; } && {
1576 test -z "$ac_c_werror_flag" ||
1577 test ! -s conftest.err
1578 } && test -s conftest.$ac_objext; then :
1579 ac_retval=0
1580else
1581 $as_echo "$as_me: failed program was:" >&5
1582sed 's/^/| /' conftest.$ac_ext >&5
1583
1584 ac_retval=1
1585fi
1586 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1587 as_fn_set_status $ac_retval
1588
1589} # ac_fn_c_try_compile
1590
1591# ac_fn_c_try_cpp LINENO
1592# ----------------------
1593# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1594ac_fn_c_try_cpp ()
1595{
1596 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1597 if { { ac_try="$ac_cpp conftest.$ac_ext"
1598case "(($ac_try" in
1599 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1600 *) ac_try_echo=$ac_try;;
1601esac
1602eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1603$as_echo "$ac_try_echo"; } >&5
1604 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1605 ac_status=$?
1606 if test -s conftest.err; then
1607 grep -v '^ *+' conftest.err >conftest.er1
1608 cat conftest.er1 >&5
1609 mv -f conftest.er1 conftest.err
1610 fi
1611 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1612 test $ac_status = 0; } > conftest.i && {
1613 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1614 test ! -s conftest.err
1615 }; then :
1616 ac_retval=0
1617else
1618 $as_echo "$as_me: failed program was:" >&5
1619sed 's/^/| /' conftest.$ac_ext >&5
1620
1621 ac_retval=1
1622fi
1623 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1624 as_fn_set_status $ac_retval
1625
1626} # ac_fn_c_try_cpp
1627
1628# ac_fn_c_try_run LINENO
1629# ----------------------
1630# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1631# that executables *can* be run.
1632ac_fn_c_try_run ()
1633{
1634 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1635 if { { ac_try="$ac_link"
1636case "(($ac_try" in
1637 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1638 *) ac_try_echo=$ac_try;;
1639esac
1640eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1641$as_echo "$ac_try_echo"; } >&5
1642 (eval "$ac_link") 2>&5
1643 ac_status=$?
1644 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1645 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1646 { { case "(($ac_try" in
1647 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1648 *) ac_try_echo=$ac_try;;
1649esac
1650eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1651$as_echo "$ac_try_echo"; } >&5
1652 (eval "$ac_try") 2>&5
1653 ac_status=$?
1654 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1655 test $ac_status = 0; }; }; then :
1656 ac_retval=0
1657else
1658 $as_echo "$as_me: program exited with status $ac_status" >&5
1659 $as_echo "$as_me: failed program was:" >&5
1660sed 's/^/| /' conftest.$ac_ext >&5
1661
1662 ac_retval=$ac_status
1663fi
1664 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1665 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1666 as_fn_set_status $ac_retval
1667
1668} # ac_fn_c_try_run
1669
1a4d82fc
JJ
1670# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1671# -------------------------------------------------------
1672# Tests whether HEADER exists and can be compiled using the include files in
1673# INCLUDES, setting the cache variable VAR accordingly.
1674ac_fn_c_check_header_compile ()
1675{
1676 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1678$as_echo_n "checking for $2... " >&6; }
1679if eval \${$3+:} false; then :
1680 $as_echo_n "(cached) " >&6
1681else
1682 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1683/* end confdefs.h. */
1684$4
1685#include <$2>
1686_ACEOF
1687if ac_fn_c_try_compile "$LINENO"; then :
1688 eval "$3=yes"
1689else
1690 eval "$3=no"
1691fi
1692rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1693fi
1694eval ac_res=\$$3
1695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1696$as_echo "$ac_res" >&6; }
1697 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1698
1699} # ac_fn_c_check_header_compile
1700
970d7e83
LB
1701# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
1702# --------------------------------------------
1703# Tries to find the compile-time value of EXPR in a program that includes
1704# INCLUDES, setting VAR accordingly. Returns whether the value could be
1705# computed
1706ac_fn_c_compute_int ()
1707{
1708 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1709 if test "$cross_compiling" = yes; then
1710 # Depending upon the size, compute the lo and hi bounds.
1711cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1712/* end confdefs.h. */
1713$4
1714int
1715main ()
1716{
1717static int test_array [1 - 2 * !(($2) >= 0)];
1718test_array [0] = 0;
1719return test_array [0];
1720
1721 ;
1722 return 0;
1723}
1724_ACEOF
1725if ac_fn_c_try_compile "$LINENO"; then :
1726 ac_lo=0 ac_mid=0
1727 while :; do
1728 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1729/* end confdefs.h. */
1730$4
1731int
1732main ()
1733{
1734static int test_array [1 - 2 * !(($2) <= $ac_mid)];
1735test_array [0] = 0;
1736return test_array [0];
1737
1738 ;
1739 return 0;
1740}
1741_ACEOF
1742if ac_fn_c_try_compile "$LINENO"; then :
1743 ac_hi=$ac_mid; break
1744else
1745 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
1746 if test $ac_lo -le $ac_mid; then
1747 ac_lo= ac_hi=
1748 break
1749 fi
1750 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
1751fi
1752rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1753 done
1754else
1755 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1756/* end confdefs.h. */
1757$4
1758int
1759main ()
1760{
1761static int test_array [1 - 2 * !(($2) < 0)];
1762test_array [0] = 0;
1763return test_array [0];
1764
1765 ;
1766 return 0;
1767}
1768_ACEOF
1769if ac_fn_c_try_compile "$LINENO"; then :
1770 ac_hi=-1 ac_mid=-1
1771 while :; do
1772 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1773/* end confdefs.h. */
1774$4
1775int
1776main ()
1777{
1778static int test_array [1 - 2 * !(($2) >= $ac_mid)];
1779test_array [0] = 0;
1780return test_array [0];
1781
1782 ;
1783 return 0;
1784}
1785_ACEOF
1786if ac_fn_c_try_compile "$LINENO"; then :
1787 ac_lo=$ac_mid; break
1788else
1789 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
1790 if test $ac_mid -le $ac_hi; then
1791 ac_lo= ac_hi=
1792 break
1793 fi
1794 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
1795fi
1796rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1797 done
1798else
1799 ac_lo= ac_hi=
1800fi
1801rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1802fi
1803rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1804# Binary search between lo and hi bounds.
1805while test "x$ac_lo" != "x$ac_hi"; do
1806 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
1807 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1808/* end confdefs.h. */
1809$4
1810int
1811main ()
1812{
1813static int test_array [1 - 2 * !(($2) <= $ac_mid)];
1814test_array [0] = 0;
1815return test_array [0];
1816
1817 ;
1818 return 0;
1819}
1820_ACEOF
1821if ac_fn_c_try_compile "$LINENO"; then :
1822 ac_hi=$ac_mid
1823else
1824 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
1825fi
1826rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1827done
1828case $ac_lo in #((
1829?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
1830'') ac_retval=1 ;;
1831esac
1832 else
1833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1834/* end confdefs.h. */
1835$4
1836static long int longval () { return $2; }
1837static unsigned long int ulongval () { return $2; }
1838#include <stdio.h>
1839#include <stdlib.h>
1840int
1841main ()
1842{
1843
1844 FILE *f = fopen ("conftest.val", "w");
1845 if (! f)
1846 return 1;
1847 if (($2) < 0)
1848 {
1849 long int i = longval ();
1850 if (i != ($2))
1851 return 1;
1852 fprintf (f, "%ld", i);
1853 }
1854 else
1855 {
1856 unsigned long int i = ulongval ();
1857 if (i != ($2))
1858 return 1;
1859 fprintf (f, "%lu", i);
1860 }
1861 /* Do not output a trailing newline, as this causes \r\n confusion
1862 on some platforms. */
1863 return ferror (f) || fclose (f) != 0;
1864
1865 ;
1866 return 0;
1867}
1868_ACEOF
1869if ac_fn_c_try_run "$LINENO"; then :
1870 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
1871else
1872 ac_retval=1
1873fi
1874rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
1875 conftest.$ac_objext conftest.beam conftest.$ac_ext
1876rm -f conftest.val
1877
1878 fi
1879 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1880 as_fn_set_status $ac_retval
1881
1882} # ac_fn_c_compute_int
1883
970d7e83
LB
1884# ac_fn_c_try_link LINENO
1885# -----------------------
1886# Try to link conftest.$ac_ext, and return whether this succeeded.
1887ac_fn_c_try_link ()
1888{
1889 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1890 rm -f conftest.$ac_objext conftest$ac_exeext
1891 if { { ac_try="$ac_link"
1892case "(($ac_try" in
1893 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1894 *) ac_try_echo=$ac_try;;
1895esac
1896eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1897$as_echo "$ac_try_echo"; } >&5
1898 (eval "$ac_link") 2>conftest.err
1899 ac_status=$?
1900 if test -s conftest.err; then
1901 grep -v '^ *+' conftest.err >conftest.er1
1902 cat conftest.er1 >&5
1903 mv -f conftest.er1 conftest.err
1904 fi
1905 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1906 test $ac_status = 0; } && {
1907 test -z "$ac_c_werror_flag" ||
1908 test ! -s conftest.err
1909 } && test -s conftest$ac_exeext && {
1910 test "$cross_compiling" = yes ||
1911 test -x conftest$ac_exeext
1912 }; then :
1913 ac_retval=0
1914else
1915 $as_echo "$as_me: failed program was:" >&5
1916sed 's/^/| /' conftest.$ac_ext >&5
1917
1918 ac_retval=1
1919fi
1920 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1921 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1922 # interfere with the next link command; also delete a directory that is
1923 # left behind by Apple's compiler. We do this before executing the actions.
1924 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1925 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1926 as_fn_set_status $ac_retval
1927
1928} # ac_fn_c_try_link
1929
970d7e83
LB
1930# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1931# -------------------------------------------------------
1932# Tests whether HEADER exists, giving a warning if it cannot be compiled using
1933# the include files in INCLUDES and setting the cache variable VAR
1934# accordingly.
1935ac_fn_c_check_header_mongrel ()
1936{
1937 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1938 if eval \${$3+:} false; then :
1939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1940$as_echo_n "checking for $2... " >&6; }
1941if eval \${$3+:} false; then :
1942 $as_echo_n "(cached) " >&6
1943fi
1944eval ac_res=\$$3
1945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1946$as_echo "$ac_res" >&6; }
1947else
1948 # Is the header compilable?
1949{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1950$as_echo_n "checking $2 usability... " >&6; }
1951cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1952/* end confdefs.h. */
1953$4
1954#include <$2>
1955_ACEOF
1956if ac_fn_c_try_compile "$LINENO"; then :
1957 ac_header_compiler=yes
1958else
1959 ac_header_compiler=no
1960fi
1961rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1962{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1963$as_echo "$ac_header_compiler" >&6; }
1964
1965# Is the header present?
1966{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1967$as_echo_n "checking $2 presence... " >&6; }
1968cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1969/* end confdefs.h. */
1970#include <$2>
1971_ACEOF
1972if ac_fn_c_try_cpp "$LINENO"; then :
1973 ac_header_preproc=yes
1974else
1975 ac_header_preproc=no
1976fi
1977rm -f conftest.err conftest.i conftest.$ac_ext
1978{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1979$as_echo "$ac_header_preproc" >&6; }
1980
1981# So? What about this header?
1982case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1983 yes:no: )
1984 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1985$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1986 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1987$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1988 ;;
1989 no:yes:* )
1990 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1991$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1992 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
1993$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
1994 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1995$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1996 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
1997$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
1998 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1999$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2000 ;;
2001esac
2002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2003$as_echo_n "checking for $2... " >&6; }
2004if eval \${$3+:} false; then :
2005 $as_echo_n "(cached) " >&6
2006else
2007 eval "$3=\$ac_header_compiler"
2008fi
2009eval ac_res=\$$3
2010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2011$as_echo "$ac_res" >&6; }
2012fi
2013 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2014
2015} # ac_fn_c_check_header_mongrel
2016
1a4d82fc
JJ
2017# ac_fn_c_check_func LINENO FUNC VAR
2018# ----------------------------------
2019# Tests whether FUNC exists, setting the cache variable VAR accordingly
2020ac_fn_c_check_func ()
2021{
2022 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2024$as_echo_n "checking for $2... " >&6; }
2025if eval \${$3+:} false; then :
2026 $as_echo_n "(cached) " >&6
2027else
2028 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2029/* end confdefs.h. */
2030/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2031 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2032#define $2 innocuous_$2
2033
2034/* System header to define __stub macros and hopefully few prototypes,
2035 which can conflict with char $2 (); below.
2036 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2037 <limits.h> exists even on freestanding compilers. */
2038
2039#ifdef __STDC__
2040# include <limits.h>
2041#else
2042# include <assert.h>
2043#endif
2044
2045#undef $2
2046
2047/* Override any GCC internal prototype to avoid an error.
2048 Use char because int might match the return type of a GCC
2049 builtin and then its argument prototype would still apply. */
2050#ifdef __cplusplus
2051extern "C"
2052#endif
2053char $2 ();
2054/* The GNU C library defines this for functions which it implements
2055 to always fail with ENOSYS. Some functions are actually named
2056 something starting with __ and the normal name is an alias. */
2057#if defined __stub_$2 || defined __stub___$2
2058choke me
2059#endif
2060
2061int
2062main ()
2063{
2064return $2 ();
2065 ;
2066 return 0;
2067}
2068_ACEOF
2069if ac_fn_c_try_link "$LINENO"; then :
2070 eval "$3=yes"
2071else
2072 eval "$3=no"
2073fi
2074rm -f core conftest.err conftest.$ac_objext \
2075 conftest$ac_exeext conftest.$ac_ext
2076fi
2077eval ac_res=\$$3
2078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2079$as_echo "$ac_res" >&6; }
2080 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2081
2082} # ac_fn_c_check_func
2083
970d7e83
LB
2084# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2085# -------------------------------------------
2086# Tests whether TYPE exists after having included INCLUDES, setting cache
2087# variable VAR accordingly.
2088ac_fn_c_check_type ()
2089{
2090 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2092$as_echo_n "checking for $2... " >&6; }
2093if eval \${$3+:} false; then :
2094 $as_echo_n "(cached) " >&6
2095else
2096 eval "$3=no"
2097 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2098/* end confdefs.h. */
2099$4
2100int
2101main ()
2102{
2103if (sizeof ($2))
2104 return 0;
2105 ;
2106 return 0;
2107}
2108_ACEOF
2109if ac_fn_c_try_compile "$LINENO"; then :
2110 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2111/* end confdefs.h. */
2112$4
2113int
2114main ()
2115{
2116if (sizeof (($2)))
2117 return 0;
2118 ;
2119 return 0;
2120}
2121_ACEOF
2122if ac_fn_c_try_compile "$LINENO"; then :
2123
2124else
2125 eval "$3=yes"
2126fi
2127rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2128fi
2129rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2130fi
2131eval ac_res=\$$3
2132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2133$as_echo "$ac_res" >&6; }
2134 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2135
2136} # ac_fn_c_check_type
2137cat >config.log <<_ACEOF
2138This file contains any messages produced by compilers while
2139running configure, to aid debugging if configure makes a mistake.
2140
2141It was created by $as_me, which was
2142generated by GNU Autoconf 2.69. Invocation command line was
2143
2144 $ $0 $@
2145
2146_ACEOF
2147exec 5>>config.log
2148{
2149cat <<_ASUNAME
2150## --------- ##
2151## Platform. ##
2152## --------- ##
2153
2154hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2155uname -m = `(uname -m) 2>/dev/null || echo unknown`
2156uname -r = `(uname -r) 2>/dev/null || echo unknown`
2157uname -s = `(uname -s) 2>/dev/null || echo unknown`
2158uname -v = `(uname -v) 2>/dev/null || echo unknown`
2159
2160/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2161/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2162
2163/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2164/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2165/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2166/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2167/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2168/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2169/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2170
2171_ASUNAME
2172
2173as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2174for as_dir in $PATH
2175do
2176 IFS=$as_save_IFS
2177 test -z "$as_dir" && as_dir=.
2178 $as_echo "PATH: $as_dir"
2179 done
2180IFS=$as_save_IFS
2181
2182} >&5
2183
2184cat >&5 <<_ACEOF
2185
2186
2187## ----------- ##
2188## Core tests. ##
2189## ----------- ##
2190
2191_ACEOF
2192
2193
2194# Keep a trace of the command line.
2195# Strip out --no-create and --no-recursion so they do not pile up.
2196# Strip out --silent because we don't want to record it for future runs.
2197# Also quote any args containing shell meta-characters.
2198# Make two passes to allow for proper duplicate-argument suppression.
2199ac_configure_args=
2200ac_configure_args0=
2201ac_configure_args1=
2202ac_must_keep_next=false
2203for ac_pass in 1 2
2204do
2205 for ac_arg
2206 do
2207 case $ac_arg in
2208 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2209 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2210 | -silent | --silent | --silen | --sile | --sil)
2211 continue ;;
2212 *\'*)
2213 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2214 esac
2215 case $ac_pass in
2216 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2217 2)
2218 as_fn_append ac_configure_args1 " '$ac_arg'"
2219 if test $ac_must_keep_next = true; then
2220 ac_must_keep_next=false # Got value, back to normal.
2221 else
2222 case $ac_arg in
2223 *=* | --config-cache | -C | -disable-* | --disable-* \
2224 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2225 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2226 | -with-* | --with-* | -without-* | --without-* | --x)
2227 case "$ac_configure_args0 " in
2228 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2229 esac
2230 ;;
2231 -* ) ac_must_keep_next=true ;;
2232 esac
2233 fi
2234 as_fn_append ac_configure_args " '$ac_arg'"
2235 ;;
2236 esac
2237 done
2238done
2239{ ac_configure_args0=; unset ac_configure_args0;}
2240{ ac_configure_args1=; unset ac_configure_args1;}
2241
2242# When interrupted or exit'd, cleanup temporary files, and complete
2243# config.log. We remove comments because anyway the quotes in there
2244# would cause problems or look ugly.
2245# WARNING: Use '\'' to represent an apostrophe within the trap.
2246# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2247trap 'exit_status=$?
2248 # Save into config.log some information that might help in debugging.
2249 {
2250 echo
2251
2252 $as_echo "## ---------------- ##
2253## Cache variables. ##
2254## ---------------- ##"
2255 echo
2256 # The following way of writing the cache mishandles newlines in values,
2257(
2258 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2259 eval ac_val=\$$ac_var
2260 case $ac_val in #(
2261 *${as_nl}*)
2262 case $ac_var in #(
2263 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2264$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2265 esac
2266 case $ac_var in #(
2267 _ | IFS | as_nl) ;; #(
2268 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2269 *) { eval $ac_var=; unset $ac_var;} ;;
2270 esac ;;
2271 esac
2272 done
2273 (set) 2>&1 |
2274 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2275 *${as_nl}ac_space=\ *)
2276 sed -n \
2277 "s/'\''/'\''\\\\'\'''\''/g;
2278 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2279 ;; #(
2280 *)
2281 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2282 ;;
2283 esac |
2284 sort
2285)
2286 echo
2287
2288 $as_echo "## ----------------- ##
2289## Output variables. ##
2290## ----------------- ##"
2291 echo
2292 for ac_var in $ac_subst_vars
2293 do
2294 eval ac_val=\$$ac_var
2295 case $ac_val in
2296 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2297 esac
2298 $as_echo "$ac_var='\''$ac_val'\''"
2299 done | sort
2300 echo
2301
2302 if test -n "$ac_subst_files"; then
2303 $as_echo "## ------------------- ##
2304## File substitutions. ##
2305## ------------------- ##"
2306 echo
2307 for ac_var in $ac_subst_files
2308 do
2309 eval ac_val=\$$ac_var
2310 case $ac_val in
2311 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2312 esac
2313 $as_echo "$ac_var='\''$ac_val'\''"
2314 done | sort
2315 echo
2316 fi
2317
2318 if test -s confdefs.h; then
2319 $as_echo "## ----------- ##
2320## confdefs.h. ##
2321## ----------- ##"
2322 echo
2323 cat confdefs.h
2324 echo
2325 fi
2326 test "$ac_signal" != 0 &&
2327 $as_echo "$as_me: caught signal $ac_signal"
2328 $as_echo "$as_me: exit $exit_status"
2329 } >&5
2330 rm -f core *.core core.conftest.* &&
2331 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2332 exit $exit_status
2333' 0
2334for ac_signal in 1 2 13 15; do
2335 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2336done
2337ac_signal=0
2338
2339# confdefs.h avoids OS command line length limits that DEFS can exceed.
2340rm -f -r conftest* confdefs.h
2341
2342$as_echo "/* confdefs.h */" > confdefs.h
2343
2344# Predefined preprocessor variables.
2345
2346cat >>confdefs.h <<_ACEOF
2347#define PACKAGE_NAME "$PACKAGE_NAME"
2348_ACEOF
2349
2350cat >>confdefs.h <<_ACEOF
2351#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2352_ACEOF
2353
2354cat >>confdefs.h <<_ACEOF
2355#define PACKAGE_VERSION "$PACKAGE_VERSION"
2356_ACEOF
2357
2358cat >>confdefs.h <<_ACEOF
2359#define PACKAGE_STRING "$PACKAGE_STRING"
2360_ACEOF
2361
2362cat >>confdefs.h <<_ACEOF
2363#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2364_ACEOF
2365
2366cat >>confdefs.h <<_ACEOF
2367#define PACKAGE_URL "$PACKAGE_URL"
2368_ACEOF
2369
2370
2371# Let the site file select an alternate cache file if it wants to.
2372# Prefer an explicitly selected file to automatically selected ones.
2373ac_site_file1=NONE
2374ac_site_file2=NONE
2375if test -n "$CONFIG_SITE"; then
2376 # We do not want a PATH search for config.site.
2377 case $CONFIG_SITE in #((
2378 -*) ac_site_file1=./$CONFIG_SITE;;
2379 */*) ac_site_file1=$CONFIG_SITE;;
2380 *) ac_site_file1=./$CONFIG_SITE;;
2381 esac
2382elif test "x$prefix" != xNONE; then
2383 ac_site_file1=$prefix/share/config.site
2384 ac_site_file2=$prefix/etc/config.site
2385else
2386 ac_site_file1=$ac_default_prefix/share/config.site
2387 ac_site_file2=$ac_default_prefix/etc/config.site
2388fi
2389for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2390do
2391 test "x$ac_site_file" = xNONE && continue
2392 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2393 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2394$as_echo "$as_me: loading site script $ac_site_file" >&6;}
2395 sed 's/^/| /' "$ac_site_file" >&5
2396 . "$ac_site_file" \
2397 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2398$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2399as_fn_error $? "failed to load site script $ac_site_file
2400See \`config.log' for more details" "$LINENO" 5; }
2401 fi
2402done
2403
2404if test -r "$cache_file"; then
2405 # Some versions of bash will fail to source /dev/null (special files
2406 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2407 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2408 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2409$as_echo "$as_me: loading cache $cache_file" >&6;}
2410 case $cache_file in
2411 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2412 *) . "./$cache_file";;
2413 esac
2414 fi
2415else
2416 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2417$as_echo "$as_me: creating cache $cache_file" >&6;}
2418 >$cache_file
2419fi
2420
2421# Check that the precious variables saved in the cache have kept the same
2422# value.
2423ac_cache_corrupted=false
2424for ac_var in $ac_precious_vars; do
2425 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2426 eval ac_new_set=\$ac_env_${ac_var}_set
2427 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2428 eval ac_new_val=\$ac_env_${ac_var}_value
2429 case $ac_old_set,$ac_new_set in
2430 set,)
2431 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2432$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2433 ac_cache_corrupted=: ;;
2434 ,set)
2435 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2436$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2437 ac_cache_corrupted=: ;;
2438 ,);;
2439 *)
2440 if test "x$ac_old_val" != "x$ac_new_val"; then
2441 # differences in whitespace do not lead to failure.
2442 ac_old_val_w=`echo x $ac_old_val`
2443 ac_new_val_w=`echo x $ac_new_val`
2444 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2445 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2446$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2447 ac_cache_corrupted=:
2448 else
2449 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2450$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2451 eval $ac_var=\$ac_old_val
2452 fi
2453 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2454$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2455 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2456$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2457 fi;;
2458 esac
2459 # Pass precious variables to config.status.
2460 if test "$ac_new_set" = set; then
2461 case $ac_new_val in
2462 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2463 *) ac_arg=$ac_var=$ac_new_val ;;
2464 esac
2465 case " $ac_configure_args " in
2466 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2467 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2468 esac
2469 fi
2470done
2471if $ac_cache_corrupted; then
2472 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2473$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2474 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2475$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2476 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2477fi
2478## -------------------- ##
2479## Main body of script. ##
2480## -------------------- ##
2481
2482ac_ext=c
2483ac_cpp='$CPP $CPPFLAGS'
2484ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2485ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2486ac_compiler_gnu=$ac_cv_c_compiler_gnu
2487
2488
2489
54a0048b
SL
2490ac_aux_dir=
2491for ac_dir in build-aux "$srcdir"/build-aux; do
2492 if test -f "$ac_dir/install-sh"; then
2493 ac_aux_dir=$ac_dir
2494 ac_install_sh="$ac_aux_dir/install-sh -c"
2495 break
2496 elif test -f "$ac_dir/install.sh"; then
2497 ac_aux_dir=$ac_dir
2498 ac_install_sh="$ac_aux_dir/install.sh -c"
2499 break
2500 elif test -f "$ac_dir/shtool"; then
2501 ac_aux_dir=$ac_dir
2502 ac_install_sh="$ac_aux_dir/shtool install -c"
2503 break
2504 fi
2505done
2506if test -z "$ac_aux_dir"; then
2507 as_fn_error $? "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
2508fi
2509
2510# These three variables are undocumented and unsupported,
2511# and are intended to be withdrawn in a future Autoconf release.
2512# They can cause serious problems if a builder's source tree is in a directory
2513# whose full name contains unusual characters.
2514ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
2515ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
2516ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
2517
2518
2519
2520
970d7e83
LB
2521
2522
2523
2524
2525
54a0048b
SL
2526CONFIG=`echo ${ac_configure_args} | sed -e 's#'"'"'\([^ ]*\)'"'"'#\1#g'`
2527
970d7e83 2528
1a4d82fc 2529rev=2
970d7e83
LB
2530
2531
2532srcroot=$srcdir
2533if test "x${srcroot}" = "x." ; then
2534 srcroot=""
2535else
2536 srcroot="${srcroot}/"
2537fi
2538
2539abs_srcroot="`cd \"${srcdir}\"; pwd`/"
2540
2541
2542objroot=""
2543
2544abs_objroot="`pwd`/"
2545
2546
2547if test "x$prefix" = "xNONE" ; then
2548 prefix="/usr/local"
2549fi
2550if test "x$exec_prefix" = "xNONE" ; then
2551 exec_prefix=$prefix
2552fi
2553PREFIX=$prefix
2554
2555BINDIR=`eval echo $bindir`
2556BINDIR=`eval echo $BINDIR`
2557
2558INCLUDEDIR=`eval echo $includedir`
2559INCLUDEDIR=`eval echo $INCLUDEDIR`
2560
2561LIBDIR=`eval echo $libdir`
2562LIBDIR=`eval echo $LIBDIR`
2563
2564DATADIR=`eval echo $datadir`
2565DATADIR=`eval echo $DATADIR`
2566
2567MANDIR=`eval echo $mandir`
2568MANDIR=`eval echo $MANDIR`
2569
2570
2571# Extract the first word of "xsltproc", so it can be a program name with args.
2572set dummy xsltproc; ac_word=$2
2573{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2574$as_echo_n "checking for $ac_word... " >&6; }
2575if ${ac_cv_path_XSLTPROC+:} false; then :
2576 $as_echo_n "(cached) " >&6
2577else
2578 case $XSLTPROC in
2579 [\\/]* | ?:[\\/]*)
2580 ac_cv_path_XSLTPROC="$XSLTPROC" # Let the user override the test with a path.
2581 ;;
2582 *)
2583 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2584for as_dir in $PATH
2585do
2586 IFS=$as_save_IFS
2587 test -z "$as_dir" && as_dir=.
2588 for ac_exec_ext in '' $ac_executable_extensions; do
2589 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2590 ac_cv_path_XSLTPROC="$as_dir/$ac_word$ac_exec_ext"
2591 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2592 break 2
2593 fi
2594done
2595 done
2596IFS=$as_save_IFS
2597
2598 test -z "$ac_cv_path_XSLTPROC" && ac_cv_path_XSLTPROC="false"
2599 ;;
2600esac
2601fi
2602XSLTPROC=$ac_cv_path_XSLTPROC
2603if test -n "$XSLTPROC"; then
2604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XSLTPROC" >&5
2605$as_echo "$XSLTPROC" >&6; }
2606else
2607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2608$as_echo "no" >&6; }
2609fi
2610
2611
2612if test -d "/usr/share/xml/docbook/stylesheet/docbook-xsl" ; then
2613 DEFAULT_XSLROOT="/usr/share/xml/docbook/stylesheet/docbook-xsl"
2614elif test -d "/usr/share/sgml/docbook/xsl-stylesheets" ; then
2615 DEFAULT_XSLROOT="/usr/share/sgml/docbook/xsl-stylesheets"
2616else
2617 DEFAULT_XSLROOT=""
2618fi
2619
2620# Check whether --with-xslroot was given.
2621if test "${with_xslroot+set}" = set; then :
2622 withval=$with_xslroot;
2623if test "x$with_xslroot" = "xno" ; then
2624 XSLROOT="${DEFAULT_XSLROOT}"
2625else
2626 XSLROOT="${with_xslroot}"
2627fi
2628
2629else
2630 XSLROOT="${DEFAULT_XSLROOT}"
2631
2632fi
2633
2634
2635
2636CFLAGS=$CFLAGS
2637ac_ext=c
2638ac_cpp='$CPP $CPPFLAGS'
2639ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2640ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2641ac_compiler_gnu=$ac_cv_c_compiler_gnu
2642if test -n "$ac_tool_prefix"; then
2643 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2644set dummy ${ac_tool_prefix}gcc; ac_word=$2
2645{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2646$as_echo_n "checking for $ac_word... " >&6; }
2647if ${ac_cv_prog_CC+:} false; then :
2648 $as_echo_n "(cached) " >&6
2649else
2650 if test -n "$CC"; then
2651 ac_cv_prog_CC="$CC" # Let the user override the test.
2652else
2653as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2654for as_dir in $PATH
2655do
2656 IFS=$as_save_IFS
2657 test -z "$as_dir" && as_dir=.
2658 for ac_exec_ext in '' $ac_executable_extensions; do
2659 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2660 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2661 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2662 break 2
2663 fi
2664done
2665 done
2666IFS=$as_save_IFS
2667
2668fi
2669fi
2670CC=$ac_cv_prog_CC
2671if test -n "$CC"; then
2672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2673$as_echo "$CC" >&6; }
2674else
2675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2676$as_echo "no" >&6; }
2677fi
2678
2679
2680fi
2681if test -z "$ac_cv_prog_CC"; then
2682 ac_ct_CC=$CC
2683 # Extract the first word of "gcc", so it can be a program name with args.
2684set dummy gcc; ac_word=$2
2685{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2686$as_echo_n "checking for $ac_word... " >&6; }
2687if ${ac_cv_prog_ac_ct_CC+:} false; then :
2688 $as_echo_n "(cached) " >&6
2689else
2690 if test -n "$ac_ct_CC"; then
2691 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2692else
2693as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2694for as_dir in $PATH
2695do
2696 IFS=$as_save_IFS
2697 test -z "$as_dir" && as_dir=.
2698 for ac_exec_ext in '' $ac_executable_extensions; do
2699 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2700 ac_cv_prog_ac_ct_CC="gcc"
2701 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2702 break 2
2703 fi
2704done
2705 done
2706IFS=$as_save_IFS
2707
2708fi
2709fi
2710ac_ct_CC=$ac_cv_prog_ac_ct_CC
2711if test -n "$ac_ct_CC"; then
2712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2713$as_echo "$ac_ct_CC" >&6; }
2714else
2715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2716$as_echo "no" >&6; }
2717fi
2718
2719 if test "x$ac_ct_CC" = x; then
2720 CC=""
2721 else
2722 case $cross_compiling:$ac_tool_warned in
2723yes:)
2724{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2725$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2726ac_tool_warned=yes ;;
2727esac
2728 CC=$ac_ct_CC
2729 fi
2730else
2731 CC="$ac_cv_prog_CC"
2732fi
2733
2734if test -z "$CC"; then
2735 if test -n "$ac_tool_prefix"; then
2736 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2737set dummy ${ac_tool_prefix}cc; ac_word=$2
2738{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2739$as_echo_n "checking for $ac_word... " >&6; }
2740if ${ac_cv_prog_CC+:} false; then :
2741 $as_echo_n "(cached) " >&6
2742else
2743 if test -n "$CC"; then
2744 ac_cv_prog_CC="$CC" # Let the user override the test.
2745else
2746as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2747for as_dir in $PATH
2748do
2749 IFS=$as_save_IFS
2750 test -z "$as_dir" && as_dir=.
2751 for ac_exec_ext in '' $ac_executable_extensions; do
2752 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2753 ac_cv_prog_CC="${ac_tool_prefix}cc"
2754 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2755 break 2
2756 fi
2757done
2758 done
2759IFS=$as_save_IFS
2760
2761fi
2762fi
2763CC=$ac_cv_prog_CC
2764if test -n "$CC"; then
2765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2766$as_echo "$CC" >&6; }
2767else
2768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2769$as_echo "no" >&6; }
2770fi
2771
2772
2773 fi
2774fi
2775if test -z "$CC"; then
2776 # Extract the first word of "cc", so it can be a program name with args.
2777set dummy cc; ac_word=$2
2778{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2779$as_echo_n "checking for $ac_word... " >&6; }
2780if ${ac_cv_prog_CC+:} false; then :
2781 $as_echo_n "(cached) " >&6
2782else
2783 if test -n "$CC"; then
2784 ac_cv_prog_CC="$CC" # Let the user override the test.
2785else
2786 ac_prog_rejected=no
2787as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2788for as_dir in $PATH
2789do
2790 IFS=$as_save_IFS
2791 test -z "$as_dir" && as_dir=.
2792 for ac_exec_ext in '' $ac_executable_extensions; do
2793 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2794 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2795 ac_prog_rejected=yes
2796 continue
2797 fi
2798 ac_cv_prog_CC="cc"
2799 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2800 break 2
2801 fi
2802done
2803 done
2804IFS=$as_save_IFS
2805
2806if test $ac_prog_rejected = yes; then
2807 # We found a bogon in the path, so make sure we never use it.
2808 set dummy $ac_cv_prog_CC
2809 shift
2810 if test $# != 0; then
2811 # We chose a different compiler from the bogus one.
2812 # However, it has the same basename, so the bogon will be chosen
2813 # first if we set CC to just the basename; use the full file name.
2814 shift
2815 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
2816 fi
2817fi
2818fi
2819fi
2820CC=$ac_cv_prog_CC
2821if test -n "$CC"; then
2822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2823$as_echo "$CC" >&6; }
2824else
2825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2826$as_echo "no" >&6; }
2827fi
2828
2829
2830fi
2831if test -z "$CC"; then
2832 if test -n "$ac_tool_prefix"; then
2833 for ac_prog in cl.exe
2834 do
2835 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2836set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2837{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2838$as_echo_n "checking for $ac_word... " >&6; }
2839if ${ac_cv_prog_CC+:} false; then :
2840 $as_echo_n "(cached) " >&6
2841else
2842 if test -n "$CC"; then
2843 ac_cv_prog_CC="$CC" # Let the user override the test.
2844else
2845as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2846for as_dir in $PATH
2847do
2848 IFS=$as_save_IFS
2849 test -z "$as_dir" && as_dir=.
2850 for ac_exec_ext in '' $ac_executable_extensions; do
2851 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2852 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2853 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2854 break 2
2855 fi
2856done
2857 done
2858IFS=$as_save_IFS
2859
2860fi
2861fi
2862CC=$ac_cv_prog_CC
2863if test -n "$CC"; then
2864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2865$as_echo "$CC" >&6; }
2866else
2867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2868$as_echo "no" >&6; }
2869fi
2870
2871
2872 test -n "$CC" && break
2873 done
2874fi
2875if test -z "$CC"; then
2876 ac_ct_CC=$CC
2877 for ac_prog in cl.exe
2878do
2879 # Extract the first word of "$ac_prog", so it can be a program name with args.
2880set dummy $ac_prog; ac_word=$2
2881{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2882$as_echo_n "checking for $ac_word... " >&6; }
2883if ${ac_cv_prog_ac_ct_CC+:} false; then :
2884 $as_echo_n "(cached) " >&6
2885else
2886 if test -n "$ac_ct_CC"; then
2887 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2888else
2889as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2890for as_dir in $PATH
2891do
2892 IFS=$as_save_IFS
2893 test -z "$as_dir" && as_dir=.
2894 for ac_exec_ext in '' $ac_executable_extensions; do
2895 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2896 ac_cv_prog_ac_ct_CC="$ac_prog"
2897 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2898 break 2
2899 fi
2900done
2901 done
2902IFS=$as_save_IFS
2903
2904fi
2905fi
2906ac_ct_CC=$ac_cv_prog_ac_ct_CC
2907if test -n "$ac_ct_CC"; then
2908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2909$as_echo "$ac_ct_CC" >&6; }
2910else
2911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2912$as_echo "no" >&6; }
2913fi
2914
2915
2916 test -n "$ac_ct_CC" && break
2917done
2918
2919 if test "x$ac_ct_CC" = x; then
2920 CC=""
2921 else
2922 case $cross_compiling:$ac_tool_warned in
2923yes:)
2924{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2925$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2926ac_tool_warned=yes ;;
2927esac
2928 CC=$ac_ct_CC
2929 fi
2930fi
2931
2932fi
2933
2934
2935test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2936$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2937as_fn_error $? "no acceptable C compiler found in \$PATH
2938See \`config.log' for more details" "$LINENO" 5; }
2939
2940# Provide some information about the compiler.
2941$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
2942set X $ac_compile
2943ac_compiler=$2
2944for ac_option in --version -v -V -qversion; do
2945 { { ac_try="$ac_compiler $ac_option >&5"
2946case "(($ac_try" in
2947 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2948 *) ac_try_echo=$ac_try;;
2949esac
2950eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2951$as_echo "$ac_try_echo"; } >&5
2952 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
2953 ac_status=$?
2954 if test -s conftest.err; then
2955 sed '10a\
2956... rest of stderr output deleted ...
2957 10q' conftest.err >conftest.er1
2958 cat conftest.er1 >&5
2959 fi
2960 rm -f conftest.er1 conftest.err
2961 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2962 test $ac_status = 0; }
2963done
2964
2965cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2966/* end confdefs.h. */
2967
2968int
2969main ()
2970{
2971
2972 ;
2973 return 0;
2974}
2975_ACEOF
2976ac_clean_files_save=$ac_clean_files
2977ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
2978# Try to create an executable without -o first, disregard a.out.
2979# It will help us diagnose broken compilers, and finding out an intuition
2980# of exeext.
2981{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
2982$as_echo_n "checking whether the C compiler works... " >&6; }
2983ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2984
2985# The possible output files:
2986ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
2987
2988ac_rmfiles=
2989for ac_file in $ac_files
2990do
2991 case $ac_file in
2992 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
2993 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
2994 esac
2995done
2996rm -f $ac_rmfiles
2997
2998if { { ac_try="$ac_link_default"
2999case "(($ac_try" in
3000 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3001 *) ac_try_echo=$ac_try;;
3002esac
3003eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3004$as_echo "$ac_try_echo"; } >&5
3005 (eval "$ac_link_default") 2>&5
3006 ac_status=$?
3007 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3008 test $ac_status = 0; }; then :
3009 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3010# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3011# in a Makefile. We should not override ac_cv_exeext if it was cached,
3012# so that the user can short-circuit this test for compilers unknown to
3013# Autoconf.
3014for ac_file in $ac_files ''
3015do
3016 test -f "$ac_file" || continue
3017 case $ac_file in
3018 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3019 ;;
3020 [ab].out )
3021 # We found the default executable, but exeext='' is most
3022 # certainly right.
3023 break;;
3024 *.* )
3025 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3026 then :; else
3027 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3028 fi
3029 # We set ac_cv_exeext here because the later test for it is not
3030 # safe: cross compilers may not add the suffix if given an `-o'
3031 # argument, so we may need to know it at that point already.
3032 # Even if this section looks crufty: it has the advantage of
3033 # actually working.
3034 break;;
3035 * )
3036 break;;
3037 esac
3038done
3039test "$ac_cv_exeext" = no && ac_cv_exeext=
3040
3041else
3042 ac_file=''
3043fi
3044if test -z "$ac_file"; then :
3045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3046$as_echo "no" >&6; }
3047$as_echo "$as_me: failed program was:" >&5
3048sed 's/^/| /' conftest.$ac_ext >&5
3049
3050{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3051$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3052as_fn_error 77 "C compiler cannot create executables
3053See \`config.log' for more details" "$LINENO" 5; }
3054else
3055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3056$as_echo "yes" >&6; }
3057fi
3058{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3059$as_echo_n "checking for C compiler default output file name... " >&6; }
3060{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3061$as_echo "$ac_file" >&6; }
3062ac_exeext=$ac_cv_exeext
3063
3064rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3065ac_clean_files=$ac_clean_files_save
3066{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3067$as_echo_n "checking for suffix of executables... " >&6; }
3068if { { ac_try="$ac_link"
3069case "(($ac_try" in
3070 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3071 *) ac_try_echo=$ac_try;;
3072esac
3073eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3074$as_echo "$ac_try_echo"; } >&5
3075 (eval "$ac_link") 2>&5
3076 ac_status=$?
3077 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3078 test $ac_status = 0; }; then :
3079 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3080# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3081# work properly (i.e., refer to `conftest.exe'), while it won't with
3082# `rm'.
3083for ac_file in conftest.exe conftest conftest.*; do
3084 test -f "$ac_file" || continue
3085 case $ac_file in
3086 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3087 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3088 break;;
3089 * ) break;;
3090 esac
3091done
3092else
3093 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3094$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3095as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3096See \`config.log' for more details" "$LINENO" 5; }
3097fi
3098rm -f conftest conftest$ac_cv_exeext
3099{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3100$as_echo "$ac_cv_exeext" >&6; }
3101
3102rm -f conftest.$ac_ext
3103EXEEXT=$ac_cv_exeext
3104ac_exeext=$EXEEXT
3105cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3106/* end confdefs.h. */
3107#include <stdio.h>
3108int
3109main ()
3110{
3111FILE *f = fopen ("conftest.out", "w");
3112 return ferror (f) || fclose (f) != 0;
3113
3114 ;
3115 return 0;
3116}
3117_ACEOF
3118ac_clean_files="$ac_clean_files conftest.out"
3119# Check that the compiler produces executables we can run. If not, either
3120# the compiler is broken, or we cross compile.
3121{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3122$as_echo_n "checking whether we are cross compiling... " >&6; }
3123if test "$cross_compiling" != yes; then
3124 { { ac_try="$ac_link"
3125case "(($ac_try" in
3126 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3127 *) ac_try_echo=$ac_try;;
3128esac
3129eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3130$as_echo "$ac_try_echo"; } >&5
3131 (eval "$ac_link") 2>&5
3132 ac_status=$?
3133 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3134 test $ac_status = 0; }
3135 if { ac_try='./conftest$ac_cv_exeext'
3136 { { case "(($ac_try" in
3137 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3138 *) ac_try_echo=$ac_try;;
3139esac
3140eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3141$as_echo "$ac_try_echo"; } >&5
3142 (eval "$ac_try") 2>&5
3143 ac_status=$?
3144 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3145 test $ac_status = 0; }; }; then
3146 cross_compiling=no
3147 else
3148 if test "$cross_compiling" = maybe; then
3149 cross_compiling=yes
3150 else
3151 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3152$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3153as_fn_error $? "cannot run C compiled programs.
3154If you meant to cross compile, use \`--host'.
3155See \`config.log' for more details" "$LINENO" 5; }
3156 fi
3157 fi
3158fi
3159{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3160$as_echo "$cross_compiling" >&6; }
3161
3162rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3163ac_clean_files=$ac_clean_files_save
3164{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3165$as_echo_n "checking for suffix of object files... " >&6; }
3166if ${ac_cv_objext+:} false; then :
3167 $as_echo_n "(cached) " >&6
3168else
3169 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3170/* end confdefs.h. */
3171
3172int
3173main ()
3174{
3175
3176 ;
3177 return 0;
3178}
3179_ACEOF
3180rm -f conftest.o conftest.obj
3181if { { ac_try="$ac_compile"
3182case "(($ac_try" in
3183 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3184 *) ac_try_echo=$ac_try;;
3185esac
3186eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3187$as_echo "$ac_try_echo"; } >&5
3188 (eval "$ac_compile") 2>&5
3189 ac_status=$?
3190 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3191 test $ac_status = 0; }; then :
3192 for ac_file in conftest.o conftest.obj conftest.*; do
3193 test -f "$ac_file" || continue;
3194 case $ac_file in
3195 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3196 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3197 break;;
3198 esac
3199done
3200else
3201 $as_echo "$as_me: failed program was:" >&5
3202sed 's/^/| /' conftest.$ac_ext >&5
3203
3204{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3205$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3206as_fn_error $? "cannot compute suffix of object files: cannot compile
3207See \`config.log' for more details" "$LINENO" 5; }
3208fi
3209rm -f conftest.$ac_cv_objext conftest.$ac_ext
3210fi
3211{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3212$as_echo "$ac_cv_objext" >&6; }
3213OBJEXT=$ac_cv_objext
3214ac_objext=$OBJEXT
3215{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3216$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3217if ${ac_cv_c_compiler_gnu+:} false; then :
3218 $as_echo_n "(cached) " >&6
3219else
3220 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3221/* end confdefs.h. */
3222
3223int
3224main ()
3225{
3226#ifndef __GNUC__
3227 choke me
3228#endif
3229
3230 ;
3231 return 0;
3232}
3233_ACEOF
3234if ac_fn_c_try_compile "$LINENO"; then :
3235 ac_compiler_gnu=yes
3236else
3237 ac_compiler_gnu=no
3238fi
3239rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3240ac_cv_c_compiler_gnu=$ac_compiler_gnu
3241
3242fi
3243{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3244$as_echo "$ac_cv_c_compiler_gnu" >&6; }
3245if test $ac_compiler_gnu = yes; then
3246 GCC=yes
3247else
3248 GCC=
3249fi
3250ac_test_CFLAGS=${CFLAGS+set}
3251ac_save_CFLAGS=$CFLAGS
3252{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3253$as_echo_n "checking whether $CC accepts -g... " >&6; }
3254if ${ac_cv_prog_cc_g+:} false; then :
3255 $as_echo_n "(cached) " >&6
3256else
3257 ac_save_c_werror_flag=$ac_c_werror_flag
3258 ac_c_werror_flag=yes
3259 ac_cv_prog_cc_g=no
3260 CFLAGS="-g"
3261 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3262/* end confdefs.h. */
3263
3264int
3265main ()
3266{
3267
3268 ;
3269 return 0;
3270}
3271_ACEOF
3272if ac_fn_c_try_compile "$LINENO"; then :
3273 ac_cv_prog_cc_g=yes
3274else
3275 CFLAGS=""
3276 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3277/* end confdefs.h. */
3278
3279int
3280main ()
3281{
3282
3283 ;
3284 return 0;
3285}
3286_ACEOF
3287if ac_fn_c_try_compile "$LINENO"; then :
3288
3289else
3290 ac_c_werror_flag=$ac_save_c_werror_flag
3291 CFLAGS="-g"
3292 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3293/* end confdefs.h. */
3294
3295int
3296main ()
3297{
3298
3299 ;
3300 return 0;
3301}
3302_ACEOF
3303if ac_fn_c_try_compile "$LINENO"; then :
3304 ac_cv_prog_cc_g=yes
3305fi
3306rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3307fi
3308rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3309fi
3310rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3311 ac_c_werror_flag=$ac_save_c_werror_flag
3312fi
3313{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3314$as_echo "$ac_cv_prog_cc_g" >&6; }
3315if test "$ac_test_CFLAGS" = set; then
3316 CFLAGS=$ac_save_CFLAGS
3317elif test $ac_cv_prog_cc_g = yes; then
3318 if test "$GCC" = yes; then
3319 CFLAGS="-g -O2"
3320 else
3321 CFLAGS="-g"
3322 fi
3323else
3324 if test "$GCC" = yes; then
3325 CFLAGS="-O2"
3326 else
3327 CFLAGS=
3328 fi
3329fi
3330{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3331$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3332if ${ac_cv_prog_cc_c89+:} false; then :
3333 $as_echo_n "(cached) " >&6
3334else
3335 ac_cv_prog_cc_c89=no
3336ac_save_CC=$CC
3337cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3338/* end confdefs.h. */
3339#include <stdarg.h>
3340#include <stdio.h>
3341struct stat;
3342/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3343struct buf { int x; };
3344FILE * (*rcsopen) (struct buf *, struct stat *, int);
3345static char *e (p, i)
3346 char **p;
3347 int i;
3348{
3349 return p[i];
3350}
3351static char *f (char * (*g) (char **, int), char **p, ...)
3352{
3353 char *s;
3354 va_list v;
3355 va_start (v,p);
3356 s = g (p, va_arg (v,int));
3357 va_end (v);
3358 return s;
3359}
3360
3361/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3362 function prototypes and stuff, but not '\xHH' hex character constants.
3363 These don't provoke an error unfortunately, instead are silently treated
3364 as 'x'. The following induces an error, until -std is added to get
3365 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3366 array size at least. It's necessary to write '\x00'==0 to get something
3367 that's true only with -std. */
3368int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3369
3370/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3371 inside strings and character constants. */
3372#define FOO(x) 'x'
3373int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3374
3375int test (int i, double x);
3376struct s1 {int (*f) (int a);};
3377struct s2 {int (*f) (double a);};
3378int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3379int argc;
3380char **argv;
3381int
3382main ()
3383{
3384return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3385 ;
3386 return 0;
3387}
3388_ACEOF
3389for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3390 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3391do
3392 CC="$ac_save_CC $ac_arg"
3393 if ac_fn_c_try_compile "$LINENO"; then :
3394 ac_cv_prog_cc_c89=$ac_arg
3395fi
3396rm -f core conftest.err conftest.$ac_objext
3397 test "x$ac_cv_prog_cc_c89" != "xno" && break
3398done
3399rm -f conftest.$ac_ext
3400CC=$ac_save_CC
3401
3402fi
3403# AC_CACHE_VAL
3404case "x$ac_cv_prog_cc_c89" in
3405 x)
3406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3407$as_echo "none needed" >&6; } ;;
3408 xno)
3409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3410$as_echo "unsupported" >&6; } ;;
3411 *)
3412 CC="$CC $ac_cv_prog_cc_c89"
3413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3414$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3415esac
3416if test "x$ac_cv_prog_cc_c89" != xno; then :
3417
3418fi
3419
3420ac_ext=c
3421ac_cpp='$CPP $CPPFLAGS'
3422ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3423ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3424ac_compiler_gnu=$ac_cv_c_compiler_gnu
3425
3426if test "x$GCC" != "xyes" ; then
3427
3428{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler is MSVC" >&5
3429$as_echo_n "checking whether compiler is MSVC... " >&6; }
3430if ${je_cv_msvc+:} false; then :
3431 $as_echo_n "(cached) " >&6
3432else
3433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3434/* end confdefs.h. */
3435
3436int
3437main ()
3438{
3439
3440#ifndef _MSC_VER
3441 int fail-1;
3442#endif
3443
3444 ;
3445 return 0;
3446}
3447_ACEOF
3448if ac_fn_c_try_compile "$LINENO"; then :
3449 je_cv_msvc=yes
3450else
3451 je_cv_msvc=no
3452fi
3453rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3454fi
3455{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_msvc" >&5
3456$as_echo "$je_cv_msvc" >&6; }
3457fi
3458
3459if test "x$CFLAGS" = "x" ; then
3460 no_CFLAGS="yes"
3461 if test "x$GCC" = "xyes" ; then
3462
3463{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -std=gnu99" >&5
3464$as_echo_n "checking whether compiler supports -std=gnu99... " >&6; }
3465TCFLAGS="${CFLAGS}"
3466if test "x${CFLAGS}" = "x" ; then
3467 CFLAGS="-std=gnu99"
3468else
3469 CFLAGS="${CFLAGS} -std=gnu99"
3470fi
3471cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3472/* end confdefs.h. */
3473
3474
3475int
3476main ()
3477{
3478
3479 return 0;
3480
3481 ;
3482 return 0;
3483}
3484_ACEOF
3485if ac_fn_c_try_compile "$LINENO"; then :
1a4d82fc
JJ
3486 je_cv_cflags_appended=-std=gnu99
3487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
970d7e83
LB
3488$as_echo "yes" >&6; }
3489else
1a4d82fc
JJ
3490 je_cv_cflags_appended=
3491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
970d7e83
LB
3492$as_echo "no" >&6; }
3493 CFLAGS="${TCFLAGS}"
3494
3495fi
3496rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3497
1a4d82fc
JJ
3498 if test "x$je_cv_cflags_appended" = "x-std=gnu99" ; then
3499 cat >>confdefs.h <<_ACEOF
3500#define JEMALLOC_HAS_RESTRICT 1
3501_ACEOF
3502
3503 fi
970d7e83
LB
3504
3505{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -Wall" >&5
3506$as_echo_n "checking whether compiler supports -Wall... " >&6; }
3507TCFLAGS="${CFLAGS}"
3508if test "x${CFLAGS}" = "x" ; then
3509 CFLAGS="-Wall"
3510else
3511 CFLAGS="${CFLAGS} -Wall"
3512fi
3513cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3514/* end confdefs.h. */
3515
3516
3517int
3518main ()
3519{
3520
3521 return 0;
3522
3523 ;
3524 return 0;
3525}
3526_ACEOF
3527if ac_fn_c_try_compile "$LINENO"; then :
1a4d82fc
JJ
3528 je_cv_cflags_appended=-Wall
3529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
970d7e83
LB
3530$as_echo "yes" >&6; }
3531else
1a4d82fc
JJ
3532 je_cv_cflags_appended=
3533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
970d7e83
LB
3534$as_echo "no" >&6; }
3535 CFLAGS="${TCFLAGS}"
3536
3537fi
3538rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3539
3540
54a0048b
SL
3541{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -Werror=declaration-after-statement" >&5
3542$as_echo_n "checking whether compiler supports -Werror=declaration-after-statement... " >&6; }
3543TCFLAGS="${CFLAGS}"
3544if test "x${CFLAGS}" = "x" ; then
3545 CFLAGS="-Werror=declaration-after-statement"
3546else
3547 CFLAGS="${CFLAGS} -Werror=declaration-after-statement"
3548fi
3549cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3550/* end confdefs.h. */
3551
3552
3553int
3554main ()
3555{
3556
3557 return 0;
3558
3559 ;
3560 return 0;
3561}
3562_ACEOF
3563if ac_fn_c_try_compile "$LINENO"; then :
3564 je_cv_cflags_appended=-Werror=declaration-after-statement
3565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3566$as_echo "yes" >&6; }
3567else
3568 je_cv_cflags_appended=
3569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3570$as_echo "no" >&6; }
3571 CFLAGS="${TCFLAGS}"
3572
3573fi
3574rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3575
3576
3577{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -Wshorten-64-to-32" >&5
3578$as_echo_n "checking whether compiler supports -Wshorten-64-to-32... " >&6; }
3579TCFLAGS="${CFLAGS}"
3580if test "x${CFLAGS}" = "x" ; then
3581 CFLAGS="-Wshorten-64-to-32"
3582else
3583 CFLAGS="${CFLAGS} -Wshorten-64-to-32"
3584fi
3585cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3586/* end confdefs.h. */
3587
3588
3589int
3590main ()
3591{
3592
3593 return 0;
3594
3595 ;
3596 return 0;
3597}
3598_ACEOF
3599if ac_fn_c_try_compile "$LINENO"; then :
3600 je_cv_cflags_appended=-Wshorten-64-to-32
3601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3602$as_echo "yes" >&6; }
3603else
3604 je_cv_cflags_appended=
3605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3606$as_echo "no" >&6; }
3607 CFLAGS="${TCFLAGS}"
3608
3609fi
3610rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3611
3612
970d7e83
LB
3613{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -pipe" >&5
3614$as_echo_n "checking whether compiler supports -pipe... " >&6; }
3615TCFLAGS="${CFLAGS}"
3616if test "x${CFLAGS}" = "x" ; then
3617 CFLAGS="-pipe"
3618else
3619 CFLAGS="${CFLAGS} -pipe"
3620fi
3621cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3622/* end confdefs.h. */
3623
3624
3625int
3626main ()
3627{
3628
3629 return 0;
3630
3631 ;
3632 return 0;
3633}
3634_ACEOF
3635if ac_fn_c_try_compile "$LINENO"; then :
1a4d82fc
JJ
3636 je_cv_cflags_appended=-pipe
3637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
970d7e83
LB
3638$as_echo "yes" >&6; }
3639else
1a4d82fc
JJ
3640 je_cv_cflags_appended=
3641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
970d7e83
LB
3642$as_echo "no" >&6; }
3643 CFLAGS="${TCFLAGS}"
3644
3645fi
3646rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3647
3648
3649{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -g3" >&5
3650$as_echo_n "checking whether compiler supports -g3... " >&6; }
3651TCFLAGS="${CFLAGS}"
3652if test "x${CFLAGS}" = "x" ; then
3653 CFLAGS="-g3"
3654else
3655 CFLAGS="${CFLAGS} -g3"
3656fi
3657cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3658/* end confdefs.h. */
3659
3660
3661int
3662main ()
3663{
3664
3665 return 0;
3666
3667 ;
3668 return 0;
3669}
3670_ACEOF
3671if ac_fn_c_try_compile "$LINENO"; then :
1a4d82fc
JJ
3672 je_cv_cflags_appended=-g3
3673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
970d7e83
LB
3674$as_echo "yes" >&6; }
3675else
1a4d82fc
JJ
3676 je_cv_cflags_appended=
3677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
970d7e83
LB
3678$as_echo "no" >&6; }
3679 CFLAGS="${TCFLAGS}"
3680
3681fi
3682rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3683
3684 elif test "x$je_cv_msvc" = "xyes" ; then
3685 CC="$CC -nologo"
3686
3687{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -Zi" >&5
3688$as_echo_n "checking whether compiler supports -Zi... " >&6; }
3689TCFLAGS="${CFLAGS}"
3690if test "x${CFLAGS}" = "x" ; then
3691 CFLAGS="-Zi"
3692else
3693 CFLAGS="${CFLAGS} -Zi"
3694fi
3695cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3696/* end confdefs.h. */
3697
3698
3699int
3700main ()
3701{
3702
3703 return 0;
3704
3705 ;
3706 return 0;
3707}
3708_ACEOF
3709if ac_fn_c_try_compile "$LINENO"; then :
1a4d82fc
JJ
3710 je_cv_cflags_appended=-Zi
3711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
970d7e83
LB
3712$as_echo "yes" >&6; }
3713else
1a4d82fc
JJ
3714 je_cv_cflags_appended=
3715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
970d7e83
LB
3716$as_echo "no" >&6; }
3717 CFLAGS="${TCFLAGS}"
3718
3719fi
3720rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3721
3722
3723{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -MT" >&5
3724$as_echo_n "checking whether compiler supports -MT... " >&6; }
3725TCFLAGS="${CFLAGS}"
3726if test "x${CFLAGS}" = "x" ; then
3727 CFLAGS="-MT"
3728else
3729 CFLAGS="${CFLAGS} -MT"
3730fi
3731cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3732/* end confdefs.h. */
3733
3734
3735int
3736main ()
3737{
3738
3739 return 0;
3740
3741 ;
3742 return 0;
3743}
3744_ACEOF
3745if ac_fn_c_try_compile "$LINENO"; then :
1a4d82fc
JJ
3746 je_cv_cflags_appended=-MT
3747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
970d7e83
LB
3748$as_echo "yes" >&6; }
3749else
1a4d82fc
JJ
3750 je_cv_cflags_appended=
3751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
970d7e83
LB
3752$as_echo "no" >&6; }
3753 CFLAGS="${TCFLAGS}"
3754
3755fi
3756rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3757
3758
3759{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -W3" >&5
3760$as_echo_n "checking whether compiler supports -W3... " >&6; }
3761TCFLAGS="${CFLAGS}"
3762if test "x${CFLAGS}" = "x" ; then
3763 CFLAGS="-W3"
3764else
3765 CFLAGS="${CFLAGS} -W3"
3766fi
3767cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3768/* end confdefs.h. */
3769
3770
3771int
3772main ()
3773{
3774
3775 return 0;
3776
3777 ;
3778 return 0;
3779}
3780_ACEOF
3781if ac_fn_c_try_compile "$LINENO"; then :
1a4d82fc
JJ
3782 je_cv_cflags_appended=-W3
3783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
970d7e83
LB
3784$as_echo "yes" >&6; }
3785else
1a4d82fc
JJ
3786 je_cv_cflags_appended=
3787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3788$as_echo "no" >&6; }
3789 CFLAGS="${TCFLAGS}"
3790
3791fi
3792rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3793
3794
3795{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -FS" >&5
3796$as_echo_n "checking whether compiler supports -FS... " >&6; }
3797TCFLAGS="${CFLAGS}"
3798if test "x${CFLAGS}" = "x" ; then
3799 CFLAGS="-FS"
3800else
3801 CFLAGS="${CFLAGS} -FS"
3802fi
3803cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3804/* end confdefs.h. */
3805
3806
3807int
3808main ()
3809{
3810
3811 return 0;
3812
3813 ;
3814 return 0;
3815}
3816_ACEOF
3817if ac_fn_c_try_compile "$LINENO"; then :
3818 je_cv_cflags_appended=-FS
3819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3820$as_echo "yes" >&6; }
3821else
3822 je_cv_cflags_appended=
3823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
970d7e83
LB
3824$as_echo "no" >&6; }
3825 CFLAGS="${TCFLAGS}"
3826
3827fi
3828rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3829
1a4d82fc 3830 CPPFLAGS="$CPPFLAGS -I${srcdir}/include/msvc_compat"
970d7e83
LB
3831 fi
3832fi
3833if test "x$EXTRA_CFLAGS" != "x" ; then
3834
3835{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports $EXTRA_CFLAGS" >&5
3836$as_echo_n "checking whether compiler supports $EXTRA_CFLAGS... " >&6; }
3837TCFLAGS="${CFLAGS}"
3838if test "x${CFLAGS}" = "x" ; then
3839 CFLAGS="$EXTRA_CFLAGS"
3840else
3841 CFLAGS="${CFLAGS} $EXTRA_CFLAGS"
3842fi
3843cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3844/* end confdefs.h. */
3845
3846
3847int
3848main ()
3849{
3850
3851 return 0;
3852
3853 ;
3854 return 0;
3855}
3856_ACEOF
3857if ac_fn_c_try_compile "$LINENO"; then :
1a4d82fc
JJ
3858 je_cv_cflags_appended=$EXTRA_CFLAGS
3859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
970d7e83
LB
3860$as_echo "yes" >&6; }
3861else
1a4d82fc
JJ
3862 je_cv_cflags_appended=
3863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
970d7e83
LB
3864$as_echo "no" >&6; }
3865 CFLAGS="${TCFLAGS}"
3866
3867fi
3868rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3869
3870fi
3871ac_ext=c
3872ac_cpp='$CPP $CPPFLAGS'
3873ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3874ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3875ac_compiler_gnu=$ac_cv_c_compiler_gnu
3876{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3877$as_echo_n "checking how to run the C preprocessor... " >&6; }
3878# On Suns, sometimes $CPP names a directory.
3879if test -n "$CPP" && test -d "$CPP"; then
3880 CPP=
3881fi
3882if test -z "$CPP"; then
3883 if ${ac_cv_prog_CPP+:} false; then :
3884 $as_echo_n "(cached) " >&6
3885else
3886 # Double quotes because CPP needs to be expanded
3887 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3888 do
3889 ac_preproc_ok=false
3890for ac_c_preproc_warn_flag in '' yes
3891do
3892 # Use a header file that comes with gcc, so configuring glibc
3893 # with a fresh cross-compiler works.
3894 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3895 # <limits.h> exists even on freestanding compilers.
3896 # On the NeXT, cc -E runs the code through the compiler's parser,
3897 # not just through cpp. "Syntax error" is here to catch this case.
3898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3899/* end confdefs.h. */
3900#ifdef __STDC__
3901# include <limits.h>
3902#else
3903# include <assert.h>
3904#endif
3905 Syntax error
3906_ACEOF
3907if ac_fn_c_try_cpp "$LINENO"; then :
3908
3909else
3910 # Broken: fails on valid input.
3911continue
3912fi
3913rm -f conftest.err conftest.i conftest.$ac_ext
3914
3915 # OK, works on sane cases. Now check whether nonexistent headers
3916 # can be detected and how.
3917 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3918/* end confdefs.h. */
3919#include <ac_nonexistent.h>
3920_ACEOF
3921if ac_fn_c_try_cpp "$LINENO"; then :
3922 # Broken: success on invalid input.
3923continue
3924else
3925 # Passes both tests.
3926ac_preproc_ok=:
3927break
3928fi
3929rm -f conftest.err conftest.i conftest.$ac_ext
3930
3931done
3932# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3933rm -f conftest.i conftest.err conftest.$ac_ext
3934if $ac_preproc_ok; then :
3935 break
3936fi
3937
3938 done
3939 ac_cv_prog_CPP=$CPP
3940
3941fi
3942 CPP=$ac_cv_prog_CPP
3943else
3944 ac_cv_prog_CPP=$CPP
3945fi
3946{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
3947$as_echo "$CPP" >&6; }
3948ac_preproc_ok=false
3949for ac_c_preproc_warn_flag in '' yes
3950do
3951 # Use a header file that comes with gcc, so configuring glibc
3952 # with a fresh cross-compiler works.
3953 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3954 # <limits.h> exists even on freestanding compilers.
3955 # On the NeXT, cc -E runs the code through the compiler's parser,
3956 # not just through cpp. "Syntax error" is here to catch this case.
3957 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3958/* end confdefs.h. */
3959#ifdef __STDC__
3960# include <limits.h>
3961#else
3962# include <assert.h>
3963#endif
3964 Syntax error
3965_ACEOF
3966if ac_fn_c_try_cpp "$LINENO"; then :
3967
3968else
3969 # Broken: fails on valid input.
3970continue
3971fi
3972rm -f conftest.err conftest.i conftest.$ac_ext
3973
3974 # OK, works on sane cases. Now check whether nonexistent headers
3975 # can be detected and how.
3976 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3977/* end confdefs.h. */
3978#include <ac_nonexistent.h>
3979_ACEOF
3980if ac_fn_c_try_cpp "$LINENO"; then :
3981 # Broken: success on invalid input.
3982continue
3983else
3984 # Passes both tests.
3985ac_preproc_ok=:
3986break
3987fi
3988rm -f conftest.err conftest.i conftest.$ac_ext
3989
3990done
3991# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3992rm -f conftest.i conftest.err conftest.$ac_ext
3993if $ac_preproc_ok; then :
3994
3995else
3996 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3997$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3998as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
3999See \`config.log' for more details" "$LINENO" 5; }
4000fi
4001
4002ac_ext=c
4003ac_cpp='$CPP $CPPFLAGS'
4004ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4005ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4006ac_compiler_gnu=$ac_cv_c_compiler_gnu
4007
4008
4009
4010{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
4011$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
4012if ${ac_cv_path_GREP+:} false; then :
4013 $as_echo_n "(cached) " >&6
4014else
4015 if test -z "$GREP"; then
4016 ac_path_GREP_found=false
4017 # Loop through the user's path and test for each of PROGNAME-LIST
4018 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4019for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4020do
4021 IFS=$as_save_IFS
4022 test -z "$as_dir" && as_dir=.
4023 for ac_prog in grep ggrep; do
4024 for ac_exec_ext in '' $ac_executable_extensions; do
4025 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
4026 as_fn_executable_p "$ac_path_GREP" || continue
4027# Check for GNU ac_path_GREP and select it if it is found.
4028 # Check for GNU $ac_path_GREP
4029case `"$ac_path_GREP" --version 2>&1` in
4030*GNU*)
4031 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4032*)
4033 ac_count=0
4034 $as_echo_n 0123456789 >"conftest.in"
4035 while :
4036 do
4037 cat "conftest.in" "conftest.in" >"conftest.tmp"
4038 mv "conftest.tmp" "conftest.in"
4039 cp "conftest.in" "conftest.nl"
4040 $as_echo 'GREP' >> "conftest.nl"
4041 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4042 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4043 as_fn_arith $ac_count + 1 && ac_count=$as_val
4044 if test $ac_count -gt ${ac_path_GREP_max-0}; then
4045 # Best one so far, save it but keep looking for a better one
4046 ac_cv_path_GREP="$ac_path_GREP"
4047 ac_path_GREP_max=$ac_count
4048 fi
4049 # 10*(2^10) chars as input seems more than enough
4050 test $ac_count -gt 10 && break
4051 done
4052 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4053esac
4054
4055 $ac_path_GREP_found && break 3
4056 done
4057 done
4058 done
4059IFS=$as_save_IFS
4060 if test -z "$ac_cv_path_GREP"; then
4061 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4062 fi
4063else
4064 ac_cv_path_GREP=$GREP
4065fi
4066
4067fi
4068{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4069$as_echo "$ac_cv_path_GREP" >&6; }
4070 GREP="$ac_cv_path_GREP"
4071
4072
4073{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4074$as_echo_n "checking for egrep... " >&6; }
4075if ${ac_cv_path_EGREP+:} false; then :
4076 $as_echo_n "(cached) " >&6
4077else
4078 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4079 then ac_cv_path_EGREP="$GREP -E"
4080 else
4081 if test -z "$EGREP"; then
4082 ac_path_EGREP_found=false
4083 # Loop through the user's path and test for each of PROGNAME-LIST
4084 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4085for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4086do
4087 IFS=$as_save_IFS
4088 test -z "$as_dir" && as_dir=.
4089 for ac_prog in egrep; do
4090 for ac_exec_ext in '' $ac_executable_extensions; do
4091 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4092 as_fn_executable_p "$ac_path_EGREP" || continue
4093# Check for GNU ac_path_EGREP and select it if it is found.
4094 # Check for GNU $ac_path_EGREP
4095case `"$ac_path_EGREP" --version 2>&1` in
4096*GNU*)
4097 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4098*)
4099 ac_count=0
4100 $as_echo_n 0123456789 >"conftest.in"
4101 while :
4102 do
4103 cat "conftest.in" "conftest.in" >"conftest.tmp"
4104 mv "conftest.tmp" "conftest.in"
4105 cp "conftest.in" "conftest.nl"
4106 $as_echo 'EGREP' >> "conftest.nl"
4107 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4108 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4109 as_fn_arith $ac_count + 1 && ac_count=$as_val
4110 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4111 # Best one so far, save it but keep looking for a better one
4112 ac_cv_path_EGREP="$ac_path_EGREP"
4113 ac_path_EGREP_max=$ac_count
4114 fi
4115 # 10*(2^10) chars as input seems more than enough
4116 test $ac_count -gt 10 && break
4117 done
4118 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4119esac
4120
4121 $ac_path_EGREP_found && break 3
4122 done
4123 done
4124 done
4125IFS=$as_save_IFS
4126 if test -z "$ac_cv_path_EGREP"; then
4127 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4128 fi
4129else
4130 ac_cv_path_EGREP=$EGREP
4131fi
4132
4133 fi
4134fi
4135{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4136$as_echo "$ac_cv_path_EGREP" >&6; }
4137 EGREP="$ac_cv_path_EGREP"
4138
4139
4140{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4141$as_echo_n "checking for ANSI C header files... " >&6; }
4142if ${ac_cv_header_stdc+:} false; then :
4143 $as_echo_n "(cached) " >&6
4144else
4145 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4146/* end confdefs.h. */
4147#include <stdlib.h>
4148#include <stdarg.h>
4149#include <string.h>
4150#include <float.h>
4151
4152int
4153main ()
4154{
4155
4156 ;
4157 return 0;
4158}
4159_ACEOF
4160if ac_fn_c_try_compile "$LINENO"; then :
4161 ac_cv_header_stdc=yes
4162else
4163 ac_cv_header_stdc=no
4164fi
4165rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4166
4167if test $ac_cv_header_stdc = yes; then
4168 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4169 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4170/* end confdefs.h. */
4171#include <string.h>
4172
4173_ACEOF
4174if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4175 $EGREP "memchr" >/dev/null 2>&1; then :
4176
4177else
4178 ac_cv_header_stdc=no
4179fi
4180rm -f conftest*
4181
4182fi
4183
4184if test $ac_cv_header_stdc = yes; then
4185 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4186 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4187/* end confdefs.h. */
4188#include <stdlib.h>
4189
4190_ACEOF
4191if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4192 $EGREP "free" >/dev/null 2>&1; then :
4193
4194else
4195 ac_cv_header_stdc=no
4196fi
4197rm -f conftest*
4198
4199fi
4200
4201if test $ac_cv_header_stdc = yes; then
4202 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4203 if test "$cross_compiling" = yes; then :
4204 :
4205else
4206 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4207/* end confdefs.h. */
4208#include <ctype.h>
4209#include <stdlib.h>
4210#if ((' ' & 0x0FF) == 0x020)
4211# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4212# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4213#else
4214# define ISLOWER(c) \
4215 (('a' <= (c) && (c) <= 'i') \
4216 || ('j' <= (c) && (c) <= 'r') \
4217 || ('s' <= (c) && (c) <= 'z'))
4218# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4219#endif
4220
4221#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4222int
4223main ()
4224{
4225 int i;
4226 for (i = 0; i < 256; i++)
4227 if (XOR (islower (i), ISLOWER (i))
4228 || toupper (i) != TOUPPER (i))
4229 return 2;
4230 return 0;
4231}
4232_ACEOF
4233if ac_fn_c_try_run "$LINENO"; then :
4234
4235else
4236 ac_cv_header_stdc=no
4237fi
4238rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4239 conftest.$ac_objext conftest.beam conftest.$ac_ext
4240fi
4241
4242fi
4243fi
4244{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4245$as_echo "$ac_cv_header_stdc" >&6; }
4246if test $ac_cv_header_stdc = yes; then
4247
4248$as_echo "#define STDC_HEADERS 1" >>confdefs.h
4249
4250fi
4251
4252# On IRIX 5.3, sys/types and inttypes.h are conflicting.
4253for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4254 inttypes.h stdint.h unistd.h
4255do :
4256 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4257ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4258"
4259if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4260 cat >>confdefs.h <<_ACEOF
4261#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4262_ACEOF
4263
4264fi
4265
4266done
4267
4268
1a4d82fc
JJ
4269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
4270$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
4271if ${ac_cv_c_bigendian+:} false; then :
970d7e83
LB
4272 $as_echo_n "(cached) " >&6
4273else
1a4d82fc
JJ
4274 ac_cv_c_bigendian=unknown
4275 # See if we're dealing with a universal compiler.
4276 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4277/* end confdefs.h. */
4278#ifndef __APPLE_CC__
4279 not a universal capable compiler
4280 #endif
4281 typedef int dummy;
970d7e83 4282
1a4d82fc
JJ
4283_ACEOF
4284if ac_fn_c_try_compile "$LINENO"; then :
4285
4286 # Check for potential -arch flags. It is not universal unless
4287 # there are at least two -arch flags with different values.
4288 ac_arch=
4289 ac_prev=
4290 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
4291 if test -n "$ac_prev"; then
4292 case $ac_word in
4293 i?86 | x86_64 | ppc | ppc64)
4294 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
4295 ac_arch=$ac_word
4296 else
4297 ac_cv_c_bigendian=universal
4298 break
4299 fi
4300 ;;
4301 esac
4302 ac_prev=
4303 elif test "x$ac_word" = "x-arch"; then
4304 ac_prev=arch
4305 fi
4306 done
4307fi
4308rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4309 if test $ac_cv_c_bigendian = unknown; then
4310 # See if sys/param.h defines the BYTE_ORDER macro.
4311 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4312/* end confdefs.h. */
4313#include <sys/types.h>
4314 #include <sys/param.h>
4315
4316int
4317main ()
4318{
4319#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
4320 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
4321 && LITTLE_ENDIAN)
4322 bogus endian macros
4323 #endif
4324
4325 ;
4326 return 0;
4327}
4328_ACEOF
4329if ac_fn_c_try_compile "$LINENO"; then :
4330 # It does; now see whether it defined to BIG_ENDIAN or not.
4331 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4332/* end confdefs.h. */
4333#include <sys/types.h>
4334 #include <sys/param.h>
4335
4336int
4337main ()
4338{
4339#if BYTE_ORDER != BIG_ENDIAN
4340 not big endian
4341 #endif
4342
4343 ;
4344 return 0;
4345}
4346_ACEOF
4347if ac_fn_c_try_compile "$LINENO"; then :
4348 ac_cv_c_bigendian=yes
4349else
4350 ac_cv_c_bigendian=no
4351fi
4352rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4353fi
4354rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4355 fi
4356 if test $ac_cv_c_bigendian = unknown; then
4357 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
4358 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4359/* end confdefs.h. */
4360#include <limits.h>
4361
4362int
4363main ()
4364{
4365#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
4366 bogus endian macros
4367 #endif
4368
4369 ;
4370 return 0;
4371}
4372_ACEOF
4373if ac_fn_c_try_compile "$LINENO"; then :
4374 # It does; now see whether it defined to _BIG_ENDIAN or not.
4375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4376/* end confdefs.h. */
4377#include <limits.h>
4378
4379int
4380main ()
4381{
4382#ifndef _BIG_ENDIAN
4383 not big endian
4384 #endif
4385
4386 ;
4387 return 0;
4388}
4389_ACEOF
4390if ac_fn_c_try_compile "$LINENO"; then :
4391 ac_cv_c_bigendian=yes
4392else
4393 ac_cv_c_bigendian=no
4394fi
4395rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4396fi
4397rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4398 fi
4399 if test $ac_cv_c_bigendian = unknown; then
4400 # Compile a test program.
4401 if test "$cross_compiling" = yes; then :
4402 # Try to guess by grepping values from an object file.
4403 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4404/* end confdefs.h. */
4405short int ascii_mm[] =
4406 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
4407 short int ascii_ii[] =
4408 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
4409 int use_ascii (int i) {
4410 return ascii_mm[i] + ascii_ii[i];
4411 }
4412 short int ebcdic_ii[] =
4413 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
4414 short int ebcdic_mm[] =
4415 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
4416 int use_ebcdic (int i) {
4417 return ebcdic_mm[i] + ebcdic_ii[i];
4418 }
4419 extern int foo;
4420
4421int
4422main ()
4423{
4424return use_ascii (foo) == use_ebcdic (foo);
4425 ;
4426 return 0;
4427}
4428_ACEOF
4429if ac_fn_c_try_compile "$LINENO"; then :
4430 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
4431 ac_cv_c_bigendian=yes
4432 fi
4433 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
4434 if test "$ac_cv_c_bigendian" = unknown; then
4435 ac_cv_c_bigendian=no
4436 else
4437 # finding both strings is unlikely to happen, but who knows?
4438 ac_cv_c_bigendian=unknown
4439 fi
4440 fi
4441fi
4442rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4443else
4444 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4445/* end confdefs.h. */
4446$ac_includes_default
4447int
4448main ()
4449{
4450
4451 /* Are we little or big endian? From Harbison&Steele. */
4452 union
4453 {
4454 long int l;
4455 char c[sizeof (long int)];
4456 } u;
4457 u.l = 1;
4458 return u.c[sizeof (long int) - 1] == 1;
4459
4460 ;
4461 return 0;
4462}
4463_ACEOF
4464if ac_fn_c_try_run "$LINENO"; then :
4465 ac_cv_c_bigendian=no
4466else
4467 ac_cv_c_bigendian=yes
4468fi
4469rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4470 conftest.$ac_objext conftest.beam conftest.$ac_ext
4471fi
4472
4473 fi
4474fi
4475{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
4476$as_echo "$ac_cv_c_bigendian" >&6; }
4477 case $ac_cv_c_bigendian in #(
4478 yes)
4479 ac_cv_big_endian=1;; #(
4480 no)
4481 ac_cv_big_endian=0 ;; #(
4482 universal)
4483
4484$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
4485
4486 ;; #(
4487 *)
4488 as_fn_error $? "unknown endianness
4489 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
4490 esac
4491
4492if test "x${ac_cv_big_endian}" = "x1" ; then
4493 cat >>confdefs.h <<_ACEOF
4494#define JEMALLOC_BIG_ENDIAN
4495_ACEOF
4496
4497fi
4498
4499if test "x${je_cv_msvc}" = "xyes" -a "x${ac_cv_header_inttypes_h}" = "xno"; then
4500 CPPFLAGS="$CPPFLAGS -I${srcdir}/include/msvc_compat/C99"
4501fi
4502
54a0048b
SL
4503if test "x${je_cv_msvc}" = "xyes" ; then
4504 LG_SIZEOF_PTR=LG_SIZEOF_PTR_WIN
4505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Using a predefined value for sizeof(void *): 4 for 32-bit, 8 for 64-bit" >&5
4506$as_echo "Using a predefined value for sizeof(void *): 4 for 32-bit, 8 for 64-bit" >&6; }
4507else
4508 # The cast to long int works around a bug in the HP C Compiler
1a4d82fc
JJ
4509# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
4510# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
4511# This bug is HP SR number 8606223364.
4512{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5
4513$as_echo_n "checking size of void *... " >&6; }
4514if ${ac_cv_sizeof_void_p+:} false; then :
4515 $as_echo_n "(cached) " >&6
4516else
4517 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"; then :
4518
4519else
970d7e83
LB
4520 if test "$ac_cv_type_void_p" = yes; then
4521 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4522$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4523as_fn_error 77 "cannot compute sizeof (void *)
4524See \`config.log' for more details" "$LINENO" 5; }
4525 else
4526 ac_cv_sizeof_void_p=0
4527 fi
4528fi
4529
4530fi
4531{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5
4532$as_echo "$ac_cv_sizeof_void_p" >&6; }
4533
4534
4535
4536cat >>confdefs.h <<_ACEOF
4537#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
4538_ACEOF
4539
4540
54a0048b
SL
4541 if test "x${ac_cv_sizeof_void_p}" = "x8" ; then
4542 LG_SIZEOF_PTR=3
4543 elif test "x${ac_cv_sizeof_void_p}" = "x4" ; then
4544 LG_SIZEOF_PTR=2
4545 else
4546 as_fn_error $? "Unsupported pointer size: ${ac_cv_sizeof_void_p}" "$LINENO" 5
4547 fi
970d7e83
LB
4548fi
4549cat >>confdefs.h <<_ACEOF
4550#define LG_SIZEOF_PTR $LG_SIZEOF_PTR
4551_ACEOF
4552
4553
4554# The cast to long int works around a bug in the HP C Compiler
4555# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
4556# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
4557# This bug is HP SR number 8606223364.
4558{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
4559$as_echo_n "checking size of int... " >&6; }
4560if ${ac_cv_sizeof_int+:} false; then :
4561 $as_echo_n "(cached) " >&6
4562else
4563 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then :
4564
4565else
4566 if test "$ac_cv_type_int" = yes; then
4567 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4568$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4569as_fn_error 77 "cannot compute sizeof (int)
4570See \`config.log' for more details" "$LINENO" 5; }
4571 else
4572 ac_cv_sizeof_int=0
4573 fi
4574fi
4575
4576fi
4577{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
4578$as_echo "$ac_cv_sizeof_int" >&6; }
4579
4580
4581
4582cat >>confdefs.h <<_ACEOF
4583#define SIZEOF_INT $ac_cv_sizeof_int
4584_ACEOF
4585
4586
4587if test "x${ac_cv_sizeof_int}" = "x8" ; then
4588 LG_SIZEOF_INT=3
4589elif test "x${ac_cv_sizeof_int}" = "x4" ; then
4590 LG_SIZEOF_INT=2
4591else
4592 as_fn_error $? "Unsupported int size: ${ac_cv_sizeof_int}" "$LINENO" 5
4593fi
4594cat >>confdefs.h <<_ACEOF
4595#define LG_SIZEOF_INT $LG_SIZEOF_INT
4596_ACEOF
4597
4598
4599# The cast to long int works around a bug in the HP C Compiler
4600# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
4601# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
4602# This bug is HP SR number 8606223364.
4603{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
4604$as_echo_n "checking size of long... " >&6; }
4605if ${ac_cv_sizeof_long+:} false; then :
4606 $as_echo_n "(cached) " >&6
4607else
4608 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then :
4609
4610else
4611 if test "$ac_cv_type_long" = yes; then
4612 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4613$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4614as_fn_error 77 "cannot compute sizeof (long)
4615See \`config.log' for more details" "$LINENO" 5; }
4616 else
4617 ac_cv_sizeof_long=0
4618 fi
4619fi
4620
4621fi
4622{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
4623$as_echo "$ac_cv_sizeof_long" >&6; }
4624
4625
4626
4627cat >>confdefs.h <<_ACEOF
4628#define SIZEOF_LONG $ac_cv_sizeof_long
4629_ACEOF
4630
4631
4632if test "x${ac_cv_sizeof_long}" = "x8" ; then
4633 LG_SIZEOF_LONG=3
4634elif test "x${ac_cv_sizeof_long}" = "x4" ; then
4635 LG_SIZEOF_LONG=2
4636else
4637 as_fn_error $? "Unsupported long size: ${ac_cv_sizeof_long}" "$LINENO" 5
4638fi
4639cat >>confdefs.h <<_ACEOF
4640#define LG_SIZEOF_LONG $LG_SIZEOF_LONG
4641_ACEOF
4642
4643
54a0048b
SL
4644# The cast to long int works around a bug in the HP C Compiler
4645# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
4646# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
4647# This bug is HP SR number 8606223364.
4648{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
4649$as_echo_n "checking size of long long... " >&6; }
4650if ${ac_cv_sizeof_long_long+:} false; then :
4651 $as_echo_n "(cached) " >&6
4652else
4653 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then :
4654
4655else
4656 if test "$ac_cv_type_long_long" = yes; then
4657 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4658$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4659as_fn_error 77 "cannot compute sizeof (long long)
4660See \`config.log' for more details" "$LINENO" 5; }
4661 else
4662 ac_cv_sizeof_long_long=0
4663 fi
4664fi
4665
4666fi
4667{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
4668$as_echo "$ac_cv_sizeof_long_long" >&6; }
4669
4670
4671
4672cat >>confdefs.h <<_ACEOF
4673#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
4674_ACEOF
4675
4676
4677if test "x${ac_cv_sizeof_long_long}" = "x8" ; then
4678 LG_SIZEOF_LONG_LONG=3
4679elif test "x${ac_cv_sizeof_long_long}" = "x4" ; then
4680 LG_SIZEOF_LONG_LONG=2
4681else
4682 as_fn_error $? "Unsupported long long size: ${ac_cv_sizeof_long_long}" "$LINENO" 5
4683fi
4684cat >>confdefs.h <<_ACEOF
4685#define LG_SIZEOF_LONG_LONG $LG_SIZEOF_LONG_LONG
4686_ACEOF
4687
4688
970d7e83
LB
4689# The cast to long int works around a bug in the HP C Compiler
4690# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
4691# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
4692# This bug is HP SR number 8606223364.
4693{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of intmax_t" >&5
4694$as_echo_n "checking size of intmax_t... " >&6; }
4695if ${ac_cv_sizeof_intmax_t+:} false; then :
4696 $as_echo_n "(cached) " >&6
4697else
4698 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (intmax_t))" "ac_cv_sizeof_intmax_t" "$ac_includes_default"; then :
4699
4700else
4701 if test "$ac_cv_type_intmax_t" = yes; then
4702 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4703$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4704as_fn_error 77 "cannot compute sizeof (intmax_t)
4705See \`config.log' for more details" "$LINENO" 5; }
4706 else
4707 ac_cv_sizeof_intmax_t=0
4708 fi
4709fi
4710
4711fi
4712{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_intmax_t" >&5
4713$as_echo "$ac_cv_sizeof_intmax_t" >&6; }
4714
4715
4716
4717cat >>confdefs.h <<_ACEOF
4718#define SIZEOF_INTMAX_T $ac_cv_sizeof_intmax_t
4719_ACEOF
4720
4721
4722if test "x${ac_cv_sizeof_intmax_t}" = "x16" ; then
4723 LG_SIZEOF_INTMAX_T=4
4724elif test "x${ac_cv_sizeof_intmax_t}" = "x8" ; then
4725 LG_SIZEOF_INTMAX_T=3
4726elif test "x${ac_cv_sizeof_intmax_t}" = "x4" ; then
4727 LG_SIZEOF_INTMAX_T=2
4728else
4729 as_fn_error $? "Unsupported intmax_t size: ${ac_cv_sizeof_intmax_t}" "$LINENO" 5
4730fi
4731cat >>confdefs.h <<_ACEOF
4732#define LG_SIZEOF_INTMAX_T $LG_SIZEOF_INTMAX_T
4733_ACEOF
4734
4735
970d7e83
LB
4736# Make sure we can run config.sub.
4737$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4738 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4739
4740{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4741$as_echo_n "checking build system type... " >&6; }
4742if ${ac_cv_build+:} false; then :
4743 $as_echo_n "(cached) " >&6
4744else
4745 ac_build_alias=$build_alias
4746test "x$ac_build_alias" = x &&
4747 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4748test "x$ac_build_alias" = x &&
4749 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
4750ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4751 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4752
4753fi
4754{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4755$as_echo "$ac_cv_build" >&6; }
4756case $ac_cv_build in
4757*-*-*) ;;
4758*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
4759esac
4760build=$ac_cv_build
4761ac_save_IFS=$IFS; IFS='-'
4762set x $ac_cv_build
4763shift
4764build_cpu=$1
4765build_vendor=$2
4766shift; shift
4767# Remember, the first character of IFS is used to create $*,
4768# except with old shells:
4769build_os=$*
4770IFS=$ac_save_IFS
4771case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4772
4773
4774{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4775$as_echo_n "checking host system type... " >&6; }
4776if ${ac_cv_host+:} false; then :
4777 $as_echo_n "(cached) " >&6
4778else
4779 if test "x$host_alias" = x; then
4780 ac_cv_host=$ac_cv_build
4781else
4782 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4783 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4784fi
4785
4786fi
4787{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4788$as_echo "$ac_cv_host" >&6; }
4789case $ac_cv_host in
4790*-*-*) ;;
4791*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
4792esac
4793host=$ac_cv_host
4794ac_save_IFS=$IFS; IFS='-'
4795set x $ac_cv_host
4796shift
4797host_cpu=$1
4798host_vendor=$2
4799shift; shift
4800# Remember, the first character of IFS is used to create $*,
4801# except with old shells:
4802host_os=$*
4803IFS=$ac_save_IFS
4804case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4805
4806
4807CPU_SPINWAIT=""
4808case "${host_cpu}" in
1a4d82fc 4809 i686|x86_64)
54a0048b
SL
4810 if test "x${je_cv_msvc}" = "xyes" ; then
4811 if ${je_cv_pause_msvc+:} false; then :
4812 $as_echo_n "(cached) " >&6
4813else
970d7e83 4814
54a0048b
SL
4815{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pause instruction MSVC is compilable" >&5
4816$as_echo_n "checking whether pause instruction MSVC is compilable... " >&6; }
4817if ${je_cv_pause_msvc+:} false; then :
970d7e83
LB
4818 $as_echo_n "(cached) " >&6
4819else
4820 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4821/* end confdefs.h. */
4822
4823int
4824main ()
4825{
54a0048b 4826_mm_pause(); return 0;
970d7e83
LB
4827 ;
4828 return 0;
4829}
4830_ACEOF
4831if ac_fn_c_try_link "$LINENO"; then :
54a0048b 4832 je_cv_pause_msvc=yes
970d7e83 4833else
54a0048b 4834 je_cv_pause_msvc=no
970d7e83
LB
4835fi
4836rm -f core conftest.err conftest.$ac_objext \
4837 conftest$ac_exeext conftest.$ac_ext
4838fi
54a0048b
SL
4839{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_pause_msvc" >&5
4840$as_echo "$je_cv_pause_msvc" >&6; }
970d7e83 4841
54a0048b
SL
4842fi
4843
4844 if test "x${je_cv_pause_msvc}" = "xyes" ; then
4845 CPU_SPINWAIT='_mm_pause()'
4846 fi
4847 else
4848 if ${je_cv_pause+:} false; then :
4849 $as_echo_n "(cached) " >&6
4850else
7453a54e 4851
54a0048b
SL
4852{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pause instruction is compilable" >&5
4853$as_echo_n "checking whether pause instruction is compilable... " >&6; }
4854if ${je_cv_pause+:} false; then :
7453a54e
SL
4855 $as_echo_n "(cached) " >&6
4856else
4857 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4858/* end confdefs.h. */
4859
7453a54e
SL
4860int
4861main ()
4862{
54a0048b 4863__asm__ volatile("pause"); return 0;
7453a54e
SL
4864 ;
4865 return 0;
4866}
4867_ACEOF
4868if ac_fn_c_try_link "$LINENO"; then :
54a0048b 4869 je_cv_pause=yes
7453a54e 4870else
54a0048b 4871 je_cv_pause=no
7453a54e
SL
4872fi
4873rm -f core conftest.err conftest.$ac_objext \
4874 conftest$ac_exeext conftest.$ac_ext
4875fi
54a0048b
SL
4876{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_pause" >&5
4877$as_echo "$je_cv_pause" >&6; }
7453a54e 4878
54a0048b 4879fi
7453a54e 4880
54a0048b
SL
4881 if test "x${je_cv_pause}" = "xyes" ; then
4882 CPU_SPINWAIT='__asm__ volatile("pause")'
4883 fi
7453a54e 4884 fi
1a4d82fc
JJ
4885 ;;
4886 powerpc)
4887 cat >>confdefs.h <<_ACEOF
4888#define HAVE_ALTIVEC
4889_ACEOF
4890
970d7e83
LB
4891 ;;
4892 *)
4893 ;;
4894esac
4895cat >>confdefs.h <<_ACEOF
4896#define CPU_SPINWAIT $CPU_SPINWAIT
4897_ACEOF
4898
4899
4900LD_PRELOAD_VAR="LD_PRELOAD"
4901so="so"
4902importlib="${so}"
4903o="$ac_objext"
4904a="a"
4905exe="$ac_exeext"
4906libprefix="lib"
4907DSO_LDFLAGS='-shared -Wl,-soname,$(@F)'
4908RPATH='-Wl,-rpath,$(1)'
4909SOREV="${so}.${rev}"
4910PIC_CFLAGS='-fPIC -DPIC'
4911CTARGET='-o $@'
4912LDTARGET='-o $@'
4913EXTRA_LDFLAGS=
1a4d82fc
JJ
4914ARFLAGS='crus'
4915AROUT=' $@'
970d7e83
LB
4916CC_MM=1
4917
1a4d82fc
JJ
4918
4919
4920
4921if test -n "$ac_tool_prefix"; then
4922 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
4923set dummy ${ac_tool_prefix}ar; ac_word=$2
4924{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4925$as_echo_n "checking for $ac_word... " >&6; }
4926if ${ac_cv_prog_AR+:} false; then :
4927 $as_echo_n "(cached) " >&6
4928else
4929 if test -n "$AR"; then
4930 ac_cv_prog_AR="$AR" # Let the user override the test.
4931else
4932as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4933for as_dir in $PATH
4934do
4935 IFS=$as_save_IFS
4936 test -z "$as_dir" && as_dir=.
4937 for ac_exec_ext in '' $ac_executable_extensions; do
4938 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4939 ac_cv_prog_AR="${ac_tool_prefix}ar"
4940 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4941 break 2
4942 fi
4943done
4944 done
4945IFS=$as_save_IFS
4946
4947fi
4948fi
4949AR=$ac_cv_prog_AR
4950if test -n "$AR"; then
4951 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
4952$as_echo "$AR" >&6; }
4953else
4954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4955$as_echo "no" >&6; }
4956fi
4957
4958
4959fi
4960if test -z "$ac_cv_prog_AR"; then
4961 ac_ct_AR=$AR
4962 # Extract the first word of "ar", so it can be a program name with args.
4963set dummy ar; ac_word=$2
4964{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4965$as_echo_n "checking for $ac_word... " >&6; }
4966if ${ac_cv_prog_ac_ct_AR+:} false; then :
4967 $as_echo_n "(cached) " >&6
4968else
4969 if test -n "$ac_ct_AR"; then
4970 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
4971else
4972as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4973for as_dir in $PATH
4974do
4975 IFS=$as_save_IFS
4976 test -z "$as_dir" && as_dir=.
4977 for ac_exec_ext in '' $ac_executable_extensions; do
4978 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4979 ac_cv_prog_ac_ct_AR="ar"
4980 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4981 break 2
4982 fi
4983done
4984 done
4985IFS=$as_save_IFS
4986
4987fi
4988fi
4989ac_ct_AR=$ac_cv_prog_ac_ct_AR
4990if test -n "$ac_ct_AR"; then
4991 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
4992$as_echo "$ac_ct_AR" >&6; }
4993else
4994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4995$as_echo "no" >&6; }
4996fi
4997
4998 if test "x$ac_ct_AR" = x; then
4999 AR=":"
5000 else
5001 case $cross_compiling:$ac_tool_warned in
5002yes:)
5003{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5004$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5005ac_tool_warned=yes ;;
5006esac
5007 AR=$ac_ct_AR
5008 fi
5009else
5010 AR="$ac_cv_prog_AR"
5011fi
5012
5013
970d7e83 5014default_munmap="1"
54a0048b 5015maps_coalesce="1"
970d7e83 5016case "${host}" in
1a4d82fc 5017 *-*-darwin* | *-*-ios*)
970d7e83
LB
5018 CFLAGS="$CFLAGS"
5019 abi="macho"
5020 $as_echo "#define JEMALLOC_PURGE_MADVISE_FREE " >>confdefs.h
5021
5022 RPATH=""
5023 LD_PRELOAD_VAR="DYLD_INSERT_LIBRARIES"
5024 so="dylib"
5025 importlib="${so}"
5026 force_tls="0"
54a0048b 5027 DSO_LDFLAGS='-shared -Wl,-install_name,$(LIBDIR)/$(@F)'
970d7e83 5028 SOREV="${rev}.${so}"
1a4d82fc 5029 sbrk_deprecated="1"
970d7e83
LB
5030 ;;
5031 *-*-freebsd*)
5032 CFLAGS="$CFLAGS"
5033 abi="elf"
5034 $as_echo "#define JEMALLOC_PURGE_MADVISE_FREE " >>confdefs.h
5035
5036 force_lazy_lock="1"
1a4d82fc
JJ
5037 ;;
5038 *-*-dragonfly*)
5039 CFLAGS="$CFLAGS"
5040 abi="elf"
5041 $as_echo "#define JEMALLOC_PURGE_MADVISE_FREE " >>confdefs.h
5042
c34b1796 5043 ;;
54a0048b
SL
5044 *-*-openbsd*)
5045 CFLAGS="$CFLAGS"
5046 abi="elf"
5047 $as_echo "#define JEMALLOC_PURGE_MADVISE_FREE " >>confdefs.h
5048
5049 force_tls="0"
5050 ;;
5051 *-*-bitrig*)
c34b1796
AL
5052 CFLAGS="$CFLAGS"
5053 abi="elf"
5054 $as_echo "#define JEMALLOC_PURGE_MADVISE_FREE " >>confdefs.h
5055
970d7e83
LB
5056 ;;
5057 *-*-linux*)
5058 CFLAGS="$CFLAGS"
5059 CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
5060 abi="elf"
5061 $as_echo "#define JEMALLOC_HAS_ALLOCA_H 1" >>confdefs.h
5062
5063 $as_echo "#define JEMALLOC_PURGE_MADVISE_DONTNEED " >>confdefs.h
5064
5065 $as_echo "#define JEMALLOC_THREADED_INIT " >>confdefs.h
5066
54a0048b
SL
5067 $as_echo "#define JEMALLOC_USE_CXX_THROW " >>confdefs.h
5068
970d7e83
LB
5069 default_munmap="0"
5070 ;;
5071 *-*-netbsd*)
5072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking ABI" >&5
5073$as_echo_n "checking ABI... " >&6; }
5074 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5075/* end confdefs.h. */
5076#ifdef __ELF__
5077/* ELF */
5078#else
5079#error aout
5080#endif
5081
5082int
5083main ()
5084{
5085
5086 ;
5087 return 0;
5088}
5089_ACEOF
5090if ac_fn_c_try_compile "$LINENO"; then :
5091 CFLAGS="$CFLAGS"; abi="elf"
5092else
5093 abi="aout"
5094fi
5095rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $abi" >&5
5097$as_echo "$abi" >&6; }
5098 $as_echo "#define JEMALLOC_PURGE_MADVISE_FREE " >>confdefs.h
5099
5100 ;;
5101 *-*-solaris2*)
5102 CFLAGS="$CFLAGS"
5103 abi="elf"
1a4d82fc
JJ
5104 $as_echo "#define JEMALLOC_PURGE_MADVISE_FREE " >>confdefs.h
5105
970d7e83
LB
5106 RPATH='-Wl,-R,$(1)'
5107 CPPFLAGS="$CPPFLAGS -D_POSIX_PTHREAD_SEMANTICS"
5108 LIBS="$LIBS -lposix4 -lsocket -lnsl"
5109 ;;
5110 *-ibm-aix*)
5111 if "$LG_SIZEOF_PTR" = "8"; then
5112 LD_PRELOAD_VAR="LDR_PRELOAD64"
5113 else
5114 LD_PRELOAD_VAR="LDR_PRELOAD"
5115 fi
5116 abi="xcoff"
5117 ;;
1a4d82fc 5118 *-*-mingw* | *-*-cygwin*)
970d7e83
LB
5119 abi="pecoff"
5120 force_tls="0"
54a0048b
SL
5121 force_lazy_lock="1"
5122 maps_coalesce="0"
970d7e83
LB
5123 RPATH=""
5124 so="dll"
5125 if test "x$je_cv_msvc" = "xyes" ; then
5126 importlib="lib"
5127 DSO_LDFLAGS="-LD"
5128 EXTRA_LDFLAGS="-link -DEBUG"
5129 CTARGET='-Fo$@'
5130 LDTARGET='-Fe$@'
1a4d82fc
JJ
5131 AR='lib'
5132 ARFLAGS='-nologo -out:'
5133 AROUT='$@'
970d7e83
LB
5134 CC_MM=
5135 else
5136 importlib="${so}"
5137 DSO_LDFLAGS="-shared"
5138 fi
5139 a="lib"
5140 libprefix=""
5141 SOREV="${so}"
5142 PIC_CFLAGS=""
5143 ;;
5144 *)
5145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Unsupported operating system: ${host}" >&5
5146$as_echo "Unsupported operating system: ${host}" >&6; }
5147 abi="elf"
5148 ;;
5149esac
1a4d82fc
JJ
5150
5151JEMALLOC_USABLE_SIZE_CONST=const
5152for ac_header in malloc.h
5153do :
5154 ac_fn_c_check_header_mongrel "$LINENO" "malloc.h" "ac_cv_header_malloc_h" "$ac_includes_default"
5155if test "x$ac_cv_header_malloc_h" = xyes; then :
5156 cat >>confdefs.h <<_ACEOF
5157#define HAVE_MALLOC_H 1
5158_ACEOF
5159
5160 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc_usable_size definition can use const argument" >&5
5161$as_echo_n "checking whether malloc_usable_size definition can use const argument... " >&6; }
5162 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5163/* end confdefs.h. */
5164#include <malloc.h>
5165 #include <stddef.h>
5166 size_t malloc_usable_size(const void *ptr);
5167
5168int
5169main ()
5170{
5171
5172 ;
5173 return 0;
5174}
5175_ACEOF
5176if ac_fn_c_try_compile "$LINENO"; then :
5177
5178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5179$as_echo "yes" >&6; }
5180
5181else
5182
5183 JEMALLOC_USABLE_SIZE_CONST=
5184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5185$as_echo "no" >&6; }
5186
5187fi
5188rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5189
5190fi
5191
5192done
5193
970d7e83
LB
5194cat >>confdefs.h <<_ACEOF
5195#define JEMALLOC_USABLE_SIZE_CONST $JEMALLOC_USABLE_SIZE_CONST
5196_ACEOF
5197
5198
5199
5200
5201
5202
5203
5204
5205
5206
5207
5208
5209
5210
5211
5212
5213
5214
5215
1a4d82fc 5216
970d7e83
LB
5217
5218
54a0048b
SL
5219{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __attribute__ syntax is compilable" >&5
5220$as_echo_n "checking whether __attribute__ syntax is compilable... " >&6; }
5221if ${je_cv_attribute+:} false; then :
5222 $as_echo_n "(cached) " >&6
5223else
5224 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5225/* end confdefs.h. */
5226static __attribute__((unused)) void foo(void){}
5227int
5228main ()
5229{
5230
5231 ;
5232 return 0;
5233}
5234_ACEOF
5235if ac_fn_c_try_link "$LINENO"; then :
5236 je_cv_attribute=yes
5237else
5238 je_cv_attribute=no
5239fi
5240rm -f core conftest.err conftest.$ac_objext \
5241 conftest$ac_exeext conftest.$ac_ext
5242fi
5243{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_attribute" >&5
5244$as_echo "$je_cv_attribute" >&6; }
5245
5246if test "x${je_cv_attribute}" = "xyes" ; then
5247 $as_echo "#define JEMALLOC_HAVE_ATTR " >>confdefs.h
5248
5249 if test "x${GCC}" = "xyes" -a "x${abi}" = "xelf"; then
5250
5251{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -fvisibility=hidden" >&5
5252$as_echo_n "checking whether compiler supports -fvisibility=hidden... " >&6; }
5253TCFLAGS="${CFLAGS}"
5254if test "x${CFLAGS}" = "x" ; then
5255 CFLAGS="-fvisibility=hidden"
5256else
5257 CFLAGS="${CFLAGS} -fvisibility=hidden"
5258fi
5259cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5260/* end confdefs.h. */
5261
5262
5263int
5264main ()
5265{
5266
5267 return 0;
5268
5269 ;
5270 return 0;
5271}
5272_ACEOF
5273if ac_fn_c_try_compile "$LINENO"; then :
5274 je_cv_cflags_appended=-fvisibility=hidden
5275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5276$as_echo "yes" >&6; }
5277else
5278 je_cv_cflags_appended=
5279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5280$as_echo "no" >&6; }
5281 CFLAGS="${TCFLAGS}"
5282
5283fi
5284rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5285
5286 fi
5287fi
5288SAVED_CFLAGS="${CFLAGS}"
5289
5290{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -Werror" >&5
5291$as_echo_n "checking whether compiler supports -Werror... " >&6; }
5292TCFLAGS="${CFLAGS}"
5293if test "x${CFLAGS}" = "x" ; then
5294 CFLAGS="-Werror"
5295else
5296 CFLAGS="${CFLAGS} -Werror"
5297fi
5298cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5299/* end confdefs.h. */
5300
5301
5302int
5303main ()
5304{
5305
5306 return 0;
5307
5308 ;
5309 return 0;
5310}
5311_ACEOF
5312if ac_fn_c_try_compile "$LINENO"; then :
5313 je_cv_cflags_appended=-Werror
5314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5315$as_echo "yes" >&6; }
5316else
5317 je_cv_cflags_appended=
5318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5319$as_echo "no" >&6; }
5320 CFLAGS="${TCFLAGS}"
5321
5322fi
5323rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5324
5325
5326{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether tls_model attribute is compilable" >&5
5327$as_echo_n "checking whether tls_model attribute is compilable... " >&6; }
5328if ${je_cv_tls_model+:} false; then :
5329 $as_echo_n "(cached) " >&6
5330else
5331 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5332/* end confdefs.h. */
5333
5334int
5335main ()
5336{
5337static __thread int
5338 __attribute__((tls_model("initial-exec"), unused)) foo;
5339 foo = 0;
5340 ;
5341 return 0;
5342}
5343_ACEOF
5344if ac_fn_c_try_link "$LINENO"; then :
5345 je_cv_tls_model=yes
5346else
5347 je_cv_tls_model=no
5348fi
5349rm -f core conftest.err conftest.$ac_objext \
5350 conftest$ac_exeext conftest.$ac_ext
5351fi
5352{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_tls_model" >&5
5353$as_echo "$je_cv_tls_model" >&6; }
5354
5355CFLAGS="${SAVED_CFLAGS}"
5356if test "x${je_cv_tls_model}" = "xyes" ; then
5357 $as_echo "#define JEMALLOC_TLS_MODEL __attribute__((tls_model(\"initial-exec\")))" >>confdefs.h
5358
5359else
5360 $as_echo "#define JEMALLOC_TLS_MODEL " >>confdefs.h
5361
5362fi
5363SAVED_CFLAGS="${CFLAGS}"
5364
5365{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -Werror" >&5
5366$as_echo_n "checking whether compiler supports -Werror... " >&6; }
5367TCFLAGS="${CFLAGS}"
5368if test "x${CFLAGS}" = "x" ; then
5369 CFLAGS="-Werror"
5370else
5371 CFLAGS="${CFLAGS} -Werror"
5372fi
5373cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5374/* end confdefs.h. */
5375
5376
5377int
5378main ()
5379{
5380
5381 return 0;
5382
5383 ;
5384 return 0;
5385}
5386_ACEOF
5387if ac_fn_c_try_compile "$LINENO"; then :
5388 je_cv_cflags_appended=-Werror
5389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5390$as_echo "yes" >&6; }
5391else
5392 je_cv_cflags_appended=
5393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5394$as_echo "no" >&6; }
5395 CFLAGS="${TCFLAGS}"
5396
5397fi
5398rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5399
5400
5401{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether alloc_size attribute is compilable" >&5
5402$as_echo_n "checking whether alloc_size attribute is compilable... " >&6; }
5403if ${je_cv_alloc_size+:} false; then :
970d7e83
LB
5404 $as_echo_n "(cached) " >&6
5405else
5406 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5407/* end confdefs.h. */
54a0048b 5408#include <stdlib.h>
970d7e83
LB
5409int
5410main ()
5411{
54a0048b 5412void *foo(size_t size) __attribute__((alloc_size(1)));
970d7e83
LB
5413 ;
5414 return 0;
5415}
5416_ACEOF
5417if ac_fn_c_try_link "$LINENO"; then :
54a0048b 5418 je_cv_alloc_size=yes
970d7e83 5419else
54a0048b 5420 je_cv_alloc_size=no
970d7e83
LB
5421fi
5422rm -f core conftest.err conftest.$ac_objext \
5423 conftest$ac_exeext conftest.$ac_ext
5424fi
54a0048b
SL
5425{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_alloc_size" >&5
5426$as_echo "$je_cv_alloc_size" >&6; }
970d7e83 5427
54a0048b
SL
5428CFLAGS="${SAVED_CFLAGS}"
5429if test "x${je_cv_alloc_size}" = "xyes" ; then
5430 $as_echo "#define JEMALLOC_HAVE_ATTR_ALLOC_SIZE " >>confdefs.h
970d7e83 5431
54a0048b
SL
5432fi
5433SAVED_CFLAGS="${CFLAGS}"
970d7e83 5434
54a0048b
SL
5435{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -Werror" >&5
5436$as_echo_n "checking whether compiler supports -Werror... " >&6; }
970d7e83
LB
5437TCFLAGS="${CFLAGS}"
5438if test "x${CFLAGS}" = "x" ; then
54a0048b 5439 CFLAGS="-Werror"
970d7e83 5440else
54a0048b 5441 CFLAGS="${CFLAGS} -Werror"
970d7e83
LB
5442fi
5443cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5444/* end confdefs.h. */
5445
5446
5447int
5448main ()
5449{
5450
5451 return 0;
5452
5453 ;
5454 return 0;
5455}
5456_ACEOF
5457if ac_fn_c_try_compile "$LINENO"; then :
54a0048b 5458 je_cv_cflags_appended=-Werror
1a4d82fc 5459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
970d7e83
LB
5460$as_echo "yes" >&6; }
5461else
1a4d82fc
JJ
5462 je_cv_cflags_appended=
5463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
970d7e83
LB
5464$as_echo "no" >&6; }
5465 CFLAGS="${TCFLAGS}"
5466
5467fi
5468rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5469
54a0048b
SL
5470
5471{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether format(gnu_printf, ...) attribute is compilable" >&5
5472$as_echo_n "checking whether format(gnu_printf, ...) attribute is compilable... " >&6; }
5473if ${je_cv_format_gnu_printf+:} false; then :
5474 $as_echo_n "(cached) " >&6
5475else
5476 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5477/* end confdefs.h. */
5478#include <stdlib.h>
5479int
5480main ()
5481{
5482void *foo(const char *format, ...) __attribute__((format(gnu_printf, 1, 2)));
5483 ;
5484 return 0;
5485}
5486_ACEOF
5487if ac_fn_c_try_link "$LINENO"; then :
5488 je_cv_format_gnu_printf=yes
5489else
5490 je_cv_format_gnu_printf=no
5491fi
5492rm -f core conftest.err conftest.$ac_objext \
5493 conftest$ac_exeext conftest.$ac_ext
5494fi
5495{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_format_gnu_printf" >&5
5496$as_echo "$je_cv_format_gnu_printf" >&6; }
5497
5498CFLAGS="${SAVED_CFLAGS}"
5499if test "x${je_cv_format_gnu_printf}" = "xyes" ; then
5500 $as_echo "#define JEMALLOC_HAVE_ATTR_FORMAT_GNU_PRINTF " >>confdefs.h
5501
970d7e83
LB
5502fi
5503SAVED_CFLAGS="${CFLAGS}"
5504
5505{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -Werror" >&5
5506$as_echo_n "checking whether compiler supports -Werror... " >&6; }
5507TCFLAGS="${CFLAGS}"
5508if test "x${CFLAGS}" = "x" ; then
5509 CFLAGS="-Werror"
5510else
5511 CFLAGS="${CFLAGS} -Werror"
5512fi
5513cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5514/* end confdefs.h. */
5515
5516
5517int
5518main ()
5519{
5520
5521 return 0;
5522
5523 ;
5524 return 0;
5525}
5526_ACEOF
5527if ac_fn_c_try_compile "$LINENO"; then :
1a4d82fc
JJ
5528 je_cv_cflags_appended=-Werror
5529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
970d7e83
LB
5530$as_echo "yes" >&6; }
5531else
1a4d82fc
JJ
5532 je_cv_cflags_appended=
5533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
970d7e83
LB
5534$as_echo "no" >&6; }
5535 CFLAGS="${TCFLAGS}"
5536
5537fi
5538rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5539
5540
54a0048b
SL
5541{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether format(printf, ...) attribute is compilable" >&5
5542$as_echo_n "checking whether format(printf, ...) attribute is compilable... " >&6; }
5543if ${je_cv_format_printf+:} false; then :
970d7e83
LB
5544 $as_echo_n "(cached) " >&6
5545else
5546 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5547/* end confdefs.h. */
54a0048b 5548#include <stdlib.h>
970d7e83
LB
5549int
5550main ()
5551{
54a0048b 5552void *foo(const char *format, ...) __attribute__((format(printf, 1, 2)));
970d7e83
LB
5553 ;
5554 return 0;
5555}
5556_ACEOF
5557if ac_fn_c_try_link "$LINENO"; then :
54a0048b 5558 je_cv_format_printf=yes
970d7e83 5559else
54a0048b 5560 je_cv_format_printf=no
970d7e83
LB
5561fi
5562rm -f core conftest.err conftest.$ac_objext \
5563 conftest$ac_exeext conftest.$ac_ext
5564fi
54a0048b
SL
5565{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_format_printf" >&5
5566$as_echo "$je_cv_format_printf" >&6; }
970d7e83
LB
5567
5568CFLAGS="${SAVED_CFLAGS}"
54a0048b
SL
5569if test "x${je_cv_format_printf}" = "xyes" ; then
5570 $as_echo "#define JEMALLOC_HAVE_ATTR_FORMAT_PRINTF " >>confdefs.h
970d7e83
LB
5571
5572fi
5573
5574
5575# Check whether --with-rpath was given.
5576if test "${with_rpath+set}" = set; then :
5577 withval=$with_rpath; if test "x$with_rpath" = "xno" ; then
5578 RPATH_EXTRA=
5579else
5580 RPATH_EXTRA="`echo $with_rpath | tr \":\" \" \"`"
5581fi
5582else
5583 RPATH_EXTRA=
5584
5585fi
5586
5587
5588
5589# Check whether --enable-autogen was given.
5590if test "${enable_autogen+set}" = set; then :
5591 enableval=$enable_autogen; if test "x$enable_autogen" = "xno" ; then
5592 enable_autogen="0"
5593else
5594 enable_autogen="1"
5595fi
5596
5597else
5598 enable_autogen="0"
5599
5600fi
5601
5602
5603
5604# Find a good install program. We prefer a C program (faster),
5605# so one script is as good as another. But avoid the broken or
5606# incompatible versions:
5607# SysV /etc/install, /usr/sbin/install
5608# SunOS /usr/etc/install
5609# IRIX /sbin/install
5610# AIX /bin/install
5611# AmigaOS /C/install, which installs bootblocks on floppy discs
5612# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
5613# AFS /usr/afsws/bin/install, which mishandles nonexistent args
5614# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
5615# OS/2's system install, which has a completely different semantic
5616# ./install, which can be erroneously created by make from ./install.sh.
5617# Reject install programs that cannot install multiple files.
5618{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
5619$as_echo_n "checking for a BSD-compatible install... " >&6; }
5620if test -z "$INSTALL"; then
5621if ${ac_cv_path_install+:} false; then :
5622 $as_echo_n "(cached) " >&6
5623else
5624 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5625for as_dir in $PATH
5626do
5627 IFS=$as_save_IFS
5628 test -z "$as_dir" && as_dir=.
5629 # Account for people who put trailing slashes in PATH elements.
5630case $as_dir/ in #((
5631 ./ | .// | /[cC]/* | \
5632 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
5633 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
5634 /usr/ucb/* ) ;;
5635 *)
5636 # OSF1 and SCO ODT 3.0 have their own names for install.
5637 # Don't use installbsd from OSF since it installs stuff as root
5638 # by default.
5639 for ac_prog in ginstall scoinst install; do
5640 for ac_exec_ext in '' $ac_executable_extensions; do
5641 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
5642 if test $ac_prog = install &&
5643 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
5644 # AIX install. It has an incompatible calling convention.
5645 :
5646 elif test $ac_prog = install &&
5647 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
5648 # program-specific install script used by HP pwplus--don't use.
5649 :
5650 else
5651 rm -rf conftest.one conftest.two conftest.dir
5652 echo one > conftest.one
5653 echo two > conftest.two
5654 mkdir conftest.dir
5655 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
5656 test -s conftest.one && test -s conftest.two &&
5657 test -s conftest.dir/conftest.one &&
5658 test -s conftest.dir/conftest.two
5659 then
5660 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
5661 break 3
5662 fi
5663 fi
5664 fi
5665 done
5666 done
5667 ;;
5668esac
5669
5670 done
5671IFS=$as_save_IFS
5672
5673rm -rf conftest.one conftest.two conftest.dir
5674
5675fi
5676 if test "${ac_cv_path_install+set}" = set; then
5677 INSTALL=$ac_cv_path_install
5678 else
5679 # As a last resort, use the slow shell script. Don't cache a
5680 # value for INSTALL within a source directory, because that will
5681 # break other packages using the cache if that directory is
5682 # removed, or if the value is a relative name.
5683 INSTALL=$ac_install_sh
5684 fi
5685fi
5686{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
5687$as_echo "$INSTALL" >&6; }
5688
5689# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
5690# It thinks the first close brace ends the variable substitution.
5691test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
5692
5693test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
5694
5695test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
5696
5697if test -n "$ac_tool_prefix"; then
5698 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5699set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5700{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5701$as_echo_n "checking for $ac_word... " >&6; }
5702if ${ac_cv_prog_RANLIB+:} false; then :
5703 $as_echo_n "(cached) " >&6
5704else
5705 if test -n "$RANLIB"; then
5706 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5707else
5708as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5709for as_dir in $PATH
5710do
5711 IFS=$as_save_IFS
5712 test -z "$as_dir" && as_dir=.
5713 for ac_exec_ext in '' $ac_executable_extensions; do
5714 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5715 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5716 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5717 break 2
5718 fi
5719done
5720 done
5721IFS=$as_save_IFS
5722
5723fi
5724fi
5725RANLIB=$ac_cv_prog_RANLIB
5726if test -n "$RANLIB"; then
5727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
5728$as_echo "$RANLIB" >&6; }
5729else
5730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5731$as_echo "no" >&6; }
5732fi
5733
5734
5735fi
5736if test -z "$ac_cv_prog_RANLIB"; then
5737 ac_ct_RANLIB=$RANLIB
5738 # Extract the first word of "ranlib", so it can be a program name with args.
5739set dummy ranlib; ac_word=$2
5740{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5741$as_echo_n "checking for $ac_word... " >&6; }
5742if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
5743 $as_echo_n "(cached) " >&6
5744else
5745 if test -n "$ac_ct_RANLIB"; then
5746 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5747else
5748as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5749for as_dir in $PATH
5750do
5751 IFS=$as_save_IFS
5752 test -z "$as_dir" && as_dir=.
5753 for ac_exec_ext in '' $ac_executable_extensions; do
5754 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5755 ac_cv_prog_ac_ct_RANLIB="ranlib"
5756 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5757 break 2
5758 fi
5759done
5760 done
5761IFS=$as_save_IFS
5762
5763fi
5764fi
5765ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5766if test -n "$ac_ct_RANLIB"; then
5767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
5768$as_echo "$ac_ct_RANLIB" >&6; }
5769else
5770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5771$as_echo "no" >&6; }
5772fi
5773
5774 if test "x$ac_ct_RANLIB" = x; then
5775 RANLIB=":"
5776 else
5777 case $cross_compiling:$ac_tool_warned in
5778yes:)
5779{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5780$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5781ac_tool_warned=yes ;;
5782esac
5783 RANLIB=$ac_ct_RANLIB
5784 fi
5785else
5786 RANLIB="$ac_cv_prog_RANLIB"
5787fi
5788
1a4d82fc
JJ
5789# Extract the first word of "ld", so it can be a program name with args.
5790set dummy ld; ac_word=$2
970d7e83
LB
5791{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5792$as_echo_n "checking for $ac_word... " >&6; }
5793if ${ac_cv_path_LD+:} false; then :
5794 $as_echo_n "(cached) " >&6
5795else
5796 case $LD in
5797 [\\/]* | ?:[\\/]*)
5798 ac_cv_path_LD="$LD" # Let the user override the test with a path.
5799 ;;
5800 *)
5801 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5802for as_dir in $PATH
5803do
5804 IFS=$as_save_IFS
5805 test -z "$as_dir" && as_dir=.
5806 for ac_exec_ext in '' $ac_executable_extensions; do
5807 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5808 ac_cv_path_LD="$as_dir/$ac_word$ac_exec_ext"
5809 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5810 break 2
5811 fi
5812done
5813 done
5814IFS=$as_save_IFS
5815
5816 test -z "$ac_cv_path_LD" && ac_cv_path_LD="false"
5817 ;;
5818esac
5819fi
5820LD=$ac_cv_path_LD
5821if test -n "$LD"; then
5822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
5823$as_echo "$LD" >&6; }
5824else
5825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5826$as_echo "no" >&6; }
5827fi
5828
5829
5830# Extract the first word of "autoconf", so it can be a program name with args.
5831set dummy autoconf; ac_word=$2
5832{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5833$as_echo_n "checking for $ac_word... " >&6; }
5834if ${ac_cv_path_AUTOCONF+:} false; then :
5835 $as_echo_n "(cached) " >&6
5836else
5837 case $AUTOCONF in
5838 [\\/]* | ?:[\\/]*)
5839 ac_cv_path_AUTOCONF="$AUTOCONF" # Let the user override the test with a path.
5840 ;;
5841 *)
5842 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5843for as_dir in $PATH
5844do
5845 IFS=$as_save_IFS
5846 test -z "$as_dir" && as_dir=.
5847 for ac_exec_ext in '' $ac_executable_extensions; do
5848 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5849 ac_cv_path_AUTOCONF="$as_dir/$ac_word$ac_exec_ext"
5850 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5851 break 2
5852 fi
5853done
5854 done
5855IFS=$as_save_IFS
5856
5857 test -z "$ac_cv_path_AUTOCONF" && ac_cv_path_AUTOCONF="false"
5858 ;;
5859esac
5860fi
5861AUTOCONF=$ac_cv_path_AUTOCONF
5862if test -n "$AUTOCONF"; then
5863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AUTOCONF" >&5
5864$as_echo "$AUTOCONF" >&6; }
5865else
5866 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5867$as_echo "no" >&6; }
5868fi
5869
5870
5871
1a4d82fc 5872public_syms="malloc_conf malloc_message malloc calloc posix_memalign aligned_alloc realloc free mallocx rallocx xallocx sallocx dallocx sdallocx nallocx mallctl mallctlnametomib mallctlbymib malloc_stats_print malloc_usable_size"
970d7e83
LB
5873
5874ac_fn_c_check_func "$LINENO" "memalign" "ac_cv_func_memalign"
5875if test "x$ac_cv_func_memalign" = xyes; then :
5876 $as_echo "#define JEMALLOC_OVERRIDE_MEMALIGN " >>confdefs.h
5877
5878 public_syms="${public_syms} memalign"
5879fi
5880
5881ac_fn_c_check_func "$LINENO" "valloc" "ac_cv_func_valloc"
5882if test "x$ac_cv_func_valloc" = xyes; then :
5883 $as_echo "#define JEMALLOC_OVERRIDE_VALLOC " >>confdefs.h
5884
5885 public_syms="${public_syms} valloc"
5886fi
5887
5888
1a4d82fc
JJ
5889GCOV_FLAGS=
5890# Check whether --enable-code-coverage was given.
5891if test "${enable_code_coverage+set}" = set; then :
5892 enableval=$enable_code_coverage; if test "x$enable_code_coverage" = "xno" ; then
5893 enable_code_coverage="0"
5894else
5895 enable_code_coverage="1"
5896fi
5897
5898else
5899 enable_code_coverage="0"
5900
5901fi
5902
5903if test "x$enable_code_coverage" = "x1" ; then
5904 deoptimize="no"
5905 echo "$CFLAGS $EXTRA_CFLAGS" | grep '\-O' >/dev/null || deoptimize="yes"
5906 if test "x${deoptimize}" = "xyes" ; then
5907
5908{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -O0" >&5
5909$as_echo_n "checking whether compiler supports -O0... " >&6; }
5910TCFLAGS="${CFLAGS}"
5911if test "x${CFLAGS}" = "x" ; then
5912 CFLAGS="-O0"
5913else
5914 CFLAGS="${CFLAGS} -O0"
5915fi
5916cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5917/* end confdefs.h. */
5918
5919
5920int
5921main ()
5922{
5923
5924 return 0;
5925
5926 ;
5927 return 0;
5928}
5929_ACEOF
5930if ac_fn_c_try_compile "$LINENO"; then :
5931 je_cv_cflags_appended=-O0
5932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5933$as_echo "yes" >&6; }
5934else
5935 je_cv_cflags_appended=
5936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5937$as_echo "no" >&6; }
5938 CFLAGS="${TCFLAGS}"
5939
5940fi
5941rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5942
5943 fi
5944
5945{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -fprofile-arcs -ftest-coverage" >&5
5946$as_echo_n "checking whether compiler supports -fprofile-arcs -ftest-coverage... " >&6; }
5947TCFLAGS="${CFLAGS}"
5948if test "x${CFLAGS}" = "x" ; then
5949 CFLAGS="-fprofile-arcs -ftest-coverage"
970d7e83 5950else
1a4d82fc 5951 CFLAGS="${CFLAGS} -fprofile-arcs -ftest-coverage"
970d7e83 5952fi
1a4d82fc
JJ
5953cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5954/* end confdefs.h. */
5955
970d7e83 5956
1a4d82fc
JJ
5957int
5958main ()
5959{
5960
5961 return 0;
5962
5963 ;
5964 return 0;
5965}
5966_ACEOF
5967if ac_fn_c_try_compile "$LINENO"; then :
5968 je_cv_cflags_appended=-fprofile-arcs -ftest-coverage
5969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5970$as_echo "yes" >&6; }
970d7e83 5971else
1a4d82fc
JJ
5972 je_cv_cflags_appended=
5973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5974$as_echo "no" >&6; }
5975 CFLAGS="${TCFLAGS}"
970d7e83
LB
5976
5977fi
1a4d82fc 5978rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
970d7e83 5979
1a4d82fc
JJ
5980 EXTRA_LDFLAGS="$EXTRA_LDFLAGS -fprofile-arcs -ftest-coverage"
5981 $as_echo "#define JEMALLOC_CODE_COVERAGE " >>confdefs.h
970d7e83 5982
970d7e83
LB
5983fi
5984
5985
5986
5987# Check whether --with-mangling was given.
5988if test "${with_mangling+set}" = set; then :
5989 withval=$with_mangling; mangling_map="$with_mangling"
5990else
5991 mangling_map=""
5992fi
5993
970d7e83
LB
5994
5995
5996# Check whether --with-jemalloc_prefix was given.
5997if test "${with_jemalloc_prefix+set}" = set; then :
5998 withval=$with_jemalloc_prefix; JEMALLOC_PREFIX="$with_jemalloc_prefix"
5999else
6000 if test "x$abi" != "xmacho" -a "x$abi" != "xpecoff"; then
6001 JEMALLOC_PREFIX=""
6002else
6003 JEMALLOC_PREFIX="je_"
6004fi
6005
6006fi
6007
6008if test "x$JEMALLOC_PREFIX" != "x" ; then
6009 JEMALLOC_CPREFIX=`echo ${JEMALLOC_PREFIX} | tr "a-z" "A-Z"`
6010 cat >>confdefs.h <<_ACEOF
6011#define JEMALLOC_PREFIX "$JEMALLOC_PREFIX"
6012_ACEOF
6013
6014 cat >>confdefs.h <<_ACEOF
6015#define JEMALLOC_CPREFIX "$JEMALLOC_CPREFIX"
6016_ACEOF
6017
6018fi
970d7e83
LB
6019
6020
54a0048b 6021
970d7e83
LB
6022# Check whether --with-export was given.
6023if test "${with_export+set}" = set; then :
6024 withval=$with_export; if test "x$with_export" = "xno"; then
6025 $as_echo "#define JEMALLOC_EXPORT /**/" >>confdefs.h
6026
6027fi
6028
6029fi
6030
6031
6032
6033# Check whether --with-private_namespace was given.
6034if test "${with_private_namespace+set}" = set; then :
1a4d82fc 6035 withval=$with_private_namespace; JEMALLOC_PRIVATE_NAMESPACE="${with_private_namespace}je_"
970d7e83 6036else
1a4d82fc 6037 JEMALLOC_PRIVATE_NAMESPACE="je_"
970d7e83
LB
6038
6039fi
6040
6041cat >>confdefs.h <<_ACEOF
1a4d82fc 6042#define JEMALLOC_PRIVATE_NAMESPACE $JEMALLOC_PRIVATE_NAMESPACE
970d7e83
LB
6043_ACEOF
6044
1a4d82fc 6045private_namespace="$JEMALLOC_PRIVATE_NAMESPACE"
970d7e83 6046
970d7e83
LB
6047
6048
6049# Check whether --with-install_suffix was given.
6050if test "${with_install_suffix+set}" = set; then :
6051 withval=$with_install_suffix; INSTALL_SUFFIX="$with_install_suffix"
6052else
6053 INSTALL_SUFFIX=
6054
6055fi
6056
6057install_suffix="$INSTALL_SUFFIX"
6058
6059
54a0048b
SL
6060
6061# Check whether --with-malloc_conf was given.
6062if test "${with_malloc_conf+set}" = set; then :
6063 withval=$with_malloc_conf; JEMALLOC_CONFIG_MALLOC_CONF="$with_malloc_conf"
6064else
6065 JEMALLOC_CONFIG_MALLOC_CONF=""
6066
6067fi
6068
6069config_malloc_conf="$JEMALLOC_CONFIG_MALLOC_CONF"
6070cat >>confdefs.h <<_ACEOF
6071#define JEMALLOC_CONFIG_MALLOC_CONF "$config_malloc_conf"
6072_ACEOF
6073
6074
1a4d82fc
JJ
6075je_="je_"
6076
6077
6078cfgoutputs_in="Makefile.in"
6079cfgoutputs_in="${cfgoutputs_in} jemalloc.pc.in"
6080cfgoutputs_in="${cfgoutputs_in} doc/html.xsl.in"
6081cfgoutputs_in="${cfgoutputs_in} doc/manpages.xsl.in"
6082cfgoutputs_in="${cfgoutputs_in} doc/jemalloc.xml.in"
6083cfgoutputs_in="${cfgoutputs_in} include/jemalloc/jemalloc_macros.h.in"
6084cfgoutputs_in="${cfgoutputs_in} include/jemalloc/jemalloc_protos.h.in"
6085cfgoutputs_in="${cfgoutputs_in} include/jemalloc/jemalloc_typedefs.h.in"
6086cfgoutputs_in="${cfgoutputs_in} include/jemalloc/internal/jemalloc_internal.h.in"
6087cfgoutputs_in="${cfgoutputs_in} test/test.sh.in"
6088cfgoutputs_in="${cfgoutputs_in} test/include/test/jemalloc_test.h.in"
970d7e83
LB
6089
6090cfgoutputs_out="Makefile"
1a4d82fc 6091cfgoutputs_out="${cfgoutputs_out} jemalloc.pc"
970d7e83
LB
6092cfgoutputs_out="${cfgoutputs_out} doc/html.xsl"
6093cfgoutputs_out="${cfgoutputs_out} doc/manpages.xsl"
1a4d82fc
JJ
6094cfgoutputs_out="${cfgoutputs_out} doc/jemalloc.xml"
6095cfgoutputs_out="${cfgoutputs_out} include/jemalloc/jemalloc_macros.h"
6096cfgoutputs_out="${cfgoutputs_out} include/jemalloc/jemalloc_protos.h"
6097cfgoutputs_out="${cfgoutputs_out} include/jemalloc/jemalloc_typedefs.h"
970d7e83 6098cfgoutputs_out="${cfgoutputs_out} include/jemalloc/internal/jemalloc_internal.h"
1a4d82fc
JJ
6099cfgoutputs_out="${cfgoutputs_out} test/test.sh"
6100cfgoutputs_out="${cfgoutputs_out} test/include/test/jemalloc_test.h"
970d7e83
LB
6101
6102cfgoutputs_tup="Makefile"
1a4d82fc 6103cfgoutputs_tup="${cfgoutputs_tup} jemalloc.pc:jemalloc.pc.in"
970d7e83
LB
6104cfgoutputs_tup="${cfgoutputs_tup} doc/html.xsl:doc/html.xsl.in"
6105cfgoutputs_tup="${cfgoutputs_tup} doc/manpages.xsl:doc/manpages.xsl.in"
1a4d82fc
JJ
6106cfgoutputs_tup="${cfgoutputs_tup} doc/jemalloc.xml:doc/jemalloc.xml.in"
6107cfgoutputs_tup="${cfgoutputs_tup} include/jemalloc/jemalloc_macros.h:include/jemalloc/jemalloc_macros.h.in"
6108cfgoutputs_tup="${cfgoutputs_tup} include/jemalloc/jemalloc_protos.h:include/jemalloc/jemalloc_protos.h.in"
6109cfgoutputs_tup="${cfgoutputs_tup} include/jemalloc/jemalloc_typedefs.h:include/jemalloc/jemalloc_typedefs.h.in"
970d7e83 6110cfgoutputs_tup="${cfgoutputs_tup} include/jemalloc/internal/jemalloc_internal.h"
1a4d82fc
JJ
6111cfgoutputs_tup="${cfgoutputs_tup} test/test.sh:test/test.sh.in"
6112cfgoutputs_tup="${cfgoutputs_tup} test/include/test/jemalloc_test.h:test/include/test/jemalloc_test.h.in"
6113
6114cfghdrs_in="include/jemalloc/jemalloc_defs.h.in"
6115cfghdrs_in="${cfghdrs_in} include/jemalloc/internal/jemalloc_internal_defs.h.in"
6116cfghdrs_in="${cfghdrs_in} include/jemalloc/internal/private_namespace.sh"
6117cfghdrs_in="${cfghdrs_in} include/jemalloc/internal/private_unnamespace.sh"
6118cfghdrs_in="${cfghdrs_in} include/jemalloc/internal/private_symbols.txt"
6119cfghdrs_in="${cfghdrs_in} include/jemalloc/internal/public_namespace.sh"
6120cfghdrs_in="${cfghdrs_in} include/jemalloc/internal/public_unnamespace.sh"
6121cfghdrs_in="${cfghdrs_in} include/jemalloc/internal/size_classes.sh"
6122cfghdrs_in="${cfghdrs_in} include/jemalloc/jemalloc_rename.sh"
6123cfghdrs_in="${cfghdrs_in} include/jemalloc/jemalloc_mangle.sh"
6124cfghdrs_in="${cfghdrs_in} include/jemalloc/jemalloc.sh"
6125cfghdrs_in="${cfghdrs_in} test/include/test/jemalloc_test_defs.h.in"
6126
6127cfghdrs_out="include/jemalloc/jemalloc_defs.h"
6128cfghdrs_out="${cfghdrs_out} include/jemalloc/jemalloc${install_suffix}.h"
6129cfghdrs_out="${cfghdrs_out} include/jemalloc/internal/private_namespace.h"
6130cfghdrs_out="${cfghdrs_out} include/jemalloc/internal/private_unnamespace.h"
6131cfghdrs_out="${cfghdrs_out} include/jemalloc/internal/public_symbols.txt"
6132cfghdrs_out="${cfghdrs_out} include/jemalloc/internal/public_namespace.h"
6133cfghdrs_out="${cfghdrs_out} include/jemalloc/internal/public_unnamespace.h"
970d7e83 6134cfghdrs_out="${cfghdrs_out} include/jemalloc/internal/size_classes.h"
1a4d82fc
JJ
6135cfghdrs_out="${cfghdrs_out} include/jemalloc/jemalloc_protos_jet.h"
6136cfghdrs_out="${cfghdrs_out} include/jemalloc/jemalloc_rename.h"
6137cfghdrs_out="${cfghdrs_out} include/jemalloc/jemalloc_mangle.h"
6138cfghdrs_out="${cfghdrs_out} include/jemalloc/jemalloc_mangle_jet.h"
6139cfghdrs_out="${cfghdrs_out} include/jemalloc/internal/jemalloc_internal_defs.h"
6140cfghdrs_out="${cfghdrs_out} test/include/test/jemalloc_test_defs.h"
970d7e83 6141
1a4d82fc
JJ
6142cfghdrs_tup="include/jemalloc/jemalloc_defs.h:include/jemalloc/jemalloc_defs.h.in"
6143cfghdrs_tup="${cfghdrs_tup} include/jemalloc/internal/jemalloc_internal_defs.h:include/jemalloc/internal/jemalloc_internal_defs.h.in"
6144cfghdrs_tup="${cfghdrs_tup} test/include/test/jemalloc_test_defs.h:test/include/test/jemalloc_test_defs.h.in"
970d7e83
LB
6145
6146# Check whether --enable-cc-silence was given.
6147if test "${enable_cc_silence+set}" = set; then :
6148 enableval=$enable_cc_silence; if test "x$enable_cc_silence" = "xno" ; then
6149 enable_cc_silence="0"
6150else
6151 enable_cc_silence="1"
6152fi
6153
6154else
1a4d82fc 6155 enable_cc_silence="1"
970d7e83
LB
6156
6157fi
6158
6159if test "x$enable_cc_silence" = "x1" ; then
6160 $as_echo "#define JEMALLOC_CC_SILENCE " >>confdefs.h
6161
6162fi
6163
6164# Check whether --enable-debug was given.
6165if test "${enable_debug+set}" = set; then :
6166 enableval=$enable_debug; if test "x$enable_debug" = "xno" ; then
6167 enable_debug="0"
6168else
6169 enable_debug="1"
6170fi
6171
6172else
6173 enable_debug="0"
6174
6175fi
6176
54a0048b
SL
6177if test "x$enable_debug" = "x1" ; then
6178 $as_echo "#define JEMALLOC_DEBUG " >>confdefs.h
6179
6180fi
970d7e83
LB
6181if test "x$enable_debug" = "x1" ; then
6182 $as_echo "#define JEMALLOC_DEBUG " >>confdefs.h
6183
6184 enable_ivsalloc="1"
6185fi
6186
6187
6188# Check whether --enable-ivsalloc was given.
6189if test "${enable_ivsalloc+set}" = set; then :
6190 enableval=$enable_ivsalloc; if test "x$enable_ivsalloc" = "xno" ; then
6191 enable_ivsalloc="0"
6192else
6193 enable_ivsalloc="1"
6194fi
6195
6196else
6197 enable_ivsalloc="0"
6198
6199fi
6200
6201if test "x$enable_ivsalloc" = "x1" ; then
6202 $as_echo "#define JEMALLOC_IVSALLOC " >>confdefs.h
6203
6204fi
6205
6206if test "x$enable_debug" = "x0" -a "x$no_CFLAGS" = "xyes" ; then
6207 optimize="no"
1a4d82fc 6208 echo "$CFLAGS $EXTRA_CFLAGS" | grep '\-O' >/dev/null || optimize="yes"
970d7e83
LB
6209 if test "x${optimize}" = "xyes" ; then
6210 if test "x$GCC" = "xyes" ; then
6211
6212{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -O3" >&5
6213$as_echo_n "checking whether compiler supports -O3... " >&6; }
6214TCFLAGS="${CFLAGS}"
6215if test "x${CFLAGS}" = "x" ; then
6216 CFLAGS="-O3"
6217else
6218 CFLAGS="${CFLAGS} -O3"
6219fi
6220cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6221/* end confdefs.h. */
6222
6223
6224int
6225main ()
6226{
6227
6228 return 0;
6229
6230 ;
6231 return 0;
6232}
6233_ACEOF
6234if ac_fn_c_try_compile "$LINENO"; then :
1a4d82fc
JJ
6235 je_cv_cflags_appended=-O3
6236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
970d7e83
LB
6237$as_echo "yes" >&6; }
6238else
1a4d82fc
JJ
6239 je_cv_cflags_appended=
6240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
970d7e83
LB
6241$as_echo "no" >&6; }
6242 CFLAGS="${TCFLAGS}"
6243
6244fi
6245rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6246
6247
6248{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -funroll-loops" >&5
6249$as_echo_n "checking whether compiler supports -funroll-loops... " >&6; }
6250TCFLAGS="${CFLAGS}"
6251if test "x${CFLAGS}" = "x" ; then
6252 CFLAGS="-funroll-loops"
6253else
6254 CFLAGS="${CFLAGS} -funroll-loops"
6255fi
6256cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6257/* end confdefs.h. */
6258
6259
6260int
6261main ()
6262{
6263
6264 return 0;
6265
6266 ;
6267 return 0;
6268}
6269_ACEOF
6270if ac_fn_c_try_compile "$LINENO"; then :
1a4d82fc
JJ
6271 je_cv_cflags_appended=-funroll-loops
6272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
970d7e83
LB
6273$as_echo "yes" >&6; }
6274else
1a4d82fc
JJ
6275 je_cv_cflags_appended=
6276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
970d7e83
LB
6277$as_echo "no" >&6; }
6278 CFLAGS="${TCFLAGS}"
6279
6280fi
6281rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6282
6283 elif test "x$je_cv_msvc" = "xyes" ; then
6284
6285{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -O2" >&5
6286$as_echo_n "checking whether compiler supports -O2... " >&6; }
6287TCFLAGS="${CFLAGS}"
6288if test "x${CFLAGS}" = "x" ; then
6289 CFLAGS="-O2"
6290else
6291 CFLAGS="${CFLAGS} -O2"
6292fi
6293cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6294/* end confdefs.h. */
6295
6296
6297int
6298main ()
6299{
6300
6301 return 0;
6302
6303 ;
6304 return 0;
6305}
6306_ACEOF
6307if ac_fn_c_try_compile "$LINENO"; then :
1a4d82fc
JJ
6308 je_cv_cflags_appended=-O2
6309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
970d7e83
LB
6310$as_echo "yes" >&6; }
6311else
1a4d82fc
JJ
6312 je_cv_cflags_appended=
6313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
970d7e83
LB
6314$as_echo "no" >&6; }
6315 CFLAGS="${TCFLAGS}"
6316
6317fi
6318rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6319
6320 else
6321
6322{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -O" >&5
6323$as_echo_n "checking whether compiler supports -O... " >&6; }
6324TCFLAGS="${CFLAGS}"
6325if test "x${CFLAGS}" = "x" ; then
6326 CFLAGS="-O"
6327else
6328 CFLAGS="${CFLAGS} -O"
6329fi
6330cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6331/* end confdefs.h. */
6332
6333
6334int
6335main ()
6336{
6337
6338 return 0;
6339
6340 ;
6341 return 0;
6342}
6343_ACEOF
6344if ac_fn_c_try_compile "$LINENO"; then :
1a4d82fc
JJ
6345 je_cv_cflags_appended=-O
6346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
970d7e83
LB
6347$as_echo "yes" >&6; }
6348else
1a4d82fc
JJ
6349 je_cv_cflags_appended=
6350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
970d7e83
LB
6351$as_echo "no" >&6; }
6352 CFLAGS="${TCFLAGS}"
6353
6354fi
6355rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6356
6357 fi
6358 fi
6359fi
6360
6361# Check whether --enable-stats was given.
6362if test "${enable_stats+set}" = set; then :
6363 enableval=$enable_stats; if test "x$enable_stats" = "xno" ; then
6364 enable_stats="0"
6365else
6366 enable_stats="1"
6367fi
6368
6369else
6370 enable_stats="1"
6371
6372fi
6373
6374if test "x$enable_stats" = "x1" ; then
6375 $as_echo "#define JEMALLOC_STATS " >>confdefs.h
6376
6377fi
6378
6379
6380# Check whether --enable-prof was given.
6381if test "${enable_prof+set}" = set; then :
6382 enableval=$enable_prof; if test "x$enable_prof" = "xno" ; then
6383 enable_prof="0"
6384else
6385 enable_prof="1"
6386fi
6387
6388else
6389 enable_prof="0"
6390
6391fi
6392
6393if test "x$enable_prof" = "x1" ; then
6394 backtrace_method=""
6395else
6396 backtrace_method="N/A"
6397fi
6398
6399# Check whether --enable-prof-libunwind was given.
6400if test "${enable_prof_libunwind+set}" = set; then :
6401 enableval=$enable_prof_libunwind; if test "x$enable_prof_libunwind" = "xno" ; then
6402 enable_prof_libunwind="0"
6403else
6404 enable_prof_libunwind="1"
6405fi
6406
6407else
6408 enable_prof_libunwind="0"
6409
6410fi
6411
6412
6413# Check whether --with-static_libunwind was given.
6414if test "${with_static_libunwind+set}" = set; then :
6415 withval=$with_static_libunwind; if test "x$with_static_libunwind" = "xno" ; then
6416 LUNWIND="-lunwind"
6417else
6418 if test ! -f "$with_static_libunwind" ; then
6419 as_fn_error $? "Static libunwind not found: $with_static_libunwind" "$LINENO" 5
6420 fi
6421 LUNWIND="$with_static_libunwind"
6422fi
6423else
6424 LUNWIND="-lunwind"
6425
6426fi
6427
6428if test "x$backtrace_method" = "x" -a "x$enable_prof_libunwind" = "x1" ; then
6429 for ac_header in libunwind.h
6430do :
6431 ac_fn_c_check_header_mongrel "$LINENO" "libunwind.h" "ac_cv_header_libunwind_h" "$ac_includes_default"
6432if test "x$ac_cv_header_libunwind_h" = xyes; then :
6433 cat >>confdefs.h <<_ACEOF
6434#define HAVE_LIBUNWIND_H 1
6435_ACEOF
6436
6437else
6438 enable_prof_libunwind="0"
6439fi
6440
6441done
6442
6443 if test "x$LUNWIND" = "x-lunwind" ; then
1a4d82fc
JJ
6444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unw_backtrace in -lunwind" >&5
6445$as_echo_n "checking for unw_backtrace in -lunwind... " >&6; }
6446if ${ac_cv_lib_unwind_unw_backtrace+:} false; then :
970d7e83
LB
6447 $as_echo_n "(cached) " >&6
6448else
6449 ac_check_lib_save_LIBS=$LIBS
6450LIBS="-lunwind $LIBS"
6451cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6452/* end confdefs.h. */
6453
6454/* Override any GCC internal prototype to avoid an error.
6455 Use char because int might match the return type of a GCC
6456 builtin and then its argument prototype would still apply. */
6457#ifdef __cplusplus
6458extern "C"
6459#endif
1a4d82fc 6460char unw_backtrace ();
970d7e83
LB
6461int
6462main ()
6463{
1a4d82fc 6464return unw_backtrace ();
970d7e83
LB
6465 ;
6466 return 0;
6467}
6468_ACEOF
6469if ac_fn_c_try_link "$LINENO"; then :
1a4d82fc 6470 ac_cv_lib_unwind_unw_backtrace=yes
970d7e83 6471else
1a4d82fc 6472 ac_cv_lib_unwind_unw_backtrace=no
970d7e83
LB
6473fi
6474rm -f core conftest.err conftest.$ac_objext \
6475 conftest$ac_exeext conftest.$ac_ext
6476LIBS=$ac_check_lib_save_LIBS
6477fi
1a4d82fc
JJ
6478{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_unwind_unw_backtrace" >&5
6479$as_echo "$ac_cv_lib_unwind_unw_backtrace" >&6; }
6480if test "x$ac_cv_lib_unwind_unw_backtrace" = xyes; then :
970d7e83
LB
6481 LIBS="$LIBS $LUNWIND"
6482else
6483 enable_prof_libunwind="0"
6484fi
6485
6486 else
6487 LIBS="$LIBS $LUNWIND"
6488 fi
6489 if test "x${enable_prof_libunwind}" = "x1" ; then
6490 backtrace_method="libunwind"
6491 $as_echo "#define JEMALLOC_PROF_LIBUNWIND " >>confdefs.h
6492
6493 fi
6494fi
6495
6496# Check whether --enable-prof-libgcc was given.
6497if test "${enable_prof_libgcc+set}" = set; then :
6498 enableval=$enable_prof_libgcc; if test "x$enable_prof_libgcc" = "xno" ; then
6499 enable_prof_libgcc="0"
6500else
6501 enable_prof_libgcc="1"
6502fi
6503
6504else
6505 enable_prof_libgcc="1"
6506
6507fi
6508
6509if test "x$backtrace_method" = "x" -a "x$enable_prof_libgcc" = "x1" \
6510 -a "x$GCC" = "xyes" ; then
6511 for ac_header in unwind.h
6512do :
6513 ac_fn_c_check_header_mongrel "$LINENO" "unwind.h" "ac_cv_header_unwind_h" "$ac_includes_default"
6514if test "x$ac_cv_header_unwind_h" = xyes; then :
6515 cat >>confdefs.h <<_ACEOF
6516#define HAVE_UNWIND_H 1
6517_ACEOF
6518
6519else
6520 enable_prof_libgcc="0"
6521fi
6522
6523done
6524
6525 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _Unwind_Backtrace in -lgcc" >&5
6526$as_echo_n "checking for _Unwind_Backtrace in -lgcc... " >&6; }
6527if ${ac_cv_lib_gcc__Unwind_Backtrace+:} false; then :
6528 $as_echo_n "(cached) " >&6
6529else
6530 ac_check_lib_save_LIBS=$LIBS
6531LIBS="-lgcc $LIBS"
6532cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6533/* end confdefs.h. */
6534
6535/* Override any GCC internal prototype to avoid an error.
6536 Use char because int might match the return type of a GCC
6537 builtin and then its argument prototype would still apply. */
6538#ifdef __cplusplus
6539extern "C"
6540#endif
6541char _Unwind_Backtrace ();
6542int
6543main ()
6544{
6545return _Unwind_Backtrace ();
6546 ;
6547 return 0;
6548}
6549_ACEOF
6550if ac_fn_c_try_link "$LINENO"; then :
6551 ac_cv_lib_gcc__Unwind_Backtrace=yes
6552else
6553 ac_cv_lib_gcc__Unwind_Backtrace=no
6554fi
6555rm -f core conftest.err conftest.$ac_objext \
6556 conftest$ac_exeext conftest.$ac_ext
6557LIBS=$ac_check_lib_save_LIBS
6558fi
6559{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gcc__Unwind_Backtrace" >&5
6560$as_echo "$ac_cv_lib_gcc__Unwind_Backtrace" >&6; }
6561if test "x$ac_cv_lib_gcc__Unwind_Backtrace" = xyes; then :
6562 LIBS="$LIBS -lgcc"
6563else
6564 enable_prof_libgcc="0"
6565fi
6566
970d7e83
LB
6567 if test "x${enable_prof_libgcc}" = "x1" ; then
6568 backtrace_method="libgcc"
6569 $as_echo "#define JEMALLOC_PROF_LIBGCC " >>confdefs.h
6570
6571 fi
6572else
6573 enable_prof_libgcc="0"
6574fi
6575
6576# Check whether --enable-prof-gcc was given.
6577if test "${enable_prof_gcc+set}" = set; then :
6578 enableval=$enable_prof_gcc; if test "x$enable_prof_gcc" = "xno" ; then
6579 enable_prof_gcc="0"
6580else
6581 enable_prof_gcc="1"
6582fi
6583
6584else
6585 enable_prof_gcc="1"
6586
6587fi
6588
6589if test "x$backtrace_method" = "x" -a "x$enable_prof_gcc" = "x1" \
6590 -a "x$GCC" = "xyes" ; then
1a4d82fc
JJ
6591
6592{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -fno-omit-frame-pointer" >&5
6593$as_echo_n "checking whether compiler supports -fno-omit-frame-pointer... " >&6; }
6594TCFLAGS="${CFLAGS}"
6595if test "x${CFLAGS}" = "x" ; then
6596 CFLAGS="-fno-omit-frame-pointer"
6597else
6598 CFLAGS="${CFLAGS} -fno-omit-frame-pointer"
6599fi
6600cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6601/* end confdefs.h. */
6602
6603
6604int
6605main ()
6606{
6607
6608 return 0;
6609
6610 ;
6611 return 0;
6612}
6613_ACEOF
6614if ac_fn_c_try_compile "$LINENO"; then :
6615 je_cv_cflags_appended=-fno-omit-frame-pointer
6616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6617$as_echo "yes" >&6; }
6618else
6619 je_cv_cflags_appended=
6620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6621$as_echo "no" >&6; }
6622 CFLAGS="${TCFLAGS}"
6623
6624fi
6625rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6626
970d7e83
LB
6627 backtrace_method="gcc intrinsics"
6628 $as_echo "#define JEMALLOC_PROF_GCC " >>confdefs.h
6629
6630else
6631 enable_prof_gcc="0"
6632fi
6633
6634if test "x$backtrace_method" = "x" ; then
6635 backtrace_method="none (disabling profiling)"
6636 enable_prof="0"
6637fi
6638{ $as_echo "$as_me:${as_lineno-$LINENO}: checking configured backtracing method" >&5
6639$as_echo_n "checking configured backtracing method... " >&6; }
6640{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $backtrace_method" >&5
6641$as_echo "$backtrace_method" >&6; }
6642if test "x$enable_prof" = "x1" ; then
1a4d82fc
JJ
6643 if test "x$abi" != "xpecoff"; then
6644 LIBS="$LIBS -lm"
970d7e83 6645 fi
1a4d82fc 6646
970d7e83
LB
6647 $as_echo "#define JEMALLOC_PROF " >>confdefs.h
6648
6649fi
6650
6651
6652# Check whether --enable-tcache was given.
6653if test "${enable_tcache+set}" = set; then :
6654 enableval=$enable_tcache; if test "x$enable_tcache" = "xno" ; then
6655 enable_tcache="0"
6656else
6657 enable_tcache="1"
6658fi
6659
6660else
6661 enable_tcache="1"
6662
6663fi
6664
6665if test "x$enable_tcache" = "x1" ; then
6666 $as_echo "#define JEMALLOC_TCACHE " >>confdefs.h
6667
6668fi
6669
6670
54a0048b
SL
6671if test "x${maps_coalesce}" = "x1" ; then
6672 $as_echo "#define JEMALLOC_MAPS_COALESCE " >>confdefs.h
6673
6674fi
6675
970d7e83
LB
6676# Check whether --enable-munmap was given.
6677if test "${enable_munmap+set}" = set; then :
6678 enableval=$enable_munmap; if test "x$enable_munmap" = "xno" ; then
6679 enable_munmap="0"
6680else
6681 enable_munmap="1"
6682fi
6683
6684else
6685 enable_munmap="${default_munmap}"
6686
6687fi
6688
6689if test "x$enable_munmap" = "x1" ; then
6690 $as_echo "#define JEMALLOC_MUNMAP " >>confdefs.h
6691
6692fi
6693
6694
1a4d82fc 6695have_dss="1"
970d7e83
LB
6696ac_fn_c_check_func "$LINENO" "sbrk" "ac_cv_func_sbrk"
6697if test "x$ac_cv_func_sbrk" = xyes; then :
6698 have_sbrk="1"
6699else
6700 have_sbrk="0"
6701fi
6702
6703if test "x$have_sbrk" = "x1" ; then
1a4d82fc
JJ
6704 if test "x$sbrk_deprecated" = "x1" ; then
6705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Disabling dss allocation because sbrk is deprecated" >&5
6706$as_echo "Disabling dss allocation because sbrk is deprecated" >&6; }
6707 have_dss="0"
6708 fi
970d7e83 6709else
1a4d82fc 6710 have_dss="0"
970d7e83
LB
6711fi
6712
1a4d82fc 6713if test "x$have_dss" = "x1" ; then
970d7e83
LB
6714 $as_echo "#define JEMALLOC_DSS " >>confdefs.h
6715
6716fi
6717
970d7e83
LB
6718# Check whether --enable-fill was given.
6719if test "${enable_fill+set}" = set; then :
6720 enableval=$enable_fill; if test "x$enable_fill" = "xno" ; then
6721 enable_fill="0"
6722else
6723 enable_fill="1"
6724fi
6725
6726else
6727 enable_fill="1"
6728
6729fi
6730
6731if test "x$enable_fill" = "x1" ; then
6732 $as_echo "#define JEMALLOC_FILL " >>confdefs.h
6733
6734fi
6735
6736
6737# Check whether --enable-utrace was given.
6738if test "${enable_utrace+set}" = set; then :
6739 enableval=$enable_utrace; if test "x$enable_utrace" = "xno" ; then
6740 enable_utrace="0"
6741else
6742 enable_utrace="1"
6743fi
6744
6745else
6746 enable_utrace="0"
6747
6748fi
6749
6750
6751{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether utrace(2) is compilable" >&5
6752$as_echo_n "checking whether utrace(2) is compilable... " >&6; }
6753if ${je_cv_utrace+:} false; then :
6754 $as_echo_n "(cached) " >&6
6755else
6756 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6757/* end confdefs.h. */
6758
6759#include <sys/types.h>
6760#include <sys/param.h>
6761#include <sys/time.h>
6762#include <sys/uio.h>
6763#include <sys/ktrace.h>
6764
6765int
6766main ()
6767{
6768
6769 utrace((void *)0, 0);
6770
6771 ;
6772 return 0;
6773}
6774_ACEOF
6775if ac_fn_c_try_link "$LINENO"; then :
6776 je_cv_utrace=yes
6777else
6778 je_cv_utrace=no
6779fi
6780rm -f core conftest.err conftest.$ac_objext \
6781 conftest$ac_exeext conftest.$ac_ext
6782fi
6783{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_utrace" >&5
6784$as_echo "$je_cv_utrace" >&6; }
6785
6786if test "x${je_cv_utrace}" = "xno" ; then
6787 enable_utrace="0"
6788fi
6789if test "x$enable_utrace" = "x1" ; then
6790 $as_echo "#define JEMALLOC_UTRACE " >>confdefs.h
6791
6792fi
6793
6794
6795# Check whether --enable-valgrind was given.
6796if test "${enable_valgrind+set}" = set; then :
6797 enableval=$enable_valgrind; if test "x$enable_valgrind" = "xno" ; then
6798 enable_valgrind="0"
6799else
6800 enable_valgrind="1"
6801fi
6802
6803else
6804 enable_valgrind="1"
6805
6806fi
6807
6808if test "x$enable_valgrind" = "x1" ; then
6809
6810{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether valgrind is compilable" >&5
6811$as_echo_n "checking whether valgrind is compilable... " >&6; }
6812if ${je_cv_valgrind+:} false; then :
6813 $as_echo_n "(cached) " >&6
6814else
6815 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6816/* end confdefs.h. */
6817
6818#include <valgrind/valgrind.h>
6819#include <valgrind/memcheck.h>
6820
6821#if !defined(VALGRIND_RESIZEINPLACE_BLOCK)
6822# error "Incompatible Valgrind version"
6823#endif
6824
6825int
6826main ()
6827{
6828
6829 ;
6830 return 0;
6831}
6832_ACEOF
6833if ac_fn_c_try_link "$LINENO"; then :
6834 je_cv_valgrind=yes
6835else
6836 je_cv_valgrind=no
6837fi
6838rm -f core conftest.err conftest.$ac_objext \
6839 conftest$ac_exeext conftest.$ac_ext
6840fi
6841{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_valgrind" >&5
6842$as_echo "$je_cv_valgrind" >&6; }
6843
6844 if test "x${je_cv_valgrind}" = "xno" ; then
6845 enable_valgrind="0"
6846 fi
6847 if test "x$enable_valgrind" = "x1" ; then
6848 $as_echo "#define JEMALLOC_VALGRIND " >>confdefs.h
6849
6850 fi
6851fi
6852
6853
1a4d82fc
JJ
6854# Check whether --enable-xmalloc was given.
6855if test "${enable_xmalloc+set}" = set; then :
6856 enableval=$enable_xmalloc; if test "x$enable_xmalloc" = "xno" ; then
6857 enable_xmalloc="0"
6858else
6859 enable_xmalloc="1"
6860fi
6861
6862else
6863 enable_xmalloc="0"
6864
6865fi
6866
6867if test "x$enable_xmalloc" = "x1" ; then
6868 $as_echo "#define JEMALLOC_XMALLOC " >>confdefs.h
6869
6870fi
6871
6872
54a0048b
SL
6873# Check whether --enable-cache-oblivious was given.
6874if test "${enable_cache_oblivious+set}" = set; then :
6875 enableval=$enable_cache_oblivious; if test "x$enable_cache_oblivious" = "xno" ; then
6876 enable_cache_oblivious="0"
6877else
6878 enable_cache_oblivious="1"
6879fi
6880
6881else
6882 enable_cache_oblivious="1"
6883
6884fi
6885
6886if test "x$enable_cache_oblivious" = "x1" ; then
6887 $as_echo "#define JEMALLOC_CACHE_OBLIVIOUS " >>confdefs.h
6888
6889fi
6890
6891
1a4d82fc
JJ
6892
6893{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program using __builtin_ffsl is compilable" >&5
6894$as_echo_n "checking whether a program using __builtin_ffsl is compilable... " >&6; }
6895if ${je_cv_gcc_builtin_ffsl+:} false; then :
6896 $as_echo_n "(cached) " >&6
6897else
6898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6899/* end confdefs.h. */
6900
6901#include <stdio.h>
6902#include <strings.h>
6903#include <string.h>
6904
6905int
6906main ()
6907{
6908
6909 {
6910 int rv = __builtin_ffsl(0x08);
6911 printf("%d\n", rv);
6912 }
6913
6914 ;
6915 return 0;
6916}
6917_ACEOF
6918if ac_fn_c_try_link "$LINENO"; then :
6919 je_cv_gcc_builtin_ffsl=yes
6920else
6921 je_cv_gcc_builtin_ffsl=no
6922fi
6923rm -f core conftest.err conftest.$ac_objext \
6924 conftest$ac_exeext conftest.$ac_ext
6925fi
6926{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_gcc_builtin_ffsl" >&5
6927$as_echo "$je_cv_gcc_builtin_ffsl" >&6; }
6928
6929if test "x${je_cv_gcc_builtin_ffsl}" = "xyes" ; then
54a0048b
SL
6930 $as_echo "#define JEMALLOC_INTERNAL_FFSLL __builtin_ffsll" >>confdefs.h
6931
1a4d82fc
JJ
6932 $as_echo "#define JEMALLOC_INTERNAL_FFSL __builtin_ffsl" >>confdefs.h
6933
6934 $as_echo "#define JEMALLOC_INTERNAL_FFS __builtin_ffs" >>confdefs.h
6935
6936else
6937
6938{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program using ffsl is compilable" >&5
6939$as_echo_n "checking whether a program using ffsl is compilable... " >&6; }
6940if ${je_cv_function_ffsl+:} false; then :
6941 $as_echo_n "(cached) " >&6
6942else
6943 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6944/* end confdefs.h. */
6945
6946 #include <stdio.h>
6947 #include <strings.h>
6948 #include <string.h>
6949
6950int
6951main ()
6952{
6953
6954 {
6955 int rv = ffsl(0x08);
6956 printf("%d\n", rv);
6957 }
6958
6959 ;
6960 return 0;
6961}
6962_ACEOF
6963if ac_fn_c_try_link "$LINENO"; then :
6964 je_cv_function_ffsl=yes
970d7e83 6965else
1a4d82fc 6966 je_cv_function_ffsl=no
970d7e83 6967fi
1a4d82fc
JJ
6968rm -f core conftest.err conftest.$ac_objext \
6969 conftest$ac_exeext conftest.$ac_ext
970d7e83 6970fi
1a4d82fc
JJ
6971{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_function_ffsl" >&5
6972$as_echo "$je_cv_function_ffsl" >&6; }
970d7e83 6973
1a4d82fc 6974 if test "x${je_cv_function_ffsl}" = "xyes" ; then
54a0048b
SL
6975 $as_echo "#define JEMALLOC_INTERNAL_FFSLL ffsll" >>confdefs.h
6976
1a4d82fc 6977 $as_echo "#define JEMALLOC_INTERNAL_FFSL ffsl" >>confdefs.h
970d7e83 6978
1a4d82fc 6979 $as_echo "#define JEMALLOC_INTERNAL_FFS ffs" >>confdefs.h
970d7e83 6980
1a4d82fc
JJ
6981 else
6982 as_fn_error $? "Cannot build without ffsl(3) or __builtin_ffsl()" "$LINENO" 5
6983 fi
6984fi
970d7e83 6985
54a0048b
SL
6986
6987# Check whether --with-lg_tiny_min was given.
6988if test "${with_lg_tiny_min+set}" = set; then :
6989 withval=$with_lg_tiny_min; LG_TINY_MIN="$with_lg_tiny_min"
6990else
6991 LG_TINY_MIN="3"
6992fi
6993
6994cat >>confdefs.h <<_ACEOF
6995#define LG_TINY_MIN $LG_TINY_MIN
6996_ACEOF
6997
6998
6999
7000# Check whether --with-lg_quantum was given.
7001if test "${with_lg_quantum+set}" = set; then :
7002 withval=$with_lg_quantum; LG_QUANTA="$with_lg_quantum"
7003else
7004 LG_QUANTA="3 4"
7005fi
7006
7007if test "x$with_lg_quantum" != "x" ; then
7008 cat >>confdefs.h <<_ACEOF
7009#define LG_QUANTUM $with_lg_quantum
7010_ACEOF
7011
7012fi
7013
7014
7015# Check whether --with-lg_page was given.
7016if test "${with_lg_page+set}" = set; then :
7017 withval=$with_lg_page; LG_PAGE="$with_lg_page"
7018else
7019 LG_PAGE="detect"
7020fi
7021
7022if test "x$LG_PAGE" = "xdetect"; then
7023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LG_PAGE" >&5
7024$as_echo_n "checking LG_PAGE... " >&6; }
7025if ${je_cv_lg_page+:} false; then :
970d7e83
LB
7026 $as_echo_n "(cached) " >&6
7027else
7028 if test "$cross_compiling" = yes; then :
54a0048b 7029 je_cv_lg_page=12
970d7e83
LB
7030else
7031 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7032/* end confdefs.h. */
7033
7034#include <strings.h>
7035#ifdef _WIN32
7036#include <windows.h>
7037#else
7038#include <unistd.h>
7039#endif
7040#include <stdio.h>
7041
7042int
7043main ()
7044{
7045
7046 int result;
7047 FILE *f;
7048
7049#ifdef _WIN32
7050 SYSTEM_INFO si;
7051 GetSystemInfo(&si);
7052 result = si.dwPageSize;
7053#else
7054 result = sysconf(_SC_PAGESIZE);
7055#endif
7056 if (result == -1) {
7057 return 1;
7058 }
1a4d82fc 7059 result = JEMALLOC_INTERNAL_FFSL(result) - 1;
970d7e83
LB
7060
7061 f = fopen("conftest.out", "w");
7062 if (f == NULL) {
7063 return 1;
7064 }
54a0048b 7065 fprintf(f, "%d", result);
970d7e83
LB
7066 fclose(f);
7067
7068 return 0;
7069
7070 ;
7071 return 0;
7072}
7073_ACEOF
7074if ac_fn_c_try_run "$LINENO"; then :
54a0048b 7075 je_cv_lg_page=`cat conftest.out`
970d7e83 7076else
54a0048b 7077 je_cv_lg_page=undefined
970d7e83
LB
7078fi
7079rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7080 conftest.$ac_objext conftest.beam conftest.$ac_ext
7081fi
7082
7083fi
54a0048b
SL
7084{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_lg_page" >&5
7085$as_echo "$je_cv_lg_page" >&6; }
7086fi
7087if test "x${je_cv_lg_page}" != "x" ; then
7088 LG_PAGE="${je_cv_lg_page}"
7089fi
7090if test "x${LG_PAGE}" != "xundefined" ; then
970d7e83 7091 cat >>confdefs.h <<_ACEOF
54a0048b 7092#define LG_PAGE $LG_PAGE
970d7e83
LB
7093_ACEOF
7094
7095else
54a0048b
SL
7096 as_fn_error $? "cannot determine value for LG_PAGE" "$LINENO" 5
7097fi
7098
7099
7100# Check whether --with-lg_page_sizes was given.
7101if test "${with_lg_page_sizes+set}" = set; then :
7102 withval=$with_lg_page_sizes; LG_PAGE_SIZES="$with_lg_page_sizes"
7103else
7104 LG_PAGE_SIZES="$LG_PAGE"
7105fi
7106
7107
7108
7109# Check whether --with-lg_size_class_group was given.
7110if test "${with_lg_size_class_group+set}" = set; then :
7111 withval=$with_lg_size_class_group; LG_SIZE_CLASS_GROUP="$with_lg_size_class_group"
7112else
7113 LG_SIZE_CLASS_GROUP="2"
970d7e83
LB
7114fi
7115
7116
54a0048b
SL
7117
7118if test "x`test ! \"${srcroot}\" && cd \"${srcroot}\"; git rev-parse --is-inside-work-tree 2>/dev/null`" = "xtrue" ; then
7119 rm -f "${objroot}VERSION"
1a4d82fc
JJ
7120 for pattern in '[0-9].[0-9].[0-9]' '[0-9].[0-9].[0-9][0-9]' \
7121 '[0-9].[0-9][0-9].[0-9]' '[0-9].[0-9][0-9].[0-9][0-9]' \
7122 '[0-9][0-9].[0-9].[0-9]' '[0-9][0-9].[0-9].[0-9][0-9]' \
7123 '[0-9][0-9].[0-9][0-9].[0-9]' \
7124 '[0-9][0-9].[0-9][0-9].[0-9][0-9]'; do
54a0048b
SL
7125 if test ! -e "${objroot}VERSION" ; then
7126 (test ! "${srcroot}" && cd "${srcroot}"; git describe --long --abbrev=40 --match="${pattern}") > "${objroot}VERSION.tmp" 2>/dev/null
1a4d82fc 7127 if test $? -eq 0 ; then
54a0048b 7128 mv "${objroot}VERSION.tmp" "${objroot}VERSION"
1a4d82fc
JJ
7129 break
7130 fi
7131 fi
7132 done
970d7e83 7133fi
54a0048b
SL
7134rm -f "${objroot}VERSION.tmp"
7135if test ! -e "${objroot}VERSION" ; then
7136 if test ! -e "${srcroot}VERSION" ; then
7137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Missing VERSION file, and unable to generate it; creating bogus VERSION" >&5
1a4d82fc 7138$as_echo "Missing VERSION file, and unable to generate it; creating bogus VERSION" >&6; }
54a0048b
SL
7139 echo "0.0.0-0-g0000000000000000000000000000000000000000" > "${objroot}VERSION"
7140 else
7141 cp ${srcroot}VERSION ${objroot}VERSION
7142 fi
1a4d82fc 7143fi
54a0048b 7144jemalloc_version=`cat "${objroot}VERSION"`
970d7e83
LB
7145jemalloc_version_major=`echo ${jemalloc_version} | tr ".g-" " " | awk '{print $1}'`
7146jemalloc_version_minor=`echo ${jemalloc_version} | tr ".g-" " " | awk '{print $2}'`
7147jemalloc_version_bugfix=`echo ${jemalloc_version} | tr ".g-" " " | awk '{print $3}'`
7148jemalloc_version_nrev=`echo ${jemalloc_version} | tr ".g-" " " | awk '{print $4}'`
7149jemalloc_version_gid=`echo ${jemalloc_version} | tr ".g-" " " | awk '{print $5}'`
7150
7151
7152
7153
7154
7155
7156
7157
7158if test "x$abi" != "xpecoff" ; then
7159 for ac_header in pthread.h
7160do :
7161 ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
7162if test "x$ac_cv_header_pthread_h" = xyes; then :
7163 cat >>confdefs.h <<_ACEOF
7164#define HAVE_PTHREAD_H 1
7165_ACEOF
7166
7167else
7168 as_fn_error $? "pthread.h is missing" "$LINENO" 5
7169fi
7170
7171done
7172
7173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthread" >&5
7174$as_echo_n "checking for pthread_create in -lpthread... " >&6; }
7175if ${ac_cv_lib_pthread_pthread_create+:} false; then :
7176 $as_echo_n "(cached) " >&6
7177else
7178 ac_check_lib_save_LIBS=$LIBS
7179LIBS="-lpthread $LIBS"
7180cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7181/* end confdefs.h. */
7182
7183/* Override any GCC internal prototype to avoid an error.
7184 Use char because int might match the return type of a GCC
7185 builtin and then its argument prototype would still apply. */
7186#ifdef __cplusplus
7187extern "C"
7188#endif
7189char pthread_create ();
7190int
7191main ()
7192{
7193return pthread_create ();
7194 ;
7195 return 0;
7196}
7197_ACEOF
7198if ac_fn_c_try_link "$LINENO"; then :
7199 ac_cv_lib_pthread_pthread_create=yes
7200else
7201 ac_cv_lib_pthread_pthread_create=no
7202fi
7203rm -f core conftest.err conftest.$ac_objext \
7204 conftest$ac_exeext conftest.$ac_ext
7205LIBS=$ac_check_lib_save_LIBS
7206fi
7207{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_create" >&5
7208$as_echo "$ac_cv_lib_pthread_pthread_create" >&6; }
7209if test "x$ac_cv_lib_pthread_pthread_create" = xyes; then :
7210 LIBS="$LIBS -lpthread"
7211else
7212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing pthread_create" >&5
7213$as_echo_n "checking for library containing pthread_create... " >&6; }
7214if ${ac_cv_search_pthread_create+:} false; then :
7215 $as_echo_n "(cached) " >&6
7216else
7217 ac_func_search_save_LIBS=$LIBS
7218cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7219/* end confdefs.h. */
7220
7221/* Override any GCC internal prototype to avoid an error.
7222 Use char because int might match the return type of a GCC
7223 builtin and then its argument prototype would still apply. */
7224#ifdef __cplusplus
7225extern "C"
7226#endif
7227char pthread_create ();
7228int
7229main ()
7230{
7231return pthread_create ();
7232 ;
7233 return 0;
7234}
7235_ACEOF
7236for ac_lib in '' ; do
7237 if test -z "$ac_lib"; then
7238 ac_res="none required"
7239 else
7240 ac_res=-l$ac_lib
7241 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
7242 fi
7243 if ac_fn_c_try_link "$LINENO"; then :
7244 ac_cv_search_pthread_create=$ac_res
7245fi
7246rm -f core conftest.err conftest.$ac_objext \
7247 conftest$ac_exeext
7248 if ${ac_cv_search_pthread_create+:} false; then :
7249 break
7250fi
7251done
7252if ${ac_cv_search_pthread_create+:} false; then :
7253
7254else
7255 ac_cv_search_pthread_create=no
7256fi
7257rm conftest.$ac_ext
7258LIBS=$ac_func_search_save_LIBS
7259fi
7260{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_pthread_create" >&5
7261$as_echo "$ac_cv_search_pthread_create" >&6; }
7262ac_res=$ac_cv_search_pthread_create
7263if test "$ac_res" != no; then :
7264 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7265
7266else
7267 as_fn_error $? "libpthread is missing" "$LINENO" 5
7268fi
7269
7270fi
7271
7272fi
7273
7274CPPFLAGS="$CPPFLAGS -D_REENTRANT"
7275
54a0048b
SL
7276SAVED_LIBS="${LIBS}"
7277LIBS=
7278{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
7279$as_echo_n "checking for library containing clock_gettime... " >&6; }
7280if ${ac_cv_search_clock_gettime+:} false; then :
7281 $as_echo_n "(cached) " >&6
7282else
7283 ac_func_search_save_LIBS=$LIBS
7284cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7285/* end confdefs.h. */
7286
7287/* Override any GCC internal prototype to avoid an error.
7288 Use char because int might match the return type of a GCC
7289 builtin and then its argument prototype would still apply. */
7290#ifdef __cplusplus
7291extern "C"
7292#endif
7293char clock_gettime ();
7294int
7295main ()
7296{
7297return clock_gettime ();
7298 ;
7299 return 0;
7300}
7301_ACEOF
7302for ac_lib in '' rt; do
7303 if test -z "$ac_lib"; then
7304 ac_res="none required"
7305 else
7306 ac_res=-l$ac_lib
7307 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
7308 fi
7309 if ac_fn_c_try_link "$LINENO"; then :
7310 ac_cv_search_clock_gettime=$ac_res
7311fi
7312rm -f core conftest.err conftest.$ac_objext \
7313 conftest$ac_exeext
7314 if ${ac_cv_search_clock_gettime+:} false; then :
7315 break
7316fi
7317done
7318if ${ac_cv_search_clock_gettime+:} false; then :
7319
7320else
7321 ac_cv_search_clock_gettime=no
7322fi
7323rm conftest.$ac_ext
7324LIBS=$ac_func_search_save_LIBS
7325fi
7326{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
7327$as_echo "$ac_cv_search_clock_gettime" >&6; }
7328ac_res=$ac_cv_search_clock_gettime
7329if test "$ac_res" != no; then :
7330 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7331 TESTLIBS="${LIBS}"
7332fi
7333
7334
7335LIBS="${SAVED_LIBS}"
7336
7337ac_fn_c_check_func "$LINENO" "secure_getenv" "ac_cv_func_secure_getenv"
7338if test "x$ac_cv_func_secure_getenv" = xyes; then :
7339 have_secure_getenv="1"
7340else
7341 have_secure_getenv="0"
7342
7343fi
7344
7345if test "x$have_secure_getenv" = "x1" ; then
7346 $as_echo "#define JEMALLOC_HAVE_SECURE_GETENV " >>confdefs.h
7347
7348fi
7349
7350ac_fn_c_check_func "$LINENO" "issetugid" "ac_cv_func_issetugid"
7351if test "x$ac_cv_func_issetugid" = xyes; then :
7352 have_issetugid="1"
7353else
7354 have_issetugid="0"
7355
7356fi
7357
7358if test "x$have_issetugid" = "x1" ; then
7359 $as_echo "#define JEMALLOC_HAVE_ISSETUGID " >>confdefs.h
7360
7361fi
7362
970d7e83
LB
7363ac_fn_c_check_func "$LINENO" "_malloc_thread_cleanup" "ac_cv_func__malloc_thread_cleanup"
7364if test "x$ac_cv_func__malloc_thread_cleanup" = xyes; then :
7365 have__malloc_thread_cleanup="1"
7366else
7367 have__malloc_thread_cleanup="0"
7368
7369fi
7370
7371if test "x$have__malloc_thread_cleanup" = "x1" ; then
7372 $as_echo "#define JEMALLOC_MALLOC_THREAD_CLEANUP " >>confdefs.h
7373
7374 force_tls="1"
7375fi
7376
7377ac_fn_c_check_func "$LINENO" "_pthread_mutex_init_calloc_cb" "ac_cv_func__pthread_mutex_init_calloc_cb"
7378if test "x$ac_cv_func__pthread_mutex_init_calloc_cb" = xyes; then :
7379 have__pthread_mutex_init_calloc_cb="1"
7380else
7381 have__pthread_mutex_init_calloc_cb="0"
7382
7383fi
7384
7385if test "x$have__pthread_mutex_init_calloc_cb" = "x1" ; then
7386 $as_echo "#define JEMALLOC_MUTEX_INIT_CB 1" >>confdefs.h
7387
7388fi
7389
7390# Check whether --enable-lazy_lock was given.
7391if test "${enable_lazy_lock+set}" = set; then :
7392 enableval=$enable_lazy_lock; if test "x$enable_lazy_lock" = "xno" ; then
7393 enable_lazy_lock="0"
7394else
7395 enable_lazy_lock="1"
7396fi
7397
7398else
54a0048b 7399 enable_lazy_lock=""
970d7e83
LB
7400
7401fi
7402
54a0048b 7403if test "x$enable_lazy_lock" = "x" -a "x${force_lazy_lock}" = "x1" ; then
970d7e83
LB
7404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Forcing lazy-lock to avoid allocator/threading bootstrap issues" >&5
7405$as_echo "Forcing lazy-lock to avoid allocator/threading bootstrap issues" >&6; }
7406 enable_lazy_lock="1"
7407fi
7408if test "x$enable_lazy_lock" = "x1" ; then
7409 if test "x$abi" != "xpecoff" ; then
7410 for ac_header in dlfcn.h
7411do :
7412 ac_fn_c_check_header_mongrel "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default"
7413if test "x$ac_cv_header_dlfcn_h" = xyes; then :
7414 cat >>confdefs.h <<_ACEOF
7415#define HAVE_DLFCN_H 1
7416_ACEOF
7417
7418else
7419 as_fn_error $? "dlfcn.h is missing" "$LINENO" 5
7420fi
7421
7422done
7423
7424 ac_fn_c_check_func "$LINENO" "dlsym" "ac_cv_func_dlsym"
7425if test "x$ac_cv_func_dlsym" = xyes; then :
7426
7427else
7428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlsym in -ldl" >&5
7429$as_echo_n "checking for dlsym in -ldl... " >&6; }
7430if ${ac_cv_lib_dl_dlsym+:} false; then :
7431 $as_echo_n "(cached) " >&6
7432else
7433 ac_check_lib_save_LIBS=$LIBS
7434LIBS="-ldl $LIBS"
7435cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7436/* end confdefs.h. */
7437
7438/* Override any GCC internal prototype to avoid an error.
7439 Use char because int might match the return type of a GCC
7440 builtin and then its argument prototype would still apply. */
7441#ifdef __cplusplus
7442extern "C"
7443#endif
7444char dlsym ();
7445int
7446main ()
7447{
7448return dlsym ();
7449 ;
7450 return 0;
7451}
7452_ACEOF
7453if ac_fn_c_try_link "$LINENO"; then :
7454 ac_cv_lib_dl_dlsym=yes
7455else
7456 ac_cv_lib_dl_dlsym=no
7457fi
7458rm -f core conftest.err conftest.$ac_objext \
7459 conftest$ac_exeext conftest.$ac_ext
7460LIBS=$ac_check_lib_save_LIBS
7461fi
7462{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlsym" >&5
7463$as_echo "$ac_cv_lib_dl_dlsym" >&6; }
7464if test "x$ac_cv_lib_dl_dlsym" = xyes; then :
7465 LIBS="$LIBS -ldl"
7466else
7467 as_fn_error $? "libdl is missing" "$LINENO" 5
7468fi
7469
7470
7471fi
7472
7473 fi
7474 $as_echo "#define JEMALLOC_LAZY_LOCK " >>confdefs.h
7475
54a0048b
SL
7476else
7477 enable_lazy_lock="0"
970d7e83
LB
7478fi
7479
7480
7481# Check whether --enable-tls was given.
7482if test "${enable_tls+set}" = set; then :
7483 enableval=$enable_tls; if test "x$enable_tls" = "xno" ; then
7484 enable_tls="0"
7485else
7486 enable_tls="1"
7487fi
7488
7489else
54a0048b 7490 enable_tls=""
970d7e83
LB
7491
7492fi
7493
54a0048b
SL
7494if test "x${enable_tls}" = "x" ; then
7495 if test "x${force_tls}" = "x1" ; then
7496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Forcing TLS to avoid allocator/threading bootstrap issues" >&5
970d7e83 7497$as_echo "Forcing TLS to avoid allocator/threading bootstrap issues" >&6; }
54a0048b
SL
7498 enable_tls="1"
7499 elif test "x${force_tls}" = "x0" ; then
7500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Forcing no TLS to avoid allocator/threading bootstrap issues" >&5
970d7e83 7501$as_echo "Forcing no TLS to avoid allocator/threading bootstrap issues" >&6; }
54a0048b
SL
7502 enable_tls="0"
7503 else
7504 enable_tls="1"
7505 fi
970d7e83
LB
7506fi
7507if test "x${enable_tls}" = "x1" ; then
7508{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for TLS" >&5
7509$as_echo_n "checking for TLS... " >&6; }
7510cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7511/* end confdefs.h. */
7512
7513 __thread int x;
7514
7515int
7516main ()
7517{
7518
7519 x = 42;
7520
7521 return 0;
7522
7523 ;
7524 return 0;
7525}
7526_ACEOF
7527if ac_fn_c_try_compile "$LINENO"; then :
7528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7529$as_echo "yes" >&6; }
7530else
7531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7532$as_echo "no" >&6; }
7533 enable_tls="0"
7534fi
7535rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
54a0048b
SL
7536else
7537 enable_tls="0"
970d7e83
LB
7538fi
7539
7540if test "x${enable_tls}" = "x1" ; then
54a0048b
SL
7541 if test "x${force_tls}" = "x0" ; then
7542 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: TLS enabled despite being marked unusable on this platform" >&5
7543$as_echo "$as_me: WARNING: TLS enabled despite being marked unusable on this platform" >&2;}
7544 fi
970d7e83
LB
7545 cat >>confdefs.h <<_ACEOF
7546#define JEMALLOC_TLS
7547_ACEOF
7548
7549elif test "x${force_tls}" = "x1" ; then
54a0048b
SL
7550 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: TLS disabled despite being marked critical on this platform" >&5
7551$as_echo "$as_me: WARNING: TLS disabled despite being marked critical on this platform" >&2;}
7552fi
7553
7554
7555
7556{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C11 atomics is compilable" >&5
7557$as_echo_n "checking whether C11 atomics is compilable... " >&6; }
7558if ${je_cv_c11atomics+:} false; then :
7559 $as_echo_n "(cached) " >&6
7560else
7561 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7562/* end confdefs.h. */
7563
7564#include <stdint.h>
7565#if (__STDC_VERSION__ >= 201112L) && !defined(__STDC_NO_ATOMICS__)
7566#include <stdatomic.h>
7567#else
7568#error Atomics not available
7569#endif
7570
7571int
7572main ()
7573{
7574
7575 uint64_t *p = (uint64_t *)0;
7576 uint64_t x = 1;
7577 volatile atomic_uint_least64_t *a = (volatile atomic_uint_least64_t *)p;
7578 uint64_t r = atomic_fetch_add(a, x) + x;
7579 return (r == 0);
7580
7581 ;
7582 return 0;
7583}
7584_ACEOF
7585if ac_fn_c_try_link "$LINENO"; then :
7586 je_cv_c11atomics=yes
7587else
7588 je_cv_c11atomics=no
7589fi
7590rm -f core conftest.err conftest.$ac_objext \
7591 conftest$ac_exeext conftest.$ac_ext
7592fi
7593{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_c11atomics" >&5
7594$as_echo "$je_cv_c11atomics" >&6; }
7595
7596if test "x${je_cv_c11atomics}" = "xyes" ; then
7597 $as_echo "#define JEMALLOC_C11ATOMICS 1" >>confdefs.h
7598
970d7e83
LB
7599fi
7600
7601
970d7e83
LB
7602
7603{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether atomic(9) is compilable" >&5
7604$as_echo_n "checking whether atomic(9) is compilable... " >&6; }
7605if ${je_cv_atomic9+:} false; then :
7606 $as_echo_n "(cached) " >&6
7607else
7608 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7609/* end confdefs.h. */
7610
7611#include <sys/types.h>
7612#include <machine/atomic.h>
7613#include <inttypes.h>
7614
7615int
7616main ()
7617{
7618
7619 {
7620 uint32_t x32 = 0;
7621 volatile uint32_t *x32p = &x32;
7622 atomic_fetchadd_32(x32p, 1);
7623 }
7624 {
7625 unsigned long xlong = 0;
7626 volatile unsigned long *xlongp = &xlong;
7627 atomic_fetchadd_long(xlongp, 1);
7628 }
7629
7630 ;
7631 return 0;
7632}
7633_ACEOF
7634if ac_fn_c_try_link "$LINENO"; then :
7635 je_cv_atomic9=yes
7636else
7637 je_cv_atomic9=no
7638fi
7639rm -f core conftest.err conftest.$ac_objext \
7640 conftest$ac_exeext conftest.$ac_ext
7641fi
7642{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_atomic9" >&5
7643$as_echo "$je_cv_atomic9" >&6; }
7644
7645if test "x${je_cv_atomic9}" = "xyes" ; then
7646 $as_echo "#define JEMALLOC_ATOMIC9 1" >>confdefs.h
7647
7648fi
7649
7650
7651
7652{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Darwin OSAtomic*() is compilable" >&5
7653$as_echo_n "checking whether Darwin OSAtomic*() is compilable... " >&6; }
7654if ${je_cv_osatomic+:} false; then :
7655 $as_echo_n "(cached) " >&6
7656else
7657 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7658/* end confdefs.h. */
7659
7660#include <libkern/OSAtomic.h>
7661#include <inttypes.h>
7662
7663int
7664main ()
7665{
7666
7667 {
7668 int32_t x32 = 0;
7669 volatile int32_t *x32p = &x32;
7670 OSAtomicAdd32(1, x32p);
7671 }
7672 {
7673 int64_t x64 = 0;
7674 volatile int64_t *x64p = &x64;
7675 OSAtomicAdd64(1, x64p);
7676 }
7677
7678 ;
7679 return 0;
7680}
7681_ACEOF
7682if ac_fn_c_try_link "$LINENO"; then :
7683 je_cv_osatomic=yes
7684else
7685 je_cv_osatomic=no
7686fi
7687rm -f core conftest.err conftest.$ac_objext \
7688 conftest$ac_exeext conftest.$ac_ext
7689fi
7690{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_osatomic" >&5
7691$as_echo "$je_cv_osatomic" >&6; }
7692
7693if test "x${je_cv_osatomic}" = "xyes" ; then
7694 $as_echo "#define JEMALLOC_OSATOMIC " >>confdefs.h
7695
7696fi
7697
7698
7699
1a4d82fc
JJ
7700{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether madvise(2) is compilable" >&5
7701$as_echo_n "checking whether madvise(2) is compilable... " >&6; }
7702if ${je_cv_madvise+:} false; then :
7703 $as_echo_n "(cached) " >&6
7704else
7705 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7706/* end confdefs.h. */
7707
7708#include <sys/mman.h>
7709
7710int
7711main ()
7712{
7713
7714 {
7715 madvise((void *)0, 0, 0);
7716 }
7717
7718 ;
7719 return 0;
7720}
7721_ACEOF
7722if ac_fn_c_try_link "$LINENO"; then :
7723 je_cv_madvise=yes
7724else
7725 je_cv_madvise=no
7726fi
7727rm -f core conftest.err conftest.$ac_objext \
7728 conftest$ac_exeext conftest.$ac_ext
7729fi
7730{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_madvise" >&5
7731$as_echo "$je_cv_madvise" >&6; }
7732
7733if test "x${je_cv_madvise}" = "xyes" ; then
7734 $as_echo "#define JEMALLOC_HAVE_MADVISE " >>confdefs.h
7735
7736fi
7737
7738
7739
970d7e83
LB
7740
7741if test "x${je_cv_atomic9}" != "xyes" -a "x${je_cv_osatomic}" != "xyes" ; then
7742
7743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to force 32-bit __sync_{add,sub}_and_fetch()" >&5
7744$as_echo_n "checking whether to force 32-bit __sync_{add,sub}_and_fetch()... " >&6; }
7745if ${je_cv_sync_compare_and_swap_4+:} false; then :
7746 $as_echo_n "(cached) " >&6
7747else
7748 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7749/* end confdefs.h. */
7750
7751 #include <stdint.h>
7752
7753int
7754main ()
7755{
7756
7757 #ifndef __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4
7758 {
7759 uint32_t x32 = 0;
7760 __sync_add_and_fetch(&x32, 42);
7761 __sync_sub_and_fetch(&x32, 1);
7762 }
7763 #else
7764 #error __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4 is defined, no need to force
7765 #endif
7766
7767 ;
7768 return 0;
7769}
7770_ACEOF
7771if ac_fn_c_try_link "$LINENO"; then :
7772 je_cv_sync_compare_and_swap_4=yes
7773else
7774 je_cv_sync_compare_and_swap_4=no
7775fi
7776rm -f core conftest.err conftest.$ac_objext \
7777 conftest$ac_exeext conftest.$ac_ext
7778fi
7779{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_sync_compare_and_swap_4" >&5
7780$as_echo "$je_cv_sync_compare_and_swap_4" >&6; }
7781
7782 if test "x${je_cv_sync_compare_and_swap_4}" = "xyes" ; then
7783 $as_echo "#define JE_FORCE_SYNC_COMPARE_AND_SWAP_4 " >>confdefs.h
7784
7785 fi
7786
7787
7788 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to force 64-bit __sync_{add,sub}_and_fetch()" >&5
7789$as_echo_n "checking whether to force 64-bit __sync_{add,sub}_and_fetch()... " >&6; }
7790if ${je_cv_sync_compare_and_swap_8+:} false; then :
7791 $as_echo_n "(cached) " >&6
7792else
7793 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7794/* end confdefs.h. */
7795
7796 #include <stdint.h>
7797
7798int
7799main ()
7800{
7801
7802 #ifndef __GCC_HAVE_SYNC_COMPARE_AND_SWAP_8
7803 {
7804 uint64_t x64 = 0;
7805 __sync_add_and_fetch(&x64, 42);
7806 __sync_sub_and_fetch(&x64, 1);
7807 }
7808 #else
7809 #error __GCC_HAVE_SYNC_COMPARE_AND_SWAP_8 is defined, no need to force
7810 #endif
7811
7812 ;
7813 return 0;
7814}
7815_ACEOF
7816if ac_fn_c_try_link "$LINENO"; then :
7817 je_cv_sync_compare_and_swap_8=yes
7818else
7819 je_cv_sync_compare_and_swap_8=no
7820fi
7821rm -f core conftest.err conftest.$ac_objext \
7822 conftest$ac_exeext conftest.$ac_ext
7823fi
7824{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_sync_compare_and_swap_8" >&5
7825$as_echo "$je_cv_sync_compare_and_swap_8" >&6; }
7826
7827 if test "x${je_cv_sync_compare_and_swap_8}" = "xyes" ; then
7828 $as_echo "#define JE_FORCE_SYNC_COMPARE_AND_SWAP_8 " >>confdefs.h
7829
7830 fi
7831
7832fi
7833
7834
1a4d82fc
JJ
7835{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_clz" >&5
7836$as_echo_n "checking for __builtin_clz... " >&6; }
7837if ${je_cv_builtin_clz+:} false; then :
7838 $as_echo_n "(cached) " >&6
7839else
7840 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7841/* end confdefs.h. */
7842
7843int
7844main ()
7845{
7846
7847 {
7848 unsigned x = 0;
7849 int y = __builtin_clz(x);
7850 }
7851 {
7852 unsigned long x = 0;
7853 int y = __builtin_clzl(x);
7854 }
7855
7856 ;
7857 return 0;
7858}
7859_ACEOF
7860if ac_fn_c_try_link "$LINENO"; then :
7861 je_cv_builtin_clz=yes
7862else
7863 je_cv_builtin_clz=no
7864fi
7865rm -f core conftest.err conftest.$ac_objext \
7866 conftest$ac_exeext conftest.$ac_ext
7867fi
7868{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_builtin_clz" >&5
7869$as_echo "$je_cv_builtin_clz" >&6; }
7870
7871if test "x${je_cv_builtin_clz}" = "xyes" ; then
7872 $as_echo "#define JEMALLOC_HAVE_BUILTIN_CLZ " >>confdefs.h
7873
7874fi
7875
7876
970d7e83
LB
7877
7878{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Darwin OSSpin*() is compilable" >&5
7879$as_echo_n "checking whether Darwin OSSpin*() is compilable... " >&6; }
7880if ${je_cv_osspin+:} false; then :
7881 $as_echo_n "(cached) " >&6
7882else
7883 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7884/* end confdefs.h. */
7885
7886#include <libkern/OSAtomic.h>
7887#include <inttypes.h>
7888
7889int
7890main ()
7891{
7892
7893 OSSpinLock lock = 0;
7894 OSSpinLockLock(&lock);
7895 OSSpinLockUnlock(&lock);
7896
7897 ;
7898 return 0;
7899}
7900_ACEOF
7901if ac_fn_c_try_link "$LINENO"; then :
7902 je_cv_osspin=yes
7903else
7904 je_cv_osspin=no
7905fi
7906rm -f core conftest.err conftest.$ac_objext \
7907 conftest$ac_exeext conftest.$ac_ext
7908fi
7909{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_osspin" >&5
7910$as_echo "$je_cv_osspin" >&6; }
7911
7912if test "x${je_cv_osspin}" = "xyes" ; then
7913 $as_echo "#define JEMALLOC_OSSPIN " >>confdefs.h
7914
7915fi
7916
7917
7918# Check whether --enable-zone-allocator was given.
7919if test "${enable_zone_allocator+set}" = set; then :
7920 enableval=$enable_zone_allocator; if test "x$enable_zone_allocator" = "xno" ; then
7921 enable_zone_allocator="0"
7922else
7923 enable_zone_allocator="1"
7924fi
7925
7926else
7927 if test "x${abi}" = "xmacho"; then
7928 enable_zone_allocator="1"
7929fi
7930
7931
7932fi
7933
7934
7935
7936if test "x${enable_zone_allocator}" = "x1" ; then
7937 if test "x${abi}" != "xmacho"; then
7938 as_fn_error $? "--enable-zone-allocator is only supported on Darwin" "$LINENO" 5
7939 fi
970d7e83
LB
7940 $as_echo "#define JEMALLOC_ZONE " >>confdefs.h
7941
7942
7943 { $as_echo "$as_me:${as_lineno-$LINENO}: checking malloc zone version" >&5
7944$as_echo_n "checking malloc zone version... " >&6; }
7945
7946
7947 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7948/* end confdefs.h. */
7949#include <malloc/malloc.h>
7950int
7951main ()
7952{
54a0048b 7953static int foo[sizeof(malloc_zone_t) == sizeof(void *) * 14 ? 1 : -1]
970d7e83
LB
7954
7955 ;
7956 return 0;
7957}
7958_ACEOF
7959if ac_fn_c_try_compile "$LINENO"; then :
7960 JEMALLOC_ZONE_VERSION=3
7961else
7962
7963 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7964/* end confdefs.h. */
7965#include <malloc/malloc.h>
7966int
7967main ()
7968{
54a0048b 7969static int foo[sizeof(malloc_zone_t) == sizeof(void *) * 15 ? 1 : -1]
970d7e83
LB
7970
7971 ;
7972 return 0;
7973}
7974_ACEOF
7975if ac_fn_c_try_compile "$LINENO"; then :
7976 JEMALLOC_ZONE_VERSION=5
7977else
7978
7979 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7980/* end confdefs.h. */
7981#include <malloc/malloc.h>
7982int
7983main ()
7984{
54a0048b 7985static int foo[sizeof(malloc_zone_t) == sizeof(void *) * 16 ? 1 : -1]
970d7e83
LB
7986
7987 ;
7988 return 0;
7989}
7990_ACEOF
7991if ac_fn_c_try_compile "$LINENO"; then :
7992
7993 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7994/* end confdefs.h. */
7995#include <malloc/malloc.h>
7996int
7997main ()
7998{
54a0048b 7999static int foo[sizeof(malloc_introspection_t) == sizeof(void *) * 9 ? 1 : -1]
970d7e83
LB
8000
8001 ;
8002 return 0;
8003}
8004_ACEOF
8005if ac_fn_c_try_compile "$LINENO"; then :
8006 JEMALLOC_ZONE_VERSION=6
8007else
8008
8009 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8010/* end confdefs.h. */
8011#include <malloc/malloc.h>
8012int
8013main ()
8014{
54a0048b 8015static int foo[sizeof(malloc_introspection_t) == sizeof(void *) * 13 ? 1 : -1]
970d7e83
LB
8016
8017 ;
8018 return 0;
8019}
8020_ACEOF
8021if ac_fn_c_try_compile "$LINENO"; then :
8022 JEMALLOC_ZONE_VERSION=7
8023else
8024 JEMALLOC_ZONE_VERSION=
8025
8026fi
8027rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8028fi
8029rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8030else
8031
8032 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8033/* end confdefs.h. */
8034#include <malloc/malloc.h>
8035int
8036main ()
8037{
54a0048b 8038static int foo[sizeof(malloc_zone_t) == sizeof(void *) * 17 ? 1 : -1]
970d7e83
LB
8039
8040 ;
8041 return 0;
8042}
8043_ACEOF
8044if ac_fn_c_try_compile "$LINENO"; then :
8045 JEMALLOC_ZONE_VERSION=8
8046else
8047
8048 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8049/* end confdefs.h. */
8050#include <malloc/malloc.h>
8051int
8052main ()
8053{
54a0048b 8054static int foo[sizeof(malloc_zone_t) > sizeof(void *) * 17 ? 1 : -1]
970d7e83
LB
8055
8056 ;
8057 return 0;
8058}
8059_ACEOF
8060if ac_fn_c_try_compile "$LINENO"; then :
8061 JEMALLOC_ZONE_VERSION=9
8062else
8063 JEMALLOC_ZONE_VERSION=
8064
8065fi
8066rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8067fi
8068rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8069fi
8070rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8071fi
8072rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8073fi
8074rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8075 if test "x${JEMALLOC_ZONE_VERSION}" = "x"; then
8076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
8077$as_echo "unsupported" >&6; }
8078 as_fn_error $? "Unsupported malloc zone version" "$LINENO" 5
8079 fi
8080 if test "${JEMALLOC_ZONE_VERSION}" = 9; then
8081 JEMALLOC_ZONE_VERSION=8
8082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: > 8" >&5
8083$as_echo "> 8" >&6; }
8084 else
8085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JEMALLOC_ZONE_VERSION" >&5
8086$as_echo "$JEMALLOC_ZONE_VERSION" >&6; }
8087 fi
8088 cat >>confdefs.h <<_ACEOF
8089#define JEMALLOC_ZONE_VERSION $JEMALLOC_ZONE_VERSION
8090_ACEOF
8091
8092fi
8093
1a4d82fc
JJ
8094
8095
8096{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether glibc malloc hook is compilable" >&5
8097$as_echo_n "checking whether glibc malloc hook is compilable... " >&6; }
8098if ${je_cv_glibc_malloc_hook+:} false; then :
8099 $as_echo_n "(cached) " >&6
8100else
8101 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8102/* end confdefs.h. */
8103
8104#include <stddef.h>
8105
8106extern void (* __free_hook)(void *ptr);
8107extern void *(* __malloc_hook)(size_t size);
8108extern void *(* __realloc_hook)(void *ptr, size_t size);
8109
8110int
8111main ()
8112{
8113
8114 void *ptr = 0L;
8115 if (__malloc_hook) ptr = __malloc_hook(1);
8116 if (__realloc_hook) ptr = __realloc_hook(ptr, 2);
8117 if (__free_hook && ptr) __free_hook(ptr);
8118
8119 ;
8120 return 0;
8121}
8122_ACEOF
8123if ac_fn_c_try_link "$LINENO"; then :
8124 je_cv_glibc_malloc_hook=yes
8125else
8126 je_cv_glibc_malloc_hook=no
8127fi
8128rm -f core conftest.err conftest.$ac_objext \
8129 conftest$ac_exeext conftest.$ac_ext
8130fi
8131{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_glibc_malloc_hook" >&5
8132$as_echo "$je_cv_glibc_malloc_hook" >&6; }
8133
8134if test "x${je_cv_glibc_malloc_hook}" = "xyes" ; then
8135 $as_echo "#define JEMALLOC_GLIBC_MALLOC_HOOK " >>confdefs.h
8136
8137fi
8138
8139
8140{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether glibc memalign hook is compilable" >&5
8141$as_echo_n "checking whether glibc memalign hook is compilable... " >&6; }
8142if ${je_cv_glibc_memalign_hook+:} false; then :
8143 $as_echo_n "(cached) " >&6
8144else
8145 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8146/* end confdefs.h. */
8147
8148#include <stddef.h>
8149
8150extern void *(* __memalign_hook)(size_t alignment, size_t size);
8151
8152int
8153main ()
8154{
8155
8156 void *ptr = 0L;
8157 if (__memalign_hook) ptr = __memalign_hook(16, 7);
8158
8159 ;
8160 return 0;
8161}
8162_ACEOF
8163if ac_fn_c_try_link "$LINENO"; then :
8164 je_cv_glibc_memalign_hook=yes
8165else
8166 je_cv_glibc_memalign_hook=no
8167fi
8168rm -f core conftest.err conftest.$ac_objext \
8169 conftest$ac_exeext conftest.$ac_ext
8170fi
8171{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_glibc_memalign_hook" >&5
8172$as_echo "$je_cv_glibc_memalign_hook" >&6; }
8173
8174if test "x${je_cv_glibc_memalign_hook}" = "xyes" ; then
8175 $as_echo "#define JEMALLOC_GLIBC_MEMALIGN_HOOK " >>confdefs.h
8176
8177fi
8178
8179
8180{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads adaptive mutexes is compilable" >&5
8181$as_echo_n "checking whether pthreads adaptive mutexes is compilable... " >&6; }
8182if ${je_cv_pthread_mutex_adaptive_np+:} false; then :
8183 $as_echo_n "(cached) " >&6
8184else
8185 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8186/* end confdefs.h. */
8187
8188#include <pthread.h>
8189
8190int
8191main ()
8192{
8193
8194 pthread_mutexattr_t attr;
8195 pthread_mutexattr_init(&attr);
8196 pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_ADAPTIVE_NP);
8197 pthread_mutexattr_destroy(&attr);
8198
8199 ;
8200 return 0;
8201}
8202_ACEOF
8203if ac_fn_c_try_link "$LINENO"; then :
8204 je_cv_pthread_mutex_adaptive_np=yes
8205else
8206 je_cv_pthread_mutex_adaptive_np=no
8207fi
8208rm -f core conftest.err conftest.$ac_objext \
8209 conftest$ac_exeext conftest.$ac_ext
8210fi
8211{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $je_cv_pthread_mutex_adaptive_np" >&5
8212$as_echo "$je_cv_pthread_mutex_adaptive_np" >&6; }
8213
8214if test "x${je_cv_pthread_mutex_adaptive_np}" = "xyes" ; then
8215 $as_echo "#define JEMALLOC_HAVE_PTHREAD_MUTEX_ADAPTIVE_NP " >>confdefs.h
8216
8217fi
8218
970d7e83
LB
8219{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
8220$as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
8221if ${ac_cv_header_stdbool_h+:} false; then :
8222 $as_echo_n "(cached) " >&6
8223else
8224 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8225/* end confdefs.h. */
8226
8227 #include <stdbool.h>
8228 #ifndef bool
8229 "error: bool is not defined"
8230 #endif
8231 #ifndef false
8232 "error: false is not defined"
8233 #endif
8234 #if false
8235 "error: false is not 0"
8236 #endif
8237 #ifndef true
8238 "error: true is not defined"
8239 #endif
8240 #if true != 1
8241 "error: true is not 1"
8242 #endif
8243 #ifndef __bool_true_false_are_defined
8244 "error: __bool_true_false_are_defined is not defined"
8245 #endif
8246
8247 struct s { _Bool s: 1; _Bool t; } s;
8248
8249 char a[true == 1 ? 1 : -1];
8250 char b[false == 0 ? 1 : -1];
8251 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
8252 char d[(bool) 0.5 == true ? 1 : -1];
8253 /* See body of main program for 'e'. */
8254 char f[(_Bool) 0.0 == false ? 1 : -1];
8255 char g[true];
8256 char h[sizeof (_Bool)];
8257 char i[sizeof s.t];
8258 enum { j = false, k = true, l = false * true, m = true * 256 };
8259 /* The following fails for
8260 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
8261 _Bool n[m];
8262 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
8263 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
8264 /* Catch a bug in an HP-UX C compiler. See
8265 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
8266 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
8267 */
8268 _Bool q = true;
8269 _Bool *pq = &q;
8270
8271int
8272main ()
8273{
8274
8275 bool e = &s;
8276 *pq |= q;
8277 *pq |= ! q;
8278 /* Refer to every declared value, to avoid compiler optimizations. */
8279 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
8280 + !m + !n + !o + !p + !q + !pq);
8281
8282 ;
8283 return 0;
8284}
8285_ACEOF
8286if ac_fn_c_try_compile "$LINENO"; then :
8287 ac_cv_header_stdbool_h=yes
8288else
8289 ac_cv_header_stdbool_h=no
8290fi
8291rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8292fi
8293{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
8294$as_echo "$ac_cv_header_stdbool_h" >&6; }
8295 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
8296if test "x$ac_cv_type__Bool" = xyes; then :
8297
8298cat >>confdefs.h <<_ACEOF
8299#define HAVE__BOOL 1
8300_ACEOF
8301
8302
8303fi
8304
8305
8306if test $ac_cv_header_stdbool_h = yes; then
8307
8308$as_echo "#define HAVE_STDBOOL_H 1" >>confdefs.h
8309
8310fi
8311
8312
1a4d82fc
JJ
8313
8314ac_config_commands="$ac_config_commands include/jemalloc/internal/private_namespace.h"
8315
8316ac_config_commands="$ac_config_commands include/jemalloc/internal/private_unnamespace.h"
8317
8318ac_config_commands="$ac_config_commands include/jemalloc/internal/public_symbols.txt"
8319
8320ac_config_commands="$ac_config_commands include/jemalloc/internal/public_namespace.h"
8321
8322ac_config_commands="$ac_config_commands include/jemalloc/internal/public_unnamespace.h"
8323
970d7e83
LB
8324ac_config_commands="$ac_config_commands include/jemalloc/internal/size_classes.h"
8325
1a4d82fc
JJ
8326ac_config_commands="$ac_config_commands include/jemalloc/jemalloc_protos_jet.h"
8327
8328ac_config_commands="$ac_config_commands include/jemalloc/jemalloc_rename.h"
8329
8330ac_config_commands="$ac_config_commands include/jemalloc/jemalloc_mangle.h"
8331
8332ac_config_commands="$ac_config_commands include/jemalloc/jemalloc_mangle_jet.h"
8333
8334ac_config_commands="$ac_config_commands include/jemalloc/jemalloc.h"
8335
970d7e83
LB
8336
8337
8338
8339ac_config_headers="$ac_config_headers $cfghdrs_tup"
8340
8341
1a4d82fc 8342
54a0048b 8343ac_config_files="$ac_config_files $cfgoutputs_tup config.stamp bin/jemalloc-config bin/jemalloc.sh bin/jeprof"
970d7e83
LB
8344
8345
8346
8347cat >confcache <<\_ACEOF
8348# This file is a shell script that caches the results of configure
8349# tests run on this system so they can be shared between configure
8350# scripts and configure runs, see configure's option --config-cache.
8351# It is not useful on other systems. If it contains results you don't
8352# want to keep, you may remove or edit it.
8353#
8354# config.status only pays attention to the cache file if you give it
8355# the --recheck option to rerun configure.
8356#
8357# `ac_cv_env_foo' variables (set or unset) will be overridden when
8358# loading this file, other *unset* `ac_cv_foo' will be assigned the
8359# following values.
8360
8361_ACEOF
8362
8363# The following way of writing the cache mishandles newlines in values,
8364# but we know of no workaround that is simple, portable, and efficient.
8365# So, we kill variables containing newlines.
8366# Ultrix sh set writes to stderr and can't be redirected directly,
8367# and sets the high bit in the cache file unless we assign to the vars.
8368(
8369 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
8370 eval ac_val=\$$ac_var
8371 case $ac_val in #(
8372 *${as_nl}*)
8373 case $ac_var in #(
8374 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
8375$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
8376 esac
8377 case $ac_var in #(
8378 _ | IFS | as_nl) ;; #(
8379 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
8380 *) { eval $ac_var=; unset $ac_var;} ;;
8381 esac ;;
8382 esac
8383 done
8384
8385 (set) 2>&1 |
8386 case $as_nl`(ac_space=' '; set) 2>&1` in #(
8387 *${as_nl}ac_space=\ *)
8388 # `set' does not quote correctly, so add quotes: double-quote
8389 # substitution turns \\\\ into \\, and sed turns \\ into \.
8390 sed -n \
8391 "s/'/'\\\\''/g;
8392 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
8393 ;; #(
8394 *)
8395 # `set' quotes correctly as required by POSIX, so do not add quotes.
8396 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
8397 ;;
8398 esac |
8399 sort
8400) |
8401 sed '
8402 /^ac_cv_env_/b end
8403 t clear
8404 :clear
8405 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
8406 t end
8407 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
8408 :end' >>confcache
8409if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
8410 if test -w "$cache_file"; then
8411 if test "x$cache_file" != "x/dev/null"; then
8412 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
8413$as_echo "$as_me: updating cache $cache_file" >&6;}
8414 if test ! -f "$cache_file" || test -h "$cache_file"; then
8415 cat confcache >"$cache_file"
8416 else
8417 case $cache_file in #(
8418 */* | ?:*)
8419 mv -f confcache "$cache_file"$$ &&
8420 mv -f "$cache_file"$$ "$cache_file" ;; #(
8421 *)
8422 mv -f confcache "$cache_file" ;;
8423 esac
8424 fi
8425 fi
8426 else
8427 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
8428$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
8429 fi
8430fi
8431rm -f confcache
8432
8433test "x$prefix" = xNONE && prefix=$ac_default_prefix
8434# Let make expand exec_prefix.
8435test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
8436
8437DEFS=-DHAVE_CONFIG_H
8438
8439ac_libobjs=
8440ac_ltlibobjs=
8441U=
8442for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
8443 # 1. Remove the extension, and $U if already installed.
8444 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
8445 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
8446 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
8447 # will be set to the directory where LIBOBJS objects are built.
8448 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
8449 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
8450done
8451LIBOBJS=$ac_libobjs
8452
8453LTLIBOBJS=$ac_ltlibobjs
8454
8455
8456
1a4d82fc 8457
970d7e83
LB
8458: "${CONFIG_STATUS=./config.status}"
8459ac_write_fail=0
8460ac_clean_files_save=$ac_clean_files
8461ac_clean_files="$ac_clean_files $CONFIG_STATUS"
8462{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
8463$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
8464as_write_fail=0
8465cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
8466#! $SHELL
8467# Generated by $as_me.
8468# Run this file to recreate the current configuration.
8469# Compiler output produced by configure, useful for debugging
8470# configure, is in config.log if it exists.
8471
8472debug=false
8473ac_cs_recheck=false
8474ac_cs_silent=false
8475
8476SHELL=\${CONFIG_SHELL-$SHELL}
8477export SHELL
8478_ASEOF
8479cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
8480## -------------------- ##
8481## M4sh Initialization. ##
8482## -------------------- ##
8483
8484# Be more Bourne compatible
8485DUALCASE=1; export DUALCASE # for MKS sh
8486if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
8487 emulate sh
8488 NULLCMD=:
8489 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
8490 # is contrary to our usage. Disable this feature.
8491 alias -g '${1+"$@"}'='"$@"'
8492 setopt NO_GLOB_SUBST
8493else
8494 case `(set -o) 2>/dev/null` in #(
8495 *posix*) :
8496 set -o posix ;; #(
8497 *) :
8498 ;;
8499esac
8500fi
8501
8502
8503as_nl='
8504'
8505export as_nl
8506# Printing a long string crashes Solaris 7 /usr/bin/printf.
8507as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
8508as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
8509as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
8510# Prefer a ksh shell builtin over an external printf program on Solaris,
8511# but without wasting forks for bash or zsh.
8512if test -z "$BASH_VERSION$ZSH_VERSION" \
8513 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
8514 as_echo='print -r --'
8515 as_echo_n='print -rn --'
8516elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
8517 as_echo='printf %s\n'
8518 as_echo_n='printf %s'
8519else
8520 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
8521 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
8522 as_echo_n='/usr/ucb/echo -n'
8523 else
8524 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
8525 as_echo_n_body='eval
8526 arg=$1;
8527 case $arg in #(
8528 *"$as_nl"*)
8529 expr "X$arg" : "X\\(.*\\)$as_nl";
8530 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
8531 esac;
8532 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
8533 '
8534 export as_echo_n_body
8535 as_echo_n='sh -c $as_echo_n_body as_echo'
8536 fi
8537 export as_echo_body
8538 as_echo='sh -c $as_echo_body as_echo'
8539fi
8540
8541# The user is always right.
8542if test "${PATH_SEPARATOR+set}" != set; then
8543 PATH_SEPARATOR=:
8544 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
8545 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
8546 PATH_SEPARATOR=';'
8547 }
8548fi
8549
8550
8551# IFS
8552# We need space, tab and new line, in precisely that order. Quoting is
8553# there to prevent editors from complaining about space-tab.
8554# (If _AS_PATH_WALK were called with IFS unset, it would disable word
8555# splitting by setting IFS to empty value.)
8556IFS=" "" $as_nl"
8557
8558# Find who we are. Look in the path if we contain no directory separator.
8559as_myself=
8560case $0 in #((
8561 *[\\/]* ) as_myself=$0 ;;
8562 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8563for as_dir in $PATH
8564do
8565 IFS=$as_save_IFS
8566 test -z "$as_dir" && as_dir=.
8567 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
8568 done
8569IFS=$as_save_IFS
8570
8571 ;;
8572esac
8573# We did not find ourselves, most probably we were run as `sh COMMAND'
8574# in which case we are not to be found in the path.
8575if test "x$as_myself" = x; then
8576 as_myself=$0
8577fi
8578if test ! -f "$as_myself"; then
8579 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
8580 exit 1
8581fi
8582
8583# Unset variables that we do not need and which cause bugs (e.g. in
8584# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
8585# suppresses any "Segmentation fault" message there. '((' could
8586# trigger a bug in pdksh 5.2.14.
8587for as_var in BASH_ENV ENV MAIL MAILPATH
8588do eval test x\${$as_var+set} = xset \
8589 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
8590done
8591PS1='$ '
8592PS2='> '
8593PS4='+ '
8594
8595# NLS nuisances.
8596LC_ALL=C
8597export LC_ALL
8598LANGUAGE=C
8599export LANGUAGE
8600
8601# CDPATH.
8602(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
8603
8604
8605# as_fn_error STATUS ERROR [LINENO LOG_FD]
8606# ----------------------------------------
8607# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
8608# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
8609# script with STATUS, using 1 if that was 0.
8610as_fn_error ()
8611{
8612 as_status=$1; test $as_status -eq 0 && as_status=1
8613 if test "$4"; then
8614 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
8615 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
8616 fi
8617 $as_echo "$as_me: error: $2" >&2
8618 as_fn_exit $as_status
8619} # as_fn_error
8620
8621
8622# as_fn_set_status STATUS
8623# -----------------------
8624# Set $? to STATUS, without forking.
8625as_fn_set_status ()
8626{
8627 return $1
8628} # as_fn_set_status
8629
8630# as_fn_exit STATUS
8631# -----------------
8632# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
8633as_fn_exit ()
8634{
8635 set +e
8636 as_fn_set_status $1
8637 exit $1
8638} # as_fn_exit
8639
8640# as_fn_unset VAR
8641# ---------------
8642# Portably unset VAR.
8643as_fn_unset ()
8644{
8645 { eval $1=; unset $1;}
8646}
8647as_unset=as_fn_unset
8648# as_fn_append VAR VALUE
8649# ----------------------
8650# Append the text in VALUE to the end of the definition contained in VAR. Take
8651# advantage of any shell optimizations that allow amortized linear growth over
8652# repeated appends, instead of the typical quadratic growth present in naive
8653# implementations.
8654if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
8655 eval 'as_fn_append ()
8656 {
8657 eval $1+=\$2
8658 }'
8659else
8660 as_fn_append ()
8661 {
8662 eval $1=\$$1\$2
8663 }
8664fi # as_fn_append
8665
8666# as_fn_arith ARG...
8667# ------------------
8668# Perform arithmetic evaluation on the ARGs, and store the result in the
8669# global $as_val. Take advantage of shells that can avoid forks. The arguments
8670# must be portable across $(()) and expr.
8671if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
8672 eval 'as_fn_arith ()
8673 {
8674 as_val=$(( $* ))
8675 }'
8676else
8677 as_fn_arith ()
8678 {
8679 as_val=`expr "$@" || test $? -eq 1`
8680 }
8681fi # as_fn_arith
8682
8683
8684if expr a : '\(a\)' >/dev/null 2>&1 &&
8685 test "X`expr 00001 : '.*\(...\)'`" = X001; then
8686 as_expr=expr
8687else
8688 as_expr=false
8689fi
8690
8691if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
8692 as_basename=basename
8693else
8694 as_basename=false
8695fi
8696
8697if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
8698 as_dirname=dirname
8699else
8700 as_dirname=false
8701fi
8702
8703as_me=`$as_basename -- "$0" ||
8704$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
8705 X"$0" : 'X\(//\)$' \| \
8706 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
8707$as_echo X/"$0" |
8708 sed '/^.*\/\([^/][^/]*\)\/*$/{
8709 s//\1/
8710 q
8711 }
8712 /^X\/\(\/\/\)$/{
8713 s//\1/
8714 q
8715 }
8716 /^X\/\(\/\).*/{
8717 s//\1/
8718 q
8719 }
8720 s/.*/./; q'`
8721
8722# Avoid depending upon Character Ranges.
8723as_cr_letters='abcdefghijklmnopqrstuvwxyz'
8724as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
8725as_cr_Letters=$as_cr_letters$as_cr_LETTERS
8726as_cr_digits='0123456789'
8727as_cr_alnum=$as_cr_Letters$as_cr_digits
8728
8729ECHO_C= ECHO_N= ECHO_T=
8730case `echo -n x` in #(((((
8731-n*)
8732 case `echo 'xy\c'` in
8733 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
8734 xy) ECHO_C='\c';;
8735 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
8736 ECHO_T=' ';;
8737 esac;;
8738*)
8739 ECHO_N='-n';;
8740esac
8741
8742rm -f conf$$ conf$$.exe conf$$.file
8743if test -d conf$$.dir; then
8744 rm -f conf$$.dir/conf$$.file
8745else
8746 rm -f conf$$.dir
8747 mkdir conf$$.dir 2>/dev/null
8748fi
8749if (echo >conf$$.file) 2>/dev/null; then
8750 if ln -s conf$$.file conf$$ 2>/dev/null; then
8751 as_ln_s='ln -s'
8752 # ... but there are two gotchas:
8753 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
8754 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
8755 # In both cases, we have to default to `cp -pR'.
8756 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
8757 as_ln_s='cp -pR'
8758 elif ln conf$$.file conf$$ 2>/dev/null; then
8759 as_ln_s=ln
8760 else
8761 as_ln_s='cp -pR'
8762 fi
8763else
8764 as_ln_s='cp -pR'
8765fi
8766rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
8767rmdir conf$$.dir 2>/dev/null
8768
8769
8770# as_fn_mkdir_p
8771# -------------
8772# Create "$as_dir" as a directory, including parents if necessary.
8773as_fn_mkdir_p ()
8774{
8775
8776 case $as_dir in #(
8777 -*) as_dir=./$as_dir;;
8778 esac
8779 test -d "$as_dir" || eval $as_mkdir_p || {
8780 as_dirs=
8781 while :; do
8782 case $as_dir in #(
8783 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
8784 *) as_qdir=$as_dir;;
8785 esac
8786 as_dirs="'$as_qdir' $as_dirs"
8787 as_dir=`$as_dirname -- "$as_dir" ||
8788$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
8789 X"$as_dir" : 'X\(//\)[^/]' \| \
8790 X"$as_dir" : 'X\(//\)$' \| \
8791 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
8792$as_echo X"$as_dir" |
8793 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
8794 s//\1/
8795 q
8796 }
8797 /^X\(\/\/\)[^/].*/{
8798 s//\1/
8799 q
8800 }
8801 /^X\(\/\/\)$/{
8802 s//\1/
8803 q
8804 }
8805 /^X\(\/\).*/{
8806 s//\1/
8807 q
8808 }
8809 s/.*/./; q'`
8810 test -d "$as_dir" && break
8811 done
8812 test -z "$as_dirs" || eval "mkdir $as_dirs"
8813 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
8814
8815
8816} # as_fn_mkdir_p
8817if mkdir -p . 2>/dev/null; then
8818 as_mkdir_p='mkdir -p "$as_dir"'
8819else
8820 test -d ./-p && rmdir ./-p
8821 as_mkdir_p=false
8822fi
8823
8824
8825# as_fn_executable_p FILE
8826# -----------------------
8827# Test if FILE is an executable regular file.
8828as_fn_executable_p ()
8829{
8830 test -f "$1" && test -x "$1"
8831} # as_fn_executable_p
8832as_test_x='test -x'
8833as_executable_p=as_fn_executable_p
8834
8835# Sed expression to map a string onto a valid CPP name.
8836as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
8837
8838# Sed expression to map a string onto a valid variable name.
8839as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
8840
8841
8842exec 6>&1
8843## ----------------------------------- ##
8844## Main body of $CONFIG_STATUS script. ##
8845## ----------------------------------- ##
8846_ASEOF
8847test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
8848
8849cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
8850# Save the log message, to keep $0 and so on meaningful, and to
8851# report actual input values of CONFIG_FILES etc. instead of their
8852# values after options handling.
8853ac_log="
8854This file was extended by $as_me, which was
8855generated by GNU Autoconf 2.69. Invocation command line was
8856
8857 CONFIG_FILES = $CONFIG_FILES
8858 CONFIG_HEADERS = $CONFIG_HEADERS
8859 CONFIG_LINKS = $CONFIG_LINKS
8860 CONFIG_COMMANDS = $CONFIG_COMMANDS
8861 $ $0 $@
8862
8863on `(hostname || uname -n) 2>/dev/null | sed 1q`
8864"
8865
8866_ACEOF
8867
8868case $ac_config_files in *"
8869"*) set x $ac_config_files; shift; ac_config_files=$*;;
8870esac
8871
8872case $ac_config_headers in *"
8873"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
8874esac
8875
8876
8877cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
8878# Files that config.status was made for.
8879config_files="$ac_config_files"
8880config_headers="$ac_config_headers"
8881config_commands="$ac_config_commands"
8882
8883_ACEOF
8884
8885cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
8886ac_cs_usage="\
8887\`$as_me' instantiates files and other configuration actions
8888from templates according to the current configuration. Unless the files
8889and actions are specified as TAGs, all are instantiated by default.
8890
8891Usage: $0 [OPTION]... [TAG]...
8892
8893 -h, --help print this help, then exit
8894 -V, --version print version number and configuration settings, then exit
8895 --config print configuration, then exit
8896 -q, --quiet, --silent
8897 do not print progress messages
8898 -d, --debug don't remove temporary files
8899 --recheck update $as_me by reconfiguring in the same conditions
8900 --file=FILE[:TEMPLATE]
8901 instantiate the configuration file FILE
8902 --header=FILE[:TEMPLATE]
8903 instantiate the configuration header FILE
8904
8905Configuration files:
8906$config_files
8907
8908Configuration headers:
8909$config_headers
8910
8911Configuration commands:
8912$config_commands
8913
8914Report bugs to the package provider."
8915
8916_ACEOF
8917cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
8918ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
8919ac_cs_version="\\
8920config.status
8921configured by $0, generated by GNU Autoconf 2.69,
8922 with options \\"\$ac_cs_config\\"
8923
8924Copyright (C) 2012 Free Software Foundation, Inc.
8925This config.status script is free software; the Free Software Foundation
8926gives unlimited permission to copy, distribute and modify it."
8927
8928ac_pwd='$ac_pwd'
8929srcdir='$srcdir'
8930INSTALL='$INSTALL'
8931test -n "\$AWK" || AWK=awk
8932_ACEOF
8933
8934cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
8935# The default lists apply if the user does not specify any file.
8936ac_need_defaults=:
8937while test $# != 0
8938do
8939 case $1 in
8940 --*=?*)
8941 ac_option=`expr "X$1" : 'X\([^=]*\)='`
8942 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
8943 ac_shift=:
8944 ;;
8945 --*=)
8946 ac_option=`expr "X$1" : 'X\([^=]*\)='`
8947 ac_optarg=
8948 ac_shift=:
8949 ;;
8950 *)
8951 ac_option=$1
8952 ac_optarg=$2
8953 ac_shift=shift
8954 ;;
8955 esac
8956
8957 case $ac_option in
8958 # Handling of the options.
8959 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
8960 ac_cs_recheck=: ;;
8961 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
8962 $as_echo "$ac_cs_version"; exit ;;
8963 --config | --confi | --conf | --con | --co | --c )
8964 $as_echo "$ac_cs_config"; exit ;;
8965 --debug | --debu | --deb | --de | --d | -d )
8966 debug=: ;;
8967 --file | --fil | --fi | --f )
8968 $ac_shift
8969 case $ac_optarg in
8970 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
8971 '') as_fn_error $? "missing file argument" ;;
8972 esac
8973 as_fn_append CONFIG_FILES " '$ac_optarg'"
8974 ac_need_defaults=false;;
8975 --header | --heade | --head | --hea )
8976 $ac_shift
8977 case $ac_optarg in
8978 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
8979 esac
8980 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
8981 ac_need_defaults=false;;
8982 --he | --h)
8983 # Conflict between --help and --header
8984 as_fn_error $? "ambiguous option: \`$1'
8985Try \`$0 --help' for more information.";;
8986 --help | --hel | -h )
8987 $as_echo "$ac_cs_usage"; exit ;;
8988 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
8989 | -silent | --silent | --silen | --sile | --sil | --si | --s)
8990 ac_cs_silent=: ;;
8991
8992 # This is an error.
8993 -*) as_fn_error $? "unrecognized option: \`$1'
8994Try \`$0 --help' for more information." ;;
8995
8996 *) as_fn_append ac_config_targets " $1"
8997 ac_need_defaults=false ;;
8998
8999 esac
9000 shift
9001done
9002
9003ac_configure_extra_args=
9004
9005if $ac_cs_silent; then
9006 exec 6>/dev/null
9007 ac_configure_extra_args="$ac_configure_extra_args --silent"
9008fi
9009
9010_ACEOF
9011cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9012if \$ac_cs_recheck; then
9013 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
9014 shift
9015 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
9016 CONFIG_SHELL='$SHELL'
9017 export CONFIG_SHELL
9018 exec "\$@"
9019fi
9020
9021_ACEOF
9022cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9023exec 5>>config.log
9024{
9025 echo
9026 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
9027## Running $as_me. ##
9028_ASBOX
9029 $as_echo "$ac_log"
9030} >&5
9031
9032_ACEOF
9033cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
1a4d82fc
JJ
9034#
9035# INIT-COMMANDS
9036#
9037
9038 srcdir="${srcdir}"
9039 objroot="${objroot}"
9040
9041
9042 srcdir="${srcdir}"
9043 objroot="${objroot}"
9044
9045
9046 srcdir="${srcdir}"
9047 objroot="${objroot}"
9048 mangling_map="${mangling_map}"
9049 public_syms="${public_syms}"
9050 JEMALLOC_PREFIX="${JEMALLOC_PREFIX}"
9051
9052
9053 srcdir="${srcdir}"
9054 objroot="${objroot}"
9055
9056
9057 srcdir="${srcdir}"
9058 objroot="${objroot}"
9059
9060
54a0048b 9061 SHELL="${SHELL}"
1a4d82fc
JJ
9062 srcdir="${srcdir}"
9063 objroot="${objroot}"
54a0048b
SL
9064 LG_QUANTA="${LG_QUANTA}"
9065 LG_TINY_MIN=${LG_TINY_MIN}
9066 LG_PAGE_SIZES="${LG_PAGE_SIZES}"
9067 LG_SIZE_CLASS_GROUP=${LG_SIZE_CLASS_GROUP}
1a4d82fc
JJ
9068
9069
9070 srcdir="${srcdir}"
9071 objroot="${objroot}"
9072
9073
9074 srcdir="${srcdir}"
9075 objroot="${objroot}"
9076
9077
9078 srcdir="${srcdir}"
9079 objroot="${objroot}"
9080
9081
9082 srcdir="${srcdir}"
9083 objroot="${objroot}"
9084
9085
9086 srcdir="${srcdir}"
9087 objroot="${objroot}"
9088 install_suffix="${install_suffix}"
9089
9090
970d7e83
LB
9091_ACEOF
9092
9093cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9094
9095# Handling of arguments.
9096for ac_config_target in $ac_config_targets
9097do
9098 case $ac_config_target in
1a4d82fc
JJ
9099 "include/jemalloc/internal/private_namespace.h") CONFIG_COMMANDS="$CONFIG_COMMANDS include/jemalloc/internal/private_namespace.h" ;;
9100 "include/jemalloc/internal/private_unnamespace.h") CONFIG_COMMANDS="$CONFIG_COMMANDS include/jemalloc/internal/private_unnamespace.h" ;;
9101 "include/jemalloc/internal/public_symbols.txt") CONFIG_COMMANDS="$CONFIG_COMMANDS include/jemalloc/internal/public_symbols.txt" ;;
9102 "include/jemalloc/internal/public_namespace.h") CONFIG_COMMANDS="$CONFIG_COMMANDS include/jemalloc/internal/public_namespace.h" ;;
9103 "include/jemalloc/internal/public_unnamespace.h") CONFIG_COMMANDS="$CONFIG_COMMANDS include/jemalloc/internal/public_unnamespace.h" ;;
970d7e83 9104 "include/jemalloc/internal/size_classes.h") CONFIG_COMMANDS="$CONFIG_COMMANDS include/jemalloc/internal/size_classes.h" ;;
1a4d82fc
JJ
9105 "include/jemalloc/jemalloc_protos_jet.h") CONFIG_COMMANDS="$CONFIG_COMMANDS include/jemalloc/jemalloc_protos_jet.h" ;;
9106 "include/jemalloc/jemalloc_rename.h") CONFIG_COMMANDS="$CONFIG_COMMANDS include/jemalloc/jemalloc_rename.h" ;;
9107 "include/jemalloc/jemalloc_mangle.h") CONFIG_COMMANDS="$CONFIG_COMMANDS include/jemalloc/jemalloc_mangle.h" ;;
9108 "include/jemalloc/jemalloc_mangle_jet.h") CONFIG_COMMANDS="$CONFIG_COMMANDS include/jemalloc/jemalloc_mangle_jet.h" ;;
9109 "include/jemalloc/jemalloc.h") CONFIG_COMMANDS="$CONFIG_COMMANDS include/jemalloc/jemalloc.h" ;;
970d7e83
LB
9110 "$cfghdrs_tup") CONFIG_HEADERS="$CONFIG_HEADERS $cfghdrs_tup" ;;
9111 "$cfgoutputs_tup") CONFIG_FILES="$CONFIG_FILES $cfgoutputs_tup" ;;
9112 "config.stamp") CONFIG_FILES="$CONFIG_FILES config.stamp" ;;
54a0048b 9113 "bin/jemalloc-config") CONFIG_FILES="$CONFIG_FILES bin/jemalloc-config" ;;
970d7e83 9114 "bin/jemalloc.sh") CONFIG_FILES="$CONFIG_FILES bin/jemalloc.sh" ;;
54a0048b 9115 "bin/jeprof") CONFIG_FILES="$CONFIG_FILES bin/jeprof" ;;
970d7e83
LB
9116
9117 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
9118 esac
9119done
9120
9121
9122# If the user did not use the arguments to specify the items to instantiate,
9123# then the envvar interface is used. Set only those that are not.
9124# We use the long form for the default assignment because of an extremely
9125# bizarre bug on SunOS 4.1.3.
9126if $ac_need_defaults; then
9127 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
9128 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
9129 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
9130fi
9131
9132# Have a temporary directory for convenience. Make it in the build tree
9133# simply because there is no reason against having it here, and in addition,
9134# creating and moving files from /tmp can sometimes cause problems.
9135# Hook for its removal unless debugging.
9136# Note that there is a small window in which the directory will not be cleaned:
9137# after its creation but before its name has been assigned to `$tmp'.
9138$debug ||
9139{
9140 tmp= ac_tmp=
9141 trap 'exit_status=$?
9142 : "${ac_tmp:=$tmp}"
9143 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
9144' 0
9145 trap 'as_fn_exit 1' 1 2 13 15
9146}
9147# Create a (secure) tmp directory for tmp files.
9148
9149{
9150 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
9151 test -d "$tmp"
9152} ||
9153{
9154 tmp=./conf$$-$RANDOM
9155 (umask 077 && mkdir "$tmp")
9156} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
9157ac_tmp=$tmp
9158
9159# Set up the scripts for CONFIG_FILES section.
9160# No need to generate them if there are no CONFIG_FILES.
9161# This happens for instance with `./config.status config.h'.
9162if test -n "$CONFIG_FILES"; then
9163
9164
9165ac_cr=`echo X | tr X '\015'`
9166# On cygwin, bash can eat \r inside `` if the user requested igncr.
9167# But we know of no other shell where ac_cr would be empty at this
9168# point, so we can use a bashism as a fallback.
9169if test "x$ac_cr" = x; then
9170 eval ac_cr=\$\'\\r\'
9171fi
9172ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
9173if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
9174 ac_cs_awk_cr='\\r'
9175else
9176 ac_cs_awk_cr=$ac_cr
9177fi
9178
9179echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
9180_ACEOF
9181
9182
9183{
9184 echo "cat >conf$$subs.awk <<_ACEOF" &&
9185 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
9186 echo "_ACEOF"
9187} >conf$$subs.sh ||
9188 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
9189ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
9190ac_delim='%!_!# '
9191for ac_last_try in false false false false false :; do
9192 . ./conf$$subs.sh ||
9193 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
9194
9195 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
9196 if test $ac_delim_n = $ac_delim_num; then
9197 break
9198 elif $ac_last_try; then
9199 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
9200 else
9201 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
9202 fi
9203done
9204rm -f conf$$subs.sh
9205
9206cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9207cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
9208_ACEOF
9209sed -n '
9210h
9211s/^/S["/; s/!.*/"]=/
9212p
9213g
9214s/^[^!]*!//
9215:repl
9216t repl
9217s/'"$ac_delim"'$//
9218t delim
9219:nl
9220h
9221s/\(.\{148\}\)..*/\1/
9222t more1
9223s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
9224p
9225n
9226b repl
9227:more1
9228s/["\\]/\\&/g; s/^/"/; s/$/"\\/
9229p
9230g
9231s/.\{148\}//
9232t nl
9233:delim
9234h
9235s/\(.\{148\}\)..*/\1/
9236t more2
9237s/["\\]/\\&/g; s/^/"/; s/$/"/
9238p
9239b
9240:more2
9241s/["\\]/\\&/g; s/^/"/; s/$/"\\/
9242p
9243g
9244s/.\{148\}//
9245t delim
9246' <conf$$subs.awk | sed '
9247/^[^""]/{
9248 N
9249 s/\n//
9250}
9251' >>$CONFIG_STATUS || ac_write_fail=1
9252rm -f conf$$subs.awk
9253cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9254_ACAWK
9255cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
9256 for (key in S) S_is_set[key] = 1
9257 FS = "\a"
9258
9259}
9260{
9261 line = $ 0
9262 nfields = split(line, field, "@")
9263 substed = 0
9264 len = length(field[1])
9265 for (i = 2; i < nfields; i++) {
9266 key = field[i]
9267 keylen = length(key)
9268 if (S_is_set[key]) {
9269 value = S[key]
9270 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
9271 len += length(value) + length(field[++i])
9272 substed = 1
9273 } else
9274 len += 1 + keylen
9275 }
9276
9277 print line
9278}
9279
9280_ACAWK
9281_ACEOF
9282cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9283if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
9284 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
9285else
9286 cat
9287fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
9288 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
9289_ACEOF
9290
9291# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
9292# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
9293# trailing colons and then remove the whole line if VPATH becomes empty
9294# (actually we leave an empty line to preserve line numbers).
9295if test "x$srcdir" = x.; then
9296 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
9297h
9298s///
9299s/^/:/
9300s/[ ]*$/:/
9301s/:\$(srcdir):/:/g
9302s/:\${srcdir}:/:/g
9303s/:@srcdir@:/:/g
9304s/^:*//
9305s/:*$//
9306x
9307s/\(=[ ]*\).*/\1/
9308G
9309s/\n//
9310s/^[^=]*=[ ]*$//
9311}'
9312fi
9313
9314cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9315fi # test -n "$CONFIG_FILES"
9316
9317# Set up the scripts for CONFIG_HEADERS section.
9318# No need to generate them if there are no CONFIG_HEADERS.
9319# This happens for instance with `./config.status Makefile'.
9320if test -n "$CONFIG_HEADERS"; then
9321cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
9322BEGIN {
9323_ACEOF
9324
9325# Transform confdefs.h into an awk script `defines.awk', embedded as
9326# here-document in config.status, that substitutes the proper values into
9327# config.h.in to produce config.h.
9328
9329# Create a delimiter string that does not exist in confdefs.h, to ease
9330# handling of long lines.
9331ac_delim='%!_!# '
9332for ac_last_try in false false :; do
9333 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
9334 if test -z "$ac_tt"; then
9335 break
9336 elif $ac_last_try; then
9337 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
9338 else
9339 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
9340 fi
9341done
9342
9343# For the awk script, D is an array of macro values keyed by name,
9344# likewise P contains macro parameters if any. Preserve backslash
9345# newline sequences.
9346
9347ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
9348sed -n '
9349s/.\{148\}/&'"$ac_delim"'/g
9350t rset
9351:rset
9352s/^[ ]*#[ ]*define[ ][ ]*/ /
9353t def
9354d
9355:def
9356s/\\$//
9357t bsnl
9358s/["\\]/\\&/g
9359s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
9360D["\1"]=" \3"/p
9361s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
9362d
9363:bsnl
9364s/["\\]/\\&/g
9365s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
9366D["\1"]=" \3\\\\\\n"\\/p
9367t cont
9368s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
9369t cont
9370d
9371:cont
9372n
9373s/.\{148\}/&'"$ac_delim"'/g
9374t clear
9375:clear
9376s/\\$//
9377t bsnlc
9378s/["\\]/\\&/g; s/^/"/; s/$/"/p
9379d
9380:bsnlc
9381s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
9382b cont
9383' <confdefs.h | sed '
9384s/'"$ac_delim"'/"\\\
9385"/g' >>$CONFIG_STATUS || ac_write_fail=1
9386
9387cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9388 for (key in D) D_is_set[key] = 1
9389 FS = "\a"
9390}
9391/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
9392 line = \$ 0
9393 split(line, arg, " ")
9394 if (arg[1] == "#") {
9395 defundef = arg[2]
9396 mac1 = arg[3]
9397 } else {
9398 defundef = substr(arg[1], 2)
9399 mac1 = arg[2]
9400 }
9401 split(mac1, mac2, "(") #)
9402 macro = mac2[1]
9403 prefix = substr(line, 1, index(line, defundef) - 1)
9404 if (D_is_set[macro]) {
9405 # Preserve the white space surrounding the "#".
9406 print prefix "define", macro P[macro] D[macro]
9407 next
9408 } else {
9409 # Replace #undef with comments. This is necessary, for example,
9410 # in the case of _POSIX_SOURCE, which is predefined and required
9411 # on some systems where configure will not decide to define it.
9412 if (defundef == "undef") {
9413 print "/*", prefix defundef, macro, "*/"
9414 next
9415 }
9416 }
9417}
9418{ print }
9419_ACAWK
9420_ACEOF
9421cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9422 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
9423fi # test -n "$CONFIG_HEADERS"
9424
9425
9426eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
9427shift
9428for ac_tag
9429do
9430 case $ac_tag in
9431 :[FHLC]) ac_mode=$ac_tag; continue;;
9432 esac
9433 case $ac_mode$ac_tag in
9434 :[FHL]*:*);;
9435 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
9436 :[FH]-) ac_tag=-:-;;
9437 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
9438 esac
9439 ac_save_IFS=$IFS
9440 IFS=:
9441 set x $ac_tag
9442 IFS=$ac_save_IFS
9443 shift
9444 ac_file=$1
9445 shift
9446
9447 case $ac_mode in
9448 :L) ac_source=$1;;
9449 :[FH])
9450 ac_file_inputs=
9451 for ac_f
9452 do
9453 case $ac_f in
9454 -) ac_f="$ac_tmp/stdin";;
9455 *) # Look for the file first in the build tree, then in the source tree
9456 # (if the path is not absolute). The absolute path cannot be DOS-style,
9457 # because $ac_f cannot contain `:'.
9458 test -f "$ac_f" ||
9459 case $ac_f in
9460 [\\/$]*) false;;
9461 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
9462 esac ||
9463 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
9464 esac
9465 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
9466 as_fn_append ac_file_inputs " '$ac_f'"
9467 done
9468
9469 # Let's still pretend it is `configure' which instantiates (i.e., don't
9470 # use $as_me), people would be surprised to read:
9471 # /* config.h. Generated by config.status. */
9472 configure_input='Generated from '`
9473 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
9474 `' by configure.'
9475 if test x"$ac_file" != x-; then
9476 configure_input="$ac_file. $configure_input"
9477 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
9478$as_echo "$as_me: creating $ac_file" >&6;}
9479 fi
9480 # Neutralize special characters interpreted by sed in replacement strings.
9481 case $configure_input in #(
9482 *\&* | *\|* | *\\* )
9483 ac_sed_conf_input=`$as_echo "$configure_input" |
9484 sed 's/[\\\\&|]/\\\\&/g'`;; #(
9485 *) ac_sed_conf_input=$configure_input;;
9486 esac
9487
9488 case $ac_tag in
9489 *:-:* | *:-) cat >"$ac_tmp/stdin" \
9490 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
9491 esac
9492 ;;
9493 esac
9494
9495 ac_dir=`$as_dirname -- "$ac_file" ||
9496$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
9497 X"$ac_file" : 'X\(//\)[^/]' \| \
9498 X"$ac_file" : 'X\(//\)$' \| \
9499 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
9500$as_echo X"$ac_file" |
9501 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
9502 s//\1/
9503 q
9504 }
9505 /^X\(\/\/\)[^/].*/{
9506 s//\1/
9507 q
9508 }
9509 /^X\(\/\/\)$/{
9510 s//\1/
9511 q
9512 }
9513 /^X\(\/\).*/{
9514 s//\1/
9515 q
9516 }
9517 s/.*/./; q'`
9518 as_dir="$ac_dir"; as_fn_mkdir_p
9519 ac_builddir=.
9520
9521case "$ac_dir" in
9522.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
9523*)
9524 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
9525 # A ".." for each directory in $ac_dir_suffix.
9526 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
9527 case $ac_top_builddir_sub in
9528 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
9529 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
9530 esac ;;
9531esac
9532ac_abs_top_builddir=$ac_pwd
9533ac_abs_builddir=$ac_pwd$ac_dir_suffix
9534# for backward compatibility:
9535ac_top_builddir=$ac_top_build_prefix
9536
9537case $srcdir in
9538 .) # We are building in place.
9539 ac_srcdir=.
9540 ac_top_srcdir=$ac_top_builddir_sub
9541 ac_abs_top_srcdir=$ac_pwd ;;
9542 [\\/]* | ?:[\\/]* ) # Absolute name.
9543 ac_srcdir=$srcdir$ac_dir_suffix;
9544 ac_top_srcdir=$srcdir
9545 ac_abs_top_srcdir=$srcdir ;;
9546 *) # Relative name.
9547 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
9548 ac_top_srcdir=$ac_top_build_prefix$srcdir
9549 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
9550esac
9551ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
9552
9553
9554 case $ac_mode in
9555 :F)
9556 #
9557 # CONFIG_FILE
9558 #
9559
9560 case $INSTALL in
9561 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
9562 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
9563 esac
9564_ACEOF
9565
9566cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9567# If the template does not know about datarootdir, expand it.
9568# FIXME: This hack should be removed a few years after 2.60.
9569ac_datarootdir_hack=; ac_datarootdir_seen=
9570ac_sed_dataroot='
9571/datarootdir/ {
9572 p
9573 q
9574}
9575/@datadir@/p
9576/@docdir@/p
9577/@infodir@/p
9578/@localedir@/p
9579/@mandir@/p'
9580case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
9581*datarootdir*) ac_datarootdir_seen=yes;;
9582*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
9583 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
9584$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
9585_ACEOF
9586cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9587 ac_datarootdir_hack='
9588 s&@datadir@&$datadir&g
9589 s&@docdir@&$docdir&g
9590 s&@infodir@&$infodir&g
9591 s&@localedir@&$localedir&g
9592 s&@mandir@&$mandir&g
9593 s&\\\${datarootdir}&$datarootdir&g' ;;
9594esac
9595_ACEOF
9596
9597# Neutralize VPATH when `$srcdir' = `.'.
9598# Shell code in configure.ac might set extrasub.
9599# FIXME: do we really want to maintain this feature?
9600cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9601ac_sed_extra="$ac_vpsub
9602$extrasub
9603_ACEOF
9604cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9605:t
9606/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
9607s|@configure_input@|$ac_sed_conf_input|;t t
9608s&@top_builddir@&$ac_top_builddir_sub&;t t
9609s&@top_build_prefix@&$ac_top_build_prefix&;t t
9610s&@srcdir@&$ac_srcdir&;t t
9611s&@abs_srcdir@&$ac_abs_srcdir&;t t
9612s&@top_srcdir@&$ac_top_srcdir&;t t
9613s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
9614s&@builddir@&$ac_builddir&;t t
9615s&@abs_builddir@&$ac_abs_builddir&;t t
9616s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
9617s&@INSTALL@&$ac_INSTALL&;t t
9618$ac_datarootdir_hack
9619"
9620eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
9621 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
9622
9623test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
9624 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
9625 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
9626 "$ac_tmp/out"`; test -z "$ac_out"; } &&
9627 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
9628which seems to be undefined. Please make sure it is defined" >&5
9629$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
9630which seems to be undefined. Please make sure it is defined" >&2;}
9631
9632 rm -f "$ac_tmp/stdin"
9633 case $ac_file in
9634 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
9635 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
9636 esac \
9637 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
9638 ;;
9639 :H)
9640 #
9641 # CONFIG_HEADER
9642 #
9643 if test x"$ac_file" != x-; then
9644 {
9645 $as_echo "/* $configure_input */" \
9646 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
9647 } >"$ac_tmp/config.h" \
9648 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
9649 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
9650 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
9651$as_echo "$as_me: $ac_file is unchanged" >&6;}
9652 else
9653 rm -f "$ac_file"
9654 mv "$ac_tmp/config.h" "$ac_file" \
9655 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
9656 fi
9657 else
9658 $as_echo "/* $configure_input */" \
9659 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
9660 || as_fn_error $? "could not create -" "$LINENO" 5
9661 fi
9662 ;;
9663
9664 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
9665$as_echo "$as_me: executing $ac_file commands" >&6;}
9666 ;;
9667 esac
9668
9669
9670 case $ac_file$ac_mode in
1a4d82fc
JJ
9671 "include/jemalloc/internal/private_namespace.h":C)
9672 mkdir -p "${objroot}include/jemalloc/internal"
9673 "${srcdir}/include/jemalloc/internal/private_namespace.sh" "${srcdir}/include/jemalloc/internal/private_symbols.txt" > "${objroot}include/jemalloc/internal/private_namespace.h"
9674 ;;
9675 "include/jemalloc/internal/private_unnamespace.h":C)
9676 mkdir -p "${objroot}include/jemalloc/internal"
9677 "${srcdir}/include/jemalloc/internal/private_unnamespace.sh" "${srcdir}/include/jemalloc/internal/private_symbols.txt" > "${objroot}include/jemalloc/internal/private_unnamespace.h"
9678 ;;
9679 "include/jemalloc/internal/public_symbols.txt":C)
9680 f="${objroot}include/jemalloc/internal/public_symbols.txt"
9681 mkdir -p "${objroot}include/jemalloc/internal"
9682 cp /dev/null "${f}"
9683 for nm in `echo ${mangling_map} |tr ',' ' '` ; do
9684 n=`echo ${nm} |tr ':' ' ' |awk '{print $1}'`
9685 m=`echo ${nm} |tr ':' ' ' |awk '{print $2}'`
9686 echo "${n}:${m}" >> "${f}"
9687 public_syms=`for sym in ${public_syms}; do echo "${sym}"; done |grep -v "^${n}\$" |tr '\n' ' '`
9688 done
9689 for sym in ${public_syms} ; do
9690 n="${sym}"
9691 m="${JEMALLOC_PREFIX}${sym}"
9692 echo "${n}:${m}" >> "${f}"
9693 done
9694 ;;
9695 "include/jemalloc/internal/public_namespace.h":C)
9696 mkdir -p "${objroot}include/jemalloc/internal"
9697 "${srcdir}/include/jemalloc/internal/public_namespace.sh" "${objroot}include/jemalloc/internal/public_symbols.txt" > "${objroot}include/jemalloc/internal/public_namespace.h"
9698 ;;
9699 "include/jemalloc/internal/public_unnamespace.h":C)
9700 mkdir -p "${objroot}include/jemalloc/internal"
9701 "${srcdir}/include/jemalloc/internal/public_unnamespace.sh" "${objroot}include/jemalloc/internal/public_symbols.txt" > "${objroot}include/jemalloc/internal/public_unnamespace.h"
9702 ;;
970d7e83 9703 "include/jemalloc/internal/size_classes.h":C)
1a4d82fc 9704 mkdir -p "${objroot}include/jemalloc/internal"
54a0048b 9705 "${SHELL}" "${srcdir}/include/jemalloc/internal/size_classes.sh" "${LG_QUANTA}" ${LG_TINY_MIN} "${LG_PAGE_SIZES}" ${LG_SIZE_CLASS_GROUP} > "${objroot}include/jemalloc/internal/size_classes.h"
970d7e83 9706 ;;
1a4d82fc
JJ
9707 "include/jemalloc/jemalloc_protos_jet.h":C)
9708 mkdir -p "${objroot}include/jemalloc"
9709 cat "${srcdir}/include/jemalloc/jemalloc_protos.h.in" | sed -e 's/@je_@/jet_/g' > "${objroot}include/jemalloc/jemalloc_protos_jet.h"
9710 ;;
9711 "include/jemalloc/jemalloc_rename.h":C)
9712 mkdir -p "${objroot}include/jemalloc"
9713 "${srcdir}/include/jemalloc/jemalloc_rename.sh" "${objroot}include/jemalloc/internal/public_symbols.txt" > "${objroot}include/jemalloc/jemalloc_rename.h"
9714 ;;
9715 "include/jemalloc/jemalloc_mangle.h":C)
9716 mkdir -p "${objroot}include/jemalloc"
9717 "${srcdir}/include/jemalloc/jemalloc_mangle.sh" "${objroot}include/jemalloc/internal/public_symbols.txt" je_ > "${objroot}include/jemalloc/jemalloc_mangle.h"
9718 ;;
9719 "include/jemalloc/jemalloc_mangle_jet.h":C)
9720 mkdir -p "${objroot}include/jemalloc"
9721 "${srcdir}/include/jemalloc/jemalloc_mangle.sh" "${objroot}include/jemalloc/internal/public_symbols.txt" jet_ > "${objroot}include/jemalloc/jemalloc_mangle_jet.h"
9722 ;;
9723 "include/jemalloc/jemalloc.h":C)
9724 mkdir -p "${objroot}include/jemalloc"
9725 "${srcdir}/include/jemalloc/jemalloc.sh" "${objroot}" > "${objroot}include/jemalloc/jemalloc${install_suffix}.h"
9726 ;;
970d7e83
LB
9727
9728 esac
9729done # for ac_tag
9730
9731
9732as_fn_exit 0
9733_ACEOF
9734ac_clean_files=$ac_clean_files_save
9735
9736test $ac_write_fail = 0 ||
9737 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
9738
9739
9740# configure is writing to config.log, and then calls config.status.
9741# config.status does its own redirection, appending to config.log.
9742# Unfortunately, on DOS this fails, as config.log is still kept open
9743# by configure, so config.status won't be able to write to it; its
9744# output is simply discarded. So we exec the FD to /dev/null,
9745# effectively closing config.log, so it can be properly (re)opened and
9746# appended to by config.status. When coming back to configure, we
9747# need to make the FD available again.
9748if test "$no_create" != yes; then
9749 ac_cs_success=:
9750 ac_config_status_args=
9751 test "$silent" = yes &&
9752 ac_config_status_args="$ac_config_status_args --quiet"
9753 exec 5>/dev/null
9754 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
9755 exec 5>>config.log
9756 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
9757 # would make configure fail if this is the last instruction.
9758 $ac_cs_success || as_fn_exit 1
9759fi
9760if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
9761 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
9762$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
9763fi
9764
9765
9766{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ===============================================================================" >&5
9767$as_echo "===============================================================================" >&6; }
9768{ $as_echo "$as_me:${as_lineno-$LINENO}: result: jemalloc version : ${jemalloc_version}" >&5
9769$as_echo "jemalloc version : ${jemalloc_version}" >&6; }
9770{ $as_echo "$as_me:${as_lineno-$LINENO}: result: library revision : ${rev}" >&5
9771$as_echo "library revision : ${rev}" >&6; }
9772{ $as_echo "$as_me:${as_lineno-$LINENO}: result: " >&5
9773$as_echo "" >&6; }
54a0048b
SL
9774{ $as_echo "$as_me:${as_lineno-$LINENO}: result: CONFIG : ${CONFIG}" >&5
9775$as_echo "CONFIG : ${CONFIG}" >&6; }
970d7e83
LB
9776{ $as_echo "$as_me:${as_lineno-$LINENO}: result: CC : ${CC}" >&5
9777$as_echo "CC : ${CC}" >&6; }
7453a54e
SL
9778{ $as_echo "$as_me:${as_lineno-$LINENO}: result: CFLAGS : ${CFLAGS}" >&5
9779$as_echo "CFLAGS : ${CFLAGS}" >&6; }
54a0048b
SL
9780{ $as_echo "$as_me:${as_lineno-$LINENO}: result: CPPFLAGS : ${CPPFLAGS}" >&5
9781$as_echo "CPPFLAGS : ${CPPFLAGS}" >&6; }
970d7e83
LB
9782{ $as_echo "$as_me:${as_lineno-$LINENO}: result: LDFLAGS : ${LDFLAGS}" >&5
9783$as_echo "LDFLAGS : ${LDFLAGS}" >&6; }
1a4d82fc
JJ
9784{ $as_echo "$as_me:${as_lineno-$LINENO}: result: EXTRA_LDFLAGS : ${EXTRA_LDFLAGS}" >&5
9785$as_echo "EXTRA_LDFLAGS : ${EXTRA_LDFLAGS}" >&6; }
970d7e83
LB
9786{ $as_echo "$as_me:${as_lineno-$LINENO}: result: LIBS : ${LIBS}" >&5
9787$as_echo "LIBS : ${LIBS}" >&6; }
54a0048b
SL
9788{ $as_echo "$as_me:${as_lineno-$LINENO}: result: TESTLIBS : ${TESTLIBS}" >&5
9789$as_echo "TESTLIBS : ${TESTLIBS}" >&6; }
970d7e83
LB
9790{ $as_echo "$as_me:${as_lineno-$LINENO}: result: RPATH_EXTRA : ${RPATH_EXTRA}" >&5
9791$as_echo "RPATH_EXTRA : ${RPATH_EXTRA}" >&6; }
9792{ $as_echo "$as_me:${as_lineno-$LINENO}: result: " >&5
9793$as_echo "" >&6; }
9794{ $as_echo "$as_me:${as_lineno-$LINENO}: result: XSLTPROC : ${XSLTPROC}" >&5
9795$as_echo "XSLTPROC : ${XSLTPROC}" >&6; }
9796{ $as_echo "$as_me:${as_lineno-$LINENO}: result: XSLROOT : ${XSLROOT}" >&5
9797$as_echo "XSLROOT : ${XSLROOT}" >&6; }
9798{ $as_echo "$as_me:${as_lineno-$LINENO}: result: " >&5
9799$as_echo "" >&6; }
9800{ $as_echo "$as_me:${as_lineno-$LINENO}: result: PREFIX : ${PREFIX}" >&5
9801$as_echo "PREFIX : ${PREFIX}" >&6; }
9802{ $as_echo "$as_me:${as_lineno-$LINENO}: result: BINDIR : ${BINDIR}" >&5
9803$as_echo "BINDIR : ${BINDIR}" >&6; }
54a0048b
SL
9804{ $as_echo "$as_me:${as_lineno-$LINENO}: result: DATADIR : ${DATADIR}" >&5
9805$as_echo "DATADIR : ${DATADIR}" >&6; }
970d7e83
LB
9806{ $as_echo "$as_me:${as_lineno-$LINENO}: result: INCLUDEDIR : ${INCLUDEDIR}" >&5
9807$as_echo "INCLUDEDIR : ${INCLUDEDIR}" >&6; }
9808{ $as_echo "$as_me:${as_lineno-$LINENO}: result: LIBDIR : ${LIBDIR}" >&5
9809$as_echo "LIBDIR : ${LIBDIR}" >&6; }
970d7e83
LB
9810{ $as_echo "$as_me:${as_lineno-$LINENO}: result: MANDIR : ${MANDIR}" >&5
9811$as_echo "MANDIR : ${MANDIR}" >&6; }
9812{ $as_echo "$as_me:${as_lineno-$LINENO}: result: " >&5
9813$as_echo "" >&6; }
9814{ $as_echo "$as_me:${as_lineno-$LINENO}: result: srcroot : ${srcroot}" >&5
9815$as_echo "srcroot : ${srcroot}" >&6; }
9816{ $as_echo "$as_me:${as_lineno-$LINENO}: result: abs_srcroot : ${abs_srcroot}" >&5
9817$as_echo "abs_srcroot : ${abs_srcroot}" >&6; }
9818{ $as_echo "$as_me:${as_lineno-$LINENO}: result: objroot : ${objroot}" >&5
9819$as_echo "objroot : ${objroot}" >&6; }
9820{ $as_echo "$as_me:${as_lineno-$LINENO}: result: abs_objroot : ${abs_objroot}" >&5
9821$as_echo "abs_objroot : ${abs_objroot}" >&6; }
9822{ $as_echo "$as_me:${as_lineno-$LINENO}: result: " >&5
9823$as_echo "" >&6; }
9824{ $as_echo "$as_me:${as_lineno-$LINENO}: result: JEMALLOC_PREFIX : ${JEMALLOC_PREFIX}" >&5
9825$as_echo "JEMALLOC_PREFIX : ${JEMALLOC_PREFIX}" >&6; }
9826{ $as_echo "$as_me:${as_lineno-$LINENO}: result: JEMALLOC_PRIVATE_NAMESPACE" >&5
9827$as_echo "JEMALLOC_PRIVATE_NAMESPACE" >&6; }
9828{ $as_echo "$as_me:${as_lineno-$LINENO}: result: : ${JEMALLOC_PRIVATE_NAMESPACE}" >&5
9829$as_echo " : ${JEMALLOC_PRIVATE_NAMESPACE}" >&6; }
9830{ $as_echo "$as_me:${as_lineno-$LINENO}: result: install_suffix : ${install_suffix}" >&5
9831$as_echo "install_suffix : ${install_suffix}" >&6; }
54a0048b
SL
9832{ $as_echo "$as_me:${as_lineno-$LINENO}: result: malloc_conf : ${config_malloc_conf}" >&5
9833$as_echo "malloc_conf : ${config_malloc_conf}" >&6; }
970d7e83
LB
9834{ $as_echo "$as_me:${as_lineno-$LINENO}: result: autogen : ${enable_autogen}" >&5
9835$as_echo "autogen : ${enable_autogen}" >&6; }
970d7e83
LB
9836{ $as_echo "$as_me:${as_lineno-$LINENO}: result: cc-silence : ${enable_cc_silence}" >&5
9837$as_echo "cc-silence : ${enable_cc_silence}" >&6; }
9838{ $as_echo "$as_me:${as_lineno-$LINENO}: result: debug : ${enable_debug}" >&5
9839$as_echo "debug : ${enable_debug}" >&6; }
1a4d82fc
JJ
9840{ $as_echo "$as_me:${as_lineno-$LINENO}: result: code-coverage : ${enable_code_coverage}" >&5
9841$as_echo "code-coverage : ${enable_code_coverage}" >&6; }
970d7e83
LB
9842{ $as_echo "$as_me:${as_lineno-$LINENO}: result: stats : ${enable_stats}" >&5
9843$as_echo "stats : ${enable_stats}" >&6; }
9844{ $as_echo "$as_me:${as_lineno-$LINENO}: result: prof : ${enable_prof}" >&5
9845$as_echo "prof : ${enable_prof}" >&6; }
9846{ $as_echo "$as_me:${as_lineno-$LINENO}: result: prof-libunwind : ${enable_prof_libunwind}" >&5
9847$as_echo "prof-libunwind : ${enable_prof_libunwind}" >&6; }
9848{ $as_echo "$as_me:${as_lineno-$LINENO}: result: prof-libgcc : ${enable_prof_libgcc}" >&5
9849$as_echo "prof-libgcc : ${enable_prof_libgcc}" >&6; }
9850{ $as_echo "$as_me:${as_lineno-$LINENO}: result: prof-gcc : ${enable_prof_gcc}" >&5
9851$as_echo "prof-gcc : ${enable_prof_gcc}" >&6; }
9852{ $as_echo "$as_me:${as_lineno-$LINENO}: result: tcache : ${enable_tcache}" >&5
9853$as_echo "tcache : ${enable_tcache}" >&6; }
9854{ $as_echo "$as_me:${as_lineno-$LINENO}: result: fill : ${enable_fill}" >&5
9855$as_echo "fill : ${enable_fill}" >&6; }
9856{ $as_echo "$as_me:${as_lineno-$LINENO}: result: utrace : ${enable_utrace}" >&5
9857$as_echo "utrace : ${enable_utrace}" >&6; }
9858{ $as_echo "$as_me:${as_lineno-$LINENO}: result: valgrind : ${enable_valgrind}" >&5
9859$as_echo "valgrind : ${enable_valgrind}" >&6; }
9860{ $as_echo "$as_me:${as_lineno-$LINENO}: result: xmalloc : ${enable_xmalloc}" >&5
9861$as_echo "xmalloc : ${enable_xmalloc}" >&6; }
970d7e83
LB
9862{ $as_echo "$as_me:${as_lineno-$LINENO}: result: munmap : ${enable_munmap}" >&5
9863$as_echo "munmap : ${enable_munmap}" >&6; }
970d7e83
LB
9864{ $as_echo "$as_me:${as_lineno-$LINENO}: result: lazy_lock : ${enable_lazy_lock}" >&5
9865$as_echo "lazy_lock : ${enable_lazy_lock}" >&6; }
9866{ $as_echo "$as_me:${as_lineno-$LINENO}: result: tls : ${enable_tls}" >&5
9867$as_echo "tls : ${enable_tls}" >&6; }
54a0048b
SL
9868{ $as_echo "$as_me:${as_lineno-$LINENO}: result: cache-oblivious : ${enable_cache_oblivious}" >&5
9869$as_echo "cache-oblivious : ${enable_cache_oblivious}" >&6; }
970d7e83
LB
9870{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ===============================================================================" >&5
9871$as_echo "===============================================================================" >&6; }