2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.69 for PostgreSQL 12devel.
5 # Report bugs to <pgsql-bugs@lists.postgresql.org>.
8 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
11 # This configure script is free software; the Free Software Foundation
12 # gives unlimited permission to copy, distribute and modify it.
14 # Copyright (c) 1996-2019, PostgreSQL Global Development Group
15 ## -------------------- ##
16 ## M4sh Initialization. ##
17 ## -------------------- ##
19 # Be more Bourne compatible
20 DUALCASE=1; export DUALCASE # for MKS sh
21 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
24 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
25 # is contrary to our usage. Disable this feature.
26 alias -g '${1+"$@"}'='"$@"'
29 case `(set -o) 2>/dev/null` in #(
41 # Printing a long string crashes Solaris 7 /usr/bin/printf.
42 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
43 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
44 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
45 # Prefer a ksh shell builtin over an external printf program on Solaris,
46 # but without wasting forks for bash or zsh.
47 if test -z "$BASH_VERSION$ZSH_VERSION" \
48 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
50 as_echo_n='print -rn --'
51 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
55 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
56 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
57 as_echo_n='/usr/ucb/echo -n'
59 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
64 expr "X$arg" : "X\\(.*\\)$as_nl";
65 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
67 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
70 as_echo_n='sh -c $as_echo_n_body as_echo'
73 as_echo='sh -c $as_echo_body as_echo'
76 # The user is always right.
77 if test "${PATH_SEPARATOR+set}" != set; then
79 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
80 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
87 # We need space, tab and new line, in precisely that order. Quoting is
88 # there to prevent editors from complaining about space-tab.
89 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
90 # splitting by setting IFS to empty value.)
93 # Find who we are. Look in the path if we contain no directory separator.
96 *[\\/]* ) as_myself=$0 ;;
97 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
101 test -z "$as_dir" && as_dir=.
102 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
108 # We did not find ourselves, most probably we were run as `sh COMMAND'
109 # in which case we are not to be found in the path.
110 if test "x$as_myself" = x; then
113 if test ! -f "$as_myself"; then
114 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
118 # Unset variables that we do not need and which cause bugs (e.g. in
119 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
120 # suppresses any "Segmentation fault" message there. '((' could
121 # trigger a bug in pdksh 5.2.14.
122 for as_var in BASH_ENV ENV MAIL MAILPATH
123 do eval test x\${$as_var+set} = xset \
124 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
137 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
139 # Use a proper internal environment variable to ensure we don't fall
140 # into an infinite loop, continuously re-executing ourselves.
141 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
142 _as_can_reexec=no; export _as_can_reexec;
143 # We cannot yet assume a decent shell, so we have to provide a
144 # neutralization value for shells without unset; and this also
145 # works around shells that cannot unset nonexistent variables.
146 # Preserve -v and -x to the replacement shell.
149 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
151 *v*x* | *x*v* ) as_opts=-vx ;;
156 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
157 # Admittedly, this is quite paranoid, since all the known shells bail
158 # out after a failed `exec'.
159 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
162 # We don't want this to propagate to other subprocesses.
163 { _as_can_reexec=; unset _as_can_reexec;}
164 if test "x$CONFIG_SHELL" = x; then
165 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
168 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
169 # is contrary to our usage. Disable this feature.
170 alias -g '\${1+\"\$@\"}'='\"\$@\"'
173 case \`(set -o) 2>/dev/null\` in #(
181 as_required="as_fn_return () { (exit \$1); }
182 as_fn_success () { as_fn_return 0; }
183 as_fn_failure () { as_fn_return 1; }
184 as_fn_ret_success () { return 0; }
185 as_fn_ret_failure () { return 1; }
188 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
189 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
190 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
191 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
192 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
195 exitcode=1; echo positional parameters were not saved.
197 test x\$exitcode = x0 || exit 1
199 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
200 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
201 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
202 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
203 test \$(( 1 + 1 )) = 2 || exit 1"
204 if (eval "$as_required") 2>/dev/null; then :
209 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
212 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
214 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
217 test -z "$as_dir" && as_dir=.
221 for as_base in sh bash ksh sh5; do
222 # Try only shells that exist, to save several forks.
223 as_shell=$as_dir/$as_base
224 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
225 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
226 CONFIG_SHELL=$as_shell as_have_required=yes
227 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
235 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
236 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
237 CONFIG_SHELL=$SHELL as_have_required=yes
242 if test "x$CONFIG_SHELL" != x; then :
244 # We cannot yet assume a decent shell, so we have to provide a
245 # neutralization value for shells without unset; and this also
246 # works around shells that cannot unset nonexistent variables.
247 # Preserve -v and -x to the replacement shell.
250 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
252 *v*x* | *x*v* ) as_opts=-vx ;;
257 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
258 # Admittedly, this is quite paranoid, since all the known shells bail
259 # out after a failed `exec'.
260 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
264 if test x$as_have_required = xno; then :
265 $as_echo "$0: This script requires a shell more modern than all"
266 $as_echo "$0: the shells that I found on your system."
267 if test x${ZSH_VERSION+set} = xset ; then
268 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
269 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
271 $as_echo "$0: Please tell bug-autoconf@gnu.org and
272 $0: pgsql-bugs@lists.postgresql.org about your system,
273 $0: including any error possibly output before this
274 $0: message. Then install a modern shell, or manually run
275 $0: the script under such a shell if you do have one."
281 SHELL=${CONFIG_SHELL-/bin/sh}
283 # Unset more variables known to interfere with behavior of common tools.
284 CLICOLOR_FORCE= GREP_OPTIONS=
285 unset CLICOLOR_FORCE GREP_OPTIONS
287 ## --------------------- ##
288 ## M4sh Shell Functions. ##
289 ## --------------------- ##
292 # Portably unset VAR.
295 { eval $1=; unset $1;}
299 # as_fn_set_status STATUS
300 # -----------------------
301 # Set $? to STATUS, without forking.
309 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
319 # Create "$as_dir" as a directory, including parents if necessary.
324 -*) as_dir=./$as_dir;;
326 test -d "$as_dir" || eval $as_mkdir_p || {
330 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
333 as_dirs="'$as_qdir' $as_dirs"
334 as_dir=`$as_dirname -- "$as_dir" ||
335 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
336 X"$as_dir" : 'X\(//\)[^/]' \| \
337 X"$as_dir" : 'X\(//\)$' \| \
338 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
339 $as_echo X"$as_dir" |
340 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
357 test -d "$as_dir" && break
359 test -z "$as_dirs" || eval "mkdir $as_dirs"
360 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
365 # as_fn_executable_p FILE
366 # -----------------------
367 # Test if FILE is an executable regular file.
368 as_fn_executable_p ()
370 test -f "$1" && test -x "$1"
371 } # as_fn_executable_p
372 # as_fn_append VAR VALUE
373 # ----------------------
374 # Append the text in VALUE to the end of the definition contained in VAR. Take
375 # advantage of any shell optimizations that allow amortized linear growth over
376 # repeated appends, instead of the typical quadratic growth present in naive
378 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
379 eval 'as_fn_append ()
392 # Perform arithmetic evaluation on the ARGs, and store the result in the
393 # global $as_val. Take advantage of shells that can avoid forks. The arguments
394 # must be portable across $(()) and expr.
395 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
403 as_val=`expr "$@" || test $? -eq 1`
408 # as_fn_error STATUS ERROR [LINENO LOG_FD]
409 # ----------------------------------------
410 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
411 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
412 # script with STATUS, using 1 if that was 0.
415 as_status=$1; test $as_status -eq 0 && as_status=1
417 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
418 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
420 $as_echo "$as_me: error: $2" >&2
421 as_fn_exit $as_status
424 if expr a : '\(a\)' >/dev/null 2>&1 &&
425 test "X`expr 00001 : '.*\(...\)'`" = X001; then
431 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
437 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
443 as_me=`$as_basename -- "$0" ||
444 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
445 X"$0" : 'X\(//\)$' \| \
446 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
448 sed '/^.*\/\([^/][^/]*\)\/*$/{
462 # Avoid depending upon Character Ranges.
463 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
464 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
465 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
466 as_cr_digits='0123456789'
467 as_cr_alnum=$as_cr_Letters$as_cr_digits
470 as_lineno_1=$LINENO as_lineno_1a=$LINENO
471 as_lineno_2=$LINENO as_lineno_2a=$LINENO
472 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
473 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
474 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
486 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
490 chmod +x "$as_me.lineno" ||
491 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
493 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
494 # already done that, so ensure we don't try to do so again and fall
495 # in an infinite loop. This has already happened in practice.
496 _as_can_reexec=no; export _as_can_reexec
497 # Don't try to exec as it changes $[0], causing all sort of problems
498 # (the dirname of $[0] is not the place where we might find the
499 # original and so on. Autoconf is especially sensitive to this).
501 # Exit status is that of the last command.
505 ECHO_C= ECHO_N= ECHO_T=
506 case `echo -n x` in #(((((
508 case `echo 'xy\c'` in
509 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
511 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
518 rm -f conf$$ conf$$.exe conf$$.file
519 if test -d conf$$.dir; then
520 rm -f conf$$.dir/conf$$.file
523 mkdir conf$$.dir 2>/dev/null
525 if (echo >conf$$.file) 2>/dev/null; then
526 if ln -s conf$$.file conf$$ 2>/dev/null; then
528 # ... but there are two gotchas:
529 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
530 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
531 # In both cases, we have to default to `cp -pR'.
532 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
534 elif ln conf$$.file conf$$ 2>/dev/null; then
542 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
543 rmdir conf$$.dir 2>/dev/null
545 if mkdir -p . 2>/dev/null; then
546 as_mkdir_p='mkdir -p "$as_dir"'
548 test -d ./-p && rmdir ./-p
553 as_executable_p=as_fn_executable_p
555 # Sed expression to map a string onto a valid CPP name.
556 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
558 # Sed expression to map a string onto a valid variable name.
559 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
562 test -n "$DJDIR" || exec 7<&0 </dev/null
566 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
567 # so uname gets run too.
568 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
573 ac_default_prefix=/usr/local
575 ac_config_libobj_dir=.
582 # Identity of this package.
583 PACKAGE_NAME='PostgreSQL'
584 PACKAGE_TARNAME='postgresql'
585 PACKAGE_VERSION='12devel'
586 PACKAGE_STRING='PostgreSQL 12devel'
587 PACKAGE_BUGREPORT='pgsql-bugs@lists.postgresql.org'
590 ac_unique_file="src/backend/access/common/heaptuple.c"
591 ac_default_prefix=/usr/local/pgsql
592 # Factoring default headers for most tests.
593 ac_includes_default="\
595 #ifdef HAVE_SYS_TYPES_H
596 # include <sys/types.h>
598 #ifdef HAVE_SYS_STAT_H
599 # include <sys/stat.h>
605 # ifdef HAVE_STDLIB_H
610 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
615 #ifdef HAVE_STRINGS_H
616 # include <strings.h>
618 #ifdef HAVE_INTTYPES_H
619 # include <inttypes.h>
628 ac_subst_vars='LTLIBOBJS
664 python_additional_libs
736 PERMIT_DECLARATION_AFTER_STATEMENT
808 program_transform_name
821 enable_option_checking
827 enable_integer_datetimes
861 with_libedit_preferred
873 ac_precious_vars='build_alias
901 # Initialize some variables set by options.
903 ac_init_version=false
904 ac_unrecognized_opts=
906 # The variables have the same names as the options, with
907 # dashes changed to underlines.
915 program_transform_name=s,x,x,
923 # Installation directory options.
924 # These are left unexpanded so users can "make install exec_prefix=/foo"
925 # and all the variables that are supposed to be based on exec_prefix
926 # by default will actually change.
927 # Use braces instead of parens because sh, perl, etc. also accept them.
928 # (The list follows the same order as the GNU Coding Standards.)
929 bindir='${exec_prefix}/bin'
930 sbindir='${exec_prefix}/sbin'
931 libexecdir='${exec_prefix}/libexec'
932 datarootdir='${prefix}/share'
933 datadir='${datarootdir}'
934 sysconfdir='${prefix}/etc'
935 sharedstatedir='${prefix}/com'
936 localstatedir='${prefix}/var'
937 includedir='${prefix}/include'
938 oldincludedir='/usr/include'
939 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
940 infodir='${datarootdir}/info'
945 libdir='${exec_prefix}/lib'
946 localedir='${datarootdir}/locale'
947 mandir='${datarootdir}/man'
953 # If the previous option needs an argument, assign it.
954 if test -n "$ac_prev"; then
955 eval $ac_prev=\$ac_option
961 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
966 # Accept the important Cygnus configure options, so we can diagnose typos.
968 case $ac_dashdash$ac_option in
972 -bindir | --bindir | --bindi | --bind | --bin | --bi)
974 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
977 -build | --build | --buil | --bui | --bu)
978 ac_prev=build_alias ;;
979 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
980 build_alias=$ac_optarg ;;
982 -cache-file | --cache-file | --cache-fil | --cache-fi \
983 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
984 ac_prev=cache_file ;;
985 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
986 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
987 cache_file=$ac_optarg ;;
990 cache_file=config.cache ;;
992 -datadir | --datadir | --datadi | --datad)
994 -datadir=* | --datadir=* | --datadi=* | --datad=*)
995 datadir=$ac_optarg ;;
997 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
998 | --dataroo | --dataro | --datar)
999 ac_prev=datarootdir ;;
1000 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1001 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1002 datarootdir=$ac_optarg ;;
1004 -disable-* | --disable-*)
1005 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1006 # Reject names that are not valid shell variable names.
1007 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1008 as_fn_error $? "invalid feature name: $ac_useropt"
1009 ac_useropt_orig=$ac_useropt
1010 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1011 case $ac_user_opts in
1013 "enable_$ac_useropt"
1015 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1016 ac_unrecognized_sep=', ';;
1018 eval enable_$ac_useropt=no ;;
1020 -docdir | --docdir | --docdi | --doc | --do)
1022 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1023 docdir=$ac_optarg ;;
1025 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1027 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1028 dvidir=$ac_optarg ;;
1030 -enable-* | --enable-*)
1031 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1032 # Reject names that are not valid shell variable names.
1033 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1034 as_fn_error $? "invalid feature name: $ac_useropt"
1035 ac_useropt_orig=$ac_useropt
1036 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1037 case $ac_user_opts in
1039 "enable_$ac_useropt"
1041 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1042 ac_unrecognized_sep=', ';;
1044 eval enable_$ac_useropt=\$ac_optarg ;;
1046 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1047 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1048 | --exec | --exe | --ex)
1049 ac_prev=exec_prefix ;;
1050 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1051 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1052 | --exec=* | --exe=* | --ex=*)
1053 exec_prefix=$ac_optarg ;;
1055 -gas | --gas | --ga | --g)
1056 # Obsolete; use --with-gas.
1059 -help | --help | --hel | --he | -h)
1060 ac_init_help=long ;;
1061 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1062 ac_init_help=recursive ;;
1063 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1064 ac_init_help=short ;;
1066 -host | --host | --hos | --ho)
1067 ac_prev=host_alias ;;
1068 -host=* | --host=* | --hos=* | --ho=*)
1069 host_alias=$ac_optarg ;;
1071 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1073 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1075 htmldir=$ac_optarg ;;
1077 -includedir | --includedir | --includedi | --included | --include \
1078 | --includ | --inclu | --incl | --inc)
1079 ac_prev=includedir ;;
1080 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1081 | --includ=* | --inclu=* | --incl=* | --inc=*)
1082 includedir=$ac_optarg ;;
1084 -infodir | --infodir | --infodi | --infod | --info | --inf)
1086 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1087 infodir=$ac_optarg ;;
1089 -libdir | --libdir | --libdi | --libd)
1091 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1092 libdir=$ac_optarg ;;
1094 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1095 | --libexe | --libex | --libe)
1096 ac_prev=libexecdir ;;
1097 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1098 | --libexe=* | --libex=* | --libe=*)
1099 libexecdir=$ac_optarg ;;
1101 -localedir | --localedir | --localedi | --localed | --locale)
1102 ac_prev=localedir ;;
1103 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1104 localedir=$ac_optarg ;;
1106 -localstatedir | --localstatedir | --localstatedi | --localstated \
1107 | --localstate | --localstat | --localsta | --localst | --locals)
1108 ac_prev=localstatedir ;;
1109 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1110 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1111 localstatedir=$ac_optarg ;;
1113 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1115 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1116 mandir=$ac_optarg ;;
1118 -nfp | --nfp | --nf)
1119 # Obsolete; use --without-fp.
1122 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1123 | --no-cr | --no-c | -n)
1126 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1127 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1130 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1131 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1132 | --oldin | --oldi | --old | --ol | --o)
1133 ac_prev=oldincludedir ;;
1134 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1135 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1136 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1137 oldincludedir=$ac_optarg ;;
1139 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1141 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1142 prefix=$ac_optarg ;;
1144 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1145 | --program-pre | --program-pr | --program-p)
1146 ac_prev=program_prefix ;;
1147 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1148 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1149 program_prefix=$ac_optarg ;;
1151 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1152 | --program-suf | --program-su | --program-s)
1153 ac_prev=program_suffix ;;
1154 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1155 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1156 program_suffix=$ac_optarg ;;
1158 -program-transform-name | --program-transform-name \
1159 | --program-transform-nam | --program-transform-na \
1160 | --program-transform-n | --program-transform- \
1161 | --program-transform | --program-transfor \
1162 | --program-transfo | --program-transf \
1163 | --program-trans | --program-tran \
1164 | --progr-tra | --program-tr | --program-t)
1165 ac_prev=program_transform_name ;;
1166 -program-transform-name=* | --program-transform-name=* \
1167 | --program-transform-nam=* | --program-transform-na=* \
1168 | --program-transform-n=* | --program-transform-=* \
1169 | --program-transform=* | --program-transfor=* \
1170 | --program-transfo=* | --program-transf=* \
1171 | --program-trans=* | --program-tran=* \
1172 | --progr-tra=* | --program-tr=* | --program-t=*)
1173 program_transform_name=$ac_optarg ;;
1175 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1177 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1178 pdfdir=$ac_optarg ;;
1180 -psdir | --psdir | --psdi | --psd | --ps)
1182 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1185 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1186 | -silent | --silent | --silen | --sile | --sil)
1189 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1191 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1193 sbindir=$ac_optarg ;;
1195 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1196 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1197 | --sharedst | --shareds | --shared | --share | --shar \
1199 ac_prev=sharedstatedir ;;
1200 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1201 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1202 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1204 sharedstatedir=$ac_optarg ;;
1206 -site | --site | --sit)
1208 -site=* | --site=* | --sit=*)
1211 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1213 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1214 srcdir=$ac_optarg ;;
1216 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1217 | --syscon | --sysco | --sysc | --sys | --sy)
1218 ac_prev=sysconfdir ;;
1219 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1220 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1221 sysconfdir=$ac_optarg ;;
1223 -target | --target | --targe | --targ | --tar | --ta | --t)
1224 ac_prev=target_alias ;;
1225 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1226 target_alias=$ac_optarg ;;
1228 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1231 -version | --version | --versio | --versi | --vers | -V)
1232 ac_init_version=: ;;
1235 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1236 # Reject names that are not valid shell variable names.
1237 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1238 as_fn_error $? "invalid package name: $ac_useropt"
1239 ac_useropt_orig=$ac_useropt
1240 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1241 case $ac_user_opts in
1245 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1246 ac_unrecognized_sep=', ';;
1248 eval with_$ac_useropt=\$ac_optarg ;;
1250 -without-* | --without-*)
1251 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1252 # Reject names that are not valid shell variable names.
1253 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1254 as_fn_error $? "invalid package name: $ac_useropt"
1255 ac_useropt_orig=$ac_useropt
1256 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1257 case $ac_user_opts in
1261 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1262 ac_unrecognized_sep=', ';;
1264 eval with_$ac_useropt=no ;;
1267 # Obsolete; use --with-x.
1270 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1271 | --x-incl | --x-inc | --x-in | --x-i)
1272 ac_prev=x_includes ;;
1273 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1274 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1275 x_includes=$ac_optarg ;;
1277 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1278 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1279 ac_prev=x_libraries ;;
1280 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1281 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1282 x_libraries=$ac_optarg ;;
1284 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1285 Try \`$0 --help' for more information"
1289 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1290 # Reject names that are not valid shell variable names.
1291 case $ac_envvar in #(
1292 '' | [0-9]* | *[!_$as_cr_alnum]* )
1293 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1295 eval $ac_envvar=\$ac_optarg
1296 export $ac_envvar ;;
1299 # FIXME: should be removed in autoconf 3.0.
1300 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1301 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1302 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1303 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1309 if test -n "$ac_prev"; then
1310 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1311 as_fn_error $? "missing argument to $ac_option"
1314 if test -n "$ac_unrecognized_opts"; then
1315 case $enable_option_checking in
1317 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1318 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1322 # Check all directory arguments for consistency.
1323 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1324 datadir sysconfdir sharedstatedir localstatedir includedir \
1325 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1326 libdir localedir mandir
1328 eval ac_val=\$$ac_var
1329 # Remove trailing slashes.
1332 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1333 eval $ac_var=\$ac_val;;
1335 # Be sure to have absolute directory names.
1337 [\\/$]* | ?:[\\/]* ) continue;;
1338 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1340 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1343 # There might be people who depend on the old broken behavior: `$host'
1344 # used to hold the argument of --host etc.
1345 # FIXME: To remove some day.
1348 target=$target_alias
1350 # FIXME: To remove some day.
1351 if test "x$host_alias" != x; then
1352 if test "x$build_alias" = x; then
1353 cross_compiling=maybe
1354 elif test "x$build_alias" != "x$host_alias"; then
1360 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1362 test "$silent" = yes && exec 6>/dev/null
1365 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1366 ac_ls_di=`ls -di .` &&
1367 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1368 as_fn_error $? "working directory cannot be determined"
1369 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1370 as_fn_error $? "pwd does not report name of working directory"
1373 # Find the source files, if location was not specified.
1374 if test -z "$srcdir"; then
1375 ac_srcdir_defaulted=yes
1376 # Try the directory containing this script, then the parent directory.
1377 ac_confdir=`$as_dirname -- "$as_myself" ||
1378 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1379 X"$as_myself" : 'X\(//\)[^/]' \| \
1380 X"$as_myself" : 'X\(//\)$' \| \
1381 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1382 $as_echo X"$as_myself" |
1383 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1401 if test ! -r "$srcdir/$ac_unique_file"; then
1405 ac_srcdir_defaulted=no
1407 if test ! -r "$srcdir/$ac_unique_file"; then
1408 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1409 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1411 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1413 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1415 # When building in place, set srcdir=.
1416 if test "$ac_abs_confdir" = "$ac_pwd"; then
1419 # Remove unnecessary trailing slashes from srcdir.
1420 # Double slashes in file names in object file debugging info
1421 # mess up M-x gdb in Emacs.
1423 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1425 for ac_var in $ac_precious_vars; do
1426 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1427 eval ac_env_${ac_var}_value=\$${ac_var}
1428 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1429 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1433 # Report the --help message.
1435 if test "$ac_init_help" = "long"; then
1436 # Omit some internal or obsolete options to make the list less imposing.
1437 # This message is too long to be a string in the A/UX 3.1 sh.
1439 \`configure' configures PostgreSQL 12devel to adapt to many kinds of systems.
1441 Usage: $0 [OPTION]... [VAR=VALUE]...
1443 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1444 VAR=VALUE. See below for descriptions of some of the useful variables.
1446 Defaults for the options are specified in brackets.
1449 -h, --help display this help and exit
1450 --help=short display options specific to this package
1451 --help=recursive display the short help of all the included packages
1452 -V, --version display version information and exit
1453 -q, --quiet, --silent do not print \`checking ...' messages
1454 --cache-file=FILE cache test results in FILE [disabled]
1455 -C, --config-cache alias for \`--cache-file=config.cache'
1456 -n, --no-create do not create output files
1457 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1459 Installation directories:
1460 --prefix=PREFIX install architecture-independent files in PREFIX
1461 [$ac_default_prefix]
1462 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1465 By default, \`make install' will install all the files in
1466 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1467 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1468 for instance \`--prefix=\$HOME'.
1470 For better control, use the options below.
1472 Fine tuning of the installation directories:
1473 --bindir=DIR user executables [EPREFIX/bin]
1474 --sbindir=DIR system admin executables [EPREFIX/sbin]
1475 --libexecdir=DIR program executables [EPREFIX/libexec]
1476 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1477 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1478 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1479 --libdir=DIR object code libraries [EPREFIX/lib]
1480 --includedir=DIR C header files [PREFIX/include]
1481 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1482 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1483 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1484 --infodir=DIR info documentation [DATAROOTDIR/info]
1485 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1486 --mandir=DIR man documentation [DATAROOTDIR/man]
1487 --docdir=DIR documentation root [DATAROOTDIR/doc/postgresql]
1488 --htmldir=DIR html documentation [DOCDIR]
1489 --dvidir=DIR dvi documentation [DOCDIR]
1490 --pdfdir=DIR pdf documentation [DOCDIR]
1491 --psdir=DIR ps documentation [DOCDIR]
1497 --build=BUILD configure for building on BUILD [guessed]
1498 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1502 if test -n "$ac_init_help"; then
1503 case $ac_init_help in
1504 short | recursive ) echo "Configuration of PostgreSQL 12devel:";;
1509 --disable-option-checking ignore unrecognized --enable/--with options
1510 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1511 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1512 --disable-integer-datetimes
1513 obsolete option, no longer supported
1514 --enable-nls[=LANGUAGES]
1515 enable Native Language Support
1516 --disable-rpath do not embed shared library search path in
1518 --disable-spinlocks do not use spinlocks
1519 --disable-atomics do not use atomic operations
1520 --enable-debug build with debugging symbols (-g)
1521 --enable-profiling build with profiling enabled
1522 --enable-coverage build with coverage testing instrumentation
1523 --enable-dtrace build with DTrace support
1524 --enable-tap-tests enable TAP tests (requires Perl and IPC::Run)
1525 --enable-depend turn on automatic dependency tracking
1526 --enable-cassert enable assertion checks (for debugging)
1527 --disable-thread-safety disable thread-safety in client libraries
1528 --disable-largefile omit support for large files
1529 --disable-float4-byval disable float4 passed by value
1530 --disable-float8-byval disable float8 passed by value
1533 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1534 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1535 --with-extra-version=STRING
1536 append STRING to version
1537 --with-template=NAME override operating system template
1538 --with-includes=DIRS look for additional header files in DIRS
1539 --with-libraries=DIRS look for additional libraries in DIRS
1540 --with-libs=DIRS alternative spelling of --with-libraries
1541 --with-pgport=PORTNUM set default port number [5432]
1542 --with-blocksize=BLOCKSIZE
1543 set table block size in kB [8]
1544 --with-segsize=SEGSIZE set table segment size in GB [1]
1545 --with-wal-blocksize=BLOCKSIZE
1546 set WAL block size in kB [8]
1547 --with-CC=CMD set compiler (deprecated)
1548 --with-llvm build with LLVM based JIT support
1549 --with-icu build with ICU support
1550 --with-tcl build Tcl modules (PL/Tcl)
1551 --with-tclconfig=DIR tclConfig.sh is in DIR
1552 --with-perl build Perl modules (PL/Perl)
1553 --with-python build Python modules (PL/Python)
1554 --with-gssapi build with GSSAPI support
1555 --with-krb-srvnam=NAME default service principal name in Kerberos (GSSAPI)
1557 --with-pam build with PAM support
1558 --with-bsd-auth build with BSD Authentication support
1559 --with-ldap build with LDAP support
1560 --with-bonjour build with Bonjour support
1561 --with-openssl build with OpenSSL support
1562 --with-selinux build with SELinux support
1563 --with-systemd build with systemd support
1564 --without-readline do not use GNU Readline nor BSD Libedit for editing
1565 --with-libedit-preferred
1566 prefer BSD Libedit over GNU Readline
1567 --with-uuid=LIB build contrib/uuid-ossp using LIB (bsd,e2fs,ossp)
1568 --with-ossp-uuid obsolete spelling of --with-uuid=ossp
1569 --with-libxml build with XML support
1570 --with-libxslt use XSLT support when building contrib/xml2
1571 --with-system-tzdata=DIR
1572 use system time zone data in DIR
1573 --without-zlib do not use Zlib
1574 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
1576 Some influential environment variables:
1577 CC C compiler command
1578 CFLAGS C compiler flags
1579 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1580 nonstandard directory <lib dir>
1581 LIBS libraries to pass to the linker, e.g. -l<library>
1582 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1583 you have headers in a nonstandard directory <include dir>
1584 CXX C++ compiler command
1585 CXXFLAGS C++ compiler flags
1586 LLVM_CONFIG path to llvm-config command
1587 CLANG path to clang compiler to generate bitcode
1589 PKG_CONFIG path to pkg-config utility
1591 directories to add to pkg-config's search path
1593 path overriding pkg-config's built-in search path
1594 ICU_CFLAGS C compiler flags for ICU, overriding pkg-config
1595 ICU_LIBS linker flags for ICU, overriding pkg-config
1596 XML2_CONFIG path to xml2-config utility
1597 LDFLAGS_EX extra linker flags for linking executables only
1598 LDFLAGS_SL extra linker flags for linking shared libraries only
1600 PYTHON Python program
1601 MSGFMT msgfmt program for NLS
1602 TCLSH Tcl interpreter program (tclsh)
1604 Use these variables to override the choices made by `configure' or to help
1605 it to find libraries and programs with nonstandard names/locations.
1607 Report bugs to <pgsql-bugs@lists.postgresql.org>.
1612 if test "$ac_init_help" = "recursive"; then
1613 # If there are subdirs, report their specific --help.
1614 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1615 test -d "$ac_dir" ||
1616 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1621 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1623 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1624 # A ".." for each directory in $ac_dir_suffix.
1625 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1626 case $ac_top_builddir_sub in
1627 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1628 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1631 ac_abs_top_builddir=$ac_pwd
1632 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1633 # for backward compatibility:
1634 ac_top_builddir=$ac_top_build_prefix
1637 .) # We are building in place.
1639 ac_top_srcdir=$ac_top_builddir_sub
1640 ac_abs_top_srcdir=$ac_pwd ;;
1641 [\\/]* | ?:[\\/]* ) # Absolute name.
1642 ac_srcdir=$srcdir$ac_dir_suffix;
1643 ac_top_srcdir=$srcdir
1644 ac_abs_top_srcdir=$srcdir ;;
1646 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1647 ac_top_srcdir=$ac_top_build_prefix$srcdir
1648 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1650 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1652 cd "$ac_dir" || { ac_status=$?; continue; }
1653 # Check for guested configure.
1654 if test -f "$ac_srcdir/configure.gnu"; then
1656 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1657 elif test -f "$ac_srcdir/configure"; then
1659 $SHELL "$ac_srcdir/configure" --help=recursive
1661 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1663 cd "$ac_pwd" || { ac_status=$?; break; }
1667 test -n "$ac_init_help" && exit $ac_status
1668 if $ac_init_version; then
1670 PostgreSQL configure 12devel
1671 generated by GNU Autoconf 2.69
1673 Copyright (C) 2012 Free Software Foundation, Inc.
1674 This configure script is free software; the Free Software Foundation
1675 gives unlimited permission to copy, distribute and modify it.
1677 Copyright (c) 1996-2019, PostgreSQL Global Development Group
1682 ## ------------------------ ##
1683 ## Autoconf initialization. ##
1684 ## ------------------------ ##
1686 # ac_fn_c_try_compile LINENO
1687 # --------------------------
1688 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1689 ac_fn_c_try_compile ()
1691 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1692 rm -f conftest.$ac_objext
1693 if { { ac_try="$ac_compile"
1695 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1696 *) ac_try_echo=$ac_try;;
1698 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1699 $as_echo "$ac_try_echo"; } >&5
1700 (eval "$ac_compile") 2>conftest.err
1702 if test -s conftest.err; then
1703 grep -v '^ *+' conftest.err >conftest.er1
1704 cat conftest.er1 >&5
1705 mv -f conftest.er1 conftest.err
1707 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1708 test $ac_status = 0; } && {
1709 test -z "$ac_c_werror_flag" ||
1710 test ! -s conftest.err
1711 } && test -s conftest.$ac_objext; then :
1714 $as_echo "$as_me: failed program was:" >&5
1715 sed 's/^/| /' conftest.$ac_ext >&5
1719 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1720 as_fn_set_status $ac_retval
1722 } # ac_fn_c_try_compile
1724 # ac_fn_cxx_try_compile LINENO
1725 # ----------------------------
1726 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1727 ac_fn_cxx_try_compile ()
1729 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1730 rm -f conftest.$ac_objext
1731 if { { ac_try="$ac_compile"
1733 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1734 *) ac_try_echo=$ac_try;;
1736 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1737 $as_echo "$ac_try_echo"; } >&5
1738 (eval "$ac_compile") 2>conftest.err
1740 if test -s conftest.err; then
1741 grep -v '^ *+' conftest.err >conftest.er1
1742 cat conftest.er1 >&5
1743 mv -f conftest.er1 conftest.err
1745 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1746 test $ac_status = 0; } && {
1747 test -z "$ac_cxx_werror_flag" ||
1748 test ! -s conftest.err
1749 } && test -s conftest.$ac_objext; then :
1752 $as_echo "$as_me: failed program was:" >&5
1753 sed 's/^/| /' conftest.$ac_ext >&5
1757 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1758 as_fn_set_status $ac_retval
1760 } # ac_fn_cxx_try_compile
1762 # ac_fn_c_try_link LINENO
1763 # -----------------------
1764 # Try to link conftest.$ac_ext, and return whether this succeeded.
1767 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1768 rm -f conftest.$ac_objext conftest$ac_exeext
1769 if { { ac_try="$ac_link"
1771 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1772 *) ac_try_echo=$ac_try;;
1774 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1775 $as_echo "$ac_try_echo"; } >&5
1776 (eval "$ac_link") 2>conftest.err
1778 if test -s conftest.err; then
1779 grep -v '^ *+' conftest.err >conftest.er1
1780 cat conftest.er1 >&5
1781 mv -f conftest.er1 conftest.err
1783 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1784 test $ac_status = 0; } && {
1785 test -z "$ac_c_werror_flag" ||
1786 test ! -s conftest.err
1787 } && test -s conftest$ac_exeext && {
1788 test "$cross_compiling" = yes ||
1789 test -x conftest$ac_exeext
1793 $as_echo "$as_me: failed program was:" >&5
1794 sed 's/^/| /' conftest.$ac_ext >&5
1798 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1799 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1800 # interfere with the next link command; also delete a directory that is
1801 # left behind by Apple's compiler. We do this before executing the actions.
1802 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1803 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1804 as_fn_set_status $ac_retval
1806 } # ac_fn_c_try_link
1808 # ac_fn_c_try_cpp LINENO
1809 # ----------------------
1810 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1813 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1814 if { { ac_try="$ac_cpp conftest.$ac_ext"
1816 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1817 *) ac_try_echo=$ac_try;;
1819 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1820 $as_echo "$ac_try_echo"; } >&5
1821 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1823 if test -s conftest.err; then
1824 grep -v '^ *+' conftest.err >conftest.er1
1825 cat conftest.er1 >&5
1826 mv -f conftest.er1 conftest.err
1828 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1829 test $ac_status = 0; } > conftest.i && {
1830 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1831 test ! -s conftest.err
1835 $as_echo "$as_me: failed program was:" >&5
1836 sed 's/^/| /' conftest.$ac_ext >&5
1840 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1841 as_fn_set_status $ac_retval
1845 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1846 # -------------------------------------------------------
1847 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1848 # the include files in INCLUDES and setting the cache variable VAR
1850 ac_fn_c_check_header_mongrel ()
1852 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1853 if eval \${$3+:} false; then :
1854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1855 $as_echo_n "checking for $2... " >&6; }
1856 if eval \${$3+:} false; then :
1857 $as_echo_n "(cached) " >&6
1860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1861 $as_echo "$ac_res" >&6; }
1863 # Is the header compilable?
1864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1865 $as_echo_n "checking $2 usability... " >&6; }
1866 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1867 /* end confdefs.h. */
1871 if ac_fn_c_try_compile "$LINENO"; then :
1872 ac_header_compiler=yes
1874 ac_header_compiler=no
1876 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1878 $as_echo "$ac_header_compiler" >&6; }
1880 # Is the header present?
1881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1882 $as_echo_n "checking $2 presence... " >&6; }
1883 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1884 /* end confdefs.h. */
1887 if ac_fn_c_try_cpp "$LINENO"; then :
1888 ac_header_preproc=yes
1890 ac_header_preproc=no
1892 rm -f conftest.err conftest.i conftest.$ac_ext
1893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1894 $as_echo "$ac_header_preproc" >&6; }
1896 # So? What about this header?
1897 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1899 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1900 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1901 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1902 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1905 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1906 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1907 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
1908 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
1909 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1910 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1911 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
1912 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
1913 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1914 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1915 ( $as_echo "## ---------------------------------------------- ##
1916 ## Report this to pgsql-bugs@lists.postgresql.org ##
1917 ## ---------------------------------------------- ##"
1918 ) | sed "s/^/$as_me: WARNING: /" >&2
1921 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1922 $as_echo_n "checking for $2... " >&6; }
1923 if eval \${$3+:} false; then :
1924 $as_echo_n "(cached) " >&6
1926 eval "$3=\$ac_header_compiler"
1929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1930 $as_echo "$ac_res" >&6; }
1932 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1934 } # ac_fn_c_check_header_mongrel
1936 # ac_fn_c_try_run LINENO
1937 # ----------------------
1938 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1939 # that executables *can* be run.
1942 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1943 if { { ac_try="$ac_link"
1945 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1946 *) ac_try_echo=$ac_try;;
1948 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1949 $as_echo "$ac_try_echo"; } >&5
1950 (eval "$ac_link") 2>&5
1952 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1953 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1954 { { case "(($ac_try" in
1955 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1956 *) ac_try_echo=$ac_try;;
1958 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1959 $as_echo "$ac_try_echo"; } >&5
1960 (eval "$ac_try") 2>&5
1962 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1963 test $ac_status = 0; }; }; then :
1966 $as_echo "$as_me: program exited with status $ac_status" >&5
1967 $as_echo "$as_me: failed program was:" >&5
1968 sed 's/^/| /' conftest.$ac_ext >&5
1970 ac_retval=$ac_status
1972 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1973 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1974 as_fn_set_status $ac_retval
1978 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1979 # -------------------------------------------------------
1980 # Tests whether HEADER exists and can be compiled using the include files in
1981 # INCLUDES, setting the cache variable VAR accordingly.
1982 ac_fn_c_check_header_compile ()
1984 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1986 $as_echo_n "checking for $2... " >&6; }
1987 if eval \${$3+:} false; then :
1988 $as_echo_n "(cached) " >&6
1990 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1991 /* end confdefs.h. */
1995 if ac_fn_c_try_compile "$LINENO"; then :
2000 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2004 $as_echo "$ac_res" >&6; }
2005 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2007 } # ac_fn_c_check_header_compile
2009 # ac_fn_c_check_func LINENO FUNC VAR
2010 # ----------------------------------
2011 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2012 ac_fn_c_check_func ()
2014 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2016 $as_echo_n "checking for $2... " >&6; }
2017 if eval \${$3+:} false; then :
2018 $as_echo_n "(cached) " >&6
2020 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2021 /* end confdefs.h. */
2022 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2023 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2024 #define $2 innocuous_$2
2026 /* System header to define __stub macros and hopefully few prototypes,
2027 which can conflict with char $2 (); below.
2028 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2029 <limits.h> exists even on freestanding compilers. */
2032 # include <limits.h>
2034 # include <assert.h>
2039 /* Override any GCC internal prototype to avoid an error.
2040 Use char because int might match the return type of a GCC
2041 builtin and then its argument prototype would still apply. */
2046 /* The GNU C library defines this for functions which it implements
2047 to always fail with ENOSYS. Some functions are actually named
2048 something starting with __ and the normal name is an alias. */
2049 #if defined __stub_$2 || defined __stub___$2
2061 if ac_fn_c_try_link "$LINENO"; then :
2066 rm -f core conftest.err conftest.$ac_objext \
2067 conftest$ac_exeext conftest.$ac_ext
2070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2071 $as_echo "$ac_res" >&6; }
2072 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2074 } # ac_fn_c_check_func
2076 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2077 # -------------------------------------------
2078 # Tests whether TYPE exists after having included INCLUDES, setting cache
2079 # variable VAR accordingly.
2080 ac_fn_c_check_type ()
2082 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2083 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2084 $as_echo_n "checking for $2... " >&6; }
2085 if eval \${$3+:} false; then :
2086 $as_echo_n "(cached) " >&6
2089 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2090 /* end confdefs.h. */
2101 if ac_fn_c_try_compile "$LINENO"; then :
2102 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2103 /* end confdefs.h. */
2114 if ac_fn_c_try_compile "$LINENO"; then :
2119 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2121 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2125 $as_echo "$ac_res" >&6; }
2126 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2128 } # ac_fn_c_check_type
2130 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2131 # ----------------------------------------------------
2132 # Tries to find if the field MEMBER exists in type AGGR, after including
2133 # INCLUDES, setting cache variable VAR accordingly.
2134 ac_fn_c_check_member ()
2136 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2137 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2138 $as_echo_n "checking for $2.$3... " >&6; }
2139 if eval \${$4+:} false; then :
2140 $as_echo_n "(cached) " >&6
2142 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2143 /* end confdefs.h. */
2155 if ac_fn_c_try_compile "$LINENO"; then :
2158 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2159 /* end confdefs.h. */
2165 if (sizeof ac_aggr.$3)
2171 if ac_fn_c_try_compile "$LINENO"; then :
2176 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2178 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2182 $as_echo "$ac_res" >&6; }
2183 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2185 } # ac_fn_c_check_member
2187 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2188 # --------------------------------------------
2189 # Tries to find the compile-time value of EXPR in a program that includes
2190 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2192 ac_fn_c_compute_int ()
2194 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2195 if test "$cross_compiling" = yes; then
2196 # Depending upon the size, compute the lo and hi bounds.
2197 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2198 /* end confdefs.h. */
2203 static int test_array [1 - 2 * !(($2) >= 0)];
2205 return test_array [0];
2211 if ac_fn_c_try_compile "$LINENO"; then :
2214 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2215 /* end confdefs.h. */
2220 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2222 return test_array [0];
2228 if ac_fn_c_try_compile "$LINENO"; then :
2229 ac_hi=$ac_mid; break
2231 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2232 if test $ac_lo -le $ac_mid; then
2236 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2238 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2241 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2242 /* end confdefs.h. */
2247 static int test_array [1 - 2 * !(($2) < 0)];
2249 return test_array [0];
2255 if ac_fn_c_try_compile "$LINENO"; then :
2258 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2259 /* end confdefs.h. */
2264 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2266 return test_array [0];
2272 if ac_fn_c_try_compile "$LINENO"; then :
2273 ac_lo=$ac_mid; break
2275 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2276 if test $ac_mid -le $ac_hi; then
2280 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2282 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2287 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2289 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2290 # Binary search between lo and hi bounds.
2291 while test "x$ac_lo" != "x$ac_hi"; do
2292 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2293 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2294 /* end confdefs.h. */
2299 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2301 return test_array [0];
2307 if ac_fn_c_try_compile "$LINENO"; then :
2310 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2312 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2315 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2319 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2320 /* end confdefs.h. */
2322 static long int longval () { return $2; }
2323 static unsigned long int ulongval () { return $2; }
2330 FILE *f = fopen ("conftest.val", "w");
2335 long int i = longval ();
2338 fprintf (f, "%ld", i);
2342 unsigned long int i = ulongval ();
2345 fprintf (f, "%lu", i);
2347 /* Do not output a trailing newline, as this causes \r\n confusion
2348 on some platforms. */
2349 return ferror (f) || fclose (f) != 0;
2355 if ac_fn_c_try_run "$LINENO"; then :
2356 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2360 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2361 conftest.$ac_objext conftest.beam conftest.$ac_ext
2365 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2366 as_fn_set_status $ac_retval
2368 } # ac_fn_c_compute_int
2370 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2371 # ---------------------------------------------
2372 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2374 ac_fn_c_check_decl ()
2376 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2377 # Initialize each $ac_[]_AC_LANG_ABBREV[]_decl_warn_flag once.
2378 as_decl_name=`echo $2|sed 's/ *(.*//'`
2379 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2381 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2382 if eval \${$3+:} false; then :
2383 $as_echo_n "(cached) " >&6
2385 ac_save_werror_flag=$ac_c_werror_flag
2386 ac_c_werror_flag="$ac_c_decl_warn_flag$ac_c_werror_flag"
2387 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2388 /* end confdefs.h. */
2393 #ifndef $as_decl_name
2395 (void) $as_decl_use;
2397 (void) $as_decl_name;
2405 if ac_fn_c_try_compile "$LINENO"; then :
2410 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2411 ac_c_werror_flag=$ac_save_werror_flag
2414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2415 $as_echo "$ac_res" >&6; }
2416 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2418 } # ac_fn_c_check_decl
2419 cat >config.log <<_ACEOF
2420 This file contains any messages produced by compilers while
2421 running configure, to aid debugging if configure makes a mistake.
2423 It was created by PostgreSQL $as_me 12devel, which was
2424 generated by GNU Autoconf 2.69. Invocation command line was
2436 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2437 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2438 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2439 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2440 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2442 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2443 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2445 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2446 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2447 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2448 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2449 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2450 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2451 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2455 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2459 test -z "$as_dir" && as_dir=.
2460 $as_echo "PATH: $as_dir"
2476 # Keep a trace of the command line.
2477 # Strip out --no-create and --no-recursion so they do not pile up.
2478 # Strip out --silent because we don't want to record it for future runs.
2479 # Also quote any args containing shell meta-characters.
2480 # Make two passes to allow for proper duplicate-argument suppression.
2484 ac_must_keep_next=false
2490 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2491 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2492 | -silent | --silent | --silen | --sile | --sil)
2495 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2498 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2500 as_fn_append ac_configure_args1 " '$ac_arg'"
2501 if test $ac_must_keep_next = true; then
2502 ac_must_keep_next=false # Got value, back to normal.
2505 *=* | --config-cache | -C | -disable-* | --disable-* \
2506 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2507 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2508 | -with-* | --with-* | -without-* | --without-* | --x)
2509 case "$ac_configure_args0 " in
2510 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2513 -* ) ac_must_keep_next=true ;;
2516 as_fn_append ac_configure_args " '$ac_arg'"
2521 { ac_configure_args0=; unset ac_configure_args0;}
2522 { ac_configure_args1=; unset ac_configure_args1;}
2524 # When interrupted or exit'd, cleanup temporary files, and complete
2525 # config.log. We remove comments because anyway the quotes in there
2526 # would cause problems or look ugly.
2527 # WARNING: Use '\'' to represent an apostrophe within the trap.
2528 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2529 trap 'exit_status=$?
2530 # Save into config.log some information that might help in debugging.
2534 $as_echo "## ---------------- ##
2535 ## Cache variables. ##
2536 ## ---------------- ##"
2538 # The following way of writing the cache mishandles newlines in values,
2540 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2541 eval ac_val=\$$ac_var
2545 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2546 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2549 _ | IFS | as_nl) ;; #(
2550 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2551 *) { eval $ac_var=; unset $ac_var;} ;;
2556 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2557 *${as_nl}ac_space=\ *)
2559 "s/'\''/'\''\\\\'\'''\''/g;
2560 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2563 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2570 $as_echo "## ----------------- ##
2571 ## Output variables. ##
2572 ## ----------------- ##"
2574 for ac_var in $ac_subst_vars
2576 eval ac_val=\$$ac_var
2578 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2580 $as_echo "$ac_var='\''$ac_val'\''"
2584 if test -n "$ac_subst_files"; then
2585 $as_echo "## ------------------- ##
2586 ## File substitutions. ##
2587 ## ------------------- ##"
2589 for ac_var in $ac_subst_files
2591 eval ac_val=\$$ac_var
2593 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2595 $as_echo "$ac_var='\''$ac_val'\''"
2600 if test -s confdefs.h; then
2601 $as_echo "## ----------- ##
2608 test "$ac_signal" != 0 &&
2609 $as_echo "$as_me: caught signal $ac_signal"
2610 $as_echo "$as_me: exit $exit_status"
2612 rm -f core *.core core.conftest.* &&
2613 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2616 for ac_signal in 1 2 13 15; do
2617 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2621 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2622 rm -f -r conftest* confdefs.h
2624 $as_echo "/* confdefs.h */" > confdefs.h
2626 # Predefined preprocessor variables.
2628 cat >>confdefs.h <<_ACEOF
2629 #define PACKAGE_NAME "$PACKAGE_NAME"
2632 cat >>confdefs.h <<_ACEOF
2633 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2636 cat >>confdefs.h <<_ACEOF
2637 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2640 cat >>confdefs.h <<_ACEOF
2641 #define PACKAGE_STRING "$PACKAGE_STRING"
2644 cat >>confdefs.h <<_ACEOF
2645 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2648 cat >>confdefs.h <<_ACEOF
2649 #define PACKAGE_URL "$PACKAGE_URL"
2653 # Let the site file select an alternate cache file if it wants to.
2654 # Prefer an explicitly selected file to automatically selected ones.
2657 if test -n "$CONFIG_SITE"; then
2658 # We do not want a PATH search for config.site.
2659 case $CONFIG_SITE in #((
2660 -*) ac_site_file1=./$CONFIG_SITE;;
2661 */*) ac_site_file1=$CONFIG_SITE;;
2662 *) ac_site_file1=./$CONFIG_SITE;;
2664 elif test "x$prefix" != xNONE; then
2665 ac_site_file1=$prefix/share/config.site
2666 ac_site_file2=$prefix/etc/config.site
2668 ac_site_file1=$ac_default_prefix/share/config.site
2669 ac_site_file2=$ac_default_prefix/etc/config.site
2671 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2673 test "x$ac_site_file" = xNONE && continue
2674 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2675 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2676 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2677 sed 's/^/| /' "$ac_site_file" >&5
2679 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2680 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2681 as_fn_error $? "failed to load site script $ac_site_file
2682 See \`config.log' for more details" "$LINENO" 5; }
2686 if test -r "$cache_file"; then
2687 # Some versions of bash will fail to source /dev/null (special files
2688 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2689 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2690 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2691 $as_echo "$as_me: loading cache $cache_file" >&6;}
2693 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2694 *) . "./$cache_file";;
2698 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2699 $as_echo "$as_me: creating cache $cache_file" >&6;}
2703 # Check that the precious variables saved in the cache have kept the same
2705 ac_cache_corrupted=false
2706 for ac_var in $ac_precious_vars; do
2707 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2708 eval ac_new_set=\$ac_env_${ac_var}_set
2709 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2710 eval ac_new_val=\$ac_env_${ac_var}_value
2711 case $ac_old_set,$ac_new_set in
2713 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2714 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2715 ac_cache_corrupted=: ;;
2717 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2718 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2719 ac_cache_corrupted=: ;;
2722 if test "x$ac_old_val" != "x$ac_new_val"; then
2723 # differences in whitespace do not lead to failure.
2724 ac_old_val_w=`echo x $ac_old_val`
2725 ac_new_val_w=`echo x $ac_new_val`
2726 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2727 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2728 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2729 ac_cache_corrupted=:
2731 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2732 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2733 eval $ac_var=\$ac_old_val
2735 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2736 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2737 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2738 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2741 # Pass precious variables to config.status.
2742 if test "$ac_new_set" = set; then
2744 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2745 *) ac_arg=$ac_var=$ac_new_val ;;
2747 case " $ac_configure_args " in
2748 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2749 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2753 if $ac_cache_corrupted; then
2754 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2755 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2756 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2757 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2758 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2760 ## -------------------- ##
2761 ## Main body of script. ##
2762 ## -------------------- ##
2765 ac_cpp='$CPP $CPPFLAGS'
2766 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2767 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2768 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2776 for ac_dir in config "$srcdir"/config; do
2777 if test -f "$ac_dir/install-sh"; then
2779 ac_install_sh="$ac_aux_dir/install-sh -c"
2781 elif test -f "$ac_dir/install.sh"; then
2783 ac_install_sh="$ac_aux_dir/install.sh -c"
2785 elif test -f "$ac_dir/shtool"; then
2787 ac_install_sh="$ac_aux_dir/shtool install -c"
2791 if test -z "$ac_aux_dir"; then
2792 as_fn_error $? "cannot find install-sh, install.sh, or shtool in config \"$srcdir\"/config" "$LINENO" 5
2795 # These three variables are undocumented and unsupported,
2796 # and are intended to be withdrawn in a future Autoconf release.
2797 # They can cause serious problems if a builder's source tree is in a directory
2798 # whose full name contains unusual characters.
2799 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
2800 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
2801 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
2805 configure_args=$ac_configure_args
2808 PG_MAJORVERSION=`expr "$PACKAGE_VERSION" : '\([0-9][0-9]*\)'`
2811 cat >>confdefs.h <<_ACEOF
2812 #define PG_MAJORVERSION "$PG_MAJORVERSION"
2819 # Check whether --with-extra-version was given.
2820 if test "${with_extra_version+set}" = set; then :
2821 withval=$with_extra_version;
2824 as_fn_error $? "argument required for --with-extra-version option" "$LINENO" 5
2827 as_fn_error $? "argument required for --with-extra-version option" "$LINENO" 5
2830 PG_VERSION="$PACKAGE_VERSION$withval"
2835 PG_VERSION="$PACKAGE_VERSION"
2840 cat >>confdefs.h <<_ACEOF
2841 #define PG_VERSION "$PG_VERSION"
2845 # Make sure we can run config.sub.
2846 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2847 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
2849 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
2850 $as_echo_n "checking build system type... " >&6; }
2851 if ${ac_cv_build+:} false; then :
2852 $as_echo_n "(cached) " >&6
2854 ac_build_alias=$build_alias
2855 test "x$ac_build_alias" = x &&
2856 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2857 test "x$ac_build_alias" = x &&
2858 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
2859 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2860 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
2863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
2864 $as_echo "$ac_cv_build" >&6; }
2865 case $ac_cv_build in
2867 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
2870 ac_save_IFS=$IFS; IFS='-'
2876 # Remember, the first character of IFS is used to create $*,
2877 # except with old shells:
2880 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
2883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
2884 $as_echo_n "checking host system type... " >&6; }
2885 if ${ac_cv_host+:} false; then :
2886 $as_echo_n "(cached) " >&6
2888 if test "x$host_alias" = x; then
2889 ac_cv_host=$ac_cv_build
2891 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2892 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
2896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
2897 $as_echo "$ac_cv_host" >&6; }
2900 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
2903 ac_save_IFS=$IFS; IFS='-'
2909 # Remember, the first character of IFS is used to create $*,
2910 # except with old shells:
2913 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which template to use" >&5
2919 $as_echo_n "checking which template to use... " >&6; }
2924 # Check whether --with-template was given.
2925 if test "${with_template+set}" = set; then :
2926 withval=$with_template;
2929 as_fn_error $? "argument required for --with-template option" "$LINENO" 5
2932 as_fn_error $? "argument required for --with-template option" "$LINENO" 5
2937 list) echo; ls "$srcdir/src/template"; exit;;
2938 *) if test -f "$srcdir/src/template/$with_template" ; then
2941 as_fn_error $? "'$withval' is not a valid template name. Use 'list' for a list." "$LINENO" 5
2950 # --with-template not given
2953 aix*) template=aix ;;
2954 cygwin*) template=cygwin ;;
2955 darwin*) template=darwin ;;
2956 dragonfly*) template=netbsd ;;
2957 freebsd*) template=freebsd ;;
2958 hpux*) template=hpux ;;
2959 linux*|gnu*|k*bsd*-gnu)
2961 mingw*) template=win32 ;;
2962 netbsd*) template=netbsd ;;
2963 openbsd*) template=openbsd ;;
2964 solaris*) template=solaris ;;
2967 if test x"$template" = x"" ; then
2969 *******************************************************************
2970 PostgreSQL has apparently not been ported to your platform yet.
2971 To try a manual configuration, look into the src/template directory
2972 for a similar platform and use the '--with-template=' option.
2974 Please also contact <pgsql-bugs@lists.postgresql.org> to see about
2975 rectifying this. Include the above 'checking host system type...'
2977 *******************************************************************
2986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $template" >&5
2987 $as_echo "$template" >&6; }
2992 # Initialize default assumption that we do not need separate assembly code
2993 # for TAS (test-and-set). This can be overridden by the template file
2994 # when it's executed.
3001 ## Command line options
3005 # Add non-standard directories to the include path
3010 # Check whether --with-includes was given.
3011 if test "${with_includes+set}" = set; then :
3012 withval=$with_includes;
3015 as_fn_error $? "argument required for --with-includes option" "$LINENO" 5
3018 as_fn_error $? "argument required for --with-includes option" "$LINENO" 5
3031 # Add non-standard directories to the library search path
3036 # Check whether --with-libraries was given.
3037 if test "${with_libraries+set}" = set; then :
3038 withval=$with_libraries;
3041 as_fn_error $? "argument required for --with-libraries option" "$LINENO" 5
3044 as_fn_error $? "argument required for --with-libraries option" "$LINENO" 5
3047 LIBRARY_DIRS=$withval
3058 # Check whether --with-libs was given.
3059 if test "${with_libs+set}" = set; then :
3063 as_fn_error $? "argument required for --with-libs option" "$LINENO" 5
3066 as_fn_error $? "argument required for --with-libs option" "$LINENO" 5
3069 LIBRARY_DIRS=$withval
3079 # 64-bit integer date/time storage is now the only option, but to avoid
3080 # unnecessary breakage of build scripts, continue to accept an explicit
3081 # "--enable-integer-datetimes" switch.
3085 # Check whether --enable-integer-datetimes was given.
3086 if test "${enable_integer_datetimes+set}" = set; then :
3087 enableval=$enable_integer_datetimes;
3093 as_fn_error $? "--disable-integer-datetimes is no longer supported" "$LINENO" 5
3096 as_fn_error $? "no argument expected for --enable-integer-datetimes option" "$LINENO" 5
3101 enable_integer_datetimes=yes
3111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is wanted" >&5
3112 $as_echo_n "checking whether NLS is wanted... " >&6; }
3115 # Check whether --enable-nls was given.
3116 if test "${enable_nls+set}" = set; then :
3117 enableval=$enable_nls;
3127 WANTED_LANGUAGES=$enableval
3137 if test "$enable_nls" = yes; then
3139 $as_echo "#define ENABLE_NLS 1" >>confdefs.h
3143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_nls" >&5
3144 $as_echo "$enable_nls" >&6; }
3149 # Default port number (--with-pgport), default 5432
3151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default port number" >&5
3152 $as_echo_n "checking for default port number... " >&6; }
3156 # Check whether --with-pgport was given.
3157 if test "${with_pgport+set}" = set; then :
3158 withval=$with_pgport;
3161 as_fn_error $? "argument required for --with-pgport option" "$LINENO" 5
3164 as_fn_error $? "argument required for --with-pgport option" "$LINENO" 5
3167 default_port=$withval
3176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $default_port" >&5
3177 $as_echo "$default_port" >&6; }
3178 # Need both of these because some places want an integer and some a string
3180 cat >>confdefs.h <<_ACEOF
3181 #define DEF_PGPORT ${default_port}
3185 cat >>confdefs.h <<_ACEOF
3186 #define DEF_PGPORT_STR "${default_port}"
3191 # It's worth validating port; you can get very confusing errors otherwise
3192 if test x"$default_port" = x""; then
3193 as_fn_error $? "invalid --with-pgport specification: empty string" "$LINENO" 5
3194 elif test ! x`echo "$default_port" | sed -e 's/[0-9]*//'` = x""; then
3195 as_fn_error $? "invalid --with-pgport specification: must be a number" "$LINENO" 5
3196 elif test ! x`echo "$default_port" | sed -e 's/^0.//'` = x"$default_port"; then
3197 as_fn_error $? "invalid --with-pgport specification: must not have leading 0" "$LINENO" 5
3198 elif test "$default_port" -lt "1" -o "$default_port" -gt "65535"; then
3199 as_fn_error $? "invalid --with-pgport specification: must be between 1 and 65535" "$LINENO" 5
3203 # '-rpath'-like feature can be disabled
3207 # Check whether --enable-rpath was given.
3208 if test "${enable_rpath+set}" = set; then :
3209 enableval=$enable_rpath;
3218 as_fn_error $? "no argument expected for --enable-rpath option" "$LINENO" 5
3235 # Check whether --enable-spinlocks was given.
3236 if test "${enable_spinlocks+set}" = set; then :
3237 enableval=$enable_spinlocks;
3246 as_fn_error $? "no argument expected for --enable-spinlocks option" "$LINENO" 5
3251 enable_spinlocks=yes
3262 # Check whether --enable-atomics was given.
3263 if test "${enable_atomics+set}" = set; then :
3264 enableval=$enable_atomics;
3273 as_fn_error $? "no argument expected for --enable-atomics option" "$LINENO" 5
3285 # --enable-debug adds -g to compiler flags
3289 # Check whether --enable-debug was given.
3290 if test "${enable_debug+set}" = set; then :
3291 enableval=$enable_debug;
3300 as_fn_error $? "no argument expected for --enable-debug option" "$LINENO" 5
3313 # --enable-profiling enables gcc profiling
3317 # Check whether --enable-profiling was given.
3318 if test "${enable_profiling+set}" = set; then :
3319 enableval=$enable_profiling;
3328 as_fn_error $? "no argument expected for --enable-profiling option" "$LINENO" 5
3340 # --enable-coverage enables generation of code coverage metrics with gcov
3344 # Check whether --enable-coverage was given.
3345 if test "${enable_coverage+set}" = set; then :
3346 enableval=$enable_coverage;
3349 if test -z "$GCOV"; then
3352 # Extract the first word of "$ac_prog", so it can be a program name with args.
3353 set dummy $ac_prog; ac_word=$2
3354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3355 $as_echo_n "checking for $ac_word... " >&6; }
3356 if ${ac_cv_path_GCOV+:} false; then :
3357 $as_echo_n "(cached) " >&6
3361 ac_cv_path_GCOV="$GCOV" # Let the user override the test with a path.
3364 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3368 test -z "$as_dir" && as_dir=.
3369 for ac_exec_ext in '' $ac_executable_extensions; do
3370 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3371 ac_cv_path_GCOV="$as_dir/$ac_word$ac_exec_ext"
3372 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3382 GCOV=$ac_cv_path_GCOV
3383 if test -n "$GCOV"; then
3384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCOV" >&5
3385 $as_echo "$GCOV" >&6; }
3387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3388 $as_echo "no" >&6; }
3392 test -n "$GCOV" && break
3396 # Report the value of GCOV in configure's output in all cases.
3397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GCOV" >&5
3398 $as_echo_n "checking for GCOV... " >&6; }
3399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCOV" >&5
3400 $as_echo "$GCOV" >&6; }
3403 if test -z "$GCOV"; then
3404 as_fn_error $? "gcov not found" "$LINENO" 5
3406 if test -z "$LCOV"; then
3409 # Extract the first word of "$ac_prog", so it can be a program name with args.
3410 set dummy $ac_prog; ac_word=$2
3411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3412 $as_echo_n "checking for $ac_word... " >&6; }
3413 if ${ac_cv_path_LCOV+:} false; then :
3414 $as_echo_n "(cached) " >&6
3418 ac_cv_path_LCOV="$LCOV" # Let the user override the test with a path.
3421 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3425 test -z "$as_dir" && as_dir=.
3426 for ac_exec_ext in '' $ac_executable_extensions; do
3427 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3428 ac_cv_path_LCOV="$as_dir/$ac_word$ac_exec_ext"
3429 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3439 LCOV=$ac_cv_path_LCOV
3440 if test -n "$LCOV"; then
3441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LCOV" >&5
3442 $as_echo "$LCOV" >&6; }
3444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3445 $as_echo "no" >&6; }
3449 test -n "$LCOV" && break
3453 # Report the value of LCOV in configure's output in all cases.
3454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LCOV" >&5
3455 $as_echo_n "checking for LCOV... " >&6; }
3456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LCOV" >&5
3457 $as_echo "$LCOV" >&6; }
3460 if test -z "$LCOV"; then
3461 as_fn_error $? "lcov not found" "$LINENO" 5
3463 if test -z "$GENHTML"; then
3464 for ac_prog in genhtml
3466 # Extract the first word of "$ac_prog", so it can be a program name with args.
3467 set dummy $ac_prog; ac_word=$2
3468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3469 $as_echo_n "checking for $ac_word... " >&6; }
3470 if ${ac_cv_path_GENHTML+:} false; then :
3471 $as_echo_n "(cached) " >&6
3475 ac_cv_path_GENHTML="$GENHTML" # Let the user override the test with a path.
3478 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3482 test -z "$as_dir" && as_dir=.
3483 for ac_exec_ext in '' $ac_executable_extensions; do
3484 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3485 ac_cv_path_GENHTML="$as_dir/$ac_word$ac_exec_ext"
3486 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3496 GENHTML=$ac_cv_path_GENHTML
3497 if test -n "$GENHTML"; then
3498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GENHTML" >&5
3499 $as_echo "$GENHTML" >&6; }
3501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3502 $as_echo "no" >&6; }
3506 test -n "$GENHTML" && break
3510 # Report the value of GENHTML in configure's output in all cases.
3511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GENHTML" >&5
3512 $as_echo_n "checking for GENHTML... " >&6; }
3513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GENHTML" >&5
3514 $as_echo "$GENHTML" >&6; }
3517 if test -z "$GENHTML"; then
3518 as_fn_error $? "genhtml not found" "$LINENO" 5
3525 as_fn_error $? "no argument expected for --enable-coverage option" "$LINENO" 5
3542 # Check whether --enable-dtrace was given.
3543 if test "${enable_dtrace+set}" = set; then :
3544 enableval=$enable_dtrace;
3547 if test -z "$DTRACE"; then
3548 for ac_prog in dtrace
3550 # Extract the first word of "$ac_prog", so it can be a program name with args.
3551 set dummy $ac_prog; ac_word=$2
3552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3553 $as_echo_n "checking for $ac_word... " >&6; }
3554 if ${ac_cv_path_DTRACE+:} false; then :
3555 $as_echo_n "(cached) " >&6
3559 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path.
3562 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3566 test -z "$as_dir" && as_dir=.
3567 for ac_exec_ext in '' $ac_executable_extensions; do
3568 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3569 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext"
3570 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3580 DTRACE=$ac_cv_path_DTRACE
3581 if test -n "$DTRACE"; then
3582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5
3583 $as_echo "$DTRACE" >&6; }
3585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3586 $as_echo "no" >&6; }
3590 test -n "$DTRACE" && break
3594 # Report the value of DTRACE in configure's output in all cases.
3595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DTRACE" >&5
3596 $as_echo_n "checking for DTRACE... " >&6; }
3597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5
3598 $as_echo "$DTRACE" >&6; }
3601 if test -z "$DTRACE"; then
3602 as_fn_error $? "dtrace not found" "$LINENO" 5
3610 as_fn_error $? "no argument expected for --enable-dtrace option" "$LINENO" 5
3627 # Check whether --enable-tap-tests was given.
3628 if test "${enable_tap_tests+set}" = set; then :
3629 enableval=$enable_tap_tests;
3638 as_fn_error $? "no argument expected for --enable-tap-tests option" "$LINENO" 5
3653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for block size" >&5
3654 $as_echo_n "checking for block size... " >&6; }
3658 # Check whether --with-blocksize was given.
3659 if test "${with_blocksize+set}" = set; then :
3660 withval=$with_blocksize;
3663 as_fn_error $? "argument required for --with-blocksize option" "$LINENO" 5
3666 as_fn_error $? "argument required for --with-blocksize option" "$LINENO" 5
3678 case ${blocksize} in
3685 *) as_fn_error $? "Invalid block size. Allowed values are 1,2,4,8,16,32." "$LINENO" 5
3687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${blocksize}kB" >&5
3688 $as_echo "${blocksize}kB" >&6; }
3691 cat >>confdefs.h <<_ACEOF
3692 #define BLCKSZ ${BLCKSZ}
3697 # Relation segment size
3699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for segment size" >&5
3700 $as_echo_n "checking for segment size... " >&6; }
3704 # Check whether --with-segsize was given.
3705 if test "${with_segsize+set}" = set; then :
3706 withval=$with_segsize;
3709 as_fn_error $? "argument required for --with-segsize option" "$LINENO" 5
3712 as_fn_error $? "argument required for --with-segsize option" "$LINENO" 5
3724 # this expression is set up to avoid unnecessary integer overflow
3725 # blocksize is already guaranteed to be a factor of 1024
3726 RELSEG_SIZE=`expr '(' 1024 / ${blocksize} ')' '*' ${segsize} '*' 1024`
3727 test $? -eq 0 || exit 1
3728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${segsize}GB" >&5
3729 $as_echo "${segsize}GB" >&6; }
3732 cat >>confdefs.h <<_ACEOF
3733 #define RELSEG_SIZE ${RELSEG_SIZE}
3740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WAL block size" >&5
3741 $as_echo_n "checking for WAL block size... " >&6; }
3745 # Check whether --with-wal-blocksize was given.
3746 if test "${with_wal_blocksize+set}" = set; then :
3747 withval=$with_wal_blocksize;
3750 as_fn_error $? "argument required for --with-wal-blocksize option" "$LINENO" 5
3753 as_fn_error $? "argument required for --with-wal-blocksize option" "$LINENO" 5
3756 wal_blocksize=$withval
3765 case ${wal_blocksize} in
3766 1) XLOG_BLCKSZ=1024;;
3767 2) XLOG_BLCKSZ=2048;;
3768 4) XLOG_BLCKSZ=4096;;
3769 8) XLOG_BLCKSZ=8192;;
3770 16) XLOG_BLCKSZ=16384;;
3771 32) XLOG_BLCKSZ=32768;;
3772 64) XLOG_BLCKSZ=65536;;
3773 *) as_fn_error $? "Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." "$LINENO" 5
3775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${wal_blocksize}kB" >&5
3776 $as_echo "${wal_blocksize}kB" >&6; }
3779 cat >>confdefs.h <<_ACEOF
3780 #define XLOG_BLCKSZ ${XLOG_BLCKSZ}
3788 # For historical reasons you can also use --with-CC to specify the C compiler
3789 # to use, although the standard way to do this is to set the CC environment
3794 # Check whether --with-CC was given.
3795 if test "${with_CC+set}" = set; then :
3799 as_fn_error $? "argument required for --with-CC option" "$LINENO" 5
3802 as_fn_error $? "argument required for --with-CC option" "$LINENO" 5
3814 aix) pgac_cc_list="gcc xlc"; pgac_cxx_list="g++ xlC";;
3815 *) pgac_cc_list="gcc cc"; pgac_cxx_list="g++ c++";;
3819 ac_cpp='$CPP $CPPFLAGS'
3820 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3821 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3822 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3823 if test -n "$ac_tool_prefix"; then
3824 for ac_prog in $pgac_cc_list
3826 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3827 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3828 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3829 $as_echo_n "checking for $ac_word... " >&6; }
3830 if ${ac_cv_prog_CC+:} false; then :
3831 $as_echo_n "(cached) " >&6
3833 if test -n "$CC"; then
3834 ac_cv_prog_CC="$CC" # Let the user override the test.
3836 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3840 test -z "$as_dir" && as_dir=.
3841 for ac_exec_ext in '' $ac_executable_extensions; do
3842 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3843 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3844 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3854 if test -n "$CC"; then
3855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3856 $as_echo "$CC" >&6; }
3858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3859 $as_echo "no" >&6; }
3863 test -n "$CC" && break
3866 if test -z "$CC"; then
3868 for ac_prog in $pgac_cc_list
3870 # Extract the first word of "$ac_prog", so it can be a program name with args.
3871 set dummy $ac_prog; ac_word=$2
3872 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3873 $as_echo_n "checking for $ac_word... " >&6; }
3874 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3875 $as_echo_n "(cached) " >&6
3877 if test -n "$ac_ct_CC"; then
3878 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3880 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3884 test -z "$as_dir" && as_dir=.
3885 for ac_exec_ext in '' $ac_executable_extensions; do
3886 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3887 ac_cv_prog_ac_ct_CC="$ac_prog"
3888 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3897 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3898 if test -n "$ac_ct_CC"; then
3899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3900 $as_echo "$ac_ct_CC" >&6; }
3902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3903 $as_echo "no" >&6; }
3907 test -n "$ac_ct_CC" && break
3910 if test "x$ac_ct_CC" = x; then
3913 case $cross_compiling:$ac_tool_warned in
3915 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3916 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3917 ac_tool_warned=yes ;;
3924 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3925 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3926 as_fn_error $? "no acceptable C compiler found in \$PATH
3927 See \`config.log' for more details" "$LINENO" 5; }
3929 # Provide some information about the compiler.
3930 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3933 for ac_option in --version -v -V -qversion; do
3934 { { ac_try="$ac_compiler $ac_option >&5"
3936 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3937 *) ac_try_echo=$ac_try;;
3939 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3940 $as_echo "$ac_try_echo"; } >&5
3941 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3943 if test -s conftest.err; then
3945 ... rest of stderr output deleted ...
3946 10q' conftest.err >conftest.er1
3947 cat conftest.er1 >&5
3949 rm -f conftest.er1 conftest.err
3950 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3951 test $ac_status = 0; }
3954 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3955 /* end confdefs.h. */
3965 ac_clean_files_save=$ac_clean_files
3966 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3967 # Try to create an executable without -o first, disregard a.out.
3968 # It will help us diagnose broken compilers, and finding out an intuition
3970 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3971 $as_echo_n "checking whether the C compiler works... " >&6; }
3972 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3974 # The possible output files:
3975 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3978 for ac_file in $ac_files
3981 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3982 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3987 if { { ac_try="$ac_link_default"
3989 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3990 *) ac_try_echo=$ac_try;;
3992 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3993 $as_echo "$ac_try_echo"; } >&5
3994 (eval "$ac_link_default") 2>&5
3996 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3997 test $ac_status = 0; }; then :
3998 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3999 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4000 # in a Makefile. We should not override ac_cv_exeext if it was cached,
4001 # so that the user can short-circuit this test for compilers unknown to
4003 for ac_file in $ac_files ''
4005 test -f "$ac_file" || continue
4007 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
4010 # We found the default executable, but exeext='' is most
4014 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
4016 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4018 # We set ac_cv_exeext here because the later test for it is not
4019 # safe: cross compilers may not add the suffix if given an `-o'
4020 # argument, so we may need to know it at that point already.
4021 # Even if this section looks crufty: it has the advantage of
4028 test "$ac_cv_exeext" = no && ac_cv_exeext=
4033 if test -z "$ac_file"; then :
4034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4035 $as_echo "no" >&6; }
4036 $as_echo "$as_me: failed program was:" >&5
4037 sed 's/^/| /' conftest.$ac_ext >&5
4039 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4040 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4041 as_fn_error 77 "C compiler cannot create executables
4042 See \`config.log' for more details" "$LINENO" 5; }
4044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4045 $as_echo "yes" >&6; }
4047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4048 $as_echo_n "checking for C compiler default output file name... " >&6; }
4049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4050 $as_echo "$ac_file" >&6; }
4051 ac_exeext=$ac_cv_exeext
4053 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
4054 ac_clean_files=$ac_clean_files_save
4055 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4056 $as_echo_n "checking for suffix of executables... " >&6; }
4057 if { { ac_try="$ac_link"
4059 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4060 *) ac_try_echo=$ac_try;;
4062 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4063 $as_echo "$ac_try_echo"; } >&5
4064 (eval "$ac_link") 2>&5
4066 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4067 test $ac_status = 0; }; then :
4068 # If both `conftest.exe' and `conftest' are `present' (well, observable)
4069 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
4070 # work properly (i.e., refer to `conftest.exe'), while it won't with
4072 for ac_file in conftest.exe conftest conftest.*; do
4073 test -f "$ac_file" || continue
4075 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4076 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4082 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4083 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4084 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
4085 See \`config.log' for more details" "$LINENO" 5; }
4087 rm -f conftest conftest$ac_cv_exeext
4088 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4089 $as_echo "$ac_cv_exeext" >&6; }
4091 rm -f conftest.$ac_ext
4092 EXEEXT=$ac_cv_exeext
4094 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4095 /* end confdefs.h. */
4100 FILE *f = fopen ("conftest.out", "w");
4101 return ferror (f) || fclose (f) != 0;
4107 ac_clean_files="$ac_clean_files conftest.out"
4108 # Check that the compiler produces executables we can run. If not, either
4109 # the compiler is broken, or we cross compile.
4110 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4111 $as_echo_n "checking whether we are cross compiling... " >&6; }
4112 if test "$cross_compiling" != yes; then
4113 { { ac_try="$ac_link"
4115 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4116 *) ac_try_echo=$ac_try;;
4118 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4119 $as_echo "$ac_try_echo"; } >&5
4120 (eval "$ac_link") 2>&5
4122 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4123 test $ac_status = 0; }
4124 if { ac_try='./conftest$ac_cv_exeext'
4125 { { case "(($ac_try" in
4126 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4127 *) ac_try_echo=$ac_try;;
4129 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4130 $as_echo "$ac_try_echo"; } >&5
4131 (eval "$ac_try") 2>&5
4133 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4134 test $ac_status = 0; }; }; then
4137 if test "$cross_compiling" = maybe; then
4140 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4141 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4142 as_fn_error $? "cannot run C compiled programs.
4143 If you meant to cross compile, use \`--host'.
4144 See \`config.log' for more details" "$LINENO" 5; }
4148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4149 $as_echo "$cross_compiling" >&6; }
4151 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4152 ac_clean_files=$ac_clean_files_save
4153 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4154 $as_echo_n "checking for suffix of object files... " >&6; }
4155 if ${ac_cv_objext+:} false; then :
4156 $as_echo_n "(cached) " >&6
4158 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4159 /* end confdefs.h. */
4169 rm -f conftest.o conftest.obj
4170 if { { ac_try="$ac_compile"
4172 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4173 *) ac_try_echo=$ac_try;;
4175 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4176 $as_echo "$ac_try_echo"; } >&5
4177 (eval "$ac_compile") 2>&5
4179 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4180 test $ac_status = 0; }; then :
4181 for ac_file in conftest.o conftest.obj conftest.*; do
4182 test -f "$ac_file" || continue;
4184 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
4185 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4190 $as_echo "$as_me: failed program was:" >&5
4191 sed 's/^/| /' conftest.$ac_ext >&5
4193 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4194 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4195 as_fn_error $? "cannot compute suffix of object files: cannot compile
4196 See \`config.log' for more details" "$LINENO" 5; }
4198 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4201 $as_echo "$ac_cv_objext" >&6; }
4202 OBJEXT=$ac_cv_objext
4204 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4205 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4206 if ${ac_cv_c_compiler_gnu+:} false; then :
4207 $as_echo_n "(cached) " >&6
4209 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4210 /* end confdefs.h. */
4223 if ac_fn_c_try_compile "$LINENO"; then :
4228 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4229 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4233 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
4234 if test $ac_compiler_gnu = yes; then
4239 ac_test_CFLAGS=${CFLAGS+set}
4240 ac_save_CFLAGS=$CFLAGS
4241 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4242 $as_echo_n "checking whether $CC accepts -g... " >&6; }
4243 if ${ac_cv_prog_cc_g+:} false; then :
4244 $as_echo_n "(cached) " >&6
4246 ac_save_c_werror_flag=$ac_c_werror_flag
4247 ac_c_werror_flag=yes
4250 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4251 /* end confdefs.h. */
4261 if ac_fn_c_try_compile "$LINENO"; then :
4265 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4266 /* end confdefs.h. */
4276 if ac_fn_c_try_compile "$LINENO"; then :
4279 ac_c_werror_flag=$ac_save_c_werror_flag
4281 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4282 /* end confdefs.h. */
4292 if ac_fn_c_try_compile "$LINENO"; then :
4295 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4297 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4299 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4300 ac_c_werror_flag=$ac_save_c_werror_flag
4302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4303 $as_echo "$ac_cv_prog_cc_g" >&6; }
4304 if test "$ac_test_CFLAGS" = set; then
4305 CFLAGS=$ac_save_CFLAGS
4306 elif test $ac_cv_prog_cc_g = yes; then
4307 if test "$GCC" = yes; then
4313 if test "$GCC" = yes; then
4319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4320 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4321 if ${ac_cv_prog_cc_c89+:} false; then :
4322 $as_echo_n "(cached) " >&6
4324 ac_cv_prog_cc_c89=no
4326 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4327 /* end confdefs.h. */
4331 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4332 struct buf { int x; };
4333 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4334 static char *e (p, i)
4340 static char *f (char * (*g) (char **, int), char **p, ...)
4345 s = g (p, va_arg (v,int));
4350 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
4351 function prototypes and stuff, but not '\xHH' hex character constants.
4352 These don't provoke an error unfortunately, instead are silently treated
4353 as 'x'. The following induces an error, until -std is added to get
4354 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
4355 array size at least. It's necessary to write '\x00'==0 to get something
4356 that's true only with -std. */
4357 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4359 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4360 inside strings and character constants. */
4362 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4364 int test (int i, double x);
4365 struct s1 {int (*f) (int a);};
4366 struct s2 {int (*f) (double a);};
4367 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4373 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4378 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4379 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4381 CC="$ac_save_CC $ac_arg"
4382 if ac_fn_c_try_compile "$LINENO"; then :
4383 ac_cv_prog_cc_c89=$ac_arg
4385 rm -f core conftest.err conftest.$ac_objext
4386 test "x$ac_cv_prog_cc_c89" != "xno" && break
4388 rm -f conftest.$ac_ext
4393 case "x$ac_cv_prog_cc_c89" in
4395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4396 $as_echo "none needed" >&6; } ;;
4398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4399 $as_echo "unsupported" >&6; } ;;
4401 CC="$CC $ac_cv_prog_cc_c89"
4402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4403 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4405 if test "x$ac_cv_prog_cc_c89" != xno; then :
4410 ac_cpp='$CPP $CPPFLAGS'
4411 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4412 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4413 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
4416 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
4417 if ${ac_cv_prog_cc_c99+:} false; then :
4418 $as_echo_n "(cached) " >&6
4420 ac_cv_prog_cc_c99=no
4422 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4423 /* end confdefs.h. */
4425 #include <stdbool.h>
4430 // Check varargs macros. These examples are taken from C99 6.10.3.5.
4431 #define debug(...) fprintf (stderr, __VA_ARGS__)
4432 #define showlist(...) puts (#__VA_ARGS__)
4433 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
4435 test_varargs_macros (void)
4440 debug ("X = %d\n", x);
4441 showlist (The first, second, and third items.);
4442 report (x>y, "x is %d but y is %d", x, y);
4445 // Check long long types.
4446 #define BIG64 18446744073709551615ull
4447 #define BIG32 4294967295ul
4448 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
4450 your preprocessor is broken;
4454 your preprocessor is broken;
4456 static long long int bignum = -9223372036854775807LL;
4457 static unsigned long long int ubignum = BIG64;
4459 struct incomplete_array
4467 const wchar_t *name;
4471 typedef const char *ccp;
4474 test_restrict (ccp restrict text)
4476 // See if C++-style comments work.
4477 // Iterate through items via the restricted pointer.
4478 // Also check for declarations in for loops.
4479 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
4484 // Check varargs and va_copy.
4486 test_varargs (const char *format, ...)
4489 va_start (args, format);
4491 va_copy (args_copy, args);
4502 str = va_arg (args_copy, const char *);
4505 number = va_arg (args_copy, int);
4508 fnumber = va_arg (args_copy, double);
4523 _Bool success = false;
4526 if (test_restrict ("String literal") == 0)
4528 char *restrict newvar = "Another string";
4531 test_varargs ("s, d' f .", "string", 65, 34.234);
4532 test_varargs_macros ();
4534 // Check flexible array members.
4535 struct incomplete_array *ia =
4536 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
4538 for (int i = 0; i < ia->datasize; ++i)
4539 ia->data[i] = i * 1.234;
4541 // Check named initializers.
4542 struct named_init ni = {
4544 .name = L"Test wide string",
4545 .average = 543.34343,
4550 int dynamic_array[ni.number];
4551 dynamic_array[ni.number - 1] = 543;
4553 // work around unused variable warnings
4554 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
4555 || dynamic_array[ni.number - 1] != 543);
4561 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc99
4563 CC="$ac_save_CC $ac_arg"
4564 if ac_fn_c_try_compile "$LINENO"; then :
4565 ac_cv_prog_cc_c99=$ac_arg
4567 rm -f core conftest.err conftest.$ac_objext
4568 test "x$ac_cv_prog_cc_c99" != "xno" && break
4570 rm -f conftest.$ac_ext
4575 case "x$ac_cv_prog_cc_c99" in
4577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4578 $as_echo "none needed" >&6; } ;;
4580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4581 $as_echo "unsupported" >&6; } ;;
4583 CC="$CC $ac_cv_prog_cc_c99"
4584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
4585 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
4587 if test "x$ac_cv_prog_cc_c99" != xno; then :
4593 # Error out if the compiler does not support C99, as the codebase
4595 if test "$ac_cv_prog_cc_c99" = no; then
4596 as_fn_error $? "C compiler \"$CC\" does not support C99" "$LINENO" 5
4600 ac_cpp='$CXXCPP $CPPFLAGS'
4601 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4602 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4603 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
4604 if test -z "$CXX"; then
4605 if test -n "$CCC"; then
4608 if test -n "$ac_tool_prefix"; then
4609 for ac_prog in $pgac_cxx_list
4611 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4612 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4613 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4614 $as_echo_n "checking for $ac_word... " >&6; }
4615 if ${ac_cv_prog_CXX+:} false; then :
4616 $as_echo_n "(cached) " >&6
4618 if test -n "$CXX"; then
4619 ac_cv_prog_CXX="$CXX" # Let the user override the test.
4621 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4625 test -z "$as_dir" && as_dir=.
4626 for ac_exec_ext in '' $ac_executable_extensions; do
4627 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4628 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
4629 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4639 if test -n "$CXX"; then
4640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
4641 $as_echo "$CXX" >&6; }
4643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4644 $as_echo "no" >&6; }
4648 test -n "$CXX" && break
4651 if test -z "$CXX"; then
4653 for ac_prog in $pgac_cxx_list
4655 # Extract the first word of "$ac_prog", so it can be a program name with args.
4656 set dummy $ac_prog; ac_word=$2
4657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4658 $as_echo_n "checking for $ac_word... " >&6; }
4659 if ${ac_cv_prog_ac_ct_CXX+:} false; then :
4660 $as_echo_n "(cached) " >&6
4662 if test -n "$ac_ct_CXX"; then
4663 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
4665 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4669 test -z "$as_dir" && as_dir=.
4670 for ac_exec_ext in '' $ac_executable_extensions; do
4671 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4672 ac_cv_prog_ac_ct_CXX="$ac_prog"
4673 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4682 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
4683 if test -n "$ac_ct_CXX"; then
4684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
4685 $as_echo "$ac_ct_CXX" >&6; }
4687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4688 $as_echo "no" >&6; }
4692 test -n "$ac_ct_CXX" && break
4695 if test "x$ac_ct_CXX" = x; then
4698 case $cross_compiling:$ac_tool_warned in
4700 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4701 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4702 ac_tool_warned=yes ;;
4710 # Provide some information about the compiler.
4711 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
4714 for ac_option in --version -v -V -qversion; do
4715 { { ac_try="$ac_compiler $ac_option >&5"
4717 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4718 *) ac_try_echo=$ac_try;;
4720 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4721 $as_echo "$ac_try_echo"; } >&5
4722 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4724 if test -s conftest.err; then
4726 ... rest of stderr output deleted ...
4727 10q' conftest.err >conftest.er1
4728 cat conftest.er1 >&5
4730 rm -f conftest.er1 conftest.err
4731 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4732 test $ac_status = 0; }
4735 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
4736 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
4737 if ${ac_cv_cxx_compiler_gnu+:} false; then :
4738 $as_echo_n "(cached) " >&6
4740 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4741 /* end confdefs.h. */
4754 if ac_fn_cxx_try_compile "$LINENO"; then :
4759 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4760 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
4763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
4764 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
4765 if test $ac_compiler_gnu = yes; then
4770 ac_test_CXXFLAGS=${CXXFLAGS+set}
4771 ac_save_CXXFLAGS=$CXXFLAGS
4772 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
4773 $as_echo_n "checking whether $CXX accepts -g... " >&6; }
4774 if ${ac_cv_prog_cxx_g+:} false; then :
4775 $as_echo_n "(cached) " >&6
4777 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
4778 ac_cxx_werror_flag=yes
4781 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4782 /* end confdefs.h. */
4792 if ac_fn_cxx_try_compile "$LINENO"; then :
4793 ac_cv_prog_cxx_g=yes
4796 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4797 /* end confdefs.h. */
4807 if ac_fn_cxx_try_compile "$LINENO"; then :
4810 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
4812 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4813 /* end confdefs.h. */
4823 if ac_fn_cxx_try_compile "$LINENO"; then :
4824 ac_cv_prog_cxx_g=yes
4826 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4828 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4830 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4831 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
4833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
4834 $as_echo "$ac_cv_prog_cxx_g" >&6; }
4835 if test "$ac_test_CXXFLAGS" = set; then
4836 CXXFLAGS=$ac_save_CXXFLAGS
4837 elif test $ac_cv_prog_cxx_g = yes; then
4838 if test "$GXX" = yes; then
4844 if test "$GXX" = yes; then
4851 ac_cpp='$CPP $CPPFLAGS'
4852 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4853 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4854 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4857 # Check if it's Intel's compiler, which (usually) pretends to be gcc,
4858 # but has idiosyncrasies of its own. We assume icc will define
4859 # __INTEL_COMPILER regardless of CFLAGS.
4861 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4862 /* end confdefs.h. */
4867 #ifndef __INTEL_COMPILER
4874 if ac_fn_c_try_compile "$LINENO"; then :
4879 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4881 # Check if it's Sun Studio compiler. We assume that
4882 # __SUNPRO_C will be defined for Sun Studio compilers
4883 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4884 /* end confdefs.h. */
4896 if ac_fn_c_try_compile "$LINENO"; then :
4901 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4909 # Checked early because subsequent tests depend on it.
4913 # Check whether --with-llvm was given.
4914 if test "${with_llvm+set}" = set; then :
4919 $as_echo "#define USE_LLVM 1" >>confdefs.h
4926 as_fn_error $? "no argument expected for --with-llvm option" "$LINENO" 5
4937 for ac_prog in gawk mawk nawk awk
4939 # Extract the first word of "$ac_prog", so it can be a program name with args.
4940 set dummy $ac_prog; ac_word=$2
4941 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4942 $as_echo_n "checking for $ac_word... " >&6; }
4943 if ${ac_cv_prog_AWK+:} false; then :
4944 $as_echo_n "(cached) " >&6
4946 if test -n "$AWK"; then
4947 ac_cv_prog_AWK="$AWK" # Let the user override the test.
4949 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4953 test -z "$as_dir" && as_dir=.
4954 for ac_exec_ext in '' $ac_executable_extensions; do
4955 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4956 ac_cv_prog_AWK="$ac_prog"
4957 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4967 if test -n "$AWK"; then
4968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
4969 $as_echo "$AWK" >&6; }
4971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4972 $as_echo "no" >&6; }
4976 test -n "$AWK" && break
4979 if test "$with_llvm" = yes; then :
4985 if test -z "$LLVM_CONFIG"; then
4986 for ac_prog in llvm-config llvm-config-7 llvm-config-6.0 llvm-config-5.0 llvm-config-4.0 llvm-config-3.9
4988 # Extract the first word of "$ac_prog", so it can be a program name with args.
4989 set dummy $ac_prog; ac_word=$2
4990 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4991 $as_echo_n "checking for $ac_word... " >&6; }
4992 if ${ac_cv_path_LLVM_CONFIG+:} false; then :
4993 $as_echo_n "(cached) " >&6
4995 case $LLVM_CONFIG in
4997 ac_cv_path_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test with a path.
5000 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5004 test -z "$as_dir" && as_dir=.
5005 for ac_exec_ext in '' $ac_executable_extensions; do
5006 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5007 ac_cv_path_LLVM_CONFIG="$as_dir/$ac_word$ac_exec_ext"
5008 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5018 LLVM_CONFIG=$ac_cv_path_LLVM_CONFIG
5019 if test -n "$LLVM_CONFIG"; then
5020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
5021 $as_echo "$LLVM_CONFIG" >&6; }
5023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5024 $as_echo "no" >&6; }
5028 test -n "$LLVM_CONFIG" && break
5032 # Report the value of LLVM_CONFIG in configure's output in all cases.
5033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LLVM_CONFIG" >&5
5034 $as_echo_n "checking for LLVM_CONFIG... " >&6; }
5035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
5036 $as_echo "$LLVM_CONFIG" >&6; }
5040 # no point continuing if llvm wasn't found
5041 if test -z "$LLVM_CONFIG"; then
5042 as_fn_error $? "llvm-config not found, but required when compiling --with-llvm, specify with LLVM_CONFIG=" "$LINENO" 5
5044 # check if detected $LLVM_CONFIG is executable
5045 pgac_llvm_version="$($LLVM_CONFIG --version 2> /dev/null || echo no)"
5046 if test "x$pgac_llvm_version" = "xno"; then
5047 as_fn_error $? "$LLVM_CONFIG does not work" "$LINENO" 5
5049 # and whether the version is supported
5050 if echo $pgac_llvm_version | $AWK -F '.' '{ if ($1 >= 4 || ($1 == 3 && $2 >= 9)) exit 1; else exit 0;}';then
5051 as_fn_error $? "$LLVM_CONFIG version is $pgac_llvm_version but at least 3.9 is required" "$LINENO" 5
5054 # need clang to create some bitcode files
5056 if test -z "$CLANG"; then
5057 for ac_prog in clang clang-7 clang-6.0 clang-5.0 clang-4.0 clang-3.9
5059 # Extract the first word of "$ac_prog", so it can be a program name with args.
5060 set dummy $ac_prog; ac_word=$2
5061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5062 $as_echo_n "checking for $ac_word... " >&6; }
5063 if ${ac_cv_path_CLANG+:} false; then :
5064 $as_echo_n "(cached) " >&6
5068 ac_cv_path_CLANG="$CLANG" # Let the user override the test with a path.
5071 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5075 test -z "$as_dir" && as_dir=.
5076 for ac_exec_ext in '' $ac_executable_extensions; do
5077 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5078 ac_cv_path_CLANG="$as_dir/$ac_word$ac_exec_ext"
5079 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5089 CLANG=$ac_cv_path_CLANG
5090 if test -n "$CLANG"; then
5091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CLANG" >&5
5092 $as_echo "$CLANG" >&6; }
5094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5095 $as_echo "no" >&6; }
5099 test -n "$CLANG" && break
5103 # Report the value of CLANG in configure's output in all cases.
5104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CLANG" >&5
5105 $as_echo_n "checking for CLANG... " >&6; }
5106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CLANG" >&5
5107 $as_echo "$CLANG" >&6; }
5110 if test -z "$CLANG"; then
5111 as_fn_error $? "clang not found, but required when compiling --with-llvm, specify with CLANG=" "$LINENO" 5
5113 # make sure clang is executable
5114 if test "x$($CLANG --version 2> /dev/null || echo no)" = "xno"; then
5115 as_fn_error $? "$CLANG does not work" "$LINENO" 5
5117 # Could check clang version, but it doesn't seem that
5118 # important. Systems with a new enough LLVM version are usually
5119 # going to have a decent clang version too. It's also not entirely
5120 # clear what the minimum version is.
5122 # Collect compiler flags necessary to build the LLVM dependent
5124 for pgac_option in `$LLVM_CONFIG --cppflags`; do
5125 case $pgac_option in
5126 -I*|-D*) LLVM_CPPFLAGS="$pgac_option $LLVM_CPPFLAGS";;
5130 for pgac_option in `$LLVM_CONFIG --ldflags`; do
5131 case $pgac_option in
5132 -L*) LDFLAGS="$LDFLAGS $pgac_option";;
5136 # ABI influencing options, standard influencing options
5137 for pgac_option in `$LLVM_CONFIG --cxxflags`; do
5138 case $pgac_option in
5139 -fno-rtti*) LLVM_CXXFLAGS="$LLVM_CXXFLAGS $pgac_option";;
5140 -std=*) LLVM_CXXFLAGS="$LLVM_CXXFLAGS $pgac_option";;
5144 # Look for components we're interested in, collect necessary
5145 # libs. As some components are optional, we can't just list all of
5146 # them as it'd raise an error.
5148 for pgac_component in `$LLVM_CONFIG --components`; do
5149 case $pgac_component in
5150 engine) pgac_components="$pgac_components $pgac_component";;
5151 debuginfodwarf) pgac_components="$pgac_components $pgac_component";;
5152 orcjit) pgac_components="$pgac_components $pgac_component";;
5153 passes) pgac_components="$pgac_components $pgac_component";;
5154 perfjitevents) pgac_components="$pgac_components $pgac_component";;
5158 # And then get the libraries that need to be linked in for the
5159 # selected components. They're large libraries, we only want to
5160 # link them into the LLVM using shared library.
5161 for pgac_option in `$LLVM_CONFIG --libs --system-libs $pgac_components`; do
5162 case $pgac_option in
5163 -l*) LLVM_LIBS="$LLVM_LIBS $pgac_option";;
5167 LLVM_BINPATH=`$LLVM_CONFIG --bindir`
5186 . "$srcdir/src/template/$template" || exit
5188 # C[XX]FLAGS are selected so:
5189 # If the user specifies something in the environment, that is used.
5190 # else: If the template file set something, that is used.
5191 # else: If coverage was enabled, don't set anything.
5192 # else: If the compiler is GCC, then we use -O2.
5193 # else: If the compiler is something else, then we use -O, unless debugging.
5195 if test "$ac_env_CFLAGS_set" = set; then
5196 CFLAGS=$ac_env_CFLAGS_value
5197 elif test "${CFLAGS+set}" = set; then
5198 : # (keep what template set)
5199 elif test "$enable_coverage" = yes; then
5200 : # no optimization by default
5201 elif test "$GCC" = yes; then
5204 # if the user selected debug mode, don't use -O
5205 if test "$enable_debug" != yes; then
5210 if test "$ac_env_CXXFLAGS_set" = set; then
5211 CXXFLAGS=$ac_env_CXXFLAGS_value
5212 elif test "${CXXFLAGS+set}" = set; then
5213 : # (keep what template set)
5214 elif test "$enable_coverage" = yes; then
5215 : # no optimization by default
5216 elif test "$GCC" = yes; then
5219 # if the user selected debug mode, don't use -O
5220 if test "$enable_debug" != yes; then
5225 # When generating bitcode (for inlining) we always want to use -O2
5226 # even when --enable-debug is specified. The bitcode it's not going to
5227 # be used for line-by-line debugging, and JIT inlining doesn't work
5228 # without at least -O1 (otherwise clang will emit 'noinline'
5229 # attributes everywhere), which is bad for testing. Still allow the
5230 # environment to override if done explicitly.
5231 if test "$ac_env_BITCODE_CFLAGS_set" = set; then
5232 BITCODE_CFLAGS=$ac_env_BITCODE_CFLAGS_value
5234 BITCODE_CFLAGS="-O2 $BITCODE_CFLAGS"
5236 if test "$ac_env_BITCODE_CXXFLAGS_set" = set; then
5237 BITCODE_CXXFLAGS=$ac_env_BITCODE_CXXFLAGS_value
5239 BITCODE_CXXFLAGS="-O2 $BITCODE_CXXFLAGS"
5242 # C[XX]FLAGS we determined above will be added back at the end
5245 user_CXXFLAGS=$CXXFLAGS
5247 user_BITCODE_CFLAGS=$BITCODE_CFLAGS
5249 user_BITCODE_CXXFLAGS=$BITCODE_CXXFLAGS
5252 # set CFLAGS_VECTOR from the environment, if available
5253 if test "$ac_env_CFLAGS_VECTOR_set" = set; then
5254 CFLAGS_VECTOR=$ac_env_CFLAGS_VECTOR_value
5257 # Some versions of GCC support some additional useful warning flags.
5258 # Check whether they are supported, and add them to CFLAGS if so.
5259 # ICC pretends to be GCC but it's lying; it doesn't support these flags,
5260 # but has its own. Also check other compiler-specific flags here.
5262 if test "$GCC" = yes -a "$ICC" = no; then
5263 CFLAGS="-Wall -Wmissing-prototypes -Wpointer-arith"
5264 CXXFLAGS="-Wall -Wpointer-arith"
5265 # These work in some but not all gcc versions
5268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wdeclaration-after-statement, for CFLAGS" >&5
5269 $as_echo_n "checking whether ${CC} supports -Wdeclaration-after-statement, for CFLAGS... " >&6; }
5270 if ${pgac_cv_prog_CC_cflags__Wdeclaration_after_statement+:} false; then :
5271 $as_echo_n "(cached) " >&6
5273 pgac_save_CFLAGS=$CFLAGS
5276 CFLAGS="${CFLAGS} -Wdeclaration-after-statement"
5277 ac_save_c_werror_flag=$ac_c_werror_flag
5278 ac_c_werror_flag=yes
5279 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5280 /* end confdefs.h. */
5290 if ac_fn_c_try_compile "$LINENO"; then :
5291 pgac_cv_prog_CC_cflags__Wdeclaration_after_statement=yes
5293 pgac_cv_prog_CC_cflags__Wdeclaration_after_statement=no
5295 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5296 ac_c_werror_flag=$ac_save_c_werror_flag
5297 CFLAGS="$pgac_save_CFLAGS"
5300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wdeclaration_after_statement" >&5
5301 $as_echo "$pgac_cv_prog_CC_cflags__Wdeclaration_after_statement" >&6; }
5302 if test x"$pgac_cv_prog_CC_cflags__Wdeclaration_after_statement" = x"yes"; then
5303 CFLAGS="${CFLAGS} -Wdeclaration-after-statement"
5307 # -Wdeclaration-after-statement isn't applicable for C++. Specific C files
5308 # disable it, so AC_SUBST the negative form.
5309 PERMIT_DECLARATION_AFTER_STATEMENT=
5310 if test x"save_$CFLAGS" != x"$CFLAGS"; then
5311 PERMIT_DECLARATION_AFTER_STATEMENT=-Wno-declaration-after-statement
5314 # Really don't want VLAs to be used in our dialect of C
5316 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Werror=vla, for CFLAGS" >&5
5317 $as_echo_n "checking whether ${CC} supports -Werror=vla, for CFLAGS... " >&6; }
5318 if ${pgac_cv_prog_CC_cflags__Werror_vla+:} false; then :
5319 $as_echo_n "(cached) " >&6
5321 pgac_save_CFLAGS=$CFLAGS
5324 CFLAGS="${CFLAGS} -Werror=vla"
5325 ac_save_c_werror_flag=$ac_c_werror_flag
5326 ac_c_werror_flag=yes
5327 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5328 /* end confdefs.h. */
5338 if ac_fn_c_try_compile "$LINENO"; then :
5339 pgac_cv_prog_CC_cflags__Werror_vla=yes
5341 pgac_cv_prog_CC_cflags__Werror_vla=no
5343 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5344 ac_c_werror_flag=$ac_save_c_werror_flag
5345 CFLAGS="$pgac_save_CFLAGS"
5348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Werror_vla" >&5
5349 $as_echo "$pgac_cv_prog_CC_cflags__Werror_vla" >&6; }
5350 if test x"$pgac_cv_prog_CC_cflags__Werror_vla" = x"yes"; then
5351 CFLAGS="${CFLAGS} -Werror=vla"
5355 # -Wvla is not applicable for C++
5357 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wendif-labels, for CFLAGS" >&5
5358 $as_echo_n "checking whether ${CC} supports -Wendif-labels, for CFLAGS... " >&6; }
5359 if ${pgac_cv_prog_CC_cflags__Wendif_labels+:} false; then :
5360 $as_echo_n "(cached) " >&6
5362 pgac_save_CFLAGS=$CFLAGS
5365 CFLAGS="${CFLAGS} -Wendif-labels"
5366 ac_save_c_werror_flag=$ac_c_werror_flag
5367 ac_c_werror_flag=yes
5368 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5369 /* end confdefs.h. */
5379 if ac_fn_c_try_compile "$LINENO"; then :
5380 pgac_cv_prog_CC_cflags__Wendif_labels=yes
5382 pgac_cv_prog_CC_cflags__Wendif_labels=no
5384 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5385 ac_c_werror_flag=$ac_save_c_werror_flag
5386 CFLAGS="$pgac_save_CFLAGS"
5389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wendif_labels" >&5
5390 $as_echo "$pgac_cv_prog_CC_cflags__Wendif_labels" >&6; }
5391 if test x"$pgac_cv_prog_CC_cflags__Wendif_labels" = x"yes"; then
5392 CFLAGS="${CFLAGS} -Wendif-labels"
5396 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -Wendif-labels, for CXXFLAGS" >&5
5397 $as_echo_n "checking whether ${CXX} supports -Wendif-labels, for CXXFLAGS... " >&6; }
5398 if ${pgac_cv_prog_CXX_cxxflags__Wendif_labels+:} false; then :
5399 $as_echo_n "(cached) " >&6
5401 pgac_save_CXXFLAGS=$CXXFLAGS
5404 CXXFLAGS="${CXXFLAGS} -Wendif-labels"
5405 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5406 ac_cxx_werror_flag=yes
5408 ac_cpp='$CXXCPP $CPPFLAGS'
5409 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5410 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5411 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5413 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5414 /* end confdefs.h. */
5424 if ac_fn_cxx_try_compile "$LINENO"; then :
5425 pgac_cv_prog_CXX_cxxflags__Wendif_labels=yes
5427 pgac_cv_prog_CXX_cxxflags__Wendif_labels=no
5429 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5431 ac_cpp='$CPP $CPPFLAGS'
5432 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5433 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5434 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5436 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5437 CXXFLAGS="$pgac_save_CXXFLAGS"
5438 CXX="$pgac_save_CXX"
5440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__Wendif_labels" >&5
5441 $as_echo "$pgac_cv_prog_CXX_cxxflags__Wendif_labels" >&6; }
5442 if test x"$pgac_cv_prog_CXX_cxxflags__Wendif_labels" = x"yes"; then
5443 CXXFLAGS="${CXXFLAGS} -Wendif-labels"
5448 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wmissing-format-attribute, for CFLAGS" >&5
5449 $as_echo_n "checking whether ${CC} supports -Wmissing-format-attribute, for CFLAGS... " >&6; }
5450 if ${pgac_cv_prog_CC_cflags__Wmissing_format_attribute+:} false; then :
5451 $as_echo_n "(cached) " >&6
5453 pgac_save_CFLAGS=$CFLAGS
5456 CFLAGS="${CFLAGS} -Wmissing-format-attribute"
5457 ac_save_c_werror_flag=$ac_c_werror_flag
5458 ac_c_werror_flag=yes
5459 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5460 /* end confdefs.h. */
5470 if ac_fn_c_try_compile "$LINENO"; then :
5471 pgac_cv_prog_CC_cflags__Wmissing_format_attribute=yes
5473 pgac_cv_prog_CC_cflags__Wmissing_format_attribute=no
5475 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5476 ac_c_werror_flag=$ac_save_c_werror_flag
5477 CFLAGS="$pgac_save_CFLAGS"
5480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wmissing_format_attribute" >&5
5481 $as_echo "$pgac_cv_prog_CC_cflags__Wmissing_format_attribute" >&6; }
5482 if test x"$pgac_cv_prog_CC_cflags__Wmissing_format_attribute" = x"yes"; then
5483 CFLAGS="${CFLAGS} -Wmissing-format-attribute"
5487 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -Wmissing-format-attribute, for CXXFLAGS" >&5
5488 $as_echo_n "checking whether ${CXX} supports -Wmissing-format-attribute, for CXXFLAGS... " >&6; }
5489 if ${pgac_cv_prog_CXX_cxxflags__Wmissing_format_attribute+:} false; then :
5490 $as_echo_n "(cached) " >&6
5492 pgac_save_CXXFLAGS=$CXXFLAGS
5495 CXXFLAGS="${CXXFLAGS} -Wmissing-format-attribute"
5496 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5497 ac_cxx_werror_flag=yes
5499 ac_cpp='$CXXCPP $CPPFLAGS'
5500 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5501 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5502 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5504 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5505 /* end confdefs.h. */
5515 if ac_fn_cxx_try_compile "$LINENO"; then :
5516 pgac_cv_prog_CXX_cxxflags__Wmissing_format_attribute=yes
5518 pgac_cv_prog_CXX_cxxflags__Wmissing_format_attribute=no
5520 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5522 ac_cpp='$CPP $CPPFLAGS'
5523 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5524 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5525 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5527 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5528 CXXFLAGS="$pgac_save_CXXFLAGS"
5529 CXX="$pgac_save_CXX"
5531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__Wmissing_format_attribute" >&5
5532 $as_echo "$pgac_cv_prog_CXX_cxxflags__Wmissing_format_attribute" >&6; }
5533 if test x"$pgac_cv_prog_CXX_cxxflags__Wmissing_format_attribute" = x"yes"; then
5534 CXXFLAGS="${CXXFLAGS} -Wmissing-format-attribute"
5538 # This was included in -Wall/-Wformat in older GCC versions
5540 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wformat-security, for CFLAGS" >&5
5541 $as_echo_n "checking whether ${CC} supports -Wformat-security, for CFLAGS... " >&6; }
5542 if ${pgac_cv_prog_CC_cflags__Wformat_security+:} false; then :
5543 $as_echo_n "(cached) " >&6
5545 pgac_save_CFLAGS=$CFLAGS
5548 CFLAGS="${CFLAGS} -Wformat-security"
5549 ac_save_c_werror_flag=$ac_c_werror_flag
5550 ac_c_werror_flag=yes
5551 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5552 /* end confdefs.h. */
5562 if ac_fn_c_try_compile "$LINENO"; then :
5563 pgac_cv_prog_CC_cflags__Wformat_security=yes
5565 pgac_cv_prog_CC_cflags__Wformat_security=no
5567 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5568 ac_c_werror_flag=$ac_save_c_werror_flag
5569 CFLAGS="$pgac_save_CFLAGS"
5572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wformat_security" >&5
5573 $as_echo "$pgac_cv_prog_CC_cflags__Wformat_security" >&6; }
5574 if test x"$pgac_cv_prog_CC_cflags__Wformat_security" = x"yes"; then
5575 CFLAGS="${CFLAGS} -Wformat-security"
5579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -Wformat-security, for CXXFLAGS" >&5
5580 $as_echo_n "checking whether ${CXX} supports -Wformat-security, for CXXFLAGS... " >&6; }
5581 if ${pgac_cv_prog_CXX_cxxflags__Wformat_security+:} false; then :
5582 $as_echo_n "(cached) " >&6
5584 pgac_save_CXXFLAGS=$CXXFLAGS
5587 CXXFLAGS="${CXXFLAGS} -Wformat-security"
5588 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5589 ac_cxx_werror_flag=yes
5591 ac_cpp='$CXXCPP $CPPFLAGS'
5592 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5593 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5594 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5597 /* end confdefs.h. */
5607 if ac_fn_cxx_try_compile "$LINENO"; then :
5608 pgac_cv_prog_CXX_cxxflags__Wformat_security=yes
5610 pgac_cv_prog_CXX_cxxflags__Wformat_security=no
5612 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5614 ac_cpp='$CPP $CPPFLAGS'
5615 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5616 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5617 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5619 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5620 CXXFLAGS="$pgac_save_CXXFLAGS"
5621 CXX="$pgac_save_CXX"
5623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__Wformat_security" >&5
5624 $as_echo "$pgac_cv_prog_CXX_cxxflags__Wformat_security" >&6; }
5625 if test x"$pgac_cv_prog_CXX_cxxflags__Wformat_security" = x"yes"; then
5626 CXXFLAGS="${CXXFLAGS} -Wformat-security"
5630 # Disable strict-aliasing rules; needed for gcc 3.3+
5632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -fno-strict-aliasing, for CFLAGS" >&5
5633 $as_echo_n "checking whether ${CC} supports -fno-strict-aliasing, for CFLAGS... " >&6; }
5634 if ${pgac_cv_prog_CC_cflags__fno_strict_aliasing+:} false; then :
5635 $as_echo_n "(cached) " >&6
5637 pgac_save_CFLAGS=$CFLAGS
5640 CFLAGS="${CFLAGS} -fno-strict-aliasing"
5641 ac_save_c_werror_flag=$ac_c_werror_flag
5642 ac_c_werror_flag=yes
5643 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5644 /* end confdefs.h. */
5654 if ac_fn_c_try_compile "$LINENO"; then :
5655 pgac_cv_prog_CC_cflags__fno_strict_aliasing=yes
5657 pgac_cv_prog_CC_cflags__fno_strict_aliasing=no
5659 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5660 ac_c_werror_flag=$ac_save_c_werror_flag
5661 CFLAGS="$pgac_save_CFLAGS"
5664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__fno_strict_aliasing" >&5
5665 $as_echo "$pgac_cv_prog_CC_cflags__fno_strict_aliasing" >&6; }
5666 if test x"$pgac_cv_prog_CC_cflags__fno_strict_aliasing" = x"yes"; then
5667 CFLAGS="${CFLAGS} -fno-strict-aliasing"
5671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -fno-strict-aliasing, for CXXFLAGS" >&5
5672 $as_echo_n "checking whether ${CXX} supports -fno-strict-aliasing, for CXXFLAGS... " >&6; }
5673 if ${pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing+:} false; then :
5674 $as_echo_n "(cached) " >&6
5676 pgac_save_CXXFLAGS=$CXXFLAGS
5679 CXXFLAGS="${CXXFLAGS} -fno-strict-aliasing"
5680 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5681 ac_cxx_werror_flag=yes
5683 ac_cpp='$CXXCPP $CPPFLAGS'
5684 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5685 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5686 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5688 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5689 /* end confdefs.h. */
5699 if ac_fn_cxx_try_compile "$LINENO"; then :
5700 pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing=yes
5702 pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing=no
5704 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5706 ac_cpp='$CPP $CPPFLAGS'
5707 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5708 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5709 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5711 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5712 CXXFLAGS="$pgac_save_CXXFLAGS"
5713 CXX="$pgac_save_CXX"
5715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing" >&5
5716 $as_echo "$pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing" >&6; }
5717 if test x"$pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing" = x"yes"; then
5718 CXXFLAGS="${CXXFLAGS} -fno-strict-aliasing"
5722 # Disable optimizations that assume no overflow; needed for gcc 4.3+
5724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -fwrapv, for CFLAGS" >&5
5725 $as_echo_n "checking whether ${CC} supports -fwrapv, for CFLAGS... " >&6; }
5726 if ${pgac_cv_prog_CC_cflags__fwrapv+:} false; then :
5727 $as_echo_n "(cached) " >&6
5729 pgac_save_CFLAGS=$CFLAGS
5732 CFLAGS="${CFLAGS} -fwrapv"
5733 ac_save_c_werror_flag=$ac_c_werror_flag
5734 ac_c_werror_flag=yes
5735 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5736 /* end confdefs.h. */
5746 if ac_fn_c_try_compile "$LINENO"; then :
5747 pgac_cv_prog_CC_cflags__fwrapv=yes
5749 pgac_cv_prog_CC_cflags__fwrapv=no
5751 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5752 ac_c_werror_flag=$ac_save_c_werror_flag
5753 CFLAGS="$pgac_save_CFLAGS"
5756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__fwrapv" >&5
5757 $as_echo "$pgac_cv_prog_CC_cflags__fwrapv" >&6; }
5758 if test x"$pgac_cv_prog_CC_cflags__fwrapv" = x"yes"; then
5759 CFLAGS="${CFLAGS} -fwrapv"
5763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -fwrapv, for CXXFLAGS" >&5
5764 $as_echo_n "checking whether ${CXX} supports -fwrapv, for CXXFLAGS... " >&6; }
5765 if ${pgac_cv_prog_CXX_cxxflags__fwrapv+:} false; then :
5766 $as_echo_n "(cached) " >&6
5768 pgac_save_CXXFLAGS=$CXXFLAGS
5771 CXXFLAGS="${CXXFLAGS} -fwrapv"
5772 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5773 ac_cxx_werror_flag=yes
5775 ac_cpp='$CXXCPP $CPPFLAGS'
5776 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5777 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5778 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5780 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5781 /* end confdefs.h. */
5791 if ac_fn_cxx_try_compile "$LINENO"; then :
5792 pgac_cv_prog_CXX_cxxflags__fwrapv=yes
5794 pgac_cv_prog_CXX_cxxflags__fwrapv=no
5796 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5798 ac_cpp='$CPP $CPPFLAGS'
5799 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5800 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5801 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5803 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5804 CXXFLAGS="$pgac_save_CXXFLAGS"
5805 CXX="$pgac_save_CXX"
5807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__fwrapv" >&5
5808 $as_echo "$pgac_cv_prog_CXX_cxxflags__fwrapv" >&6; }
5809 if test x"$pgac_cv_prog_CXX_cxxflags__fwrapv" = x"yes"; then
5810 CXXFLAGS="${CXXFLAGS} -fwrapv"
5814 # Disable FP optimizations that cause various errors on gcc 4.5+ or maybe 4.6+
5816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -fexcess-precision=standard, for CFLAGS" >&5
5817 $as_echo_n "checking whether ${CC} supports -fexcess-precision=standard, for CFLAGS... " >&6; }
5818 if ${pgac_cv_prog_CC_cflags__fexcess_precision_standard+:} false; then :
5819 $as_echo_n "(cached) " >&6
5821 pgac_save_CFLAGS=$CFLAGS
5824 CFLAGS="${CFLAGS} -fexcess-precision=standard"
5825 ac_save_c_werror_flag=$ac_c_werror_flag
5826 ac_c_werror_flag=yes
5827 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5828 /* end confdefs.h. */
5838 if ac_fn_c_try_compile "$LINENO"; then :
5839 pgac_cv_prog_CC_cflags__fexcess_precision_standard=yes
5841 pgac_cv_prog_CC_cflags__fexcess_precision_standard=no
5843 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5844 ac_c_werror_flag=$ac_save_c_werror_flag
5845 CFLAGS="$pgac_save_CFLAGS"
5848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__fexcess_precision_standard" >&5
5849 $as_echo "$pgac_cv_prog_CC_cflags__fexcess_precision_standard" >&6; }
5850 if test x"$pgac_cv_prog_CC_cflags__fexcess_precision_standard" = x"yes"; then
5851 CFLAGS="${CFLAGS} -fexcess-precision=standard"
5855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -fexcess-precision=standard, for CXXFLAGS" >&5
5856 $as_echo_n "checking whether ${CXX} supports -fexcess-precision=standard, for CXXFLAGS... " >&6; }
5857 if ${pgac_cv_prog_CXX_cxxflags__fexcess_precision_standard+:} false; then :
5858 $as_echo_n "(cached) " >&6
5860 pgac_save_CXXFLAGS=$CXXFLAGS
5863 CXXFLAGS="${CXXFLAGS} -fexcess-precision=standard"
5864 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5865 ac_cxx_werror_flag=yes
5867 ac_cpp='$CXXCPP $CPPFLAGS'
5868 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5869 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5870 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5872 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5873 /* end confdefs.h. */
5883 if ac_fn_cxx_try_compile "$LINENO"; then :
5884 pgac_cv_prog_CXX_cxxflags__fexcess_precision_standard=yes
5886 pgac_cv_prog_CXX_cxxflags__fexcess_precision_standard=no
5888 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5890 ac_cpp='$CPP $CPPFLAGS'
5891 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5892 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5893 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5895 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5896 CXXFLAGS="$pgac_save_CXXFLAGS"
5897 CXX="$pgac_save_CXX"
5899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__fexcess_precision_standard" >&5
5900 $as_echo "$pgac_cv_prog_CXX_cxxflags__fexcess_precision_standard" >&6; }
5901 if test x"$pgac_cv_prog_CXX_cxxflags__fexcess_precision_standard" = x"yes"; then
5902 CXXFLAGS="${CXXFLAGS} -fexcess-precision=standard"
5906 # Optimization flags for specific files that benefit from vectorization
5907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -funroll-loops, for CFLAGS_VECTOR" >&5
5908 $as_echo_n "checking whether ${CC} supports -funroll-loops, for CFLAGS_VECTOR... " >&6; }
5909 if ${pgac_cv_prog_CC_cflags__funroll_loops+:} false; then :
5910 $as_echo_n "(cached) " >&6
5912 pgac_save_CFLAGS=$CFLAGS
5915 CFLAGS="${CFLAGS_VECTOR} -funroll-loops"
5916 ac_save_c_werror_flag=$ac_c_werror_flag
5917 ac_c_werror_flag=yes
5918 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5919 /* end confdefs.h. */
5929 if ac_fn_c_try_compile "$LINENO"; then :
5930 pgac_cv_prog_CC_cflags__funroll_loops=yes
5932 pgac_cv_prog_CC_cflags__funroll_loops=no
5934 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5935 ac_c_werror_flag=$ac_save_c_werror_flag
5936 CFLAGS="$pgac_save_CFLAGS"
5939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__funroll_loops" >&5
5940 $as_echo "$pgac_cv_prog_CC_cflags__funroll_loops" >&6; }
5941 if test x"$pgac_cv_prog_CC_cflags__funroll_loops" = x"yes"; then
5942 CFLAGS_VECTOR="${CFLAGS_VECTOR} -funroll-loops"
5946 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -ftree-vectorize, for CFLAGS_VECTOR" >&5
5947 $as_echo_n "checking whether ${CC} supports -ftree-vectorize, for CFLAGS_VECTOR... " >&6; }
5948 if ${pgac_cv_prog_CC_cflags__ftree_vectorize+:} false; then :
5949 $as_echo_n "(cached) " >&6
5951 pgac_save_CFLAGS=$CFLAGS
5954 CFLAGS="${CFLAGS_VECTOR} -ftree-vectorize"
5955 ac_save_c_werror_flag=$ac_c_werror_flag
5956 ac_c_werror_flag=yes
5957 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5958 /* end confdefs.h. */
5968 if ac_fn_c_try_compile "$LINENO"; then :
5969 pgac_cv_prog_CC_cflags__ftree_vectorize=yes
5971 pgac_cv_prog_CC_cflags__ftree_vectorize=no
5973 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5974 ac_c_werror_flag=$ac_save_c_werror_flag
5975 CFLAGS="$pgac_save_CFLAGS"
5978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__ftree_vectorize" >&5
5979 $as_echo "$pgac_cv_prog_CC_cflags__ftree_vectorize" >&6; }
5980 if test x"$pgac_cv_prog_CC_cflags__ftree_vectorize" = x"yes"; then
5981 CFLAGS_VECTOR="${CFLAGS_VECTOR} -ftree-vectorize"
5985 # We want to suppress clang's unhelpful unused-command-line-argument warnings
5986 # but gcc won't complain about unrecognized -Wno-foo switches, so we have to
5987 # test for the positive form and if that works, add the negative form
5989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wunused-command-line-argument, for NOT_THE_CFLAGS" >&5
5990 $as_echo_n "checking whether ${CC} supports -Wunused-command-line-argument, for NOT_THE_CFLAGS... " >&6; }
5991 if ${pgac_cv_prog_CC_cflags__Wunused_command_line_argument+:} false; then :
5992 $as_echo_n "(cached) " >&6
5994 pgac_save_CFLAGS=$CFLAGS
5997 CFLAGS="${NOT_THE_CFLAGS} -Wunused-command-line-argument"
5998 ac_save_c_werror_flag=$ac_c_werror_flag
5999 ac_c_werror_flag=yes
6000 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6001 /* end confdefs.h. */
6011 if ac_fn_c_try_compile "$LINENO"; then :
6012 pgac_cv_prog_CC_cflags__Wunused_command_line_argument=yes
6014 pgac_cv_prog_CC_cflags__Wunused_command_line_argument=no
6016 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6017 ac_c_werror_flag=$ac_save_c_werror_flag
6018 CFLAGS="$pgac_save_CFLAGS"
6021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wunused_command_line_argument" >&5
6022 $as_echo "$pgac_cv_prog_CC_cflags__Wunused_command_line_argument" >&6; }
6023 if test x"$pgac_cv_prog_CC_cflags__Wunused_command_line_argument" = x"yes"; then
6024 NOT_THE_CFLAGS="${NOT_THE_CFLAGS} -Wunused-command-line-argument"
6028 if test -n "$NOT_THE_CFLAGS"; then
6029 CFLAGS="$CFLAGS -Wno-unused-command-line-argument"
6031 # Similarly disable useless truncation warnings from gcc 8+
6033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wformat-truncation, for NOT_THE_CFLAGS" >&5
6034 $as_echo_n "checking whether ${CC} supports -Wformat-truncation, for NOT_THE_CFLAGS... " >&6; }
6035 if ${pgac_cv_prog_CC_cflags__Wformat_truncation+:} false; then :
6036 $as_echo_n "(cached) " >&6
6038 pgac_save_CFLAGS=$CFLAGS
6041 CFLAGS="${NOT_THE_CFLAGS} -Wformat-truncation"
6042 ac_save_c_werror_flag=$ac_c_werror_flag
6043 ac_c_werror_flag=yes
6044 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6045 /* end confdefs.h. */
6055 if ac_fn_c_try_compile "$LINENO"; then :
6056 pgac_cv_prog_CC_cflags__Wformat_truncation=yes
6058 pgac_cv_prog_CC_cflags__Wformat_truncation=no
6060 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6061 ac_c_werror_flag=$ac_save_c_werror_flag
6062 CFLAGS="$pgac_save_CFLAGS"
6065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wformat_truncation" >&5
6066 $as_echo "$pgac_cv_prog_CC_cflags__Wformat_truncation" >&6; }
6067 if test x"$pgac_cv_prog_CC_cflags__Wformat_truncation" = x"yes"; then
6068 NOT_THE_CFLAGS="${NOT_THE_CFLAGS} -Wformat-truncation"
6072 if test -n "$NOT_THE_CFLAGS"; then
6073 CFLAGS="$CFLAGS -Wno-format-truncation"
6076 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wstringop-truncation, for NOT_THE_CFLAGS" >&5
6077 $as_echo_n "checking whether ${CC} supports -Wstringop-truncation, for NOT_THE_CFLAGS... " >&6; }
6078 if ${pgac_cv_prog_CC_cflags__Wstringop_truncation+:} false; then :
6079 $as_echo_n "(cached) " >&6
6081 pgac_save_CFLAGS=$CFLAGS
6084 CFLAGS="${NOT_THE_CFLAGS} -Wstringop-truncation"
6085 ac_save_c_werror_flag=$ac_c_werror_flag
6086 ac_c_werror_flag=yes
6087 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6088 /* end confdefs.h. */
6098 if ac_fn_c_try_compile "$LINENO"; then :
6099 pgac_cv_prog_CC_cflags__Wstringop_truncation=yes
6101 pgac_cv_prog_CC_cflags__Wstringop_truncation=no
6103 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6104 ac_c_werror_flag=$ac_save_c_werror_flag
6105 CFLAGS="$pgac_save_CFLAGS"
6108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wstringop_truncation" >&5
6109 $as_echo "$pgac_cv_prog_CC_cflags__Wstringop_truncation" >&6; }
6110 if test x"$pgac_cv_prog_CC_cflags__Wstringop_truncation" = x"yes"; then
6111 NOT_THE_CFLAGS="${NOT_THE_CFLAGS} -Wstringop-truncation"
6115 if test -n "$NOT_THE_CFLAGS"; then
6116 CFLAGS="$CFLAGS -Wno-stringop-truncation"
6118 elif test "$ICC" = yes; then
6119 # Intel's compiler has a bug/misoptimization in checking for
6120 # division by NAN (NaN == 0), -mp1 fixes it, so add it to the CFLAGS.
6122 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -mp1, for CFLAGS" >&5
6123 $as_echo_n "checking whether ${CC} supports -mp1, for CFLAGS... " >&6; }
6124 if ${pgac_cv_prog_CC_cflags__mp1+:} false; then :
6125 $as_echo_n "(cached) " >&6
6127 pgac_save_CFLAGS=$CFLAGS
6130 CFLAGS="${CFLAGS} -mp1"
6131 ac_save_c_werror_flag=$ac_c_werror_flag
6132 ac_c_werror_flag=yes
6133 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6134 /* end confdefs.h. */
6144 if ac_fn_c_try_compile "$LINENO"; then :
6145 pgac_cv_prog_CC_cflags__mp1=yes
6147 pgac_cv_prog_CC_cflags__mp1=no
6149 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6150 ac_c_werror_flag=$ac_save_c_werror_flag
6151 CFLAGS="$pgac_save_CFLAGS"
6154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__mp1" >&5
6155 $as_echo "$pgac_cv_prog_CC_cflags__mp1" >&6; }
6156 if test x"$pgac_cv_prog_CC_cflags__mp1" = x"yes"; then
6157 CFLAGS="${CFLAGS} -mp1"
6161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -mp1, for CXXFLAGS" >&5
6162 $as_echo_n "checking whether ${CXX} supports -mp1, for CXXFLAGS... " >&6; }
6163 if ${pgac_cv_prog_CXX_cxxflags__mp1+:} false; then :
6164 $as_echo_n "(cached) " >&6
6166 pgac_save_CXXFLAGS=$CXXFLAGS
6169 CXXFLAGS="${CXXFLAGS} -mp1"
6170 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6171 ac_cxx_werror_flag=yes
6173 ac_cpp='$CXXCPP $CPPFLAGS'
6174 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6175 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6176 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6178 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6179 /* end confdefs.h. */
6189 if ac_fn_cxx_try_compile "$LINENO"; then :
6190 pgac_cv_prog_CXX_cxxflags__mp1=yes
6192 pgac_cv_prog_CXX_cxxflags__mp1=no
6194 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6196 ac_cpp='$CPP $CPPFLAGS'
6197 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6198 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6199 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6201 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6202 CXXFLAGS="$pgac_save_CXXFLAGS"
6203 CXX="$pgac_save_CXX"
6205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__mp1" >&5
6206 $as_echo "$pgac_cv_prog_CXX_cxxflags__mp1" >&6; }
6207 if test x"$pgac_cv_prog_CXX_cxxflags__mp1" = x"yes"; then
6208 CXXFLAGS="${CXXFLAGS} -mp1"
6212 # Make sure strict aliasing is off (though this is said to be the default)
6214 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -fno-strict-aliasing, for CFLAGS" >&5
6215 $as_echo_n "checking whether ${CC} supports -fno-strict-aliasing, for CFLAGS... " >&6; }
6216 if ${pgac_cv_prog_CC_cflags__fno_strict_aliasing+:} false; then :
6217 $as_echo_n "(cached) " >&6
6219 pgac_save_CFLAGS=$CFLAGS
6222 CFLAGS="${CFLAGS} -fno-strict-aliasing"
6223 ac_save_c_werror_flag=$ac_c_werror_flag
6224 ac_c_werror_flag=yes
6225 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6226 /* end confdefs.h. */
6236 if ac_fn_c_try_compile "$LINENO"; then :
6237 pgac_cv_prog_CC_cflags__fno_strict_aliasing=yes
6239 pgac_cv_prog_CC_cflags__fno_strict_aliasing=no
6241 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6242 ac_c_werror_flag=$ac_save_c_werror_flag
6243 CFLAGS="$pgac_save_CFLAGS"
6246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__fno_strict_aliasing" >&5
6247 $as_echo "$pgac_cv_prog_CC_cflags__fno_strict_aliasing" >&6; }
6248 if test x"$pgac_cv_prog_CC_cflags__fno_strict_aliasing" = x"yes"; then
6249 CFLAGS="${CFLAGS} -fno-strict-aliasing"
6253 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -fno-strict-aliasing, for CXXFLAGS" >&5
6254 $as_echo_n "checking whether ${CXX} supports -fno-strict-aliasing, for CXXFLAGS... " >&6; }
6255 if ${pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing+:} false; then :
6256 $as_echo_n "(cached) " >&6
6258 pgac_save_CXXFLAGS=$CXXFLAGS
6261 CXXFLAGS="${CXXFLAGS} -fno-strict-aliasing"
6262 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6263 ac_cxx_werror_flag=yes
6265 ac_cpp='$CXXCPP $CPPFLAGS'
6266 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6267 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6268 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6270 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6271 /* end confdefs.h. */
6281 if ac_fn_cxx_try_compile "$LINENO"; then :
6282 pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing=yes
6284 pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing=no
6286 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6288 ac_cpp='$CPP $CPPFLAGS'
6289 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6290 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6291 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6293 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6294 CXXFLAGS="$pgac_save_CXXFLAGS"
6295 CXX="$pgac_save_CXX"
6297 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing" >&5
6298 $as_echo "$pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing" >&6; }
6299 if test x"$pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing" = x"yes"; then
6300 CXXFLAGS="${CXXFLAGS} -fno-strict-aliasing"
6304 elif test "$PORTNAME" = "aix"; then
6305 # AIX's xlc has to have strict aliasing turned off too
6307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -qnoansialias, for CFLAGS" >&5
6308 $as_echo_n "checking whether ${CC} supports -qnoansialias, for CFLAGS... " >&6; }
6309 if ${pgac_cv_prog_CC_cflags__qnoansialias+:} false; then :
6310 $as_echo_n "(cached) " >&6
6312 pgac_save_CFLAGS=$CFLAGS
6315 CFLAGS="${CFLAGS} -qnoansialias"
6316 ac_save_c_werror_flag=$ac_c_werror_flag
6317 ac_c_werror_flag=yes
6318 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6319 /* end confdefs.h. */
6329 if ac_fn_c_try_compile "$LINENO"; then :
6330 pgac_cv_prog_CC_cflags__qnoansialias=yes
6332 pgac_cv_prog_CC_cflags__qnoansialias=no
6334 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6335 ac_c_werror_flag=$ac_save_c_werror_flag
6336 CFLAGS="$pgac_save_CFLAGS"
6339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__qnoansialias" >&5
6340 $as_echo "$pgac_cv_prog_CC_cflags__qnoansialias" >&6; }
6341 if test x"$pgac_cv_prog_CC_cflags__qnoansialias" = x"yes"; then
6342 CFLAGS="${CFLAGS} -qnoansialias"
6346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -qnoansialias, for CXXFLAGS" >&5
6347 $as_echo_n "checking whether ${CXX} supports -qnoansialias, for CXXFLAGS... " >&6; }
6348 if ${pgac_cv_prog_CXX_cxxflags__qnoansialias+:} false; then :
6349 $as_echo_n "(cached) " >&6
6351 pgac_save_CXXFLAGS=$CXXFLAGS
6354 CXXFLAGS="${CXXFLAGS} -qnoansialias"
6355 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6356 ac_cxx_werror_flag=yes
6358 ac_cpp='$CXXCPP $CPPFLAGS'
6359 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6360 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6361 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6363 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6364 /* end confdefs.h. */
6374 if ac_fn_cxx_try_compile "$LINENO"; then :
6375 pgac_cv_prog_CXX_cxxflags__qnoansialias=yes
6377 pgac_cv_prog_CXX_cxxflags__qnoansialias=no
6379 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6381 ac_cpp='$CPP $CPPFLAGS'
6382 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6383 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6384 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6386 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6387 CXXFLAGS="$pgac_save_CXXFLAGS"
6388 CXX="$pgac_save_CXX"
6390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__qnoansialias" >&5
6391 $as_echo "$pgac_cv_prog_CXX_cxxflags__qnoansialias" >&6; }
6392 if test x"$pgac_cv_prog_CXX_cxxflags__qnoansialias" = x"yes"; then
6393 CXXFLAGS="${CXXFLAGS} -qnoansialias"
6398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -qlonglong, for CFLAGS" >&5
6399 $as_echo_n "checking whether ${CC} supports -qlonglong, for CFLAGS... " >&6; }
6400 if ${pgac_cv_prog_CC_cflags__qlonglong+:} false; then :
6401 $as_echo_n "(cached) " >&6
6403 pgac_save_CFLAGS=$CFLAGS
6406 CFLAGS="${CFLAGS} -qlonglong"
6407 ac_save_c_werror_flag=$ac_c_werror_flag
6408 ac_c_werror_flag=yes
6409 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6410 /* end confdefs.h. */
6420 if ac_fn_c_try_compile "$LINENO"; then :
6421 pgac_cv_prog_CC_cflags__qlonglong=yes
6423 pgac_cv_prog_CC_cflags__qlonglong=no
6425 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6426 ac_c_werror_flag=$ac_save_c_werror_flag
6427 CFLAGS="$pgac_save_CFLAGS"
6430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__qlonglong" >&5
6431 $as_echo "$pgac_cv_prog_CC_cflags__qlonglong" >&6; }
6432 if test x"$pgac_cv_prog_CC_cflags__qlonglong" = x"yes"; then
6433 CFLAGS="${CFLAGS} -qlonglong"
6437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -qlonglong, for CXXFLAGS" >&5
6438 $as_echo_n "checking whether ${CXX} supports -qlonglong, for CXXFLAGS... " >&6; }
6439 if ${pgac_cv_prog_CXX_cxxflags__qlonglong+:} false; then :
6440 $as_echo_n "(cached) " >&6
6442 pgac_save_CXXFLAGS=$CXXFLAGS
6445 CXXFLAGS="${CXXFLAGS} -qlonglong"
6446 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6447 ac_cxx_werror_flag=yes
6449 ac_cpp='$CXXCPP $CPPFLAGS'
6450 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6451 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6452 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6454 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6455 /* end confdefs.h. */
6465 if ac_fn_cxx_try_compile "$LINENO"; then :
6466 pgac_cv_prog_CXX_cxxflags__qlonglong=yes
6468 pgac_cv_prog_CXX_cxxflags__qlonglong=no
6470 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6472 ac_cpp='$CPP $CPPFLAGS'
6473 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6474 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6475 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6477 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6478 CXXFLAGS="$pgac_save_CXXFLAGS"
6479 CXX="$pgac_save_CXX"
6481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__qlonglong" >&5
6482 $as_echo "$pgac_cv_prog_CXX_cxxflags__qlonglong" >&6; }
6483 if test x"$pgac_cv_prog_CXX_cxxflags__qlonglong" = x"yes"; then
6484 CXXFLAGS="${CXXFLAGS} -qlonglong"
6488 elif test "$PORTNAME" = "hpux"; then
6489 # On some versions of HP-UX, libm functions do not set errno by default.
6490 # Fix that by using +Olibmerrno if the compiler recognizes it.
6492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports +Olibmerrno, for CFLAGS" >&5
6493 $as_echo_n "checking whether ${CC} supports +Olibmerrno, for CFLAGS... " >&6; }
6494 if ${pgac_cv_prog_CC_cflags_pOlibmerrno+:} false; then :
6495 $as_echo_n "(cached) " >&6
6497 pgac_save_CFLAGS=$CFLAGS
6500 CFLAGS="${CFLAGS} +Olibmerrno"
6501 ac_save_c_werror_flag=$ac_c_werror_flag
6502 ac_c_werror_flag=yes
6503 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6504 /* end confdefs.h. */
6514 if ac_fn_c_try_compile "$LINENO"; then :
6515 pgac_cv_prog_CC_cflags_pOlibmerrno=yes
6517 pgac_cv_prog_CC_cflags_pOlibmerrno=no
6519 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6520 ac_c_werror_flag=$ac_save_c_werror_flag
6521 CFLAGS="$pgac_save_CFLAGS"
6524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags_pOlibmerrno" >&5
6525 $as_echo "$pgac_cv_prog_CC_cflags_pOlibmerrno" >&6; }
6526 if test x"$pgac_cv_prog_CC_cflags_pOlibmerrno" = x"yes"; then
6527 CFLAGS="${CFLAGS} +Olibmerrno"
6531 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports +Olibmerrno, for CXXFLAGS" >&5
6532 $as_echo_n "checking whether ${CXX} supports +Olibmerrno, for CXXFLAGS... " >&6; }
6533 if ${pgac_cv_prog_CXX_cxxflags_pOlibmerrno+:} false; then :
6534 $as_echo_n "(cached) " >&6
6536 pgac_save_CXXFLAGS=$CXXFLAGS
6539 CXXFLAGS="${CXXFLAGS} +Olibmerrno"
6540 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6541 ac_cxx_werror_flag=yes
6543 ac_cpp='$CXXCPP $CPPFLAGS'
6544 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6545 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6546 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6548 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6549 /* end confdefs.h. */
6559 if ac_fn_cxx_try_compile "$LINENO"; then :
6560 pgac_cv_prog_CXX_cxxflags_pOlibmerrno=yes
6562 pgac_cv_prog_CXX_cxxflags_pOlibmerrno=no
6564 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6566 ac_cpp='$CPP $CPPFLAGS'
6567 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6568 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6569 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6571 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6572 CXXFLAGS="$pgac_save_CXXFLAGS"
6573 CXX="$pgac_save_CXX"
6575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags_pOlibmerrno" >&5
6576 $as_echo "$pgac_cv_prog_CXX_cxxflags_pOlibmerrno" >&6; }
6577 if test x"$pgac_cv_prog_CXX_cxxflags_pOlibmerrno" = x"yes"; then
6578 CXXFLAGS="${CXXFLAGS} +Olibmerrno"
6584 CFLAGS_VECTOR=$CFLAGS_VECTOR
6587 # Determine flags used to emit bitcode for JIT inlining. Need to test
6588 # for behaviour changing compiler flags, to keep compatibility with
6589 # compiler used for normal postgres code.
6590 if test "$with_llvm" = yes ; then
6591 CLANGXX="$CLANG -xc++"
6593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CLANG} supports -fno-strict-aliasing, for BITCODE_CFLAGS" >&5
6594 $as_echo_n "checking whether ${CLANG} supports -fno-strict-aliasing, for BITCODE_CFLAGS... " >&6; }
6595 if ${pgac_cv_prog_CLANG_cflags__fno_strict_aliasing+:} false; then :
6596 $as_echo_n "(cached) " >&6
6598 pgac_save_CFLAGS=$CFLAGS
6601 CFLAGS="${BITCODE_CFLAGS} -fno-strict-aliasing"
6602 ac_save_c_werror_flag=$ac_c_werror_flag
6603 ac_c_werror_flag=yes
6604 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6605 /* end confdefs.h. */
6615 if ac_fn_c_try_compile "$LINENO"; then :
6616 pgac_cv_prog_CLANG_cflags__fno_strict_aliasing=yes
6618 pgac_cv_prog_CLANG_cflags__fno_strict_aliasing=no
6620 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6621 ac_c_werror_flag=$ac_save_c_werror_flag
6622 CFLAGS="$pgac_save_CFLAGS"
6625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CLANG_cflags__fno_strict_aliasing" >&5
6626 $as_echo "$pgac_cv_prog_CLANG_cflags__fno_strict_aliasing" >&6; }
6627 if test x"$pgac_cv_prog_CLANG_cflags__fno_strict_aliasing" = x"yes"; then
6628 BITCODE_CFLAGS="${BITCODE_CFLAGS} -fno-strict-aliasing"
6631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CLANGXX} supports -fno-strict-aliasing, for BITCODE_CXXFLAGS" >&5
6632 $as_echo_n "checking whether ${CLANGXX} supports -fno-strict-aliasing, for BITCODE_CXXFLAGS... " >&6; }
6633 if ${pgac_cv_prog_CLANGXX_cxxflags__fno_strict_aliasing+:} false; then :
6634 $as_echo_n "(cached) " >&6
6636 pgac_save_CXXFLAGS=$CXXFLAGS
6639 CXXFLAGS="${BITCODE_CXXFLAGS} -fno-strict-aliasing"
6640 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6641 ac_cxx_werror_flag=yes
6643 ac_cpp='$CXXCPP $CPPFLAGS'
6644 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6645 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6646 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6648 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6649 /* end confdefs.h. */
6659 if ac_fn_cxx_try_compile "$LINENO"; then :
6660 pgac_cv_prog_CLANGXX_cxxflags__fno_strict_aliasing=yes
6662 pgac_cv_prog_CLANGXX_cxxflags__fno_strict_aliasing=no
6664 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6666 ac_cpp='$CPP $CPPFLAGS'
6667 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6668 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6669 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6671 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6672 CXXFLAGS="$pgac_save_CXXFLAGS"
6673 CXX="$pgac_save_CXX"
6675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CLANGXX_cxxflags__fno_strict_aliasing" >&5
6676 $as_echo "$pgac_cv_prog_CLANGXX_cxxflags__fno_strict_aliasing" >&6; }
6677 if test x"$pgac_cv_prog_CLANGXX_cxxflags__fno_strict_aliasing" = x"yes"; then
6678 BITCODE_CXXFLAGS="${BITCODE_CXXFLAGS} -fno-strict-aliasing"
6681 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CLANG} supports -fwrapv, for BITCODE_CFLAGS" >&5
6682 $as_echo_n "checking whether ${CLANG} supports -fwrapv, for BITCODE_CFLAGS... " >&6; }
6683 if ${pgac_cv_prog_CLANG_cflags__fwrapv+:} false; then :
6684 $as_echo_n "(cached) " >&6
6686 pgac_save_CFLAGS=$CFLAGS
6689 CFLAGS="${BITCODE_CFLAGS} -fwrapv"
6690 ac_save_c_werror_flag=$ac_c_werror_flag
6691 ac_c_werror_flag=yes
6692 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6693 /* end confdefs.h. */
6703 if ac_fn_c_try_compile "$LINENO"; then :
6704 pgac_cv_prog_CLANG_cflags__fwrapv=yes
6706 pgac_cv_prog_CLANG_cflags__fwrapv=no
6708 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6709 ac_c_werror_flag=$ac_save_c_werror_flag
6710 CFLAGS="$pgac_save_CFLAGS"
6713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CLANG_cflags__fwrapv" >&5
6714 $as_echo "$pgac_cv_prog_CLANG_cflags__fwrapv" >&6; }
6715 if test x"$pgac_cv_prog_CLANG_cflags__fwrapv" = x"yes"; then
6716 BITCODE_CFLAGS="${BITCODE_CFLAGS} -fwrapv"
6719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CLANGXX} supports -fwrapv, for BITCODE_CXXFLAGS" >&5
6720 $as_echo_n "checking whether ${CLANGXX} supports -fwrapv, for BITCODE_CXXFLAGS... " >&6; }
6721 if ${pgac_cv_prog_CLANGXX_cxxflags__fwrapv+:} false; then :
6722 $as_echo_n "(cached) " >&6
6724 pgac_save_CXXFLAGS=$CXXFLAGS
6727 CXXFLAGS="${BITCODE_CXXFLAGS} -fwrapv"
6728 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6729 ac_cxx_werror_flag=yes
6731 ac_cpp='$CXXCPP $CPPFLAGS'
6732 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6733 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6734 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6736 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6737 /* end confdefs.h. */
6747 if ac_fn_cxx_try_compile "$LINENO"; then :
6748 pgac_cv_prog_CLANGXX_cxxflags__fwrapv=yes
6750 pgac_cv_prog_CLANGXX_cxxflags__fwrapv=no
6752 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6754 ac_cpp='$CPP $CPPFLAGS'
6755 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6756 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6757 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6759 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6760 CXXFLAGS="$pgac_save_CXXFLAGS"
6761 CXX="$pgac_save_CXX"
6763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CLANGXX_cxxflags__fwrapv" >&5
6764 $as_echo "$pgac_cv_prog_CLANGXX_cxxflags__fwrapv" >&6; }
6765 if test x"$pgac_cv_prog_CLANGXX_cxxflags__fwrapv" = x"yes"; then
6766 BITCODE_CXXFLAGS="${BITCODE_CXXFLAGS} -fwrapv"
6769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CLANG} supports -fexcess-precision=standard, for BITCODE_CFLAGS" >&5
6770 $as_echo_n "checking whether ${CLANG} supports -fexcess-precision=standard, for BITCODE_CFLAGS... " >&6; }
6771 if ${pgac_cv_prog_CLANG_cflags__fexcess_precision_standard+:} false; then :
6772 $as_echo_n "(cached) " >&6
6774 pgac_save_CFLAGS=$CFLAGS
6777 CFLAGS="${BITCODE_CFLAGS} -fexcess-precision=standard"
6778 ac_save_c_werror_flag=$ac_c_werror_flag
6779 ac_c_werror_flag=yes
6780 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6781 /* end confdefs.h. */
6791 if ac_fn_c_try_compile "$LINENO"; then :
6792 pgac_cv_prog_CLANG_cflags__fexcess_precision_standard=yes
6794 pgac_cv_prog_CLANG_cflags__fexcess_precision_standard=no
6796 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6797 ac_c_werror_flag=$ac_save_c_werror_flag
6798 CFLAGS="$pgac_save_CFLAGS"
6801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CLANG_cflags__fexcess_precision_standard" >&5
6802 $as_echo "$pgac_cv_prog_CLANG_cflags__fexcess_precision_standard" >&6; }
6803 if test x"$pgac_cv_prog_CLANG_cflags__fexcess_precision_standard" = x"yes"; then
6804 BITCODE_CFLAGS="${BITCODE_CFLAGS} -fexcess-precision=standard"
6807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CLANGXX} supports -fexcess-precision=standard, for BITCODE_CXXFLAGS" >&5
6808 $as_echo_n "checking whether ${CLANGXX} supports -fexcess-precision=standard, for BITCODE_CXXFLAGS... " >&6; }
6809 if ${pgac_cv_prog_CLANGXX_cxxflags__fexcess_precision_standard+:} false; then :
6810 $as_echo_n "(cached) " >&6
6812 pgac_save_CXXFLAGS=$CXXFLAGS
6815 CXXFLAGS="${BITCODE_CXXFLAGS} -fexcess-precision=standard"
6816 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6817 ac_cxx_werror_flag=yes
6819 ac_cpp='$CXXCPP $CPPFLAGS'
6820 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6821 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6822 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6824 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6825 /* end confdefs.h. */
6835 if ac_fn_cxx_try_compile "$LINENO"; then :
6836 pgac_cv_prog_CLANGXX_cxxflags__fexcess_precision_standard=yes
6838 pgac_cv_prog_CLANGXX_cxxflags__fexcess_precision_standard=no
6840 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6842 ac_cpp='$CPP $CPPFLAGS'
6843 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6844 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6845 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6847 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6848 CXXFLAGS="$pgac_save_CXXFLAGS"
6849 CXX="$pgac_save_CXX"
6851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CLANGXX_cxxflags__fexcess_precision_standard" >&5
6852 $as_echo "$pgac_cv_prog_CLANGXX_cxxflags__fexcess_precision_standard" >&6; }
6853 if test x"$pgac_cv_prog_CLANGXX_cxxflags__fexcess_precision_standard" = x"yes"; then
6854 BITCODE_CXXFLAGS="${BITCODE_CXXFLAGS} -fexcess-precision=standard"
6859 # supply -g if --enable-debug
6860 if test "$enable_debug" = yes && test "$ac_cv_prog_cc_g" = yes; then
6864 if test "$enable_debug" = yes && test "$ac_cv_prog_cxx_g" = yes; then
6865 CXXFLAGS="$CXXFLAGS -g"
6868 # enable code coverage if --enable-coverage
6869 if test "$enable_coverage" = yes; then
6870 if test "$GCC" = yes; then
6871 CFLAGS="$CFLAGS -fprofile-arcs -ftest-coverage"
6872 CXXFLAGS="$CXXFLAGS -fprofile-arcs -ftest-coverage"
6874 as_fn_error $? "--enable-coverage is supported only when using GCC" "$LINENO" 5
6878 # enable profiling if --enable-profiling
6879 if test "$enable_profiling" = yes && test "$ac_cv_prog_cc_g" = yes; then
6880 if test "$GCC" = yes; then
6882 $as_echo "#define PROFILE_PID_DIR 1" >>confdefs.h
6884 CFLAGS="$CFLAGS -pg $PLATFORM_PROFILE_FLAGS"
6885 CXXFLAGS="$CXXFLAGS -pg $PLATFORM_PROFILE_FLAGS"
6887 as_fn_error $? "--enable-profiling is supported only when using GCC" "$LINENO" 5
6891 # We already have this in Makefile.win32, but configure needs it too
6892 if test "$PORTNAME" = "win32"; then
6893 CPPFLAGS="$CPPFLAGS -I$srcdir/src/include/port/win32 -DEXEC_BACKEND"
6896 # Now that we're done automatically adding stuff to C[XX]FLAGS, put back the
6897 # user-specified flags (if any) at the end. This lets users override
6898 # the automatic additions.
6899 CFLAGS="$CFLAGS $user_CFLAGS"
6900 CXXFLAGS="$CXXFLAGS $user_CXXFLAGS"
6901 BITCODE_CFLAGS="$BITCODE_CFLAGS $user_BITCODE_CFLAGS"
6902 BITCODE_CXXFLAGS="$BITCODE_CXXFLAGS $user_BITCODE_CXXFLAGS"
6904 BITCODE_CFLAGS=$BITCODE_CFLAGS
6906 BITCODE_CXXFLAGS=$BITCODE_CXXFLAGS
6909 # Check if the compiler still works with the final flag settings
6910 # (note, we're not checking that for CXX, which is optional)
6911 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler still works" >&5
6912 $as_echo_n "checking whether the C compiler still works... " >&6; }
6913 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6914 /* end confdefs.h. */
6924 if ac_fn_c_try_link "$LINENO"; then :
6925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6926 $as_echo "yes" >&6; }
6928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6929 $as_echo "no" >&6; }
6930 as_fn_error $? "cannot proceed" "$LINENO" 5
6932 rm -f core conftest.err conftest.$ac_objext \
6933 conftest$ac_exeext conftest.$ac_ext
6935 # Defend against gcc -ffast-math
6936 if test "$GCC" = yes; then
6937 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6938 /* end confdefs.h. */
6943 #ifdef __FAST_MATH__
6950 if ac_fn_c_try_compile "$LINENO"; then :
6953 as_fn_error $? "do not put -ffast-math in CFLAGS" "$LINENO" 5
6955 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6958 # Defend against clang being used on x86-32 without SSE2 enabled. As current
6959 # versions of clang do not understand -fexcess-precision=standard, the use of
6960 # x87 floating point operations leads to problems like isinf possibly returning
6961 # false for a value that is infinite when converted from the 80bit register to
6962 # the 8byte memory representation.
6964 # Only perform the test if the compiler doesn't understand
6965 # -fexcess-precision=standard, that way a potentially fixed compiler will work
6967 if test "$pgac_cv_prog_CC_cflags__fexcess_precision_standard" = no; then
6968 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6969 /* end confdefs.h. */
6975 #if defined(__clang__) && defined(__i386__) && !defined(__SSE2_MATH__)
6983 if ac_fn_c_try_compile "$LINENO"; then :
6986 as_fn_error $? "Compiling PostgreSQL with clang, on 32bit x86, requires SSE2 support. Use -msse2 or use gcc." "$LINENO" 5
6988 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6992 ac_cpp='$CPP $CPPFLAGS'
6993 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6994 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6995 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
6997 $as_echo_n "checking how to run the C preprocessor... " >&6; }
6998 # On Suns, sometimes $CPP names a directory.
6999 if test -n "$CPP" && test -d "$CPP"; then
7002 if test -z "$CPP"; then
7003 if ${ac_cv_prog_CPP+:} false; then :
7004 $as_echo_n "(cached) " >&6
7006 # Double quotes because CPP needs to be expanded
7007 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
7010 for ac_c_preproc_warn_flag in '' yes
7012 # Use a header file that comes with gcc, so configuring glibc
7013 # with a fresh cross-compiler works.
7014 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
7015 # <limits.h> exists even on freestanding compilers.
7016 # On the NeXT, cc -E runs the code through the compiler's parser,
7017 # not just through cpp. "Syntax error" is here to catch this case.
7018 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7019 /* end confdefs.h. */
7021 # include <limits.h>
7023 # include <assert.h>
7027 if ac_fn_c_try_cpp "$LINENO"; then :
7030 # Broken: fails on valid input.
7033 rm -f conftest.err conftest.i conftest.$ac_ext
7035 # OK, works on sane cases. Now check whether nonexistent headers
7036 # can be detected and how.
7037 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7038 /* end confdefs.h. */
7039 #include <ac_nonexistent.h>
7041 if ac_fn_c_try_cpp "$LINENO"; then :
7042 # Broken: success on invalid input.
7045 # Passes both tests.
7049 rm -f conftest.err conftest.i conftest.$ac_ext
7052 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
7053 rm -f conftest.i conftest.err conftest.$ac_ext
7054 if $ac_preproc_ok; then :
7066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
7067 $as_echo "$CPP" >&6; }
7069 for ac_c_preproc_warn_flag in '' yes
7071 # Use a header file that comes with gcc, so configuring glibc
7072 # with a fresh cross-compiler works.
7073 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
7074 # <limits.h> exists even on freestanding compilers.
7075 # On the NeXT, cc -E runs the code through the compiler's parser,
7076 # not just through cpp. "Syntax error" is here to catch this case.
7077 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7078 /* end confdefs.h. */
7080 # include <limits.h>
7082 # include <assert.h>
7086 if ac_fn_c_try_cpp "$LINENO"; then :
7089 # Broken: fails on valid input.
7092 rm -f conftest.err conftest.i conftest.$ac_ext
7094 # OK, works on sane cases. Now check whether nonexistent headers
7095 # can be detected and how.
7096 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7097 /* end confdefs.h. */
7098 #include <ac_nonexistent.h>
7100 if ac_fn_c_try_cpp "$LINENO"; then :
7101 # Broken: success on invalid input.
7104 # Passes both tests.
7108 rm -f conftest.err conftest.i conftest.$ac_ext
7111 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
7112 rm -f conftest.i conftest.err conftest.$ac_ext
7113 if $ac_preproc_ok; then :
7116 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
7117 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
7118 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
7119 See \`config.log' for more details" "$LINENO" 5; }
7123 ac_cpp='$CPP $CPPFLAGS'
7124 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7125 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7126 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7132 # Set up TAS assembly code if needed; the template file has now had its
7133 # chance to request this.
7135 ac_config_links="$ac_config_links src/backend/port/tas.s:src/backend/port/tas/${tas_file}"
7138 if test "$need_tas" = yes ; then
7147 # Automatic dependency tracking
7151 # Check whether --enable-depend was given.
7152 if test "${enable_depend+set}" = set; then :
7153 enableval=$enable_depend;
7162 as_fn_error $? "no argument expected for --enable-depend option" "$LINENO" 5
7176 # Enable assert checks
7180 # Check whether --enable-cassert was given.
7181 if test "${enable_cassert+set}" = set; then :
7182 enableval=$enable_cassert;
7186 $as_echo "#define USE_ASSERT_CHECKING 1" >>confdefs.h
7193 as_fn_error $? "no argument expected for --enable-cassert option" "$LINENO" 5
7206 # Include directories
7209 IFS="${IFS}${PATH_SEPARATOR}"
7210 # SRCH_INC comes from the template file
7211 for dir in $with_includes $SRCH_INC; do
7212 if test -d "$dir"; then
7213 INCLUDES="$INCLUDES -I$dir"
7215 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** Include directory $dir does not exist." >&5
7216 $as_echo "$as_me: WARNING: *** Include directory $dir does not exist." >&2;}
7224 # Library directories
7227 IFS="${IFS}${PATH_SEPARATOR}"
7228 # LIBRARY_DIRS comes from command line, SRCH_LIB from template file.
7229 for dir in $LIBRARY_DIRS $SRCH_LIB; do
7230 if test -d "$dir"; then
7231 LIBDIRS="$LIBDIRS -L$dir"
7233 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** Library directory $dir does not exist." >&5
7234 $as_echo "$as_me: WARNING: *** Library directory $dir does not exist." >&2;}
7240 # Enable thread-safe client libraries
7242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking allow thread-safe client libraries" >&5
7243 $as_echo_n "checking allow thread-safe client libraries... " >&6; }
7246 # Check whether --enable-thread-safety was given.
7247 if test "${enable_thread_safety+set}" = set; then :
7248 enableval=$enable_thread_safety;
7257 as_fn_error $? "no argument expected for --enable-thread-safety option" "$LINENO" 5
7262 enable_thread_safety=yes
7267 if test "$enable_thread_safety" = yes; then
7269 $as_echo "#define ENABLE_THREAD_SAFETY 1" >>confdefs.h
7272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_thread_safety" >&5
7273 $as_echo "$enable_thread_safety" >&6; }
7279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with ICU support" >&5
7280 $as_echo_n "checking whether to build with ICU support... " >&6; }
7284 # Check whether --with-icu was given.
7285 if test "${with_icu+set}" = set; then :
7290 $as_echo "#define USE_ICU 1" >>confdefs.h
7297 as_fn_error $? "no argument expected for --with-icu option" "$LINENO" 5
7307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_icu" >&5
7308 $as_echo "$with_icu" >&6; }
7311 if test "$with_icu" = yes; then
7319 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
7320 if test -n "$ac_tool_prefix"; then
7321 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
7322 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
7323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7324 $as_echo_n "checking for $ac_word... " >&6; }
7325 if ${ac_cv_path_PKG_CONFIG+:} false; then :
7326 $as_echo_n "(cached) " >&6
7330 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
7333 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7337 test -z "$as_dir" && as_dir=.
7338 for ac_exec_ext in '' $ac_executable_extensions; do
7339 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7340 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
7341 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7351 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
7352 if test -n "$PKG_CONFIG"; then
7353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
7354 $as_echo "$PKG_CONFIG" >&6; }
7356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7357 $as_echo "no" >&6; }
7362 if test -z "$ac_cv_path_PKG_CONFIG"; then
7363 ac_pt_PKG_CONFIG=$PKG_CONFIG
7364 # Extract the first word of "pkg-config", so it can be a program name with args.
7365 set dummy pkg-config; ac_word=$2
7366 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7367 $as_echo_n "checking for $ac_word... " >&6; }
7368 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
7369 $as_echo_n "(cached) " >&6
7371 case $ac_pt_PKG_CONFIG in
7373 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
7376 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7380 test -z "$as_dir" && as_dir=.
7381 for ac_exec_ext in '' $ac_executable_extensions; do
7382 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7383 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
7384 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7394 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
7395 if test -n "$ac_pt_PKG_CONFIG"; then
7396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
7397 $as_echo "$ac_pt_PKG_CONFIG" >&6; }
7399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7400 $as_echo "no" >&6; }
7403 if test "x$ac_pt_PKG_CONFIG" = x; then
7406 case $cross_compiling:$ac_tool_warned in
7408 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7409 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7410 ac_tool_warned=yes ;;
7412 PKG_CONFIG=$ac_pt_PKG_CONFIG
7415 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
7419 if test -n "$PKG_CONFIG"; then
7420 _pkg_min_version=0.9.0
7421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
7422 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
7423 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
7424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7425 $as_echo "yes" >&6; }
7427 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7428 $as_echo "no" >&6; }
7434 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icu-uc icu-i18n" >&5
7435 $as_echo_n "checking for icu-uc icu-i18n... " >&6; }
7437 if test -n "$ICU_CFLAGS"; then
7438 pkg_cv_ICU_CFLAGS="$ICU_CFLAGS"
7439 elif test -n "$PKG_CONFIG"; then
7440 if test -n "$PKG_CONFIG" && \
7441 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"icu-uc icu-i18n\""; } >&5
7442 ($PKG_CONFIG --exists --print-errors "icu-uc icu-i18n") 2>&5
7444 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7445 test $ac_status = 0; }; then
7446 pkg_cv_ICU_CFLAGS=`$PKG_CONFIG --cflags "icu-uc icu-i18n" 2>/dev/null`
7447 test "x$?" != "x0" && pkg_failed=yes
7454 if test -n "$ICU_LIBS"; then
7455 pkg_cv_ICU_LIBS="$ICU_LIBS"
7456 elif test -n "$PKG_CONFIG"; then
7457 if test -n "$PKG_CONFIG" && \
7458 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"icu-uc icu-i18n\""; } >&5
7459 ($PKG_CONFIG --exists --print-errors "icu-uc icu-i18n") 2>&5
7461 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7462 test $ac_status = 0; }; then
7463 pkg_cv_ICU_LIBS=`$PKG_CONFIG --libs "icu-uc icu-i18n" 2>/dev/null`
7464 test "x$?" != "x0" && pkg_failed=yes
7474 if test $pkg_failed = yes; then
7475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7476 $as_echo "no" >&6; }
7478 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
7479 _pkg_short_errors_supported=yes
7481 _pkg_short_errors_supported=no
7483 if test $_pkg_short_errors_supported = yes; then
7484 ICU_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "icu-uc icu-i18n" 2>&1`
7486 ICU_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "icu-uc icu-i18n" 2>&1`
7488 # Put the nasty error message in config.log where it belongs
7489 echo "$ICU_PKG_ERRORS" >&5
7491 as_fn_error $? "Package requirements (icu-uc icu-i18n) were not met:
7495 Consider adjusting the PKG_CONFIG_PATH environment variable if you
7496 installed software in a non-standard prefix.
7498 Alternatively, you may set the environment variables ICU_CFLAGS
7499 and ICU_LIBS to avoid the need to call pkg-config.
7500 See the pkg-config man page for more details." "$LINENO" 5
7501 elif test $pkg_failed = untried; then
7502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7503 $as_echo "no" >&6; }
7504 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
7505 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
7506 as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it
7507 is in your PATH or set the PKG_CONFIG environment variable to the full
7510 Alternatively, you may set the environment variables ICU_CFLAGS
7511 and ICU_LIBS to avoid the need to call pkg-config.
7512 See the pkg-config man page for more details.
7514 To get pkg-config, see <http://pkg-config.freedesktop.org/>.
7515 See \`config.log' for more details" "$LINENO" 5; }
7517 ICU_CFLAGS=$pkg_cv_ICU_CFLAGS
7518 ICU_LIBS=$pkg_cv_ICU_LIBS
7519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7520 $as_echo "yes" >&6; }
7526 # Optionally build Tcl modules (PL/Tcl)
7528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with Tcl" >&5
7529 $as_echo_n "checking whether to build with Tcl... " >&6; }
7533 # Check whether --with-tcl was given.
7534 if test "${with_tcl+set}" = set; then :
7544 as_fn_error $? "no argument expected for --with-tcl option" "$LINENO" 5
7554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_tcl" >&5
7555 $as_echo "$with_tcl" >&6; }
7558 # We see if the path to the Tcl/Tk configuration scripts is specified.
7559 # This will override the use of tclsh to find the paths to search.
7564 # Check whether --with-tclconfig was given.
7565 if test "${with_tclconfig+set}" = set; then :
7566 withval=$with_tclconfig;
7569 as_fn_error $? "argument required for --with-tclconfig option" "$LINENO" 5
7572 as_fn_error $? "argument required for --with-tclconfig option" "$LINENO" 5
7584 # Optionally build Perl modules (PL/Perl)
7586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build Perl modules" >&5
7587 $as_echo_n "checking whether to build Perl modules... " >&6; }
7591 # Check whether --with-perl was given.
7592 if test "${with_perl+set}" = set; then :
7602 as_fn_error $? "no argument expected for --with-perl option" "$LINENO" 5
7612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_perl" >&5
7613 $as_echo "$with_perl" >&6; }
7617 # Optionally build Python modules (PL/Python)
7619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build Python modules" >&5
7620 $as_echo_n "checking whether to build Python modules... " >&6; }
7624 # Check whether --with-python was given.
7625 if test "${with_python+set}" = set; then :
7626 withval=$with_python;
7635 as_fn_error $? "no argument expected for --with-python option" "$LINENO" 5
7645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_python" >&5
7646 $as_echo "$with_python" >&6; }
7652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with GSSAPI support" >&5
7653 $as_echo_n "checking whether to build with GSSAPI support... " >&6; }
7657 # Check whether --with-gssapi was given.
7658 if test "${with_gssapi+set}" = set; then :
7659 withval=$with_gssapi;
7664 $as_echo "#define ENABLE_GSS 1" >>confdefs.h
7666 krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
7673 as_fn_error $? "no argument expected for --with-gssapi option" "$LINENO" 5
7683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_gssapi" >&5
7684 $as_echo "$with_gssapi" >&6; }
7692 # Kerberos configuration parameters
7697 # Check whether --with-krb-srvnam was given.
7698 if test "${with_krb_srvnam+set}" = set; then :
7699 withval=$with_krb_srvnam;
7702 as_fn_error $? "argument required for --with-krb-srvnam option" "$LINENO" 5
7705 as_fn_error $? "argument required for --with-krb-srvnam option" "$LINENO" 5
7713 with_krb_srvnam="postgres"
7719 cat >>confdefs.h <<_ACEOF
7720 #define PG_KRB_SRVNAM "$with_krb_srvnam"
7728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with PAM support" >&5
7729 $as_echo_n "checking whether to build with PAM support... " >&6; }
7733 # Check whether --with-pam was given.
7734 if test "${with_pam+set}" = set; then :
7739 $as_echo "#define USE_PAM 1" >>confdefs.h
7746 as_fn_error $? "no argument expected for --with-pam option" "$LINENO" 5
7756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_pam" >&5
7757 $as_echo "$with_pam" >&6; }
7763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with BSD Authentication support" >&5
7764 $as_echo_n "checking whether to build with BSD Authentication support... " >&6; }
7768 # Check whether --with-bsd-auth was given.
7769 if test "${with_bsd_auth+set}" = set; then :
7770 withval=$with_bsd_auth;
7774 $as_echo "#define USE_BSD_AUTH 1" >>confdefs.h
7781 as_fn_error $? "no argument expected for --with-bsd-auth option" "$LINENO" 5
7791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_bsd_auth" >&5
7792 $as_echo "$with_bsd_auth" >&6; }
7798 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with LDAP support" >&5
7799 $as_echo_n "checking whether to build with LDAP support... " >&6; }
7803 # Check whether --with-ldap was given.
7804 if test "${with_ldap+set}" = set; then :
7809 $as_echo "#define USE_LDAP 1" >>confdefs.h
7816 as_fn_error $? "no argument expected for --with-ldap option" "$LINENO" 5
7826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_ldap" >&5
7827 $as_echo "$with_ldap" >&6; }
7834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with Bonjour support" >&5
7835 $as_echo_n "checking whether to build with Bonjour support... " >&6; }
7839 # Check whether --with-bonjour was given.
7840 if test "${with_bonjour+set}" = set; then :
7841 withval=$with_bonjour;
7845 $as_echo "#define USE_BONJOUR 1" >>confdefs.h
7852 as_fn_error $? "no argument expected for --with-bonjour option" "$LINENO" 5
7862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_bonjour" >&5
7863 $as_echo "$with_bonjour" >&6; }
7869 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with OpenSSL support" >&5
7870 $as_echo_n "checking whether to build with OpenSSL support... " >&6; }
7874 # Check whether --with-openssl was given.
7875 if test "${with_openssl+set}" = set; then :
7876 withval=$with_openssl;
7880 $as_echo "#define USE_OPENSSL 1" >>confdefs.h
7887 as_fn_error $? "no argument expected for --with-openssl option" "$LINENO" 5
7897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_openssl" >&5
7898 $as_echo "$with_openssl" >&6; }
7904 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with SELinux support" >&5
7905 $as_echo_n "checking whether to build with SELinux support... " >&6; }
7909 # Check whether --with-selinux was given.
7910 if test "${with_selinux+set}" = set; then :
7911 withval=$with_selinux;
7920 as_fn_error $? "no argument expected for --with-selinux option" "$LINENO" 5
7931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_selinux" >&5
7932 $as_echo "$with_selinux" >&6; }
7937 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with systemd support" >&5
7938 $as_echo_n "checking whether to build with systemd support... " >&6; }
7942 # Check whether --with-systemd was given.
7943 if test "${with_systemd+set}" = set; then :
7944 withval=$with_systemd;
7948 $as_echo "#define USE_SYSTEMD 1" >>confdefs.h
7955 as_fn_error $? "no argument expected for --with-systemd option" "$LINENO" 5
7966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_systemd" >&5
7967 $as_echo "$with_systemd" >&6; }
7975 # Check whether --with-readline was given.
7976 if test "${with_readline+set}" = set; then :
7977 withval=$with_readline;
7986 as_fn_error $? "no argument expected for --with-readline option" "$LINENO" 5
7996 # readline on MinGW has problems with backslashes in psql and other bugs.
7997 # This is particularly a problem with non-US code pages.
7998 # Therefore disable its use until we understand the cause. 2004-07-20
7999 if test "$PORTNAME" = "win32"; then
8000 if test "$with_readline" = yes; then
8001 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** Readline does not work on MinGW --- disabling" >&5
8002 $as_echo "$as_me: WARNING: *** Readline does not work on MinGW --- disabling" >&2;}
8014 # Check whether --with-libedit-preferred was given.
8015 if test "${with_libedit_preferred+set}" = set; then :
8016 withval=$with_libedit_preferred;
8025 as_fn_error $? "no argument expected for --with-libedit-preferred option" "$LINENO" 5
8030 with_libedit_preferred=no
8040 # There are at least three UUID libraries in common use: the FreeBSD/NetBSD
8041 # library, the e2fsprogs libuuid (now part of util-linux-ng), and the OSSP
8042 # UUID library. More than one of these might be present on a given platform,
8043 # so we make the user say which one she wants.
8048 # Check whether --with-uuid was given.
8049 if test "${with_uuid+set}" = set; then :
8053 as_fn_error $? "argument required for --with-uuid option" "$LINENO" 5
8056 as_fn_error $? "argument required for --with-uuid option" "$LINENO" 5
8066 if test x"$with_uuid" = x"" ; then
8072 # Check whether --with-ossp-uuid was given.
8073 if test "${with_ossp_uuid+set}" = set; then :
8074 withval=$with_ossp_uuid;
8083 as_fn_error $? "no argument expected for --with-ossp-uuid option" "$LINENO" 5
8093 if test "$with_ossp_uuid" = yes ; then
8097 if test "$with_uuid" = bsd ; then
8099 $as_echo "#define HAVE_UUID_BSD 1" >>confdefs.h
8101 UUID_EXTRA_OBJS="md5.o sha1.o"
8102 elif test "$with_uuid" = e2fs ; then
8104 $as_echo "#define HAVE_UUID_E2FS 1" >>confdefs.h
8106 UUID_EXTRA_OBJS="md5.o sha1.o"
8107 elif test "$with_uuid" = ossp ; then
8109 $as_echo "#define HAVE_UUID_OSSP 1" >>confdefs.h
8112 elif test "$with_uuid" = no ; then
8115 as_fn_error $? "--with-uuid must specify one of bsd, e2fs, or ossp" "$LINENO" 5
8127 # Check whether --with-libxml was given.
8128 if test "${with_libxml+set}" = set; then :
8129 withval=$with_libxml;
8133 $as_echo "#define USE_LIBXML 1" >>confdefs.h
8140 as_fn_error $? "no argument expected for --with-libxml option" "$LINENO" 5
8151 if test "$with_libxml" = yes ; then
8152 if test -z "$XML2_CONFIG"; then
8153 for ac_prog in xml2-config
8155 # Extract the first word of "$ac_prog", so it can be a program name with args.
8156 set dummy $ac_prog; ac_word=$2
8157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8158 $as_echo_n "checking for $ac_word... " >&6; }
8159 if ${ac_cv_path_XML2_CONFIG+:} false; then :
8160 $as_echo_n "(cached) " >&6
8162 case $XML2_CONFIG in
8164 ac_cv_path_XML2_CONFIG="$XML2_CONFIG" # Let the user override the test with a path.
8167 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8171 test -z "$as_dir" && as_dir=.
8172 for ac_exec_ext in '' $ac_executable_extensions; do
8173 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8174 ac_cv_path_XML2_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8175 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8185 XML2_CONFIG=$ac_cv_path_XML2_CONFIG
8186 if test -n "$XML2_CONFIG"; then
8187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XML2_CONFIG" >&5
8188 $as_echo "$XML2_CONFIG" >&6; }
8190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8191 $as_echo "no" >&6; }
8195 test -n "$XML2_CONFIG" && break
8199 # Report the value of XML2_CONFIG in configure's output in all cases.
8200 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XML2_CONFIG" >&5
8201 $as_echo_n "checking for XML2_CONFIG... " >&6; }
8202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XML2_CONFIG" >&5
8203 $as_echo "$XML2_CONFIG" >&6; }
8206 if test -n "$XML2_CONFIG"; then
8207 for pgac_option in `$XML2_CONFIG --cflags`; do
8208 case $pgac_option in
8209 -I*|-D*) CPPFLAGS="$CPPFLAGS $pgac_option";;
8212 for pgac_option in `$XML2_CONFIG --libs`; do
8213 case $pgac_option in
8214 -L*) LDFLAGS="$LDFLAGS $pgac_option";;
8228 # Check whether --with-libxslt was given.
8229 if test "${with_libxslt+set}" = set; then :
8230 withval=$with_libxslt;
8234 $as_echo "#define USE_LIBXSLT 1" >>confdefs.h
8241 as_fn_error $? "no argument expected for --with-libxslt option" "$LINENO" 5
8261 # Check whether --with-system-tzdata was given.
8262 if test "${with_system_tzdata+set}" = set; then :
8263 withval=$with_system_tzdata;
8266 as_fn_error $? "argument required for --with-system-tzdata option" "$LINENO" 5
8269 as_fn_error $? "argument required for --with-system-tzdata option" "$LINENO" 5
8287 # Check whether --with-zlib was given.
8288 if test "${with_zlib+set}" = set; then :
8298 as_fn_error $? "no argument expected for --with-zlib option" "$LINENO" 5
8314 # Assume system is ELF if it predefines __ELF__ as 1,
8315 # otherwise believe host_os based default.
8317 freebsd1*|freebsd2*) elf=no;;
8318 freebsd3*|freebsd4*) elf=yes;;
8322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
8323 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
8324 if ${ac_cv_path_GREP+:} false; then :
8325 $as_echo_n "(cached) " >&6
8327 if test -z "$GREP"; then
8328 ac_path_GREP_found=false
8329 # Loop through the user's path and test for each of PROGNAME-LIST
8330 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8331 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
8334 test -z "$as_dir" && as_dir=.
8335 for ac_prog in grep ggrep; do
8336 for ac_exec_ext in '' $ac_executable_extensions; do
8337 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
8338 as_fn_executable_p "$ac_path_GREP" || continue
8339 # Check for GNU ac_path_GREP and select it if it is found.
8340 # Check for GNU $ac_path_GREP
8341 case `"$ac_path_GREP" --version 2>&1` in
8343 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
8346 $as_echo_n 0123456789 >"conftest.in"
8349 cat "conftest.in" "conftest.in" >"conftest.tmp"
8350 mv "conftest.tmp" "conftest.in"
8351 cp "conftest.in" "conftest.nl"
8352 $as_echo 'GREP' >> "conftest.nl"
8353 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
8354 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
8355 as_fn_arith $ac_count + 1 && ac_count=$as_val
8356 if test $ac_count -gt ${ac_path_GREP_max-0}; then
8357 # Best one so far, save it but keep looking for a better one
8358 ac_cv_path_GREP="$ac_path_GREP"
8359 ac_path_GREP_max=$ac_count
8361 # 10*(2^10) chars as input seems more than enough
8362 test $ac_count -gt 10 && break
8364 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
8367 $ac_path_GREP_found && break 3
8372 if test -z "$ac_cv_path_GREP"; then
8373 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
8376 ac_cv_path_GREP=$GREP
8380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
8381 $as_echo "$ac_cv_path_GREP" >&6; }
8382 GREP="$ac_cv_path_GREP"
8385 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
8386 $as_echo_n "checking for egrep... " >&6; }
8387 if ${ac_cv_path_EGREP+:} false; then :
8388 $as_echo_n "(cached) " >&6
8390 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
8391 then ac_cv_path_EGREP="$GREP -E"
8393 if test -z "$EGREP"; then
8394 ac_path_EGREP_found=false
8395 # Loop through the user's path and test for each of PROGNAME-LIST
8396 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8397 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
8400 test -z "$as_dir" && as_dir=.
8401 for ac_prog in egrep; do
8402 for ac_exec_ext in '' $ac_executable_extensions; do
8403 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
8404 as_fn_executable_p "$ac_path_EGREP" || continue
8405 # Check for GNU ac_path_EGREP and select it if it is found.
8406 # Check for GNU $ac_path_EGREP
8407 case `"$ac_path_EGREP" --version 2>&1` in
8409 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
8412 $as_echo_n 0123456789 >"conftest.in"
8415 cat "conftest.in" "conftest.in" >"conftest.tmp"
8416 mv "conftest.tmp" "conftest.in"
8417 cp "conftest.in" "conftest.nl"
8418 $as_echo 'EGREP' >> "conftest.nl"
8419 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
8420 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
8421 as_fn_arith $ac_count + 1 && ac_count=$as_val
8422 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
8423 # Best one so far, save it but keep looking for a better one
8424 ac_cv_path_EGREP="$ac_path_EGREP"
8425 ac_path_EGREP_max=$ac_count
8427 # 10*(2^10) chars as input seems more than enough
8428 test $ac_count -gt 10 && break
8430 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
8433 $ac_path_EGREP_found && break 3
8438 if test -z "$ac_cv_path_EGREP"; then
8439 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
8442 ac_cv_path_EGREP=$EGREP
8447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
8448 $as_echo "$ac_cv_path_EGREP" >&6; }
8449 EGREP="$ac_cv_path_EGREP"
8452 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8453 /* end confdefs.h. */
8459 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8460 $EGREP "yes" >/dev/null 2>&1; then :
8463 if test "X$elf" = "Xyes" ; then
8477 CPPFLAGS="$CPPFLAGS $INCLUDES"
8478 LDFLAGS="$LDFLAGS $LIBDIRS"
8484 # Check whether --with-gnu-ld was given.
8485 if test "${with_gnu_ld+set}" = set; then :
8486 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
8492 if test "$GCC" = yes; then
8493 # Check if gcc -print-prog-name=ld gives a path.
8494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
8495 $as_echo_n "checking for ld used by GCC... " >&6; }
8498 # gcc leaves a trailing carriage return which upsets mingw
8499 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
8501 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
8504 # Accept absolute paths.
8505 [\\/]* | [A-Za-z]:[\\/]*)
8506 re_direlt='/[^/][^/]*/\.\./'
8507 # Canonicalize the path of ld
8508 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
8509 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
8510 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
8512 test -z "$LD" && LD="$ac_prog"
8515 # If it fails, then pretend we aren't using GCC.
8519 # If it is relative, then search for the first ld in PATH.
8523 elif test "$with_gnu_ld" = yes; then
8524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
8525 $as_echo_n "checking for GNU ld... " >&6; }
8527 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
8528 $as_echo_n "checking for non-GNU ld... " >&6; }
8530 if ${ac_cv_path_LD+:} false; then :
8531 $as_echo_n "(cached) " >&6
8533 if test -z "$LD"; then
8534 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
8535 for ac_dir in $PATH; do
8536 test -z "$ac_dir" && ac_dir=.
8537 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
8538 ac_cv_path_LD="$ac_dir/$ac_prog"
8539 # Check to see if the program is GNU ld. I'd rather use --version,
8540 # but apparently some GNU ld's only accept -v.
8541 # Break only if it was the GNU/non-GNU ld that we prefer.
8542 if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
8543 test "$with_gnu_ld" != no && break
8545 test "$with_gnu_ld" != yes && break
8551 ac_cv_path_LD="$LD" # Let the user override the test with a path.
8556 if test -n "$LD"; then
8557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
8558 $as_echo "$LD" >&6; }
8560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8561 $as_echo "no" >&6; }
8563 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
8564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
8565 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
8566 if ${ac_cv_prog_gnu_ld+:} false; then :
8567 $as_echo_n "(cached) " >&6
8569 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
8570 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
8571 ac_cv_prog_gnu_ld=yes
8573 ac_cv_prog_gnu_ld=no
8576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_gnu_ld" >&5
8577 $as_echo "$ac_cv_prog_gnu_ld" >&6; }
8578 with_gnu_ld=$ac_cv_prog_gnu_ld
8583 if test -n "$ac_tool_prefix"; then
8584 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
8585 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
8586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8587 $as_echo_n "checking for $ac_word... " >&6; }
8588 if ${ac_cv_prog_RANLIB+:} false; then :
8589 $as_echo_n "(cached) " >&6
8591 if test -n "$RANLIB"; then
8592 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
8594 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8598 test -z "$as_dir" && as_dir=.
8599 for ac_exec_ext in '' $ac_executable_extensions; do
8600 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8601 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
8602 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8611 RANLIB=$ac_cv_prog_RANLIB
8612 if test -n "$RANLIB"; then
8613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
8614 $as_echo "$RANLIB" >&6; }
8616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8617 $as_echo "no" >&6; }
8622 if test -z "$ac_cv_prog_RANLIB"; then
8623 ac_ct_RANLIB=$RANLIB
8624 # Extract the first word of "ranlib", so it can be a program name with args.
8625 set dummy ranlib; ac_word=$2
8626 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8627 $as_echo_n "checking for $ac_word... " >&6; }
8628 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
8629 $as_echo_n "(cached) " >&6
8631 if test -n "$ac_ct_RANLIB"; then
8632 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
8634 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8638 test -z "$as_dir" && as_dir=.
8639 for ac_exec_ext in '' $ac_executable_extensions; do
8640 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8641 ac_cv_prog_ac_ct_RANLIB="ranlib"
8642 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8651 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
8652 if test -n "$ac_ct_RANLIB"; then
8653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
8654 $as_echo "$ac_ct_RANLIB" >&6; }
8656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8657 $as_echo "no" >&6; }
8660 if test "x$ac_ct_RANLIB" = x; then
8663 case $cross_compiling:$ac_tool_warned in
8665 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8666 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8667 ac_tool_warned=yes ;;
8669 RANLIB=$ac_ct_RANLIB
8672 RANLIB="$ac_cv_prog_RANLIB"
8676 if test -n "$ac_tool_prefix"; then
8677 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
8678 set dummy ${ac_tool_prefix}strip; ac_word=$2
8679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8680 $as_echo_n "checking for $ac_word... " >&6; }
8681 if ${ac_cv_prog_STRIP+:} false; then :
8682 $as_echo_n "(cached) " >&6
8684 if test -n "$STRIP"; then
8685 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
8687 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8691 test -z "$as_dir" && as_dir=.
8692 for ac_exec_ext in '' $ac_executable_extensions; do
8693 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8694 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
8695 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8704 STRIP=$ac_cv_prog_STRIP
8705 if test -n "$STRIP"; then
8706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
8707 $as_echo "$STRIP" >&6; }
8709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8710 $as_echo "no" >&6; }
8715 if test -z "$ac_cv_prog_STRIP"; then
8717 # Extract the first word of "strip", so it can be a program name with args.
8718 set dummy strip; ac_word=$2
8719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8720 $as_echo_n "checking for $ac_word... " >&6; }
8721 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
8722 $as_echo_n "(cached) " >&6
8724 if test -n "$ac_ct_STRIP"; then
8725 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
8727 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8731 test -z "$as_dir" && as_dir=.
8732 for ac_exec_ext in '' $ac_executable_extensions; do
8733 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8734 ac_cv_prog_ac_ct_STRIP="strip"
8735 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8744 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
8745 if test -n "$ac_ct_STRIP"; then
8746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
8747 $as_echo "$ac_ct_STRIP" >&6; }
8749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8750 $as_echo "no" >&6; }
8753 if test "x$ac_ct_STRIP" = x; then
8756 case $cross_compiling:$ac_tool_warned in
8758 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8759 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8760 ac_tool_warned=yes ;;
8765 STRIP="$ac_cv_prog_STRIP"
8769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is possible to strip libraries" >&5
8770 $as_echo_n "checking whether it is possible to strip libraries... " >&6; }
8771 if test x"$STRIP" != x"" && "$STRIP" -V 2>&1 | grep "GNU strip" >/dev/null; then
8772 STRIP_STATIC_LIB="$STRIP -x"
8773 STRIP_SHARED_LIB="$STRIP --strip-unneeded"
8774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8775 $as_echo "yes" >&6; }
8780 STRIP_STATIC_LIB=$STRIP
8781 STRIP_SHARED_LIB=$STRIP
8782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8783 $as_echo "yes" >&6; }
8788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8789 $as_echo "no" >&6; }
8796 if test -n "$ac_tool_prefix"; then
8797 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
8798 set dummy ${ac_tool_prefix}ar; ac_word=$2
8799 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8800 $as_echo_n "checking for $ac_word... " >&6; }
8801 if ${ac_cv_prog_AR+:} false; then :
8802 $as_echo_n "(cached) " >&6
8804 if test -n "$AR"; then
8805 ac_cv_prog_AR="$AR" # Let the user override the test.
8807 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8811 test -z "$as_dir" && as_dir=.
8812 for ac_exec_ext in '' $ac_executable_extensions; do
8813 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8814 ac_cv_prog_AR="${ac_tool_prefix}ar"
8815 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8825 if test -n "$AR"; then
8826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
8827 $as_echo "$AR" >&6; }
8829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8830 $as_echo "no" >&6; }
8835 if test -z "$ac_cv_prog_AR"; then
8837 # Extract the first word of "ar", so it can be a program name with args.
8838 set dummy ar; ac_word=$2
8839 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8840 $as_echo_n "checking for $ac_word... " >&6; }
8841 if ${ac_cv_prog_ac_ct_AR+:} false; then :
8842 $as_echo_n "(cached) " >&6
8844 if test -n "$ac_ct_AR"; then
8845 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
8847 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8851 test -z "$as_dir" && as_dir=.
8852 for ac_exec_ext in '' $ac_executable_extensions; do
8853 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8854 ac_cv_prog_ac_ct_AR="ar"
8855 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8864 ac_ct_AR=$ac_cv_prog_ac_ct_AR
8865 if test -n "$ac_ct_AR"; then
8866 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
8867 $as_echo "$ac_ct_AR" >&6; }
8869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8870 $as_echo "no" >&6; }
8873 if test "x$ac_ct_AR" = x; then
8876 case $cross_compiling:$ac_tool_warned in
8878 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8879 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8880 ac_tool_warned=yes ;;
8888 if test "$PORTNAME" = "win32"; then
8889 if test -n "$ac_tool_prefix"; then
8890 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
8891 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
8892 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8893 $as_echo_n "checking for $ac_word... " >&6; }
8894 if ${ac_cv_prog_DLLTOOL+:} false; then :
8895 $as_echo_n "(cached) " >&6
8897 if test -n "$DLLTOOL"; then
8898 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
8900 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8904 test -z "$as_dir" && as_dir=.
8905 for ac_exec_ext in '' $ac_executable_extensions; do
8906 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8907 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
8908 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8917 DLLTOOL=$ac_cv_prog_DLLTOOL
8918 if test -n "$DLLTOOL"; then
8919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
8920 $as_echo "$DLLTOOL" >&6; }
8922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8923 $as_echo "no" >&6; }
8928 if test -z "$ac_cv_prog_DLLTOOL"; then
8929 ac_ct_DLLTOOL=$DLLTOOL
8930 # Extract the first word of "dlltool", so it can be a program name with args.
8931 set dummy dlltool; ac_word=$2
8932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8933 $as_echo_n "checking for $ac_word... " >&6; }
8934 if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
8935 $as_echo_n "(cached) " >&6
8937 if test -n "$ac_ct_DLLTOOL"; then
8938 ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
8940 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8944 test -z "$as_dir" && as_dir=.
8945 for ac_exec_ext in '' $ac_executable_extensions; do
8946 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8947 ac_cv_prog_ac_ct_DLLTOOL="dlltool"
8948 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8957 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
8958 if test -n "$ac_ct_DLLTOOL"; then
8959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
8960 $as_echo "$ac_ct_DLLTOOL" >&6; }
8962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8963 $as_echo "no" >&6; }
8966 if test "x$ac_ct_DLLTOOL" = x; then
8969 case $cross_compiling:$ac_tool_warned in
8971 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8972 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8973 ac_tool_warned=yes ;;
8975 DLLTOOL=$ac_ct_DLLTOOL
8978 DLLTOOL="$ac_cv_prog_DLLTOOL"
8981 if test -n "$ac_tool_prefix"; then
8982 # Extract the first word of "${ac_tool_prefix}dllwrap", so it can be a program name with args.
8983 set dummy ${ac_tool_prefix}dllwrap; ac_word=$2
8984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8985 $as_echo_n "checking for $ac_word... " >&6; }
8986 if ${ac_cv_prog_DLLWRAP+:} false; then :
8987 $as_echo_n "(cached) " >&6
8989 if test -n "$DLLWRAP"; then
8990 ac_cv_prog_DLLWRAP="$DLLWRAP" # Let the user override the test.
8992 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8996 test -z "$as_dir" && as_dir=.
8997 for ac_exec_ext in '' $ac_executable_extensions; do
8998 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8999 ac_cv_prog_DLLWRAP="${ac_tool_prefix}dllwrap"
9000 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9009 DLLWRAP=$ac_cv_prog_DLLWRAP
9010 if test -n "$DLLWRAP"; then
9011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLWRAP" >&5
9012 $as_echo "$DLLWRAP" >&6; }
9014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9015 $as_echo "no" >&6; }
9020 if test -z "$ac_cv_prog_DLLWRAP"; then
9021 ac_ct_DLLWRAP=$DLLWRAP
9022 # Extract the first word of "dllwrap", so it can be a program name with args.
9023 set dummy dllwrap; ac_word=$2
9024 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9025 $as_echo_n "checking for $ac_word... " >&6; }
9026 if ${ac_cv_prog_ac_ct_DLLWRAP+:} false; then :
9027 $as_echo_n "(cached) " >&6
9029 if test -n "$ac_ct_DLLWRAP"; then
9030 ac_cv_prog_ac_ct_DLLWRAP="$ac_ct_DLLWRAP" # Let the user override the test.
9032 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9036 test -z "$as_dir" && as_dir=.
9037 for ac_exec_ext in '' $ac_executable_extensions; do
9038 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9039 ac_cv_prog_ac_ct_DLLWRAP="dllwrap"
9040 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9049 ac_ct_DLLWRAP=$ac_cv_prog_ac_ct_DLLWRAP
9050 if test -n "$ac_ct_DLLWRAP"; then
9051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLWRAP" >&5
9052 $as_echo "$ac_ct_DLLWRAP" >&6; }
9054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9055 $as_echo "no" >&6; }
9058 if test "x$ac_ct_DLLWRAP" = x; then
9061 case $cross_compiling:$ac_tool_warned in
9063 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9064 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9065 ac_tool_warned=yes ;;
9067 DLLWRAP=$ac_ct_DLLWRAP
9070 DLLWRAP="$ac_cv_prog_DLLWRAP"
9073 if test -n "$ac_tool_prefix"; then
9074 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
9075 set dummy ${ac_tool_prefix}windres; ac_word=$2
9076 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9077 $as_echo_n "checking for $ac_word... " >&6; }
9078 if ${ac_cv_prog_WINDRES+:} false; then :
9079 $as_echo_n "(cached) " >&6
9081 if test -n "$WINDRES"; then
9082 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
9084 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9088 test -z "$as_dir" && as_dir=.
9089 for ac_exec_ext in '' $ac_executable_extensions; do
9090 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9091 ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
9092 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9101 WINDRES=$ac_cv_prog_WINDRES
9102 if test -n "$WINDRES"; then
9103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
9104 $as_echo "$WINDRES" >&6; }
9106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9107 $as_echo "no" >&6; }
9112 if test -z "$ac_cv_prog_WINDRES"; then
9113 ac_ct_WINDRES=$WINDRES
9114 # Extract the first word of "windres", so it can be a program name with args.
9115 set dummy windres; ac_word=$2
9116 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9117 $as_echo_n "checking for $ac_word... " >&6; }
9118 if ${ac_cv_prog_ac_ct_WINDRES+:} false; then :
9119 $as_echo_n "(cached) " >&6
9121 if test -n "$ac_ct_WINDRES"; then
9122 ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
9124 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9128 test -z "$as_dir" && as_dir=.
9129 for ac_exec_ext in '' $ac_executable_extensions; do
9130 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9131 ac_cv_prog_ac_ct_WINDRES="windres"
9132 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9141 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
9142 if test -n "$ac_ct_WINDRES"; then
9143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
9144 $as_echo "$ac_ct_WINDRES" >&6; }
9146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9147 $as_echo "no" >&6; }
9150 if test "x$ac_ct_WINDRES" = x; then
9153 case $cross_compiling:$ac_tool_warned in
9155 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9156 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9157 ac_tool_warned=yes ;;
9159 WINDRES=$ac_ct_WINDRES
9162 WINDRES="$ac_cv_prog_WINDRES"
9167 # Find a good install program. We prefer a C program (faster),
9168 # so one script is as good as another. But avoid the broken or
9169 # incompatible versions:
9170 # SysV /etc/install, /usr/sbin/install
9171 # SunOS /usr/etc/install
9172 # IRIX /sbin/install
9174 # AmigaOS /C/install, which installs bootblocks on floppy discs
9175 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
9176 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
9177 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
9178 # OS/2's system install, which has a completely different semantic
9179 # ./install, which can be erroneously created by make from ./install.sh.
9180 # Reject install programs that cannot install multiple files.
9181 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
9182 $as_echo_n "checking for a BSD-compatible install... " >&6; }
9183 if test -z "$INSTALL"; then
9184 if ${ac_cv_path_install+:} false; then :
9185 $as_echo_n "(cached) " >&6
9187 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9191 test -z "$as_dir" && as_dir=.
9192 # Account for people who put trailing slashes in PATH elements.
9193 case $as_dir/ in #((
9194 ./ | .// | /[cC]/* | \
9195 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
9196 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
9199 # OSF1 and SCO ODT 3.0 have their own names for install.
9200 # Don't use installbsd from OSF since it installs stuff as root
9202 for ac_prog in ginstall scoinst install; do
9203 for ac_exec_ext in '' $ac_executable_extensions; do
9204 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
9205 if test $ac_prog = install &&
9206 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
9207 # AIX install. It has an incompatible calling convention.
9209 elif test $ac_prog = install &&
9210 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
9211 # program-specific install script used by HP pwplus--don't use.
9214 rm -rf conftest.one conftest.two conftest.dir
9215 echo one > conftest.one
9216 echo two > conftest.two
9218 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
9219 test -s conftest.one && test -s conftest.two &&
9220 test -s conftest.dir/conftest.one &&
9221 test -s conftest.dir/conftest.two
9223 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
9236 rm -rf conftest.one conftest.two conftest.dir
9239 if test "${ac_cv_path_install+set}" = set; then
9240 INSTALL=$ac_cv_path_install
9242 # As a last resort, use the slow shell script. Don't cache a
9243 # value for INSTALL within a source directory, because that will
9244 # break other packages using the cache if that directory is
9245 # removed, or if the value is a relative name.
9246 INSTALL=$ac_install_sh
9249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
9250 $as_echo "$INSTALL" >&6; }
9252 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
9253 # It thinks the first close brace ends the variable substitution.
9254 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
9256 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
9258 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
9260 # When Autoconf chooses install-sh as install program it tries to generate
9261 # a relative path to it in each makefile where it substitutes it. This clashes
9262 # with our Makefile.global concept. This workaround helps.
9264 *install-sh*) install_bin='';;
9265 *) install_bin=$INSTALL;;
9269 if test -z "$TAR"; then
9272 # Extract the first word of "$ac_prog", so it can be a program name with args.
9273 set dummy $ac_prog; ac_word=$2
9274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9275 $as_echo_n "checking for $ac_word... " >&6; }
9276 if ${ac_cv_path_TAR+:} false; then :
9277 $as_echo_n "(cached) " >&6
9281 ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
9284 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9288 test -z "$as_dir" && as_dir=.
9289 for ac_exec_ext in '' $ac_executable_extensions; do
9290 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9291 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
9292 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9303 if test -n "$TAR"; then
9304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9305 $as_echo "$TAR" >&6; }
9307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9308 $as_echo "no" >&6; }
9312 test -n "$TAR" && break
9316 # Report the value of TAR in configure's output in all cases.
9317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5
9318 $as_echo_n "checking for TAR... " >&6; }
9319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9320 $as_echo "$TAR" >&6; }
9323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
9324 $as_echo_n "checking whether ln -s works... " >&6; }
9326 if test "$LN_S" = "ln -s"; then
9327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9328 $as_echo "yes" >&6; }
9330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
9331 $as_echo "no, using $LN_S" >&6; }
9334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
9335 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
9336 if test -z "$MKDIR_P"; then
9337 if ${ac_cv_path_mkdir+:} false; then :
9338 $as_echo_n "(cached) " >&6
9340 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9341 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
9344 test -z "$as_dir" && as_dir=.
9345 for ac_prog in mkdir gmkdir; do
9346 for ac_exec_ext in '' $ac_executable_extensions; do
9347 as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
9348 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
9349 'mkdir (GNU coreutils) '* | \
9350 'mkdir (coreutils) '* | \
9351 'mkdir (fileutils) '4.1*)
9352 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
9362 test -d ./--version && rmdir ./--version
9363 if test "${ac_cv_path_mkdir+set}" = set; then
9364 MKDIR_P="$ac_cv_path_mkdir -p"
9366 # As a last resort, use the slow shell script. Don't cache a
9367 # value for MKDIR_P within a source directory, because that will
9368 # break other packages using the cache if that directory is
9369 # removed, or if the value is a relative name.
9370 MKDIR_P="$ac_install_sh -d"
9373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
9374 $as_echo "$MKDIR_P" >&6; }
9376 # When Autoconf chooses install-sh as mkdir -p program it tries to generate
9377 # a relative path to it in each makefile where it substitutes it. This clashes
9378 # with our Makefile.global concept. This workaround helps.
9380 *install-sh*) MKDIR_P='\${SHELL} \${top_srcdir}/config/install-sh -c -d';;
9383 if test -z "$BISON"; then
9384 for ac_prog in bison
9386 # Extract the first word of "$ac_prog", so it can be a program name with args.
9387 set dummy $ac_prog; ac_word=$2
9388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9389 $as_echo_n "checking for $ac_word... " >&6; }
9390 if ${ac_cv_path_BISON+:} false; then :
9391 $as_echo_n "(cached) " >&6
9395 ac_cv_path_BISON="$BISON" # Let the user override the test with a path.
9398 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9402 test -z "$as_dir" && as_dir=.
9403 for ac_exec_ext in '' $ac_executable_extensions; do
9404 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9405 ac_cv_path_BISON="$as_dir/$ac_word$ac_exec_ext"
9406 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9416 BISON=$ac_cv_path_BISON
9417 if test -n "$BISON"; then
9418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BISON" >&5
9419 $as_echo "$BISON" >&6; }
9421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9422 $as_echo "no" >&6; }
9426 test -n "$BISON" && break
9430 # Report the value of BISON in configure's output in all cases.
9431 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BISON" >&5
9432 $as_echo_n "checking for BISON... " >&6; }
9433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BISON" >&5
9434 $as_echo "$BISON" >&6; }
9438 if test "$BISON"; then
9439 pgac_bison_version=`$BISON --version 2>/dev/null | sed q`
9440 { $as_echo "$as_me:${as_lineno-$LINENO}: using $pgac_bison_version" >&5
9441 $as_echo "$as_me: using $pgac_bison_version" >&6;}
9442 if echo "$pgac_bison_version" | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'
9444 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
9445 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
9446 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&5
9447 $as_echo "$as_me: WARNING:
9448 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
9449 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&2;}
9452 # Bison >=3.0 issues warnings about %name-prefix="base_yy", instead
9453 # of the now preferred %name-prefix "base_yy", but the latter
9454 # doesn't work with Bison 2.3 or less. So for now we silence the
9455 # deprecation warnings.
9456 if echo "$pgac_bison_version" | $AWK '{ if ($4 >= 3) exit 0; else exit 1;}'
9458 BISONFLAGS="$BISONFLAGS -Wno-deprecated"
9462 if test -z "$BISON"; then
9463 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
9464 *** Without Bison you will not be able to build PostgreSQL from Git nor
9465 *** change any of the parser definition files. You can obtain Bison from
9466 *** a GNU mirror site. (If you are using the official distribution of
9467 *** PostgreSQL then you do not need to worry about this, because the Bison
9468 *** output is pre-generated.)" >&5
9469 $as_echo "$as_me: WARNING:
9470 *** Without Bison you will not be able to build PostgreSQL from Git nor
9471 *** change any of the parser definition files. You can obtain Bison from
9472 *** a GNU mirror site. (If you are using the official distribution of
9473 *** PostgreSQL then you do not need to worry about this, because the Bison
9474 *** output is pre-generated.)" >&2;}
9478 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flex" >&5
9479 $as_echo_n "checking for flex... " >&6; }
9480 if ${pgac_cv_path_flex+:} false; then :
9481 $as_echo_n "(cached) " >&6
9483 # Let the user override the test
9484 if test -n "$FLEX"; then
9485 pgac_cv_path_flex=$FLEX
9489 for pgac_dir in $PATH; do
9491 if test -z "$pgac_dir" || test x"$pgac_dir" = x"."; then
9494 for pgac_prog in flex lex; do
9495 pgac_candidate="$pgac_dir/$pgac_prog"
9496 if test -f "$pgac_candidate" \
9497 && $pgac_candidate --version </dev/null >/dev/null 2>&1
9499 echo '%%' > conftest.l
9500 if $pgac_candidate -t conftest.l 2>/dev/null | grep FLEX_SCANNER >/dev/null 2>&1; then
9501 pgac_flex_version=`$pgac_candidate --version 2>/dev/null`
9502 if echo "$pgac_flex_version" | sed 's/[.a-z]/ /g' | $AWK '{ if ($1 == 2 && ($2 > 5 || ($2 == 5 && $3 >= 31))) exit 0; else exit 1;}'
9504 pgac_cv_path_flex=$pgac_candidate
9507 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
9508 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
9509 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&5
9510 $as_echo "$as_me: WARNING:
9511 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
9512 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&2;}
9518 rm -f conftest.l lex.yy.c
9519 : ${pgac_cv_path_flex=no}
9523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_path_flex" >&5
9524 $as_echo "$pgac_cv_path_flex" >&6; }
9525 if test x"$pgac_cv_path_flex" = x"no"; then
9526 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
9527 *** Without Flex you will not be able to build PostgreSQL from Git nor
9528 *** change any of the scanner definition files. You can obtain Flex from
9529 *** a GNU mirror site. (If you are using the official distribution of
9530 *** PostgreSQL then you do not need to worry about this because the Flex
9531 *** output is pre-generated.)" >&5
9532 $as_echo "$as_me: WARNING:
9533 *** Without Flex you will not be able to build PostgreSQL from Git nor
9534 *** change any of the scanner definition files. You can obtain Flex from
9535 *** a GNU mirror site. (If you are using the official distribution of
9536 *** PostgreSQL then you do not need to worry about this because the Flex
9537 *** output is pre-generated.)" >&2;}
9541 FLEX=$pgac_cv_path_flex
9542 pgac_flex_version=`$FLEX --version 2>/dev/null`
9543 { $as_echo "$as_me:${as_lineno-$LINENO}: using $pgac_flex_version" >&5
9544 $as_echo "$as_me: using $pgac_flex_version" >&6;}
9551 if test -z "$PERL"; then
9554 # Extract the first word of "$ac_prog", so it can be a program name with args.
9555 set dummy $ac_prog; ac_word=$2
9556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9557 $as_echo_n "checking for $ac_word... " >&6; }
9558 if ${ac_cv_path_PERL+:} false; then :
9559 $as_echo_n "(cached) " >&6
9563 ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
9566 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9570 test -z "$as_dir" && as_dir=.
9571 for ac_exec_ext in '' $ac_executable_extensions; do
9572 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9573 ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
9574 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9584 PERL=$ac_cv_path_PERL
9585 if test -n "$PERL"; then
9586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5
9587 $as_echo "$PERL" >&6; }
9589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9590 $as_echo "no" >&6; }
9594 test -n "$PERL" && break
9598 # Report the value of PERL in configure's output in all cases.
9599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PERL" >&5
9600 $as_echo_n "checking for PERL... " >&6; }
9601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5
9602 $as_echo "$PERL" >&6; }
9606 if test "$PERL"; then
9607 pgac_perl_version=`$PERL -v 2>/dev/null | sed -n 's/This is perl.*v[a-z ]*\([0-9]\.[0-9][0-9.]*\).*$/\1/p'`
9608 { $as_echo "$as_me:${as_lineno-$LINENO}: using perl $pgac_perl_version" >&5
9609 $as_echo "$as_me: using perl $pgac_perl_version" >&6;}
9610 if echo "$pgac_perl_version" | sed 's/[.a-z_]/ /g' | \
9611 $AWK '{ if ($1 == 5 && $2 >= 8) exit 1; else exit 0;}'
9613 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
9614 *** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
9615 *** Perl version 5.8 or later is required, but this is $pgac_perl_version." >&5
9616 $as_echo "$as_me: WARNING:
9617 *** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
9618 *** Perl version 5.8 or later is required, but this is $pgac_perl_version." >&2;}
9623 if test -z "$PERL"; then
9624 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
9625 *** Without Perl you will not be able to build PostgreSQL from Git.
9626 *** You can obtain Perl from any CPAN mirror site.
9627 *** (If you are using the official distribution of PostgreSQL then you do not
9628 *** need to worry about this, because the Perl output is pre-generated.)" >&5
9629 $as_echo "$as_me: WARNING:
9630 *** Without Perl you will not be able to build PostgreSQL from Git.
9631 *** You can obtain Perl from any CPAN mirror site.
9632 *** (If you are using the official distribution of PostgreSQL then you do not
9633 *** need to worry about this, because the Perl output is pre-generated.)" >&2;}
9636 if test "$with_perl" = yes; then
9637 if test -z "$PERL"; then
9638 as_fn_error $? "Perl not found" "$LINENO" 5
9641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Perl archlibexp" >&5
9642 $as_echo_n "checking for Perl archlibexp... " >&6; }
9643 perl_archlibexp=`$PERL -MConfig -e 'print $Config{archlibexp}'`
9644 test "$PORTNAME" = "win32" && perl_archlibexp=`echo $perl_archlibexp | sed 's,\\\\,/,g'`
9645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_archlibexp" >&5
9646 $as_echo "$perl_archlibexp" >&6; }
9647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Perl privlibexp" >&5
9648 $as_echo_n "checking for Perl privlibexp... " >&6; }
9649 perl_privlibexp=`$PERL -MConfig -e 'print $Config{privlibexp}'`
9650 test "$PORTNAME" = "win32" && perl_privlibexp=`echo $perl_privlibexp | sed 's,\\\\,/,g'`
9651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_privlibexp" >&5
9652 $as_echo "$perl_privlibexp" >&6; }
9653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Perl useshrplib" >&5
9654 $as_echo_n "checking for Perl useshrplib... " >&6; }
9655 perl_useshrplib=`$PERL -MConfig -e 'print $Config{useshrplib}'`
9656 test "$PORTNAME" = "win32" && perl_useshrplib=`echo $perl_useshrplib | sed 's,\\\\,/,g'`
9657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_useshrplib" >&5
9658 $as_echo "$perl_useshrplib" >&6; }
9659 if test "$perl_useshrplib" != yes && test "$perl_useshrplib" != true; then
9660 as_fn_error $? "cannot build PL/Perl because libperl is not a shared library
9661 You might have to rebuild your Perl installation. Refer to the
9662 documentation for details. Use --without-perl to disable building
9663 PL/Perl." "$LINENO" 5
9665 # On most platforms, archlibexp is also where the Perl include files live ...
9666 perl_includespec="-I$perl_archlibexp/CORE"
9667 # ... but on newer macOS versions, we must use -iwithsysroot to look
9669 if test \! -f "$perl_archlibexp/CORE/perl.h" ; then
9670 if test -f "$PG_SYSROOT$perl_archlibexp/CORE/perl.h" ; then
9671 perl_includespec="-iwithsysroot $perl_archlibexp/CORE"
9675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLAGS recommended by Perl" >&5
9676 $as_echo_n "checking for CFLAGS recommended by Perl... " >&6; }
9677 perl_ccflags=`$PERL -MConfig -e 'print $Config{ccflags}'`
9678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_ccflags" >&5
9679 $as_echo "$perl_ccflags" >&6; }
9680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLAGS to compile embedded Perl" >&5
9681 $as_echo_n "checking for CFLAGS to compile embedded Perl... " >&6; }
9682 perl_embed_ccflags=`$PERL -MConfig -e 'foreach $f (split(" ",$Config{ccflags})) {print $f, " " if ($f =~ /^-D[^_]/ || $f =~ /^-D_USE_32BIT_TIME_T/)}'`
9683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_embed_ccflags" >&5
9684 $as_echo "$perl_embed_ccflags" >&6; }
9687 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flags to link embedded Perl" >&5
9688 $as_echo_n "checking for flags to link embedded Perl... " >&6; }
9689 if test "$PORTNAME" = "win32" ; then
9690 perl_lib=`basename $perl_archlibexp/CORE/perl[5-9]*.lib .lib`
9691 if test -e "$perl_archlibexp/CORE/$perl_lib.lib"; then
9692 perl_embed_ldflags="-L$perl_archlibexp/CORE -l$perl_lib"
9694 perl_lib=`basename $perl_archlibexp/CORE/libperl[5-9]*.a .a | sed 's/^lib//'`
9695 if test -e "$perl_archlibexp/CORE/lib$perl_lib.a"; then
9696 perl_embed_ldflags="-L$perl_archlibexp/CORE -l$perl_lib"
9700 pgac_tmp1=`$PERL -MExtUtils::Embed -e ldopts`
9701 pgac_tmp2=`$PERL -MConfig -e 'print $Config{ccdlflags}'`
9702 perl_embed_ldflags=`echo X"$pgac_tmp1" | sed -e "s/^X//" -e "s%$pgac_tmp2%%" -e "s/ -arch [-a-zA-Z0-9_]*//g"`
9704 if test -z "$perl_embed_ldflags" ; then
9705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9706 $as_echo "no" >&6; }
9707 as_fn_error $? "could not determine flags for linking embedded Perl.
9708 This probably means that ExtUtils::Embed or ExtUtils::MakeMaker is not
9709 installed." "$LINENO" 5
9711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_embed_ldflags" >&5
9712 $as_echo "$perl_embed_ldflags" >&6; }
9717 if test "$with_python" = yes; then
9718 if test -z "$PYTHON"; then
9719 for ac_prog in python python3 python2
9721 # Extract the first word of "$ac_prog", so it can be a program name with args.
9722 set dummy $ac_prog; ac_word=$2
9723 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9724 $as_echo_n "checking for $ac_word... " >&6; }
9725 if ${ac_cv_path_PYTHON+:} false; then :
9726 $as_echo_n "(cached) " >&6
9730 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
9733 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9737 test -z "$as_dir" && as_dir=.
9738 for ac_exec_ext in '' $ac_executable_extensions; do
9739 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9740 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
9741 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9751 PYTHON=$ac_cv_path_PYTHON
9752 if test -n "$PYTHON"; then
9753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
9754 $as_echo "$PYTHON" >&6; }
9756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9757 $as_echo "no" >&6; }
9761 test -n "$PYTHON" && break
9765 # Report the value of PYTHON in configure's output in all cases.
9766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PYTHON" >&5
9767 $as_echo_n "checking for PYTHON... " >&6; }
9768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
9769 $as_echo "$PYTHON" >&6; }
9772 if test x"$PYTHON" = x""; then
9773 as_fn_error $? "Python not found" "$LINENO" 5
9777 python_fullversion=`${PYTHON} -c "import sys; print(sys.version)" | sed q`
9778 { $as_echo "$as_me:${as_lineno-$LINENO}: using python $python_fullversion" >&5
9779 $as_echo "$as_me: using python $python_fullversion" >&6;}
9780 # python_fullversion is typically n.n.n plus some trailing junk
9781 python_majorversion=`echo "$python_fullversion" | sed 's/^\([0-9]*\).*/\1/'`
9782 python_minorversion=`echo "$python_fullversion" | sed 's/^[0-9]*\.\([0-9]*\).*/\1/'`
9783 python_version=`echo "$python_fullversion" | sed 's/^\([0-9]*\.[0-9]*\).*/\1/'`
9784 # Reject unsupported Python versions as soon as practical.
9785 if test "$python_majorversion" -lt 3 -a "$python_minorversion" -lt 4; then
9786 as_fn_error $? "Python version $python_version is too old (version 2.4 or later is required)" "$LINENO" 5
9789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python distutils module" >&5
9790 $as_echo_n "checking for Python distutils module... " >&6; }
9791 if "${PYTHON}" -c 'import distutils' 2>&5
9793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9794 $as_echo "yes" >&6; }
9796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9797 $as_echo "no" >&6; }
9798 as_fn_error $? "distutils module not found" "$LINENO" 5
9801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python configuration directory" >&5
9802 $as_echo_n "checking Python configuration directory... " >&6; }
9803 python_configdir=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBPL'))))"`
9804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_configdir" >&5
9805 $as_echo "$python_configdir" >&6; }
9807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python include directories" >&5
9808 $as_echo_n "checking Python include directories... " >&6; }
9809 python_includespec=`${PYTHON} -c "
9810 import distutils.sysconfig
9811 a = '-I' + distutils.sysconfig.get_python_inc(False)
9812 b = '-I' + distutils.sysconfig.get_python_inc(True)
9816 print(a + ' ' + b)"`
9817 if test "$PORTNAME" = win32 ; then
9818 python_includespec=`echo $python_includespec | sed 's,[\],/,g'`
9820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_includespec" >&5
9821 $as_echo "$python_includespec" >&6; }
9825 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link an embedded Python application" >&5
9826 $as_echo_n "checking how to link an embedded Python application... " >&6; }
9828 python_libdir=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBDIR'))))"`
9829 python_ldlibrary=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LDLIBRARY'))))"`
9831 # If LDLIBRARY exists and has a shlib extension, use it verbatim.
9832 ldlibrary=`echo "${python_ldlibrary}" | sed -e 's/\.so$//' -e 's/\.dll$//' -e 's/\.dylib$//' -e 's/\.sl$//'`
9833 if test -e "${python_libdir}/${python_ldlibrary}" -a x"${python_ldlibrary}" != x"${ldlibrary}"
9835 ldlibrary=`echo "${ldlibrary}" | sed "s/^lib//"`
9838 # Otherwise, guess the base name of the shlib.
9839 # LDVERSION was added in Python 3.2, before that use VERSION,
9840 # or failing that, $python_version from _PGAC_CHECK_PYTHON_DIRS.
9841 python_ldversion=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LDVERSION'))))"`
9842 if test x"${python_ldversion}" != x""; then
9843 ldlibrary="python${python_ldversion}"
9845 python_version_var=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('VERSION'))))"`
9846 if test x"${python_version_var}" != x""; then
9847 ldlibrary="python${python_version_var}"
9849 ldlibrary="python${python_version}"
9852 # Search for a likely-looking file.
9854 for d in "${python_libdir}" "${python_configdir}" /usr/lib64 /usr/lib
9856 # We don't know the platform DLSUFFIX here, so check 'em all.
9857 for e in .so .dll .dylib .sl; do
9858 if test -e "$d/lib${ldlibrary}$e"; then
9865 # Some platforms (OpenBSD) require us to accept a bare versioned shlib
9866 # (".so.n.n") as well. However, check this only after failing to find
9867 # ".so" anywhere, because yet other platforms (Debian) put the .so
9868 # symlink in a different directory from the underlying versioned shlib.
9869 if test "$found_shlib" != 1; then
9870 for d in "${python_libdir}" "${python_configdir}" /usr/lib64 /usr/lib
9872 for f in "$d/lib${ldlibrary}.so."* ; do
9873 if test -e "$f"; then
9881 # As usual, Windows has its own ideas. Possible default library
9882 # locations include c:/Windows/System32 and (for Cygwin) /usr/bin,
9883 # and the "lib" prefix might not be there.
9884 if test "$found_shlib" != 1 -a \( "$PORTNAME" = win32 -o "$PORTNAME" = cygwin \); then
9885 for d in "${python_libdir}" "${python_configdir}" c:/Windows/System32 /usr/bin
9887 for f in "$d/lib${ldlibrary}.dll" "$d/${ldlibrary}.dll" ; do
9888 if test -e "$f"; then
9897 if test "$found_shlib" != 1; then
9898 as_fn_error $? "could not find shared library for Python
9899 You might have to rebuild your Python installation. Refer to the
9900 documentation for details. Use --without-python to disable building
9901 PL/Python." "$LINENO" 5
9903 python_libspec="-L${python_libdir} -l${ldlibrary}"
9905 python_additional_libs=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBS','LIBC','LIBM','BASEMODLIBS'))))"`
9907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${python_libspec} ${python_additional_libs}" >&5
9908 $as_echo "${python_libspec} ${python_additional_libs}" >&6; }
9914 if test "$cross_compiling" = yes && test -z "$with_system_tzdata"; then
9915 if test -z "$ZIC"; then
9918 # Extract the first word of "$ac_prog", so it can be a program name with args.
9919 set dummy $ac_prog; ac_word=$2
9920 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9921 $as_echo_n "checking for $ac_word... " >&6; }
9922 if ${ac_cv_path_ZIC+:} false; then :
9923 $as_echo_n "(cached) " >&6
9927 ac_cv_path_ZIC="$ZIC" # Let the user override the test with a path.
9930 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9934 test -z "$as_dir" && as_dir=.
9935 for ac_exec_ext in '' $ac_executable_extensions; do
9936 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9937 ac_cv_path_ZIC="$as_dir/$ac_word$ac_exec_ext"
9938 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9949 if test -n "$ZIC"; then
9950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIC" >&5
9951 $as_echo "$ZIC" >&6; }
9953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9954 $as_echo "no" >&6; }
9958 test -n "$ZIC" && break
9962 # Report the value of ZIC in configure's output in all cases.
9963 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIC" >&5
9964 $as_echo_n "checking for ZIC... " >&6; }
9965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIC" >&5
9966 $as_echo "$ZIC" >&6; }
9969 if test -z "$ZIC"; then
9971 When cross-compiling, either use the option --with-system-tzdata to use
9972 existing time-zone data, or set the environment variable ZIC to a zic
9973 program to use during the build." "$LINENO" 5
9980 # For each platform, we need to know about any special compile and link
9981 # libraries, and whether the normal C function names are thread-safe.
9982 # See the comment at the top of src/port/thread.c for more information.
9983 # WIN32 doesn't need the pthread tests; it always uses threads
9985 # These tests are run before the library-tests, because linking with the
9986 # other libraries can pull in the pthread functions as a side-effect. We
9987 # want to use the -pthread or similar flags directly, and not rely on
9988 # the side-effects of linking with some other library.
9990 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
9991 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
9992 if ${ac_cv_path_SED+:} false; then :
9993 $as_echo_n "(cached) " >&6
9995 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
9996 for ac_i in 1 2 3 4 5 6 7; do
9997 ac_script="$ac_script$as_nl$ac_script"
9999 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
10000 { ac_script=; unset ac_script;}
10001 if test -z "$SED"; then
10002 ac_path_SED_found=false
10003 # Loop through the user's path and test for each of PROGNAME-LIST
10004 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10005 for as_dir in $PATH
10008 test -z "$as_dir" && as_dir=.
10009 for ac_prog in sed gsed; do
10010 for ac_exec_ext in '' $ac_executable_extensions; do
10011 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
10012 as_fn_executable_p "$ac_path_SED" || continue
10013 # Check for GNU ac_path_SED and select it if it is found.
10014 # Check for GNU $ac_path_SED
10015 case `"$ac_path_SED" --version 2>&1` in
10017 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
10020 $as_echo_n 0123456789 >"conftest.in"
10023 cat "conftest.in" "conftest.in" >"conftest.tmp"
10024 mv "conftest.tmp" "conftest.in"
10025 cp "conftest.in" "conftest.nl"
10026 $as_echo '' >> "conftest.nl"
10027 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
10028 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
10029 as_fn_arith $ac_count + 1 && ac_count=$as_val
10030 if test $ac_count -gt ${ac_path_SED_max-0}; then
10031 # Best one so far, save it but keep looking for a better one
10032 ac_cv_path_SED="$ac_path_SED"
10033 ac_path_SED_max=$ac_count
10035 # 10*(2^10) chars as input seems more than enough
10036 test $ac_count -gt 10 && break
10038 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
10041 $ac_path_SED_found && break 3
10046 if test -z "$ac_cv_path_SED"; then
10047 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
10050 ac_cv_path_SED=$SED
10054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
10055 $as_echo "$ac_cv_path_SED" >&6; }
10056 SED="$ac_cv_path_SED"
10059 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
10060 $as_echo_n "checking for ANSI C header files... " >&6; }
10061 if ${ac_cv_header_stdc+:} false; then :
10062 $as_echo_n "(cached) " >&6
10064 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10065 /* end confdefs.h. */
10066 #include <stdlib.h>
10067 #include <stdarg.h>
10068 #include <string.h>
10079 if ac_fn_c_try_compile "$LINENO"; then :
10080 ac_cv_header_stdc=yes
10082 ac_cv_header_stdc=no
10084 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10086 if test $ac_cv_header_stdc = yes; then
10087 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
10088 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10089 /* end confdefs.h. */
10090 #include <string.h>
10093 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10094 $EGREP "memchr" >/dev/null 2>&1; then :
10097 ac_cv_header_stdc=no
10103 if test $ac_cv_header_stdc = yes; then
10104 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
10105 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10106 /* end confdefs.h. */
10107 #include <stdlib.h>
10110 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10111 $EGREP "free" >/dev/null 2>&1; then :
10114 ac_cv_header_stdc=no
10120 if test $ac_cv_header_stdc = yes; then
10121 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
10122 if test "$cross_compiling" = yes; then :
10125 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10126 /* end confdefs.h. */
10128 #include <stdlib.h>
10129 #if ((' ' & 0x0FF) == 0x020)
10130 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
10131 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
10133 # define ISLOWER(c) \
10134 (('a' <= (c) && (c) <= 'i') \
10135 || ('j' <= (c) && (c) <= 'r') \
10136 || ('s' <= (c) && (c) <= 'z'))
10137 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
10140 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
10145 for (i = 0; i < 256; i++)
10146 if (XOR (islower (i), ISLOWER (i))
10147 || toupper (i) != TOUPPER (i))
10152 if ac_fn_c_try_run "$LINENO"; then :
10155 ac_cv_header_stdc=no
10157 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10158 conftest.$ac_objext conftest.beam conftest.$ac_ext
10163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
10164 $as_echo "$ac_cv_header_stdc" >&6; }
10165 if test $ac_cv_header_stdc = yes; then
10167 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
10171 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
10172 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
10173 inttypes.h stdint.h unistd.h
10175 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10176 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
10178 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
10179 cat >>confdefs.h <<_ACEOF
10180 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10188 if test "$enable_thread_safety" = yes -a "$PORTNAME" != "win32"; then :
10195 ac_cpp='$CPP $CPPFLAGS'
10196 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10197 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10198 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10202 # We used to check for pthread.h first, but this fails if pthread.h
10203 # requires special compiler flags (e.g. on Tru64 or Sequent).
10204 # It gets checked for in the link test anyway.
10206 # First of all, check if the user has set any of the PTHREAD_LIBS,
10207 # etcetera environment variables, and if threads linking works using
10209 if test "x$PTHREAD_CFLAGS$PTHREAD_LIBS" != "x"; then
10210 ax_pthread_save_CC="$CC"
10211 ax_pthread_save_CFLAGS="$CFLAGS"
10212 ax_pthread_save_LIBS="$LIBS"
10213 if test "x$PTHREAD_CC" != "x"; then :
10216 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
10217 LIBS="$PTHREAD_LIBS $LIBS"
10218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS" >&5
10219 $as_echo_n "checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS... " >&6; }
10220 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10221 /* end confdefs.h. */
10223 /* Override any GCC internal prototype to avoid an error.
10224 Use char because int might match the return type of a GCC
10225 builtin and then its argument prototype would still apply. */
10229 char pthread_join ();
10233 return pthread_join ();
10238 if ac_fn_c_try_link "$LINENO"; then :
10241 rm -f core conftest.err conftest.$ac_objext \
10242 conftest$ac_exeext conftest.$ac_ext
10243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
10244 $as_echo "$ax_pthread_ok" >&6; }
10245 if test "x$ax_pthread_ok" = "xno"; then
10249 CC="$ax_pthread_save_CC"
10250 CFLAGS="$ax_pthread_save_CFLAGS"
10251 LIBS="$ax_pthread_save_LIBS"
10254 # We must check for the threads library under a number of different
10255 # names; the ordering is very important because some systems
10256 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
10257 # libraries is broken (non-POSIX).
10259 # Create a list of thread flags to try. Items starting with a "-" are
10260 # C compiler flags, and other items are library names, except for "none"
10261 # which indicates that we try without any flags at all, and "pthread-config"
10262 # which is a program returning the flags for the Pth emulation library.
10264 ax_pthread_flags="pthreads none -Kthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
10266 # The ordering *is* (sometimes) important. Some notes on the
10267 # individual items follow:
10269 # pthreads: AIX (must check this before -lpthread)
10270 # none: in case threads are in libc; should be tried before -Kthread and
10271 # other compiler flags to prevent continual compiler warnings
10272 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
10273 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads), Tru64
10274 # (Note: HP C rejects this with "bad form for `-t' option")
10275 # -pthreads: Solaris/gcc (Note: HP C also rejects)
10276 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
10277 # doesn't hurt to check since this sometimes defines pthreads and
10278 # -D_REENTRANT too), HP C (must be checked before -lpthread, which
10279 # is present but should not be used directly; and before -mthreads,
10280 # because the compiler interprets this as "-mt" + "-hreads")
10281 # -mthreads: Mingw32/gcc, Lynx/gcc
10282 # pthread: Linux, etcetera
10283 # --thread-safe: KAI C++
10284 # pthread-config: use pthread-config program (for GNU Pth library)
10290 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
10291 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
10293 ax_pthread_flags="-kthread lthread $ax_pthread_flags"
10298 # From the cc(1) man page: "[-mt] Sets various -D flags to enable
10299 # multi-threading and also sets -lpthread."
10301 ax_pthread_flags="-mt -pthread pthread $ax_pthread_flags"
10306 # IBM z/OS requires a feature-test macro to be defined in order to
10307 # enable POSIX threads at all, so give the user a hint if this is
10308 # not set. (We don't define these ourselves, as they can affect
10309 # other portions of the system API in unpredictable ways.)
10311 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10312 /* end confdefs.h. */
10314 # if !defined(_OPEN_THREADS) && !defined(_UNIX03_THREADS)
10315 AX_PTHREAD_ZOS_MISSING
10319 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10320 $EGREP "AX_PTHREAD_ZOS_MISSING" >/dev/null 2>&1; then :
10321 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&5
10322 $as_echo "$as_me: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&2;}
10330 # On Solaris (at least, for some versions), libc contains stubbed
10331 # (non-functional) versions of the pthreads routines, so link-based
10332 # tests will erroneously succeed. (N.B.: The stubs are missing
10333 # pthread_cleanup_push, or rather a function called by this macro,
10334 # so we could check for that, but who knows whether they'll stub
10335 # that too in a future libc.) So we'll check first for the
10336 # standard Solaris way of linking pthreads (-mt -lpthread).
10338 ax_pthread_flags="-mt,pthread pthread $ax_pthread_flags"
10342 # GCC generally uses -pthread, or -pthreads on some platforms (e.g. SPARC)
10344 if test "x$GCC" = "xyes"; then :
10345 ax_pthread_flags="-pthread -pthreads $ax_pthread_flags"
10348 # The presence of a feature test macro requesting re-entrant function
10349 # definitions is, on some systems, a strong hint that pthreads support is
10350 # correctly enabled
10353 darwin* | hpux* | linux* | osf* | solaris*)
10354 ax_pthread_check_macro="_REENTRANT"
10358 ax_pthread_check_macro="_THREAD_SAFE"
10362 ax_pthread_check_macro="--"
10365 if test "x$ax_pthread_check_macro" = "x--"; then :
10366 ax_pthread_check_cond=0
10368 ax_pthread_check_cond="!defined($ax_pthread_check_macro)"
10371 # Are we compiling with Clang?
10373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC is Clang" >&5
10374 $as_echo_n "checking whether $CC is Clang... " >&6; }
10375 if ${ax_cv_PTHREAD_CLANG+:} false; then :
10376 $as_echo_n "(cached) " >&6
10378 ax_cv_PTHREAD_CLANG=no
10379 # Note that Autoconf sets GCC=yes for Clang as well as GCC
10380 if test "x$GCC" = "xyes"; then
10381 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10382 /* end confdefs.h. */
10383 /* Note: Clang 2.7 lacks __clang_[a-z]+__ */
10384 # if defined(__clang__) && defined(__llvm__)
10385 AX_PTHREAD_CC_IS_CLANG
10389 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10390 $EGREP "AX_PTHREAD_CC_IS_CLANG" >/dev/null 2>&1; then :
10391 ax_cv_PTHREAD_CLANG=yes
10398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG" >&5
10399 $as_echo "$ax_cv_PTHREAD_CLANG" >&6; }
10400 ax_pthread_clang="$ax_cv_PTHREAD_CLANG"
10402 ax_pthread_clang_warning=no
10404 # Clang needs special handling, because older versions handle the -pthread
10405 # option in a rather... idiosyncratic way
10407 if test "x$ax_pthread_clang" = "xyes"; then
10409 # Clang takes -pthread; it has never supported any other flag
10411 # (Note 1: This will need to be revisited if a system that Clang
10412 # supports has POSIX threads in a separate library. This tends not
10413 # to be the way of modern systems, but it's conceivable.)
10415 # (Note 2: On some systems, notably Darwin, -pthread is not needed
10416 # to get POSIX threads support; the API is always present and
10417 # active. We could reasonably leave PTHREAD_CFLAGS empty. But
10418 # -pthread does define _REENTRANT, and while the Darwin headers
10419 # ignore this macro, third-party headers might not.)
10421 PTHREAD_CFLAGS="-pthread"
10426 # However, older versions of Clang make a point of warning the user
10427 # that, in an invocation where only linking and no compilation is
10428 # taking place, the -pthread option has no effect ("argument unused
10429 # during compilation"). They expect -pthread to be passed in only
10430 # when source code is being compiled.
10432 # Problem is, this is at odds with the way Automake and most other
10433 # C build frameworks function, which is that the same flags used in
10434 # compilation (CFLAGS) are also used in linking. Many systems
10435 # supported by AX_PTHREAD require exactly this for POSIX threads
10436 # support, and in fact it is often not straightforward to specify a
10437 # flag that is used only in the compilation phase and not in
10438 # linking. Such a scenario is extremely rare in practice.
10440 # Even though use of the -pthread flag in linking would only print
10441 # a warning, this can be a nuisance for well-run software projects
10442 # that build with -Werror. So if the active version of Clang has
10443 # this misfeature, we search for an option to squash it.
10445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread" >&5
10446 $as_echo_n "checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread... " >&6; }
10447 if ${ax_cv_PTHREAD_CLANG_NO_WARN_FLAG+:} false; then :
10448 $as_echo_n "(cached) " >&6
10450 ax_cv_PTHREAD_CLANG_NO_WARN_FLAG=unknown
10451 # Create an alternate version of $ac_link that compiles and
10452 # links in two steps (.c -> .o, .o -> exe) instead of one
10453 # (.c -> exe), because the warning occurs only in the second
10455 ax_pthread_save_ac_link="$ac_link"
10456 ax_pthread_sed='s/conftest\.\$ac_ext/conftest.$ac_objext/g'
10457 ax_pthread_link_step=`$as_echo "$ac_link" | sed "$ax_pthread_sed"`
10458 ax_pthread_2step_ac_link="($ac_compile) && (echo ==== >&5) && ($ax_pthread_link_step)"
10459 ax_pthread_save_CFLAGS="$CFLAGS"
10460 for ax_pthread_try in '' -Qunused-arguments -Wno-unused-command-line-argument unknown; do
10461 if test "x$ax_pthread_try" = "xunknown"; then :
10464 CFLAGS="-Werror -Wunknown-warning-option $ax_pthread_try -pthread $ax_pthread_save_CFLAGS"
10465 ac_link="$ax_pthread_save_ac_link"
10466 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10467 /* end confdefs.h. */
10468 int main(void){return 0;}
10470 if ac_fn_c_try_link "$LINENO"; then :
10471 ac_link="$ax_pthread_2step_ac_link"
10472 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10473 /* end confdefs.h. */
10474 int main(void){return 0;}
10476 if ac_fn_c_try_link "$LINENO"; then :
10479 rm -f core conftest.err conftest.$ac_objext \
10480 conftest$ac_exeext conftest.$ac_ext
10483 rm -f core conftest.err conftest.$ac_objext \
10484 conftest$ac_exeext conftest.$ac_ext
10486 ac_link="$ax_pthread_save_ac_link"
10487 CFLAGS="$ax_pthread_save_CFLAGS"
10488 if test "x$ax_pthread_try" = "x"; then :
10491 ax_cv_PTHREAD_CLANG_NO_WARN_FLAG="$ax_pthread_try"
10494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&5
10495 $as_echo "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&6; }
10497 case "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" in
10499 *) PTHREAD_CFLAGS="$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG $PTHREAD_CFLAGS" ;;
10502 fi # $ax_pthread_clang = yes
10504 if test "x$ax_pthread_ok" = "xno"; then
10505 for ax_pthread_try_flag in $ax_pthread_flags; do
10507 case $ax_pthread_try_flag in
10509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5
10510 $as_echo_n "checking whether pthreads work without any flags... " >&6; }
10514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with -mt -lpthread" >&5
10515 $as_echo_n "checking whether pthreads work with -mt -lpthread... " >&6; }
10516 PTHREAD_CFLAGS="-mt"
10517 PTHREAD_LIBS="-lpthread"
10521 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $ax_pthread_try_flag" >&5
10522 $as_echo_n "checking whether pthreads work with $ax_pthread_try_flag... " >&6; }
10523 PTHREAD_CFLAGS="$ax_pthread_try_flag"
10527 # Extract the first word of "pthread-config", so it can be a program name with args.
10528 set dummy pthread-config; ac_word=$2
10529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10530 $as_echo_n "checking for $ac_word... " >&6; }
10531 if ${ac_cv_prog_ax_pthread_config+:} false; then :
10532 $as_echo_n "(cached) " >&6
10534 if test -n "$ax_pthread_config"; then
10535 ac_cv_prog_ax_pthread_config="$ax_pthread_config" # Let the user override the test.
10537 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10538 for as_dir in $PATH
10541 test -z "$as_dir" && as_dir=.
10542 for ac_exec_ext in '' $ac_executable_extensions; do
10543 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10544 ac_cv_prog_ax_pthread_config="yes"
10545 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10552 test -z "$ac_cv_prog_ax_pthread_config" && ac_cv_prog_ax_pthread_config="no"
10555 ax_pthread_config=$ac_cv_prog_ax_pthread_config
10556 if test -n "$ax_pthread_config"; then
10557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_config" >&5
10558 $as_echo "$ax_pthread_config" >&6; }
10560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10561 $as_echo "no" >&6; }
10565 if test "x$ax_pthread_config" = "xno"; then :
10568 PTHREAD_CFLAGS="`pthread-config --cflags`"
10569 PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
10573 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$ax_pthread_try_flag" >&5
10574 $as_echo_n "checking for the pthreads library -l$ax_pthread_try_flag... " >&6; }
10575 PTHREAD_LIBS="-l$ax_pthread_try_flag"
10579 ax_pthread_save_CFLAGS="$CFLAGS"
10580 ax_pthread_save_LIBS="$LIBS"
10581 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
10582 LIBS="$PTHREAD_LIBS $LIBS"
10584 # Check for various functions. We must include pthread.h,
10585 # since some functions may be macros. (On the Sequent, we
10586 # need a special flag -Kthread to make this header compile.)
10587 # We check for pthread_join because it is in -lpthread on IRIX
10588 # while pthread_create is in libc. We check for pthread_attr_init
10589 # due to DEC craziness with -lpthreads. We check for
10590 # pthread_cleanup_push because it is one of the few pthread
10591 # functions on Solaris that doesn't have a non-functional libc stub.
10592 # We try pthread_create on general principles.
10594 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10595 /* end confdefs.h. */
10596 #include <pthread.h>
10597 # if $ax_pthread_check_cond
10598 # error "$ax_pthread_check_macro must be defined"
10600 static void routine(void *a) { a = 0; }
10601 static void *start_routine(void *a) { return a; }
10605 pthread_t th; pthread_attr_t attr;
10606 pthread_create(&th, 0, start_routine, 0);
10607 pthread_join(th, 0);
10608 pthread_attr_init(&attr);
10609 pthread_cleanup_push(routine, 0);
10610 pthread_cleanup_pop(0) /* ; */
10615 if ac_fn_c_try_link "$LINENO"; then :
10618 rm -f core conftest.err conftest.$ac_objext \
10619 conftest$ac_exeext conftest.$ac_ext
10621 CFLAGS="$ax_pthread_save_CFLAGS"
10622 LIBS="$ax_pthread_save_LIBS"
10624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
10625 $as_echo "$ax_pthread_ok" >&6; }
10626 if test "x$ax_pthread_ok" = "xyes"; then :
10635 # Various other checks:
10636 if test "x$ax_pthread_ok" = "xyes"; then
10637 ax_pthread_save_CFLAGS="$CFLAGS"
10638 ax_pthread_save_LIBS="$LIBS"
10639 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
10640 LIBS="$PTHREAD_LIBS $LIBS"
10642 # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
10643 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5
10644 $as_echo_n "checking for joinable pthread attribute... " >&6; }
10645 if ${ax_cv_PTHREAD_JOINABLE_ATTR+:} false; then :
10646 $as_echo_n "(cached) " >&6
10648 ax_cv_PTHREAD_JOINABLE_ATTR=unknown
10649 for ax_pthread_attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
10650 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10651 /* end confdefs.h. */
10652 #include <pthread.h>
10656 int attr = $ax_pthread_attr; return attr /* ; */
10661 if ac_fn_c_try_link "$LINENO"; then :
10662 ax_cv_PTHREAD_JOINABLE_ATTR=$ax_pthread_attr; break
10664 rm -f core conftest.err conftest.$ac_objext \
10665 conftest$ac_exeext conftest.$ac_ext
10669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_JOINABLE_ATTR" >&5
10670 $as_echo "$ax_cv_PTHREAD_JOINABLE_ATTR" >&6; }
10671 if test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xunknown" && \
10672 test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xPTHREAD_CREATE_JOINABLE" && \
10673 test "x$ax_pthread_joinable_attr_defined" != "xyes"; then :
10675 cat >>confdefs.h <<_ACEOF
10676 #define PTHREAD_CREATE_JOINABLE $ax_cv_PTHREAD_JOINABLE_ATTR
10679 ax_pthread_joinable_attr_defined=yes
10683 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether more special flags are required for pthreads" >&5
10684 $as_echo_n "checking whether more special flags are required for pthreads... " >&6; }
10685 if ${ax_cv_PTHREAD_SPECIAL_FLAGS+:} false; then :
10686 $as_echo_n "(cached) " >&6
10688 ax_cv_PTHREAD_SPECIAL_FLAGS=no
10691 ax_cv_PTHREAD_SPECIAL_FLAGS="-D_POSIX_PTHREAD_SEMANTICS"
10696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_SPECIAL_FLAGS" >&5
10697 $as_echo "$ax_cv_PTHREAD_SPECIAL_FLAGS" >&6; }
10698 if test "x$ax_cv_PTHREAD_SPECIAL_FLAGS" != "xno" && \
10699 test "x$ax_pthread_special_flags_added" != "xyes"; then :
10700 PTHREAD_CFLAGS="$ax_cv_PTHREAD_SPECIAL_FLAGS $PTHREAD_CFLAGS"
10701 ax_pthread_special_flags_added=yes
10704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_PRIO_INHERIT" >&5
10705 $as_echo_n "checking for PTHREAD_PRIO_INHERIT... " >&6; }
10706 if ${ax_cv_PTHREAD_PRIO_INHERIT+:} false; then :
10707 $as_echo_n "(cached) " >&6
10709 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10710 /* end confdefs.h. */
10711 #include <pthread.h>
10715 int i = PTHREAD_PRIO_INHERIT;
10720 if ac_fn_c_try_link "$LINENO"; then :
10721 ax_cv_PTHREAD_PRIO_INHERIT=yes
10723 ax_cv_PTHREAD_PRIO_INHERIT=no
10725 rm -f core conftest.err conftest.$ac_objext \
10726 conftest$ac_exeext conftest.$ac_ext
10729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_PRIO_INHERIT" >&5
10730 $as_echo "$ax_cv_PTHREAD_PRIO_INHERIT" >&6; }
10731 if test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes" && \
10732 test "x$ax_pthread_prio_inherit_defined" != "xyes"; then :
10734 $as_echo "#define HAVE_PTHREAD_PRIO_INHERIT 1" >>confdefs.h
10736 ax_pthread_prio_inherit_defined=yes
10740 CFLAGS="$ax_pthread_save_CFLAGS"
10741 LIBS="$ax_pthread_save_LIBS"
10743 # More AIX lossage: compile with *_r variant
10744 if test "x$GCC" != "xyes"; then
10748 x*/c89|x*/c89_128|x*/c99|x*/c99_128|x*/cc|x*/cc128|x*/xlc|x*/xlc_v6|x*/xlc128|x*/xlc128_v6) :
10749 #handle absolute path differently from PATH based program lookup
10752 if as_fn_executable_p ${CC}_r; then :
10753 PTHREAD_CC="${CC}_r"
10756 for ac_prog in ${CC}_r
10758 # Extract the first word of "$ac_prog", so it can be a program name with args.
10759 set dummy $ac_prog; ac_word=$2
10760 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10761 $as_echo_n "checking for $ac_word... " >&6; }
10762 if ${ac_cv_prog_PTHREAD_CC+:} false; then :
10763 $as_echo_n "(cached) " >&6
10765 if test -n "$PTHREAD_CC"; then
10766 ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
10768 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10769 for as_dir in $PATH
10772 test -z "$as_dir" && as_dir=.
10773 for ac_exec_ext in '' $ac_executable_extensions; do
10774 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10775 ac_cv_prog_PTHREAD_CC="$ac_prog"
10776 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10785 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
10786 if test -n "$PTHREAD_CC"; then
10787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5
10788 $as_echo "$PTHREAD_CC" >&6; }
10790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10791 $as_echo "no" >&6; }
10795 test -n "$PTHREAD_CC" && break
10797 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
10808 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
10814 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
10815 if test "x$ax_pthread_ok" = "xyes"; then
10817 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
10825 ac_cpp='$CPP $CPPFLAGS'
10826 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10827 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10828 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10832 # Some platforms use these, so just define them. They can't hurt if they
10833 # are not supported. For example, on Solaris -D_POSIX_PTHREAD_SEMANTICS
10834 # enables 5-arg getpwuid_r, among other things.
10835 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
10837 # Check for *_r functions
10840 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
10841 LIBS="$LIBS $PTHREAD_LIBS"
10843 ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
10844 if test "x$ac_cv_header_pthread_h" = xyes; then :
10848 pthread.h not found; use --disable-thread-safety to disable thread safety" "$LINENO" 5
10853 for ac_func in strerror_r getpwuid_r gethostbyname_r
10855 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10856 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10857 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
10858 cat >>confdefs.h <<_ACEOF
10859 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10866 # Do test here with the proper thread flags
10867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror_r returns int" >&5
10868 $as_echo_n "checking whether strerror_r returns int... " >&6; }
10869 if ${pgac_cv_func_strerror_r_int+:} false; then :
10870 $as_echo_n "(cached) " >&6
10872 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10873 /* end confdefs.h. */
10874 #include <string.h>
10879 switch (strerror_r(1, buf, sizeof(buf)))
10880 { case 0: break; default: break; }
10886 if ac_fn_c_try_compile "$LINENO"; then :
10887 pgac_cv_func_strerror_r_int=yes
10889 pgac_cv_func_strerror_r_int=no
10891 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_func_strerror_r_int" >&5
10894 $as_echo "$pgac_cv_func_strerror_r_int" >&6; }
10895 if test x"$pgac_cv_func_strerror_r_int" = xyes ; then
10897 $as_echo "#define STRERROR_R_INT 1" >>confdefs.h
10908 # do not use values from template file
10921 ## Most libraries are included only if they demonstrably provide a function
10922 ## we need, but libm is an exception: always include it, because there are
10923 ## too many compilers that play cute optimization games that will break
10924 ## probes for standard functions such as pow().
10927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lm" >&5
10928 $as_echo_n "checking for main in -lm... " >&6; }
10929 if ${ac_cv_lib_m_main+:} false; then :
10930 $as_echo_n "(cached) " >&6
10932 ac_check_lib_save_LIBS=$LIBS
10934 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10935 /* end confdefs.h. */
10946 if ac_fn_c_try_link "$LINENO"; then :
10947 ac_cv_lib_m_main=yes
10949 ac_cv_lib_m_main=no
10951 rm -f core conftest.err conftest.$ac_objext \
10952 conftest$ac_exeext conftest.$ac_ext
10953 LIBS=$ac_check_lib_save_LIBS
10955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_main" >&5
10956 $as_echo "$ac_cv_lib_m_main" >&6; }
10957 if test "x$ac_cv_lib_m_main" = xyes; then :
10958 cat >>confdefs.h <<_ACEOF
10959 #define HAVE_LIBM 1
10966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setproctitle" >&5
10967 $as_echo_n "checking for library containing setproctitle... " >&6; }
10968 if ${ac_cv_search_setproctitle+:} false; then :
10969 $as_echo_n "(cached) " >&6
10971 ac_func_search_save_LIBS=$LIBS
10972 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10973 /* end confdefs.h. */
10975 /* Override any GCC internal prototype to avoid an error.
10976 Use char because int might match the return type of a GCC
10977 builtin and then its argument prototype would still apply. */
10981 char setproctitle ();
10985 return setproctitle ();
10990 for ac_lib in '' util; do
10991 if test -z "$ac_lib"; then
10992 ac_res="none required"
10995 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
10997 if ac_fn_c_try_link "$LINENO"; then :
10998 ac_cv_search_setproctitle=$ac_res
11000 rm -f core conftest.err conftest.$ac_objext \
11002 if ${ac_cv_search_setproctitle+:} false; then :
11006 if ${ac_cv_search_setproctitle+:} false; then :
11009 ac_cv_search_setproctitle=no
11011 rm conftest.$ac_ext
11012 LIBS=$ac_func_search_save_LIBS
11014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setproctitle" >&5
11015 $as_echo "$ac_cv_search_setproctitle" >&6; }
11016 ac_res=$ac_cv_search_setproctitle
11017 if test "$ac_res" != no; then :
11018 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
11023 $as_echo_n "checking for library containing dlopen... " >&6; }
11024 if ${ac_cv_search_dlopen+:} false; then :
11025 $as_echo_n "(cached) " >&6
11027 ac_func_search_save_LIBS=$LIBS
11028 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11029 /* end confdefs.h. */
11031 /* Override any GCC internal prototype to avoid an error.
11032 Use char because int might match the return type of a GCC
11033 builtin and then its argument prototype would still apply. */
11046 for ac_lib in '' dl; do
11047 if test -z "$ac_lib"; then
11048 ac_res="none required"
11051 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11053 if ac_fn_c_try_link "$LINENO"; then :
11054 ac_cv_search_dlopen=$ac_res
11056 rm -f core conftest.err conftest.$ac_objext \
11058 if ${ac_cv_search_dlopen+:} false; then :
11062 if ${ac_cv_search_dlopen+:} false; then :
11065 ac_cv_search_dlopen=no
11067 rm conftest.$ac_ext
11068 LIBS=$ac_func_search_save_LIBS
11070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
11071 $as_echo "$ac_cv_search_dlopen" >&6; }
11072 ac_res=$ac_cv_search_dlopen
11073 if test "$ac_res" != no; then :
11074 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11078 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socket" >&5
11079 $as_echo_n "checking for library containing socket... " >&6; }
11080 if ${ac_cv_search_socket+:} false; then :
11081 $as_echo_n "(cached) " >&6
11083 ac_func_search_save_LIBS=$LIBS
11084 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11085 /* end confdefs.h. */
11087 /* Override any GCC internal prototype to avoid an error.
11088 Use char because int might match the return type of a GCC
11089 builtin and then its argument prototype would still apply. */
11102 for ac_lib in '' socket ws2_32; do
11103 if test -z "$ac_lib"; then
11104 ac_res="none required"
11107 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11109 if ac_fn_c_try_link "$LINENO"; then :
11110 ac_cv_search_socket=$ac_res
11112 rm -f core conftest.err conftest.$ac_objext \
11114 if ${ac_cv_search_socket+:} false; then :
11118 if ${ac_cv_search_socket+:} false; then :
11121 ac_cv_search_socket=no
11123 rm conftest.$ac_ext
11124 LIBS=$ac_func_search_save_LIBS
11126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socket" >&5
11127 $as_echo "$ac_cv_search_socket" >&6; }
11128 ac_res=$ac_cv_search_socket
11129 if test "$ac_res" != no; then :
11130 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11134 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing shl_load" >&5
11135 $as_echo_n "checking for library containing shl_load... " >&6; }
11136 if ${ac_cv_search_shl_load+:} false; then :
11137 $as_echo_n "(cached) " >&6
11139 ac_func_search_save_LIBS=$LIBS
11140 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11141 /* end confdefs.h. */
11143 /* Override any GCC internal prototype to avoid an error.
11144 Use char because int might match the return type of a GCC
11145 builtin and then its argument prototype would still apply. */
11153 return shl_load ();
11158 for ac_lib in '' dld; do
11159 if test -z "$ac_lib"; then
11160 ac_res="none required"
11163 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11165 if ac_fn_c_try_link "$LINENO"; then :
11166 ac_cv_search_shl_load=$ac_res
11168 rm -f core conftest.err conftest.$ac_objext \
11170 if ${ac_cv_search_shl_load+:} false; then :
11174 if ${ac_cv_search_shl_load+:} false; then :
11177 ac_cv_search_shl_load=no
11179 rm conftest.$ac_ext
11180 LIBS=$ac_func_search_save_LIBS
11182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_shl_load" >&5
11183 $as_echo "$ac_cv_search_shl_load" >&6; }
11184 ac_res=$ac_cv_search_shl_load
11185 if test "$ac_res" != no; then :
11186 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing getopt_long" >&5
11191 $as_echo_n "checking for library containing getopt_long... " >&6; }
11192 if ${ac_cv_search_getopt_long+:} false; then :
11193 $as_echo_n "(cached) " >&6
11195 ac_func_search_save_LIBS=$LIBS
11196 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11197 /* end confdefs.h. */
11199 /* Override any GCC internal prototype to avoid an error.
11200 Use char because int might match the return type of a GCC
11201 builtin and then its argument prototype would still apply. */
11205 char getopt_long ();
11209 return getopt_long ();
11214 for ac_lib in '' getopt gnugetopt; do
11215 if test -z "$ac_lib"; then
11216 ac_res="none required"
11219 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11221 if ac_fn_c_try_link "$LINENO"; then :
11222 ac_cv_search_getopt_long=$ac_res
11224 rm -f core conftest.err conftest.$ac_objext \
11226 if ${ac_cv_search_getopt_long+:} false; then :
11230 if ${ac_cv_search_getopt_long+:} false; then :
11233 ac_cv_search_getopt_long=no
11235 rm conftest.$ac_ext
11236 LIBS=$ac_func_search_save_LIBS
11238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getopt_long" >&5
11239 $as_echo "$ac_cv_search_getopt_long" >&6; }
11240 ac_res=$ac_cv_search_getopt_long
11241 if test "$ac_res" != no; then :
11242 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing crypt" >&5
11247 $as_echo_n "checking for library containing crypt... " >&6; }
11248 if ${ac_cv_search_crypt+:} false; then :
11249 $as_echo_n "(cached) " >&6
11251 ac_func_search_save_LIBS=$LIBS
11252 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11253 /* end confdefs.h. */
11255 /* Override any GCC internal prototype to avoid an error.
11256 Use char because int might match the return type of a GCC
11257 builtin and then its argument prototype would still apply. */
11270 for ac_lib in '' crypt; do
11271 if test -z "$ac_lib"; then
11272 ac_res="none required"
11275 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11277 if ac_fn_c_try_link "$LINENO"; then :
11278 ac_cv_search_crypt=$ac_res
11280 rm -f core conftest.err conftest.$ac_objext \
11282 if ${ac_cv_search_crypt+:} false; then :
11286 if ${ac_cv_search_crypt+:} false; then :
11289 ac_cv_search_crypt=no
11291 rm conftest.$ac_ext
11292 LIBS=$ac_func_search_save_LIBS
11294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_crypt" >&5
11295 $as_echo "$ac_cv_search_crypt" >&6; }
11296 ac_res=$ac_cv_search_crypt
11297 if test "$ac_res" != no; then :
11298 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing shm_open" >&5
11303 $as_echo_n "checking for library containing shm_open... " >&6; }
11304 if ${ac_cv_search_shm_open+:} false; then :
11305 $as_echo_n "(cached) " >&6
11307 ac_func_search_save_LIBS=$LIBS
11308 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11309 /* end confdefs.h. */
11311 /* Override any GCC internal prototype to avoid an error.
11312 Use char because int might match the return type of a GCC
11313 builtin and then its argument prototype would still apply. */
11321 return shm_open ();
11326 for ac_lib in '' rt; do
11327 if test -z "$ac_lib"; then
11328 ac_res="none required"
11331 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11333 if ac_fn_c_try_link "$LINENO"; then :
11334 ac_cv_search_shm_open=$ac_res
11336 rm -f core conftest.err conftest.$ac_objext \
11338 if ${ac_cv_search_shm_open+:} false; then :
11342 if ${ac_cv_search_shm_open+:} false; then :
11345 ac_cv_search_shm_open=no
11347 rm conftest.$ac_ext
11348 LIBS=$ac_func_search_save_LIBS
11350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_shm_open" >&5
11351 $as_echo "$ac_cv_search_shm_open" >&6; }
11352 ac_res=$ac_cv_search_shm_open
11353 if test "$ac_res" != no; then :
11354 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing shm_unlink" >&5
11359 $as_echo_n "checking for library containing shm_unlink... " >&6; }
11360 if ${ac_cv_search_shm_unlink+:} false; then :
11361 $as_echo_n "(cached) " >&6
11363 ac_func_search_save_LIBS=$LIBS
11364 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11365 /* end confdefs.h. */
11367 /* Override any GCC internal prototype to avoid an error.
11368 Use char because int might match the return type of a GCC
11369 builtin and then its argument prototype would still apply. */
11373 char shm_unlink ();
11377 return shm_unlink ();
11382 for ac_lib in '' rt; do
11383 if test -z "$ac_lib"; then
11384 ac_res="none required"
11387 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11389 if ac_fn_c_try_link "$LINENO"; then :
11390 ac_cv_search_shm_unlink=$ac_res
11392 rm -f core conftest.err conftest.$ac_objext \
11394 if ${ac_cv_search_shm_unlink+:} false; then :
11398 if ${ac_cv_search_shm_unlink+:} false; then :
11401 ac_cv_search_shm_unlink=no
11403 rm conftest.$ac_ext
11404 LIBS=$ac_func_search_save_LIBS
11406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_shm_unlink" >&5
11407 $as_echo "$ac_cv_search_shm_unlink" >&6; }
11408 ac_res=$ac_cv_search_shm_unlink
11409 if test "$ac_res" != no; then :
11410 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
11415 $as_echo_n "checking for library containing clock_gettime... " >&6; }
11416 if ${ac_cv_search_clock_gettime+:} false; then :
11417 $as_echo_n "(cached) " >&6
11419 ac_func_search_save_LIBS=$LIBS
11420 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11421 /* end confdefs.h. */
11423 /* Override any GCC internal prototype to avoid an error.
11424 Use char because int might match the return type of a GCC
11425 builtin and then its argument prototype would still apply. */
11429 char clock_gettime ();
11433 return clock_gettime ();
11438 for ac_lib in '' rt posix4; do
11439 if test -z "$ac_lib"; then
11440 ac_res="none required"
11443 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11445 if ac_fn_c_try_link "$LINENO"; then :
11446 ac_cv_search_clock_gettime=$ac_res
11448 rm -f core conftest.err conftest.$ac_objext \
11450 if ${ac_cv_search_clock_gettime+:} false; then :
11454 if ${ac_cv_search_clock_gettime+:} false; then :
11457 ac_cv_search_clock_gettime=no
11459 rm conftest.$ac_ext
11460 LIBS=$ac_func_search_save_LIBS
11462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
11463 $as_echo "$ac_cv_search_clock_gettime" >&6; }
11464 ac_res=$ac_cv_search_clock_gettime
11465 if test "$ac_res" != no; then :
11466 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11471 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing fdatasync" >&5
11472 $as_echo_n "checking for library containing fdatasync... " >&6; }
11473 if ${ac_cv_search_fdatasync+:} false; then :
11474 $as_echo_n "(cached) " >&6
11476 ac_func_search_save_LIBS=$LIBS
11477 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11478 /* end confdefs.h. */
11480 /* Override any GCC internal prototype to avoid an error.
11481 Use char because int might match the return type of a GCC
11482 builtin and then its argument prototype would still apply. */
11490 return fdatasync ();
11495 for ac_lib in '' rt posix4; do
11496 if test -z "$ac_lib"; then
11497 ac_res="none required"
11500 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11502 if ac_fn_c_try_link "$LINENO"; then :
11503 ac_cv_search_fdatasync=$ac_res
11505 rm -f core conftest.err conftest.$ac_objext \
11507 if ${ac_cv_search_fdatasync+:} false; then :
11511 if ${ac_cv_search_fdatasync+:} false; then :
11514 ac_cv_search_fdatasync=no
11516 rm conftest.$ac_ext
11517 LIBS=$ac_func_search_save_LIBS
11519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_fdatasync" >&5
11520 $as_echo "$ac_cv_search_fdatasync" >&6; }
11521 ac_res=$ac_cv_search_fdatasync
11522 if test "$ac_res" != no; then :
11523 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11527 # Required for thread_test.c on Solaris
11528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sched_yield" >&5
11529 $as_echo_n "checking for library containing sched_yield... " >&6; }
11530 if ${ac_cv_search_sched_yield+:} false; then :
11531 $as_echo_n "(cached) " >&6
11533 ac_func_search_save_LIBS=$LIBS
11534 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11535 /* end confdefs.h. */
11537 /* Override any GCC internal prototype to avoid an error.
11538 Use char because int might match the return type of a GCC
11539 builtin and then its argument prototype would still apply. */
11543 char sched_yield ();
11547 return sched_yield ();
11552 for ac_lib in '' rt; do
11553 if test -z "$ac_lib"; then
11554 ac_res="none required"
11557 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11559 if ac_fn_c_try_link "$LINENO"; then :
11560 ac_cv_search_sched_yield=$ac_res
11562 rm -f core conftest.err conftest.$ac_objext \
11564 if ${ac_cv_search_sched_yield+:} false; then :
11568 if ${ac_cv_search_sched_yield+:} false; then :
11571 ac_cv_search_sched_yield=no
11573 rm conftest.$ac_ext
11574 LIBS=$ac_func_search_save_LIBS
11576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sched_yield" >&5
11577 $as_echo "$ac_cv_search_sched_yield" >&6; }
11578 ac_res=$ac_cv_search_sched_yield
11579 if test "$ac_res" != no; then :
11580 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11584 # Required for thread_test.c on Solaris 2.5:
11585 # Other ports use it too (HP-UX) so test unconditionally
11586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname_r" >&5
11587 $as_echo_n "checking for library containing gethostbyname_r... " >&6; }
11588 if ${ac_cv_search_gethostbyname_r+:} false; then :
11589 $as_echo_n "(cached) " >&6
11591 ac_func_search_save_LIBS=$LIBS
11592 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11593 /* end confdefs.h. */
11595 /* Override any GCC internal prototype to avoid an error.
11596 Use char because int might match the return type of a GCC
11597 builtin and then its argument prototype would still apply. */
11601 char gethostbyname_r ();
11605 return gethostbyname_r ();
11610 for ac_lib in '' nsl; do
11611 if test -z "$ac_lib"; then
11612 ac_res="none required"
11615 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11617 if ac_fn_c_try_link "$LINENO"; then :
11618 ac_cv_search_gethostbyname_r=$ac_res
11620 rm -f core conftest.err conftest.$ac_objext \
11622 if ${ac_cv_search_gethostbyname_r+:} false; then :
11626 if ${ac_cv_search_gethostbyname_r+:} false; then :
11629 ac_cv_search_gethostbyname_r=no
11631 rm conftest.$ac_ext
11632 LIBS=$ac_func_search_save_LIBS
11634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname_r" >&5
11635 $as_echo "$ac_cv_search_gethostbyname_r" >&6; }
11636 ac_res=$ac_cv_search_gethostbyname_r
11637 if test "$ac_res" != no; then :
11638 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11643 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing shmget" >&5
11644 $as_echo_n "checking for library containing shmget... " >&6; }
11645 if ${ac_cv_search_shmget+:} false; then :
11646 $as_echo_n "(cached) " >&6
11648 ac_func_search_save_LIBS=$LIBS
11649 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11650 /* end confdefs.h. */
11652 /* Override any GCC internal prototype to avoid an error.
11653 Use char because int might match the return type of a GCC
11654 builtin and then its argument prototype would still apply. */
11667 for ac_lib in '' cygipc; do
11668 if test -z "$ac_lib"; then
11669 ac_res="none required"
11672 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11674 if ac_fn_c_try_link "$LINENO"; then :
11675 ac_cv_search_shmget=$ac_res
11677 rm -f core conftest.err conftest.$ac_objext \
11679 if ${ac_cv_search_shmget+:} false; then :
11683 if ${ac_cv_search_shmget+:} false; then :
11686 ac_cv_search_shmget=no
11688 rm conftest.$ac_ext
11689 LIBS=$ac_func_search_save_LIBS
11691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_shmget" >&5
11692 $as_echo "$ac_cv_search_shmget" >&6; }
11693 ac_res=$ac_cv_search_shmget
11694 if test "$ac_res" != no; then :
11695 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11700 if test "$with_readline" = yes; then
11703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing readline" >&5
11704 $as_echo_n "checking for library containing readline... " >&6; }
11705 if ${pgac_cv_check_readline+:} false; then :
11706 $as_echo_n "(cached) " >&6
11708 pgac_cv_check_readline=no
11709 pgac_save_LIBS=$LIBS
11710 if test x"$with_libedit_preferred" != x"yes"
11711 then READLINE_ORDER="-lreadline -ledit"
11712 else READLINE_ORDER="-ledit -lreadline"
11714 for pgac_rllib in $READLINE_ORDER ; do
11715 for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
11716 LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
11717 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11718 /* end confdefs.h. */
11720 /* Override any GCC internal prototype to avoid an error.
11721 Use char because int might match the return type of a GCC
11722 builtin and then its argument prototype would still apply. */
11730 return readline ();
11735 if ac_fn_c_try_link "$LINENO"; then :
11737 # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
11738 # recognize dependent libraries; assume curses is needed if we didn't
11739 # find any dependency.
11741 netbsd* | openbsd* | irix*)
11742 if test x"$pgac_lib" = x"" ; then
11743 pgac_lib=" -lcurses"
11747 pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
11751 rm -f core conftest.err conftest.$ac_objext \
11752 conftest$ac_exeext conftest.$ac_ext
11754 if test "$pgac_cv_check_readline" != no ; then
11758 LIBS=$pgac_save_LIBS
11761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_check_readline" >&5
11762 $as_echo "$pgac_cv_check_readline" >&6; }
11763 if test "$pgac_cv_check_readline" != no ; then
11764 LIBS="$pgac_cv_check_readline $LIBS"
11766 $as_echo "#define HAVE_LIBREADLINE 1" >>confdefs.h
11771 if test x"$pgac_cv_check_readline" = x"no"; then
11772 as_fn_error $? "readline library not found
11773 If you have readline already installed, see config.log for details on the
11774 failure. It is possible the compiler isn't looking in the proper directory.
11775 Use --without-readline to disable readline support." "$LINENO" 5
11779 if test "$with_zlib" = yes; then
11780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inflate in -lz" >&5
11781 $as_echo_n "checking for inflate in -lz... " >&6; }
11782 if ${ac_cv_lib_z_inflate+:} false; then :
11783 $as_echo_n "(cached) " >&6
11785 ac_check_lib_save_LIBS=$LIBS
11787 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11788 /* end confdefs.h. */
11790 /* Override any GCC internal prototype to avoid an error.
11791 Use char because int might match the return type of a GCC
11792 builtin and then its argument prototype would still apply. */
11805 if ac_fn_c_try_link "$LINENO"; then :
11806 ac_cv_lib_z_inflate=yes
11808 ac_cv_lib_z_inflate=no
11810 rm -f core conftest.err conftest.$ac_objext \
11811 conftest$ac_exeext conftest.$ac_ext
11812 LIBS=$ac_check_lib_save_LIBS
11814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_inflate" >&5
11815 $as_echo "$ac_cv_lib_z_inflate" >&6; }
11816 if test "x$ac_cv_lib_z_inflate" = xyes; then :
11817 cat >>confdefs.h <<_ACEOF
11818 #define HAVE_LIBZ 1
11824 as_fn_error $? "zlib library not found
11825 If you have zlib already installed, see config.log for details on the
11826 failure. It is possible the compiler isn't looking in the proper directory.
11827 Use --without-zlib to disable zlib support." "$LINENO" 5
11832 if test "$enable_spinlocks" = yes; then
11834 $as_echo "#define HAVE_SPINLOCKS 1" >>confdefs.h
11837 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
11838 *** Not using spinlocks will cause poor performance." >&5
11839 $as_echo "$as_me: WARNING:
11840 *** Not using spinlocks will cause poor performance." >&2;}
11843 if test "$enable_atomics" = yes; then
11845 $as_echo "#define HAVE_ATOMICS 1" >>confdefs.h
11848 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
11849 *** Not using atomic operations will cause poor performance." >&5
11850 $as_echo "$as_me: WARNING:
11851 *** Not using atomic operations will cause poor performance." >&2;}
11854 if test "$with_gssapi" = yes ; then
11855 if test "$PORTNAME" != "win32"; then
11856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gss_init_sec_context" >&5
11857 $as_echo_n "checking for library containing gss_init_sec_context... " >&6; }
11858 if ${ac_cv_search_gss_init_sec_context+:} false; then :
11859 $as_echo_n "(cached) " >&6
11861 ac_func_search_save_LIBS=$LIBS
11862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11863 /* end confdefs.h. */
11865 /* Override any GCC internal prototype to avoid an error.
11866 Use char because int might match the return type of a GCC
11867 builtin and then its argument prototype would still apply. */
11871 char gss_init_sec_context ();
11875 return gss_init_sec_context ();
11880 for ac_lib in '' gssapi_krb5 gss 'gssapi -lkrb5 -lcrypto'; do
11881 if test -z "$ac_lib"; then
11882 ac_res="none required"
11885 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11887 if ac_fn_c_try_link "$LINENO"; then :
11888 ac_cv_search_gss_init_sec_context=$ac_res
11890 rm -f core conftest.err conftest.$ac_objext \
11892 if ${ac_cv_search_gss_init_sec_context+:} false; then :
11896 if ${ac_cv_search_gss_init_sec_context+:} false; then :
11899 ac_cv_search_gss_init_sec_context=no
11901 rm conftest.$ac_ext
11902 LIBS=$ac_func_search_save_LIBS
11904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gss_init_sec_context" >&5
11905 $as_echo "$ac_cv_search_gss_init_sec_context" >&6; }
11906 ac_res=$ac_cv_search_gss_init_sec_context
11907 if test "$ac_res" != no; then :
11908 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11911 as_fn_error $? "could not find function 'gss_init_sec_context' required for GSSAPI" "$LINENO" 5
11915 LIBS="$LIBS -lgssapi32"
11919 if test "$with_openssl" = yes ; then
11920 if test "$PORTNAME" != "win32"; then
11921 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CRYPTO_new_ex_data in -lcrypto" >&5
11922 $as_echo_n "checking for CRYPTO_new_ex_data in -lcrypto... " >&6; }
11923 if ${ac_cv_lib_crypto_CRYPTO_new_ex_data+:} false; then :
11924 $as_echo_n "(cached) " >&6
11926 ac_check_lib_save_LIBS=$LIBS
11927 LIBS="-lcrypto $LIBS"
11928 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11929 /* end confdefs.h. */
11931 /* Override any GCC internal prototype to avoid an error.
11932 Use char because int might match the return type of a GCC
11933 builtin and then its argument prototype would still apply. */
11937 char CRYPTO_new_ex_data ();
11941 return CRYPTO_new_ex_data ();
11946 if ac_fn_c_try_link "$LINENO"; then :
11947 ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
11949 ac_cv_lib_crypto_CRYPTO_new_ex_data=no
11951 rm -f core conftest.err conftest.$ac_objext \
11952 conftest$ac_exeext conftest.$ac_ext
11953 LIBS=$ac_check_lib_save_LIBS
11955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
11956 $as_echo "$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6; }
11957 if test "x$ac_cv_lib_crypto_CRYPTO_new_ex_data" = xyes; then :
11958 cat >>confdefs.h <<_ACEOF
11959 #define HAVE_LIBCRYPTO 1
11962 LIBS="-lcrypto $LIBS"
11965 as_fn_error $? "library 'crypto' is required for OpenSSL" "$LINENO" 5
11968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL_new in -lssl" >&5
11969 $as_echo_n "checking for SSL_new in -lssl... " >&6; }
11970 if ${ac_cv_lib_ssl_SSL_new+:} false; then :
11971 $as_echo_n "(cached) " >&6
11973 ac_check_lib_save_LIBS=$LIBS
11975 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11976 /* end confdefs.h. */
11978 /* Override any GCC internal prototype to avoid an error.
11979 Use char because int might match the return type of a GCC
11980 builtin and then its argument prototype would still apply. */
11993 if ac_fn_c_try_link "$LINENO"; then :
11994 ac_cv_lib_ssl_SSL_new=yes
11996 ac_cv_lib_ssl_SSL_new=no
11998 rm -f core conftest.err conftest.$ac_objext \
11999 conftest$ac_exeext conftest.$ac_ext
12000 LIBS=$ac_check_lib_save_LIBS
12002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ssl_SSL_new" >&5
12003 $as_echo "$ac_cv_lib_ssl_SSL_new" >&6; }
12004 if test "x$ac_cv_lib_ssl_SSL_new" = xyes; then :
12005 cat >>confdefs.h <<_ACEOF
12006 #define HAVE_LIBSSL 1
12012 as_fn_error $? "library 'ssl' is required for OpenSSL" "$LINENO" 5
12016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing CRYPTO_new_ex_data" >&5
12017 $as_echo_n "checking for library containing CRYPTO_new_ex_data... " >&6; }
12018 if ${ac_cv_search_CRYPTO_new_ex_data+:} false; then :
12019 $as_echo_n "(cached) " >&6
12021 ac_func_search_save_LIBS=$LIBS
12022 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12023 /* end confdefs.h. */
12025 /* Override any GCC internal prototype to avoid an error.
12026 Use char because int might match the return type of a GCC
12027 builtin and then its argument prototype would still apply. */
12031 char CRYPTO_new_ex_data ();
12035 return CRYPTO_new_ex_data ();
12040 for ac_lib in '' eay32 crypto; do
12041 if test -z "$ac_lib"; then
12042 ac_res="none required"
12045 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
12047 if ac_fn_c_try_link "$LINENO"; then :
12048 ac_cv_search_CRYPTO_new_ex_data=$ac_res
12050 rm -f core conftest.err conftest.$ac_objext \
12052 if ${ac_cv_search_CRYPTO_new_ex_data+:} false; then :
12056 if ${ac_cv_search_CRYPTO_new_ex_data+:} false; then :
12059 ac_cv_search_CRYPTO_new_ex_data=no
12061 rm conftest.$ac_ext
12062 LIBS=$ac_func_search_save_LIBS
12064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_CRYPTO_new_ex_data" >&5
12065 $as_echo "$ac_cv_search_CRYPTO_new_ex_data" >&6; }
12066 ac_res=$ac_cv_search_CRYPTO_new_ex_data
12067 if test "$ac_res" != no; then :
12068 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
12071 as_fn_error $? "library 'eay32' or 'crypto' is required for OpenSSL" "$LINENO" 5
12074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing SSL_new" >&5
12075 $as_echo_n "checking for library containing SSL_new... " >&6; }
12076 if ${ac_cv_search_SSL_new+:} false; then :
12077 $as_echo_n "(cached) " >&6
12079 ac_func_search_save_LIBS=$LIBS
12080 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12081 /* end confdefs.h. */
12083 /* Override any GCC internal prototype to avoid an error.
12084 Use char because int might match the return type of a GCC
12085 builtin and then its argument prototype would still apply. */
12098 for ac_lib in '' ssleay32 ssl; do
12099 if test -z "$ac_lib"; then
12100 ac_res="none required"
12103 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
12105 if ac_fn_c_try_link "$LINENO"; then :
12106 ac_cv_search_SSL_new=$ac_res
12108 rm -f core conftest.err conftest.$ac_objext \
12110 if ${ac_cv_search_SSL_new+:} false; then :
12114 if ${ac_cv_search_SSL_new+:} false; then :
12117 ac_cv_search_SSL_new=no
12119 rm conftest.$ac_ext
12120 LIBS=$ac_func_search_save_LIBS
12122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_SSL_new" >&5
12123 $as_echo "$ac_cv_search_SSL_new" >&6; }
12124 ac_res=$ac_cv_search_SSL_new
12125 if test "$ac_res" != no; then :
12126 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
12129 as_fn_error $? "library 'ssleay32' or 'ssl' is required for OpenSSL" "$LINENO" 5
12133 for ac_func in SSL_clear_options SSL_get_current_compression X509_get_signature_nid
12135 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
12136 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
12137 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
12138 cat >>confdefs.h <<_ACEOF
12139 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
12145 # Functions introduced in OpenSSL 1.1.0. We used to check for
12146 # OPENSSL_VERSION_NUMBER, but that didn't work with 1.1.0, because LibreSSL
12147 # defines OPENSSL_VERSION_NUMBER to claim version 2.0.0, even though it
12148 # doesn't have these OpenSSL 1.1.0 functions. So check for individual
12150 for ac_func in OPENSSL_init_ssl BIO_get_data BIO_meth_new ASN1_STRING_get0_data RAND_OpenSSL
12152 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
12153 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
12154 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
12155 cat >>confdefs.h <<_ACEOF
12156 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
12162 # OpenSSL versions before 1.1.0 required setting callback functions, for
12163 # thread-safety. In 1.1.0, it's no longer required, and CRYPTO_lock()
12164 # function was removed.
12165 for ac_func in CRYPTO_lock
12167 ac_fn_c_check_func "$LINENO" "CRYPTO_lock" "ac_cv_func_CRYPTO_lock"
12168 if test "x$ac_cv_func_CRYPTO_lock" = xyes; then :
12169 cat >>confdefs.h <<_ACEOF
12170 #define HAVE_CRYPTO_LOCK 1
12178 if test "$with_pam" = yes ; then
12179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pam_start in -lpam" >&5
12180 $as_echo_n "checking for pam_start in -lpam... " >&6; }
12181 if ${ac_cv_lib_pam_pam_start+:} false; then :
12182 $as_echo_n "(cached) " >&6
12184 ac_check_lib_save_LIBS=$LIBS
12186 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12187 /* end confdefs.h. */
12189 /* Override any GCC internal prototype to avoid an error.
12190 Use char because int might match the return type of a GCC
12191 builtin and then its argument prototype would still apply. */
12199 return pam_start ();
12204 if ac_fn_c_try_link "$LINENO"; then :
12205 ac_cv_lib_pam_pam_start=yes
12207 ac_cv_lib_pam_pam_start=no
12209 rm -f core conftest.err conftest.$ac_objext \
12210 conftest$ac_exeext conftest.$ac_ext
12211 LIBS=$ac_check_lib_save_LIBS
12213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pam_pam_start" >&5
12214 $as_echo "$ac_cv_lib_pam_pam_start" >&6; }
12215 if test "x$ac_cv_lib_pam_pam_start" = xyes; then :
12216 cat >>confdefs.h <<_ACEOF
12217 #define HAVE_LIBPAM 1
12223 as_fn_error $? "library 'pam' is required for PAM" "$LINENO" 5
12228 if test "$with_libxml" = yes ; then
12229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xmlSaveToBuffer in -lxml2" >&5
12230 $as_echo_n "checking for xmlSaveToBuffer in -lxml2... " >&6; }
12231 if ${ac_cv_lib_xml2_xmlSaveToBuffer+:} false; then :
12232 $as_echo_n "(cached) " >&6
12234 ac_check_lib_save_LIBS=$LIBS
12235 LIBS="-lxml2 $LIBS"
12236 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12237 /* end confdefs.h. */
12239 /* Override any GCC internal prototype to avoid an error.
12240 Use char because int might match the return type of a GCC
12241 builtin and then its argument prototype would still apply. */
12245 char xmlSaveToBuffer ();
12249 return xmlSaveToBuffer ();
12254 if ac_fn_c_try_link "$LINENO"; then :
12255 ac_cv_lib_xml2_xmlSaveToBuffer=yes
12257 ac_cv_lib_xml2_xmlSaveToBuffer=no
12259 rm -f core conftest.err conftest.$ac_objext \
12260 conftest$ac_exeext conftest.$ac_ext
12261 LIBS=$ac_check_lib_save_LIBS
12263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_xmlSaveToBuffer" >&5
12264 $as_echo "$ac_cv_lib_xml2_xmlSaveToBuffer" >&6; }
12265 if test "x$ac_cv_lib_xml2_xmlSaveToBuffer" = xyes; then :
12266 cat >>confdefs.h <<_ACEOF
12267 #define HAVE_LIBXML2 1
12270 LIBS="-lxml2 $LIBS"
12273 as_fn_error $? "library 'xml2' (version >= 2.6.23) is required for XML support" "$LINENO" 5
12278 if test "$with_libxslt" = yes ; then
12279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xsltCleanupGlobals in -lxslt" >&5
12280 $as_echo_n "checking for xsltCleanupGlobals in -lxslt... " >&6; }
12281 if ${ac_cv_lib_xslt_xsltCleanupGlobals+:} false; then :
12282 $as_echo_n "(cached) " >&6
12284 ac_check_lib_save_LIBS=$LIBS
12285 LIBS="-lxslt $LIBS"
12286 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12287 /* end confdefs.h. */
12289 /* Override any GCC internal prototype to avoid an error.
12290 Use char because int might match the return type of a GCC
12291 builtin and then its argument prototype would still apply. */
12295 char xsltCleanupGlobals ();
12299 return xsltCleanupGlobals ();
12304 if ac_fn_c_try_link "$LINENO"; then :
12305 ac_cv_lib_xslt_xsltCleanupGlobals=yes
12307 ac_cv_lib_xslt_xsltCleanupGlobals=no
12309 rm -f core conftest.err conftest.$ac_objext \
12310 conftest$ac_exeext conftest.$ac_ext
12311 LIBS=$ac_check_lib_save_LIBS
12313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xslt_xsltCleanupGlobals" >&5
12314 $as_echo "$ac_cv_lib_xslt_xsltCleanupGlobals" >&6; }
12315 if test "x$ac_cv_lib_xslt_xsltCleanupGlobals" = xyes; then :
12316 cat >>confdefs.h <<_ACEOF
12317 #define HAVE_LIBXSLT 1
12320 LIBS="-lxslt $LIBS"
12323 as_fn_error $? "library 'xslt' is required for XSLT support" "$LINENO" 5
12328 # Note: We can test for libldap_r only after we know PTHREAD_LIBS
12329 if test "$with_ldap" = yes ; then
12331 if test "$PORTNAME" != "win32"; then
12332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ldap_bind in -lldap" >&5
12333 $as_echo_n "checking for ldap_bind in -lldap... " >&6; }
12334 if ${ac_cv_lib_ldap_ldap_bind+:} false; then :
12335 $as_echo_n "(cached) " >&6
12337 ac_check_lib_save_LIBS=$LIBS
12338 LIBS="-lldap $EXTRA_LDAP_LIBS $LIBS"
12339 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12340 /* end confdefs.h. */
12342 /* Override any GCC internal prototype to avoid an error.
12343 Use char because int might match the return type of a GCC
12344 builtin and then its argument prototype would still apply. */
12352 return ldap_bind ();
12357 if ac_fn_c_try_link "$LINENO"; then :
12358 ac_cv_lib_ldap_ldap_bind=yes
12360 ac_cv_lib_ldap_ldap_bind=no
12362 rm -f core conftest.err conftest.$ac_objext \
12363 conftest$ac_exeext conftest.$ac_ext
12364 LIBS=$ac_check_lib_save_LIBS
12366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ldap_ldap_bind" >&5
12367 $as_echo "$ac_cv_lib_ldap_ldap_bind" >&6; }
12368 if test "x$ac_cv_lib_ldap_ldap_bind" = xyes; then :
12369 cat >>confdefs.h <<_ACEOF
12370 #define HAVE_LIBLDAP 1
12373 LIBS="-lldap $LIBS"
12376 as_fn_error $? "library 'ldap' is required for LDAP" "$LINENO" 5
12379 LDAP_LIBS_BE="-lldap $EXTRA_LDAP_LIBS"
12380 if test "$enable_thread_safety" = yes; then
12381 # on some platforms ldap_r fails to link without PTHREAD_LIBS
12382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ldap_simple_bind in -lldap_r" >&5
12383 $as_echo_n "checking for ldap_simple_bind in -lldap_r... " >&6; }
12384 if ${ac_cv_lib_ldap_r_ldap_simple_bind+:} false; then :
12385 $as_echo_n "(cached) " >&6
12387 ac_check_lib_save_LIBS=$LIBS
12388 LIBS="-lldap_r $PTHREAD_CFLAGS $PTHREAD_LIBS $EXTRA_LDAP_LIBS $LIBS"
12389 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12390 /* end confdefs.h. */
12392 /* Override any GCC internal prototype to avoid an error.
12393 Use char because int might match the return type of a GCC
12394 builtin and then its argument prototype would still apply. */
12398 char ldap_simple_bind ();
12402 return ldap_simple_bind ();
12407 if ac_fn_c_try_link "$LINENO"; then :
12408 ac_cv_lib_ldap_r_ldap_simple_bind=yes
12410 ac_cv_lib_ldap_r_ldap_simple_bind=no
12412 rm -f core conftest.err conftest.$ac_objext \
12413 conftest$ac_exeext conftest.$ac_ext
12414 LIBS=$ac_check_lib_save_LIBS
12416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ldap_r_ldap_simple_bind" >&5
12417 $as_echo "$ac_cv_lib_ldap_r_ldap_simple_bind" >&6; }
12418 if test "x$ac_cv_lib_ldap_r_ldap_simple_bind" = xyes; then :
12419 cat >>confdefs.h <<_ACEOF
12420 #define HAVE_LIBLDAP_R 1
12423 LIBS="-lldap_r $LIBS"
12426 as_fn_error $? "library 'ldap_r' is required for LDAP" "$LINENO" 5
12429 LDAP_LIBS_FE="-lldap_r $EXTRA_LDAP_LIBS"
12431 LDAP_LIBS_FE="-lldap $EXTRA_LDAP_LIBS"
12433 for ac_func in ldap_initialize
12435 ac_fn_c_check_func "$LINENO" "ldap_initialize" "ac_cv_func_ldap_initialize"
12436 if test "x$ac_cv_func_ldap_initialize" = xyes; then :
12437 cat >>confdefs.h <<_ACEOF
12438 #define HAVE_LDAP_INITIALIZE 1
12445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ldap_bind in -lwldap32" >&5
12446 $as_echo_n "checking for ldap_bind in -lwldap32... " >&6; }
12447 if ${ac_cv_lib_wldap32_ldap_bind+:} false; then :
12448 $as_echo_n "(cached) " >&6
12450 ac_check_lib_save_LIBS=$LIBS
12451 LIBS="-lwldap32 $LIBS"
12452 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12453 /* end confdefs.h. */
12455 /* Override any GCC internal prototype to avoid an error.
12456 Use char because int might match the return type of a GCC
12457 builtin and then its argument prototype would still apply. */
12465 return ldap_bind ();
12470 if ac_fn_c_try_link "$LINENO"; then :
12471 ac_cv_lib_wldap32_ldap_bind=yes
12473 ac_cv_lib_wldap32_ldap_bind=no
12475 rm -f core conftest.err conftest.$ac_objext \
12476 conftest$ac_exeext conftest.$ac_ext
12477 LIBS=$ac_check_lib_save_LIBS
12479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_wldap32_ldap_bind" >&5
12480 $as_echo "$ac_cv_lib_wldap32_ldap_bind" >&6; }
12481 if test "x$ac_cv_lib_wldap32_ldap_bind" = xyes; then :
12482 cat >>confdefs.h <<_ACEOF
12483 #define HAVE_LIBWLDAP32 1
12486 LIBS="-lwldap32 $LIBS"
12489 as_fn_error $? "library 'wldap32' is required for LDAP" "$LINENO" 5
12492 LDAP_LIBS_FE="-lwldap32"
12493 LDAP_LIBS_BE="-lwldap32"
12500 # for contrib/sepgsql
12501 if test "$with_selinux" = yes; then
12502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for security_compute_create_name in -lselinux" >&5
12503 $as_echo_n "checking for security_compute_create_name in -lselinux... " >&6; }
12504 if ${ac_cv_lib_selinux_security_compute_create_name+:} false; then :
12505 $as_echo_n "(cached) " >&6
12507 ac_check_lib_save_LIBS=$LIBS
12508 LIBS="-lselinux $LIBS"
12509 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12510 /* end confdefs.h. */
12512 /* Override any GCC internal prototype to avoid an error.
12513 Use char because int might match the return type of a GCC
12514 builtin and then its argument prototype would still apply. */
12518 char security_compute_create_name ();
12522 return security_compute_create_name ();
12527 if ac_fn_c_try_link "$LINENO"; then :
12528 ac_cv_lib_selinux_security_compute_create_name=yes
12530 ac_cv_lib_selinux_security_compute_create_name=no
12532 rm -f core conftest.err conftest.$ac_objext \
12533 conftest$ac_exeext conftest.$ac_ext
12534 LIBS=$ac_check_lib_save_LIBS
12536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_security_compute_create_name" >&5
12537 $as_echo "$ac_cv_lib_selinux_security_compute_create_name" >&6; }
12538 if test "x$ac_cv_lib_selinux_security_compute_create_name" = xyes; then :
12539 cat >>confdefs.h <<_ACEOF
12540 #define HAVE_LIBSELINUX 1
12543 LIBS="-lselinux $LIBS"
12546 as_fn_error $? "library 'libselinux', version 2.1.10 or newer, is required for SELinux support" "$LINENO" 5
12551 # for contrib/uuid-ossp
12552 if test "$with_uuid" = bsd ; then
12553 # On BSD, the UUID functions are in libc
12554 ac_fn_c_check_func "$LINENO" "uuid_to_string" "ac_cv_func_uuid_to_string"
12555 if test "x$ac_cv_func_uuid_to_string" = xyes; then :
12558 as_fn_error $? "BSD UUID functions are not present" "$LINENO" 5
12561 elif test "$with_uuid" = e2fs ; then
12562 # On macOS, the UUID functions are in libc
12563 ac_fn_c_check_func "$LINENO" "uuid_generate" "ac_cv_func_uuid_generate"
12564 if test "x$ac_cv_func_uuid_generate" = xyes; then :
12567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uuid_generate in -luuid" >&5
12568 $as_echo_n "checking for uuid_generate in -luuid... " >&6; }
12569 if ${ac_cv_lib_uuid_uuid_generate+:} false; then :
12570 $as_echo_n "(cached) " >&6
12572 ac_check_lib_save_LIBS=$LIBS
12573 LIBS="-luuid $LIBS"
12574 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12575 /* end confdefs.h. */
12577 /* Override any GCC internal prototype to avoid an error.
12578 Use char because int might match the return type of a GCC
12579 builtin and then its argument prototype would still apply. */
12583 char uuid_generate ();
12587 return uuid_generate ();
12592 if ac_fn_c_try_link "$LINENO"; then :
12593 ac_cv_lib_uuid_uuid_generate=yes
12595 ac_cv_lib_uuid_uuid_generate=no
12597 rm -f core conftest.err conftest.$ac_objext \
12598 conftest$ac_exeext conftest.$ac_ext
12599 LIBS=$ac_check_lib_save_LIBS
12601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_uuid_uuid_generate" >&5
12602 $as_echo "$ac_cv_lib_uuid_uuid_generate" >&6; }
12603 if test "x$ac_cv_lib_uuid_uuid_generate" = xyes; then :
12606 as_fn_error $? "library 'uuid' is required for E2FS UUID" "$LINENO" 5
12611 elif test "$with_uuid" = ossp ; then
12612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uuid_export in -lossp-uuid" >&5
12613 $as_echo_n "checking for uuid_export in -lossp-uuid... " >&6; }
12614 if ${ac_cv_lib_ossp_uuid_uuid_export+:} false; then :
12615 $as_echo_n "(cached) " >&6
12617 ac_check_lib_save_LIBS=$LIBS
12618 LIBS="-lossp-uuid $LIBS"
12619 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12620 /* end confdefs.h. */
12622 /* Override any GCC internal prototype to avoid an error.
12623 Use char because int might match the return type of a GCC
12624 builtin and then its argument prototype would still apply. */
12628 char uuid_export ();
12632 return uuid_export ();
12637 if ac_fn_c_try_link "$LINENO"; then :
12638 ac_cv_lib_ossp_uuid_uuid_export=yes
12640 ac_cv_lib_ossp_uuid_uuid_export=no
12642 rm -f core conftest.err conftest.$ac_objext \
12643 conftest$ac_exeext conftest.$ac_ext
12644 LIBS=$ac_check_lib_save_LIBS
12646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossp_uuid_uuid_export" >&5
12647 $as_echo "$ac_cv_lib_ossp_uuid_uuid_export" >&6; }
12648 if test "x$ac_cv_lib_ossp_uuid_uuid_export" = xyes; then :
12649 UUID_LIBS="-lossp-uuid"
12651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uuid_export in -luuid" >&5
12652 $as_echo_n "checking for uuid_export in -luuid... " >&6; }
12653 if ${ac_cv_lib_uuid_uuid_export+:} false; then :
12654 $as_echo_n "(cached) " >&6
12656 ac_check_lib_save_LIBS=$LIBS
12657 LIBS="-luuid $LIBS"
12658 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12659 /* end confdefs.h. */
12661 /* Override any GCC internal prototype to avoid an error.
12662 Use char because int might match the return type of a GCC
12663 builtin and then its argument prototype would still apply. */
12667 char uuid_export ();
12671 return uuid_export ();
12676 if ac_fn_c_try_link "$LINENO"; then :
12677 ac_cv_lib_uuid_uuid_export=yes
12679 ac_cv_lib_uuid_uuid_export=no
12681 rm -f core conftest.err conftest.$ac_objext \
12682 conftest$ac_exeext conftest.$ac_ext
12683 LIBS=$ac_check_lib_save_LIBS
12685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_uuid_uuid_export" >&5
12686 $as_echo "$ac_cv_lib_uuid_uuid_export" >&6; }
12687 if test "x$ac_cv_lib_uuid_uuid_export" = xyes; then :
12690 as_fn_error $? "library 'ossp-uuid' or 'uuid' is required for OSSP UUID" "$LINENO" 5
12703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
12704 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
12705 if ${ac_cv_header_stdbool_h+:} false; then :
12706 $as_echo_n "(cached) " >&6
12708 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12709 /* end confdefs.h. */
12711 #include <stdbool.h>
12713 "error: bool is not defined"
12716 "error: false is not defined"
12719 "error: false is not 0"
12722 "error: true is not defined"
12725 "error: true is not 1"
12727 #ifndef __bool_true_false_are_defined
12728 "error: __bool_true_false_are_defined is not defined"
12731 struct s { _Bool s: 1; _Bool t; } s;
12733 char a[true == 1 ? 1 : -1];
12734 char b[false == 0 ? 1 : -1];
12735 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
12736 char d[(bool) 0.5 == true ? 1 : -1];
12737 /* See body of main program for 'e'. */
12738 char f[(_Bool) 0.0 == false ? 1 : -1];
12740 char h[sizeof (_Bool)];
12741 char i[sizeof s.t];
12742 enum { j = false, k = true, l = false * true, m = true * 256 };
12743 /* The following fails for
12744 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
12746 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
12747 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
12748 /* Catch a bug in an HP-UX C compiler. See
12749 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
12750 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
12762 /* Refer to every declared value, to avoid compiler optimizations. */
12763 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
12764 + !m + !n + !o + !p + !q + !pq);
12770 if ac_fn_c_try_compile "$LINENO"; then :
12771 ac_cv_header_stdbool_h=yes
12773 ac_cv_header_stdbool_h=no
12775 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
12778 $as_echo "$ac_cv_header_stdbool_h" >&6; }
12779 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
12780 if test "x$ac_cv_type__Bool" = xyes; then :
12782 cat >>confdefs.h <<_ACEOF
12783 #define HAVE__BOOL 1
12790 if test $ac_cv_header_stdbool_h = yes; then
12792 $as_echo "#define HAVE_STDBOOL_H 1" >>confdefs.h
12797 for ac_header in atomic.h copyfile.h crypt.h fp_class.h getopt.h ieeefp.h ifaddrs.h langinfo.h mbarrier.h poll.h sys/epoll.h sys/ipc.h sys/prctl.h sys/procctl.h sys/pstat.h sys/resource.h sys/select.h sys/sem.h sys/shm.h sys/sockio.h sys/tas.h sys/un.h termios.h ucred.h utime.h wchar.h wctype.h
12799 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12800 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12801 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
12802 cat >>confdefs.h <<_ACEOF
12803 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12811 # On BSD, test for net/if.h will fail unless sys/socket.h
12812 # is included first.
12813 for ac_header in net/if.h
12815 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
12816 #include <sys/socket.h>
12819 if test "x$ac_cv_header_net_if_h" = xyes; then :
12820 cat >>confdefs.h <<_ACEOF
12821 #define HAVE_NET_IF_H 1
12829 # On OpenBSD, test for sys/ucred.h will fail unless sys/param.h
12830 # is included first.
12831 for ac_header in sys/ucred.h
12833 ac_fn_c_check_header_compile "$LINENO" "sys/ucred.h" "ac_cv_header_sys_ucred_h" "$ac_includes_default
12834 #include <sys/param.h>
12837 if test "x$ac_cv_header_sys_ucred_h" = xyes; then :
12838 cat >>confdefs.h <<_ACEOF
12839 #define HAVE_SYS_UCRED_H 1
12847 # At least on IRIX, test for netinet/tcp.h will fail unless
12848 # netinet/in.h is included first.
12849 for ac_header in netinet/tcp.h
12851 ac_fn_c_check_header_compile "$LINENO" "netinet/tcp.h" "ac_cv_header_netinet_tcp_h" "$ac_includes_default
12852 #include <netinet/in.h>
12855 if test "x$ac_cv_header_netinet_tcp_h" = xyes; then :
12856 cat >>confdefs.h <<_ACEOF
12857 #define HAVE_NETINET_TCP_H 1
12865 if expr x"$pgac_cv_check_readline" : 'x-lreadline' >/dev/null ; then
12866 for ac_header in readline/readline.h
12868 ac_fn_c_check_header_mongrel "$LINENO" "readline/readline.h" "ac_cv_header_readline_readline_h" "$ac_includes_default"
12869 if test "x$ac_cv_header_readline_readline_h" = xyes; then :
12870 cat >>confdefs.h <<_ACEOF
12871 #define HAVE_READLINE_READLINE_H 1
12875 for ac_header in readline.h
12877 ac_fn_c_check_header_mongrel "$LINENO" "readline.h" "ac_cv_header_readline_h" "$ac_includes_default"
12878 if test "x$ac_cv_header_readline_h" = xyes; then :
12879 cat >>confdefs.h <<_ACEOF
12880 #define HAVE_READLINE_H 1
12884 as_fn_error $? "readline header not found
12885 If you have readline already installed, see config.log for details on the
12886 failure. It is possible the compiler isn't looking in the proper directory.
12887 Use --without-readline to disable readline support." "$LINENO" 5
12896 for ac_header in readline/history.h
12898 ac_fn_c_check_header_mongrel "$LINENO" "readline/history.h" "ac_cv_header_readline_history_h" "$ac_includes_default"
12899 if test "x$ac_cv_header_readline_history_h" = xyes; then :
12900 cat >>confdefs.h <<_ACEOF
12901 #define HAVE_READLINE_HISTORY_H 1
12905 for ac_header in history.h
12907 ac_fn_c_check_header_mongrel "$LINENO" "history.h" "ac_cv_header_history_h" "$ac_includes_default"
12908 if test "x$ac_cv_header_history_h" = xyes; then :
12909 cat >>confdefs.h <<_ACEOF
12910 #define HAVE_HISTORY_H 1
12914 as_fn_error $? "history header not found
12915 If you have readline already installed, see config.log for details on the
12916 failure. It is possible the compiler isn't looking in the proper directory.
12917 Use --without-readline to disable readline support." "$LINENO" 5
12928 if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then
12929 # Some installations of libedit usurp /usr/include/readline/, which seems
12930 # bad practice, since in combined installations readline will have its headers
12931 # there. We might have to resort to AC_EGREP checks to make sure we found
12932 # the proper header...
12933 for ac_header in editline/readline.h
12935 ac_fn_c_check_header_mongrel "$LINENO" "editline/readline.h" "ac_cv_header_editline_readline_h" "$ac_includes_default"
12936 if test "x$ac_cv_header_editline_readline_h" = xyes; then :
12937 cat >>confdefs.h <<_ACEOF
12938 #define HAVE_EDITLINE_READLINE_H 1
12942 for ac_header in readline.h
12944 ac_fn_c_check_header_mongrel "$LINENO" "readline.h" "ac_cv_header_readline_h" "$ac_includes_default"
12945 if test "x$ac_cv_header_readline_h" = xyes; then :
12946 cat >>confdefs.h <<_ACEOF
12947 #define HAVE_READLINE_H 1
12951 for ac_header in readline/readline.h
12953 ac_fn_c_check_header_mongrel "$LINENO" "readline/readline.h" "ac_cv_header_readline_readline_h" "$ac_includes_default"
12954 if test "x$ac_cv_header_readline_readline_h" = xyes; then :
12955 cat >>confdefs.h <<_ACEOF
12956 #define HAVE_READLINE_READLINE_H 1
12960 as_fn_error $? "readline header not found
12961 If you have libedit already installed, see config.log for details on the
12962 failure. It is possible the compiler isn't looking in the proper directory.
12963 Use --without-readline to disable libedit support." "$LINENO" 5
12976 # Note: in a libedit installation, history.h is sometimes a dummy, and may
12977 # not be there at all. Hence, don't complain if not found. We must check
12978 # though, since in yet other versions it is an independent header.
12979 for ac_header in editline/history.h
12981 ac_fn_c_check_header_mongrel "$LINENO" "editline/history.h" "ac_cv_header_editline_history_h" "$ac_includes_default"
12982 if test "x$ac_cv_header_editline_history_h" = xyes; then :
12983 cat >>confdefs.h <<_ACEOF
12984 #define HAVE_EDITLINE_HISTORY_H 1
12988 for ac_header in history.h
12990 ac_fn_c_check_header_mongrel "$LINENO" "history.h" "ac_cv_header_history_h" "$ac_includes_default"
12991 if test "x$ac_cv_header_history_h" = xyes; then :
12992 cat >>confdefs.h <<_ACEOF
12993 #define HAVE_HISTORY_H 1
12997 for ac_header in readline/history.h
12999 ac_fn_c_check_header_mongrel "$LINENO" "readline/history.h" "ac_cv_header_readline_history_h" "$ac_includes_default"
13000 if test "x$ac_cv_header_readline_history_h" = xyes; then :
13001 cat >>confdefs.h <<_ACEOF
13002 #define HAVE_READLINE_HISTORY_H 1
13019 if test "$with_zlib" = yes; then
13020 ac_fn_c_check_header_mongrel "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default"
13021 if test "x$ac_cv_header_zlib_h" = xyes; then :
13024 as_fn_error $? "zlib header not found
13025 If you have zlib already installed, see config.log for details on the
13026 failure. It is possible the compiler isn't looking in the proper directory.
13027 Use --without-zlib to disable zlib support." "$LINENO" 5
13033 if test "$with_gssapi" = yes ; then
13034 for ac_header in gssapi/gssapi.h
13036 ac_fn_c_check_header_mongrel "$LINENO" "gssapi/gssapi.h" "ac_cv_header_gssapi_gssapi_h" "$ac_includes_default"
13037 if test "x$ac_cv_header_gssapi_gssapi_h" = xyes; then :
13038 cat >>confdefs.h <<_ACEOF
13039 #define HAVE_GSSAPI_GSSAPI_H 1
13043 for ac_header in gssapi.h
13045 ac_fn_c_check_header_mongrel "$LINENO" "gssapi.h" "ac_cv_header_gssapi_h" "$ac_includes_default"
13046 if test "x$ac_cv_header_gssapi_h" = xyes; then :
13047 cat >>confdefs.h <<_ACEOF
13048 #define HAVE_GSSAPI_H 1
13052 as_fn_error $? "gssapi.h header file is required for GSSAPI" "$LINENO" 5
13063 if test "$with_openssl" = yes ; then
13064 ac_fn_c_check_header_mongrel "$LINENO" "openssl/ssl.h" "ac_cv_header_openssl_ssl_h" "$ac_includes_default"
13065 if test "x$ac_cv_header_openssl_ssl_h" = xyes; then :
13068 as_fn_error $? "header file <openssl/ssl.h> is required for OpenSSL" "$LINENO" 5
13072 ac_fn_c_check_header_mongrel "$LINENO" "openssl/err.h" "ac_cv_header_openssl_err_h" "$ac_includes_default"
13073 if test "x$ac_cv_header_openssl_err_h" = xyes; then :
13076 as_fn_error $? "header file <openssl/err.h> is required for OpenSSL" "$LINENO" 5
13082 if test "$with_pam" = yes ; then
13083 for ac_header in security/pam_appl.h
13085 ac_fn_c_check_header_mongrel "$LINENO" "security/pam_appl.h" "ac_cv_header_security_pam_appl_h" "$ac_includes_default"
13086 if test "x$ac_cv_header_security_pam_appl_h" = xyes; then :
13087 cat >>confdefs.h <<_ACEOF
13088 #define HAVE_SECURITY_PAM_APPL_H 1
13092 for ac_header in pam/pam_appl.h
13094 ac_fn_c_check_header_mongrel "$LINENO" "pam/pam_appl.h" "ac_cv_header_pam_pam_appl_h" "$ac_includes_default"
13095 if test "x$ac_cv_header_pam_pam_appl_h" = xyes; then :
13096 cat >>confdefs.h <<_ACEOF
13097 #define HAVE_PAM_PAM_APPL_H 1
13101 as_fn_error $? "header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." "$LINENO" 5
13112 if test "$with_bsd_auth" = yes ; then
13113 ac_fn_c_check_header_mongrel "$LINENO" "bsd_auth.h" "ac_cv_header_bsd_auth_h" "$ac_includes_default"
13114 if test "x$ac_cv_header_bsd_auth_h" = xyes; then :
13117 as_fn_error $? "header file <bsd_auth.h> is required for BSD Authentication support" "$LINENO" 5
13123 if test "$with_systemd" = yes ; then
13124 ac_fn_c_check_header_mongrel "$LINENO" "systemd/sd-daemon.h" "ac_cv_header_systemd_sd_daemon_h" "$ac_includes_default"
13125 if test "x$ac_cv_header_systemd_sd_daemon_h" = xyes; then :
13128 as_fn_error $? "header file <systemd/sd-daemon.h> is required for systemd support" "$LINENO" 5
13134 if test "$with_libxml" = yes ; then
13135 ac_fn_c_check_header_mongrel "$LINENO" "libxml/parser.h" "ac_cv_header_libxml_parser_h" "$ac_includes_default"
13136 if test "x$ac_cv_header_libxml_parser_h" = xyes; then :
13139 as_fn_error $? "header file <libxml/parser.h> is required for XML support" "$LINENO" 5
13145 if test "$with_libxslt" = yes ; then
13146 ac_fn_c_check_header_mongrel "$LINENO" "libxslt/xslt.h" "ac_cv_header_libxslt_xslt_h" "$ac_includes_default"
13147 if test "x$ac_cv_header_libxslt_xslt_h" = xyes; then :
13150 as_fn_error $? "header file <libxslt/xslt.h> is required for XSLT support" "$LINENO" 5
13156 if test "$with_ldap" = yes ; then
13157 if test "$PORTNAME" != "win32"; then
13158 for ac_header in ldap.h
13160 ac_fn_c_check_header_mongrel "$LINENO" "ldap.h" "ac_cv_header_ldap_h" "$ac_includes_default"
13161 if test "x$ac_cv_header_ldap_h" = xyes; then :
13162 cat >>confdefs.h <<_ACEOF
13163 #define HAVE_LDAP_H 1
13167 as_fn_error $? "header file <ldap.h> is required for LDAP" "$LINENO" 5
13172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compatible LDAP implementation" >&5
13173 $as_echo_n "checking for compatible LDAP implementation... " >&6; }
13174 if ${pgac_cv_ldap_safe+:} false; then :
13175 $as_echo_n "(cached) " >&6
13177 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13178 /* end confdefs.h. */
13180 #if !defined(LDAP_VENDOR_VERSION) || \
13181 (defined(LDAP_API_FEATURE_X_OPENLDAP) && \
13182 LDAP_VENDOR_VERSION >= 20424 && LDAP_VENDOR_VERSION <= 20431)
13193 if ac_fn_c_try_compile "$LINENO"; then :
13194 pgac_cv_ldap_safe=yes
13196 pgac_cv_ldap_safe=no
13198 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_ldap_safe" >&5
13201 $as_echo "$pgac_cv_ldap_safe" >&6; }
13203 if test "$pgac_cv_ldap_safe" != yes; then
13204 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
13205 *** With OpenLDAP versions 2.4.24 through 2.4.31, inclusive, each backend
13206 *** process that loads libpq (via WAL receiver, dblink, or postgres_fdw) and
13207 *** also uses LDAP will crash on exit." >&5
13208 $as_echo "$as_me: WARNING:
13209 *** With OpenLDAP versions 2.4.24 through 2.4.31, inclusive, each backend
13210 *** process that loads libpq (via WAL receiver, dblink, or postgres_fdw) and
13211 *** also uses LDAP will crash on exit." >&2;}
13214 for ac_header in winldap.h
13216 ac_fn_c_check_header_compile "$LINENO" "winldap.h" "ac_cv_header_winldap_h" "$ac_includes_default
13217 #include <windows.h>
13220 if test "x$ac_cv_header_winldap_h" = xyes; then :
13221 cat >>confdefs.h <<_ACEOF
13222 #define HAVE_WINLDAP_H 1
13226 as_fn_error $? "header file <winldap.h> is required for LDAP" "$LINENO" 5
13234 if test "$with_bonjour" = yes ; then
13235 ac_fn_c_check_header_mongrel "$LINENO" "dns_sd.h" "ac_cv_header_dns_sd_h" "$ac_includes_default"
13236 if test "x$ac_cv_header_dns_sd_h" = xyes; then :
13239 as_fn_error $? "header file <dns_sd.h> is required for Bonjour" "$LINENO" 5
13245 # for contrib/uuid-ossp
13246 if test "$with_uuid" = bsd ; then
13247 for ac_header in uuid.h
13249 ac_fn_c_check_header_mongrel "$LINENO" "uuid.h" "ac_cv_header_uuid_h" "$ac_includes_default"
13250 if test "x$ac_cv_header_uuid_h" = xyes; then :
13251 cat >>confdefs.h <<_ACEOF
13252 #define HAVE_UUID_H 1
13254 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13255 /* end confdefs.h. */
13259 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13260 $EGREP "uuid_to_string" >/dev/null 2>&1; then :
13263 as_fn_error $? "header file <uuid.h> does not match BSD UUID library" "$LINENO" 5
13268 as_fn_error $? "header file <uuid.h> is required for BSD UUID" "$LINENO" 5
13273 elif test "$with_uuid" = e2fs ; then
13274 for ac_header in uuid/uuid.h
13276 ac_fn_c_check_header_mongrel "$LINENO" "uuid/uuid.h" "ac_cv_header_uuid_uuid_h" "$ac_includes_default"
13277 if test "x$ac_cv_header_uuid_uuid_h" = xyes; then :
13278 cat >>confdefs.h <<_ACEOF
13279 #define HAVE_UUID_UUID_H 1
13281 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13282 /* end confdefs.h. */
13283 #include <uuid/uuid.h>
13286 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13287 $EGREP "uuid_generate" >/dev/null 2>&1; then :
13290 as_fn_error $? "header file <uuid/uuid.h> does not match E2FS UUID library" "$LINENO" 5
13295 for ac_header in uuid.h
13297 ac_fn_c_check_header_mongrel "$LINENO" "uuid.h" "ac_cv_header_uuid_h" "$ac_includes_default"
13298 if test "x$ac_cv_header_uuid_h" = xyes; then :
13299 cat >>confdefs.h <<_ACEOF
13300 #define HAVE_UUID_H 1
13302 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13303 /* end confdefs.h. */
13307 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13308 $EGREP "uuid_generate" >/dev/null 2>&1; then :
13311 as_fn_error $? "header file <uuid.h> does not match E2FS UUID library" "$LINENO" 5
13316 as_fn_error $? "header file <uuid/uuid.h> or <uuid.h> is required for E2FS UUID" "$LINENO" 5
13325 elif test "$with_uuid" = ossp ; then
13326 for ac_header in ossp/uuid.h
13328 ac_fn_c_check_header_mongrel "$LINENO" "ossp/uuid.h" "ac_cv_header_ossp_uuid_h" "$ac_includes_default"
13329 if test "x$ac_cv_header_ossp_uuid_h" = xyes; then :
13330 cat >>confdefs.h <<_ACEOF
13331 #define HAVE_OSSP_UUID_H 1
13333 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13334 /* end confdefs.h. */
13335 #include <ossp/uuid.h>
13338 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13339 $EGREP "uuid_export" >/dev/null 2>&1; then :
13342 as_fn_error $? "header file <ossp/uuid.h> does not match OSSP UUID library" "$LINENO" 5
13347 for ac_header in uuid.h
13349 ac_fn_c_check_header_mongrel "$LINENO" "uuid.h" "ac_cv_header_uuid_h" "$ac_includes_default"
13350 if test "x$ac_cv_header_uuid_h" = xyes; then :
13351 cat >>confdefs.h <<_ACEOF
13352 #define HAVE_UUID_H 1
13354 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13355 /* end confdefs.h. */
13359 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13360 $EGREP "uuid_export" >/dev/null 2>&1; then :
13363 as_fn_error $? "header file <uuid.h> does not match OSSP UUID library" "$LINENO" 5
13368 as_fn_error $? "header file <ossp/uuid.h> or <uuid.h> is required for OSSP UUID" "$LINENO" 5
13379 if test "$PORTNAME" = "win32" ; then
13380 for ac_header in crtdefs.h
13382 ac_fn_c_check_header_mongrel "$LINENO" "crtdefs.h" "ac_cv_header_crtdefs_h" "$ac_includes_default"
13383 if test "x$ac_cv_header_crtdefs_h" = xyes; then :
13384 cat >>confdefs.h <<_ACEOF
13385 #define HAVE_CRTDEFS_H 1
13395 ## Types, structures, compiler characteristics
13398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
13399 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
13400 if ${ac_cv_c_bigendian+:} false; then :
13401 $as_echo_n "(cached) " >&6
13403 ac_cv_c_bigendian=unknown
13404 # See if we're dealing with a universal compiler.
13405 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13406 /* end confdefs.h. */
13407 #ifndef __APPLE_CC__
13408 not a universal capable compiler
13413 if ac_fn_c_try_compile "$LINENO"; then :
13415 # Check for potential -arch flags. It is not universal unless
13416 # there are at least two -arch flags with different values.
13419 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
13420 if test -n "$ac_prev"; then
13422 i?86 | x86_64 | ppc | ppc64)
13423 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
13426 ac_cv_c_bigendian=universal
13432 elif test "x$ac_word" = "x-arch"; then
13437 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13438 if test $ac_cv_c_bigendian = unknown; then
13439 # See if sys/param.h defines the BYTE_ORDER macro.
13440 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13441 /* end confdefs.h. */
13442 #include <sys/types.h>
13443 #include <sys/param.h>
13448 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
13449 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
13451 bogus endian macros
13458 if ac_fn_c_try_compile "$LINENO"; then :
13459 # It does; now see whether it defined to BIG_ENDIAN or not.
13460 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13461 /* end confdefs.h. */
13462 #include <sys/types.h>
13463 #include <sys/param.h>
13468 #if BYTE_ORDER != BIG_ENDIAN
13476 if ac_fn_c_try_compile "$LINENO"; then :
13477 ac_cv_c_bigendian=yes
13479 ac_cv_c_bigendian=no
13481 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13483 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13485 if test $ac_cv_c_bigendian = unknown; then
13486 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
13487 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13488 /* end confdefs.h. */
13489 #include <limits.h>
13494 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
13495 bogus endian macros
13502 if ac_fn_c_try_compile "$LINENO"; then :
13503 # It does; now see whether it defined to _BIG_ENDIAN or not.
13504 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13505 /* end confdefs.h. */
13506 #include <limits.h>
13511 #ifndef _BIG_ENDIAN
13519 if ac_fn_c_try_compile "$LINENO"; then :
13520 ac_cv_c_bigendian=yes
13522 ac_cv_c_bigendian=no
13524 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13526 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13528 if test $ac_cv_c_bigendian = unknown; then
13529 # Compile a test program.
13530 if test "$cross_compiling" = yes; then :
13531 # Try to guess by grepping values from an object file.
13532 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13533 /* end confdefs.h. */
13534 short int ascii_mm[] =
13535 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
13536 short int ascii_ii[] =
13537 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
13538 int use_ascii (int i) {
13539 return ascii_mm[i] + ascii_ii[i];
13541 short int ebcdic_ii[] =
13542 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
13543 short int ebcdic_mm[] =
13544 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
13545 int use_ebcdic (int i) {
13546 return ebcdic_mm[i] + ebcdic_ii[i];
13553 return use_ascii (foo) == use_ebcdic (foo);
13558 if ac_fn_c_try_compile "$LINENO"; then :
13559 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
13560 ac_cv_c_bigendian=yes
13562 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
13563 if test "$ac_cv_c_bigendian" = unknown; then
13564 ac_cv_c_bigendian=no
13566 # finding both strings is unlikely to happen, but who knows?
13567 ac_cv_c_bigendian=unknown
13571 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13573 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13574 /* end confdefs.h. */
13575 $ac_includes_default
13580 /* Are we little or big endian? From Harbison&Steele. */
13584 char c[sizeof (long int)];
13587 return u.c[sizeof (long int) - 1] == 1;
13593 if ac_fn_c_try_run "$LINENO"; then :
13594 ac_cv_c_bigendian=no
13596 ac_cv_c_bigendian=yes
13598 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13599 conftest.$ac_objext conftest.beam conftest.$ac_ext
13604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
13605 $as_echo "$ac_cv_c_bigendian" >&6; }
13606 case $ac_cv_c_bigendian in #(
13608 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
13614 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
13618 as_fn_error $? "unknown endianness
13619 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
13622 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
13623 $as_echo_n "checking for inline... " >&6; }
13624 if ${ac_cv_c_inline+:} false; then :
13625 $as_echo_n "(cached) " >&6
13628 for ac_kw in inline __inline__ __inline; do
13629 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13630 /* end confdefs.h. */
13631 #ifndef __cplusplus
13633 static $ac_kw foo_t static_foo () {return 0; }
13634 $ac_kw foo_t foo () {return 0; }
13638 if ac_fn_c_try_compile "$LINENO"; then :
13639 ac_cv_c_inline=$ac_kw
13641 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13642 test "$ac_cv_c_inline" != no && break
13646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
13647 $as_echo "$ac_cv_c_inline" >&6; }
13649 case $ac_cv_c_inline in
13652 case $ac_cv_c_inline in
13654 *) ac_val=$ac_cv_c_inline;;
13656 cat >>confdefs.h <<_ACEOF
13657 #ifndef __cplusplus
13658 #define inline $ac_val
13664 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for printf format archetype" >&5
13665 $as_echo_n "checking for printf format archetype... " >&6; }
13666 if ${pgac_cv_printf_archetype+:} false; then :
13667 $as_echo_n "(cached) " >&6
13669 pgac_cv_printf_archetype=gnu_printf
13670 ac_save_c_werror_flag=$ac_c_werror_flag
13671 ac_c_werror_flag=yes
13672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13673 /* end confdefs.h. */
13674 extern void pgac_write(int ignore, const char *fmt,...)
13675 __attribute__((format($pgac_cv_printf_archetype, 2, 3)));
13679 pgac_write(0, "error %s: %m", "foo");
13684 if ac_fn_c_try_compile "$LINENO"; then :
13685 ac_archetype_ok=yes
13689 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13690 ac_c_werror_flag=$ac_save_c_werror_flag
13692 if [ "$ac_archetype_ok" = no ]; then
13693 pgac_cv_printf_archetype=__syslog__
13694 ac_save_c_werror_flag=$ac_c_werror_flag
13695 ac_c_werror_flag=yes
13696 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13697 /* end confdefs.h. */
13698 extern void pgac_write(int ignore, const char *fmt,...)
13699 __attribute__((format($pgac_cv_printf_archetype, 2, 3)));
13703 pgac_write(0, "error %s: %m", "foo");
13708 if ac_fn_c_try_compile "$LINENO"; then :
13709 ac_archetype_ok=yes
13713 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13714 ac_c_werror_flag=$ac_save_c_werror_flag
13716 if [ "$ac_archetype_ok" = no ]; then
13717 pgac_cv_printf_archetype=printf
13721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_printf_archetype" >&5
13722 $as_echo "$pgac_cv_printf_archetype" >&6; }
13724 cat >>confdefs.h <<_ACEOF
13725 #define PG_PRINTF_ATTRIBUTE $pgac_cv_printf_archetype
13730 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flexible array members" >&5
13731 $as_echo_n "checking for flexible array members... " >&6; }
13732 if ${ac_cv_c_flexmember+:} false; then :
13733 $as_echo_n "(cached) " >&6
13735 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13736 /* end confdefs.h. */
13737 #include <stdlib.h>
13739 #include <stddef.h>
13740 struct s { int n; double d[]; };
13744 int m = getchar ();
13745 struct s *p = malloc (offsetof (struct s, d)
13746 + m * sizeof (double));
13748 return p->d != (double *) NULL;
13753 if ac_fn_c_try_compile "$LINENO"; then :
13754 ac_cv_c_flexmember=yes
13756 ac_cv_c_flexmember=no
13758 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_flexmember" >&5
13761 $as_echo "$ac_cv_c_flexmember" >&6; }
13762 if test $ac_cv_c_flexmember = yes; then
13764 $as_echo "#define FLEXIBLE_ARRAY_MEMBER /**/" >>confdefs.h
13767 $as_echo "#define FLEXIBLE_ARRAY_MEMBER 1" >>confdefs.h
13771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signed types" >&5
13772 $as_echo_n "checking for signed types... " >&6; }
13773 if ${pgac_cv_c_signed+:} false; then :
13774 $as_echo_n "(cached) " >&6
13776 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13777 /* end confdefs.h. */
13782 signed char c; signed short s; signed int i;
13787 if ac_fn_c_try_compile "$LINENO"; then :
13788 pgac_cv_c_signed=yes
13790 pgac_cv_c_signed=no
13792 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_c_signed" >&5
13795 $as_echo "$pgac_cv_c_signed" >&6; }
13796 if test x"$pgac_cv_c_signed" = xno ; then
13798 $as_echo "#define signed /**/" >>confdefs.h
13801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __func__" >&5
13802 $as_echo_n "checking for __func__... " >&6; }
13803 if ${pgac_cv_funcname_func_support+:} false; then :
13804 $as_echo_n "(cached) " >&6
13806 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13807 /* end confdefs.h. */
13812 printf("%s\n", __func__);
13817 if ac_fn_c_try_compile "$LINENO"; then :
13818 pgac_cv_funcname_func_support=yes
13820 pgac_cv_funcname_func_support=no
13822 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_funcname_func_support" >&5
13825 $as_echo "$pgac_cv_funcname_func_support" >&6; }
13826 if test x"$pgac_cv_funcname_func_support" = xyes ; then
13828 $as_echo "#define HAVE_FUNCNAME__FUNC 1" >>confdefs.h
13831 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __FUNCTION__" >&5
13832 $as_echo_n "checking for __FUNCTION__... " >&6; }
13833 if ${pgac_cv_funcname_function_support+:} false; then :
13834 $as_echo_n "(cached) " >&6
13836 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13837 /* end confdefs.h. */
13842 printf("%s\n", __FUNCTION__);
13847 if ac_fn_c_try_compile "$LINENO"; then :
13848 pgac_cv_funcname_function_support=yes
13850 pgac_cv_funcname_function_support=no
13852 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_funcname_function_support" >&5
13855 $as_echo "$pgac_cv_funcname_function_support" >&6; }
13856 if test x"$pgac_cv_funcname_function_support" = xyes ; then
13858 $as_echo "#define HAVE_FUNCNAME__FUNCTION 1" >>confdefs.h
13862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _Static_assert" >&5
13863 $as_echo_n "checking for _Static_assert... " >&6; }
13864 if ${pgac_cv__static_assert+:} false; then :
13865 $as_echo_n "(cached) " >&6
13867 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13868 /* end confdefs.h. */
13873 ({ _Static_assert(1, "foo"); })
13878 if ac_fn_c_try_link "$LINENO"; then :
13879 pgac_cv__static_assert=yes
13881 pgac_cv__static_assert=no
13883 rm -f core conftest.err conftest.$ac_objext \
13884 conftest$ac_exeext conftest.$ac_ext
13886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__static_assert" >&5
13887 $as_echo "$pgac_cv__static_assert" >&6; }
13888 if test x"$pgac_cv__static_assert" = xyes ; then
13890 $as_echo "#define HAVE__STATIC_ASSERT 1" >>confdefs.h
13893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for typeof" >&5
13894 $as_echo_n "checking for typeof... " >&6; }
13895 if ${pgac_cv_c_typeof+:} false; then :
13896 $as_echo_n "(cached) " >&6
13898 pgac_cv_c_typeof=no
13899 for pgac_kw in typeof __typeof__ decltype; do
13900 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13901 /* end confdefs.h. */
13914 if ac_fn_c_try_compile "$LINENO"; then :
13915 pgac_cv_c_typeof=$pgac_kw
13917 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13918 test "$pgac_cv_c_typeof" != no && break
13921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_c_typeof" >&5
13922 $as_echo "$pgac_cv_c_typeof" >&6; }
13923 if test "$pgac_cv_c_typeof" != no; then
13925 $as_echo "#define HAVE_TYPEOF 1" >>confdefs.h
13927 if test "$pgac_cv_c_typeof" != typeof; then
13929 cat >>confdefs.h <<_ACEOF
13930 #define typeof $pgac_cv_c_typeof
13935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_types_compatible_p" >&5
13936 $as_echo_n "checking for __builtin_types_compatible_p... " >&6; }
13937 if ${pgac_cv__types_compatible+:} false; then :
13938 $as_echo_n "(cached) " >&6
13940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13941 /* end confdefs.h. */
13946 int x; static int y[__builtin_types_compatible_p(__typeof__(x), int)];
13951 if ac_fn_c_try_compile "$LINENO"; then :
13952 pgac_cv__types_compatible=yes
13954 pgac_cv__types_compatible=no
13956 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__types_compatible" >&5
13959 $as_echo "$pgac_cv__types_compatible" >&6; }
13960 if test x"$pgac_cv__types_compatible" = xyes ; then
13962 $as_echo "#define HAVE__BUILTIN_TYPES_COMPATIBLE_P 1" >>confdefs.h
13965 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_bswap16" >&5
13966 $as_echo_n "checking for __builtin_bswap16... " >&6; }
13967 if ${pgac_cv__builtin_bswap16+:} false; then :
13968 $as_echo_n "(cached) " >&6
13970 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13971 /* end confdefs.h. */
13972 static unsigned long int x = __builtin_bswap16(0xaabb);
13975 if ac_fn_c_try_compile "$LINENO"; then :
13976 pgac_cv__builtin_bswap16=yes
13978 pgac_cv__builtin_bswap16=no
13980 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_bswap16" >&5
13983 $as_echo "$pgac_cv__builtin_bswap16" >&6; }
13984 if test x"$pgac_cv__builtin_bswap16" = xyes ; then
13986 $as_echo "#define HAVE__BUILTIN_BSWAP16 1" >>confdefs.h
13989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_bswap32" >&5
13990 $as_echo_n "checking for __builtin_bswap32... " >&6; }
13991 if ${pgac_cv__builtin_bswap32+:} false; then :
13992 $as_echo_n "(cached) " >&6
13994 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13995 /* end confdefs.h. */
13996 static unsigned long int x = __builtin_bswap32(0xaabbccdd);
13999 if ac_fn_c_try_compile "$LINENO"; then :
14000 pgac_cv__builtin_bswap32=yes
14002 pgac_cv__builtin_bswap32=no
14004 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_bswap32" >&5
14007 $as_echo "$pgac_cv__builtin_bswap32" >&6; }
14008 if test x"$pgac_cv__builtin_bswap32" = xyes ; then
14010 $as_echo "#define HAVE__BUILTIN_BSWAP32 1" >>confdefs.h
14013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_bswap64" >&5
14014 $as_echo_n "checking for __builtin_bswap64... " >&6; }
14015 if ${pgac_cv__builtin_bswap64+:} false; then :
14016 $as_echo_n "(cached) " >&6
14018 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14019 /* end confdefs.h. */
14020 static unsigned long int x = __builtin_bswap64(0xaabbccddeeff0011);
14023 if ac_fn_c_try_compile "$LINENO"; then :
14024 pgac_cv__builtin_bswap64=yes
14026 pgac_cv__builtin_bswap64=no
14028 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_bswap64" >&5
14031 $as_echo "$pgac_cv__builtin_bswap64" >&6; }
14032 if test x"$pgac_cv__builtin_bswap64" = xyes ; then
14034 $as_echo "#define HAVE__BUILTIN_BSWAP64 1" >>confdefs.h
14037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_clz" >&5
14038 $as_echo_n "checking for __builtin_clz... " >&6; }
14039 if ${pgac_cv__builtin_clz+:} false; then :
14040 $as_echo_n "(cached) " >&6
14042 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14043 /* end confdefs.h. */
14044 static int x = __builtin_clz(256);
14047 if ac_fn_c_try_compile "$LINENO"; then :
14048 pgac_cv__builtin_clz=yes
14050 pgac_cv__builtin_clz=no
14052 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_clz" >&5
14055 $as_echo "$pgac_cv__builtin_clz" >&6; }
14056 if test x"$pgac_cv__builtin_clz" = xyes ; then
14058 $as_echo "#define HAVE__BUILTIN_CLZ 1" >>confdefs.h
14061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_constant_p" >&5
14062 $as_echo_n "checking for __builtin_constant_p... " >&6; }
14063 if ${pgac_cv__builtin_constant_p+:} false; then :
14064 $as_echo_n "(cached) " >&6
14066 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14067 /* end confdefs.h. */
14069 static int y[__builtin_constant_p(x) ? x : 1];
14070 static int z[__builtin_constant_p("string literal") ? 1 : x];
14074 if ac_fn_c_try_compile "$LINENO"; then :
14075 pgac_cv__builtin_constant_p=yes
14077 pgac_cv__builtin_constant_p=no
14079 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_constant_p" >&5
14082 $as_echo "$pgac_cv__builtin_constant_p" >&6; }
14083 if test x"$pgac_cv__builtin_constant_p" = xyes ; then
14085 $as_echo "#define HAVE__BUILTIN_CONSTANT_P 1" >>confdefs.h
14088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_ctz" >&5
14089 $as_echo_n "checking for __builtin_ctz... " >&6; }
14090 if ${pgac_cv__builtin_ctz+:} false; then :
14091 $as_echo_n "(cached) " >&6
14093 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14094 /* end confdefs.h. */
14095 static int x = __builtin_ctz(256);
14098 if ac_fn_c_try_compile "$LINENO"; then :
14099 pgac_cv__builtin_ctz=yes
14101 pgac_cv__builtin_ctz=no
14103 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_ctz" >&5
14106 $as_echo "$pgac_cv__builtin_ctz" >&6; }
14107 if test x"$pgac_cv__builtin_ctz" = xyes ; then
14109 $as_echo "#define HAVE__BUILTIN_CTZ 1" >>confdefs.h
14112 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_popcount" >&5
14113 $as_echo_n "checking for __builtin_popcount... " >&6; }
14114 if ${pgac_cv_popcount+:} false; then :
14115 $as_echo_n "(cached) " >&6
14117 pgac_save_CFLAGS=$CFLAGS
14118 CFLAGS="$pgac_save_CFLAGS -mpopcnt"
14119 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14120 /* end confdefs.h. */
14121 static int x = __builtin_popcount(255);
14123 if ac_fn_c_try_compile "$LINENO"; then :
14124 pgac_cv_popcount=yes
14126 pgac_cv_popcount=no
14128 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14129 CFLAGS="$pgac_save_CFLAGS"
14131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_popcount" >&5
14132 $as_echo "$pgac_cv_popcount" >&6; }
14133 if test x"$pgac_cv_popcount" = x"yes"; then
14134 CFLAGS_POPCNT="-mpopcnt"
14136 $as_echo "#define HAVE__BUILTIN_POPCOUNT 1" >>confdefs.h
14140 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unreachable" >&5
14141 $as_echo_n "checking for __builtin_unreachable... " >&6; }
14142 if ${pgac_cv__builtin_unreachable+:} false; then :
14143 $as_echo_n "(cached) " >&6
14145 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14146 /* end confdefs.h. */
14151 __builtin_unreachable();
14156 if ac_fn_c_try_link "$LINENO"; then :
14157 pgac_cv__builtin_unreachable=yes
14159 pgac_cv__builtin_unreachable=no
14161 rm -f core conftest.err conftest.$ac_objext \
14162 conftest$ac_exeext conftest.$ac_ext
14164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_unreachable" >&5
14165 $as_echo "$pgac_cv__builtin_unreachable" >&6; }
14166 if test x"$pgac_cv__builtin_unreachable" = xyes ; then
14168 $as_echo "#define HAVE__BUILTIN_UNREACHABLE 1" >>confdefs.h
14171 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for computed goto support" >&5
14172 $as_echo_n "checking for computed goto support... " >&6; }
14173 if ${pgac_cv_computed_goto+:} false; then :
14174 $as_echo_n "(cached) " >&6
14176 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14177 /* end confdefs.h. */
14182 void *labeladdrs[] = {&&my_label};
14183 goto *labeladdrs[0];
14191 if ac_fn_c_try_compile "$LINENO"; then :
14192 pgac_cv_computed_goto=yes
14194 pgac_cv_computed_goto=no
14196 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_computed_goto" >&5
14199 $as_echo "$pgac_cv_computed_goto" >&6; }
14200 if test x"$pgac_cv_computed_goto" = xyes ; then
14202 $as_echo "#define HAVE_COMPUTED_GOTO 1" >>confdefs.h
14205 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
14206 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
14207 if ${ac_cv_struct_tm+:} false; then :
14208 $as_echo_n "(cached) " >&6
14210 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14211 /* end confdefs.h. */
14212 #include <sys/types.h>
14219 int *p = &tm.tm_sec;
14225 if ac_fn_c_try_compile "$LINENO"; then :
14226 ac_cv_struct_tm=time.h
14228 ac_cv_struct_tm=sys/time.h
14230 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
14233 $as_echo "$ac_cv_struct_tm" >&6; }
14234 if test $ac_cv_struct_tm = sys/time.h; then
14236 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
14240 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
14241 #include <$ac_cv_struct_tm>
14244 if test "x$ac_cv_member_struct_tm_tm_zone" = xyes; then :
14246 cat >>confdefs.h <<_ACEOF
14247 #define HAVE_STRUCT_TM_TM_ZONE 1
14253 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
14255 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
14258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
14259 $as_echo_n "checking for tzname... " >&6; }
14260 if ${ac_cv_var_tzname+:} false; then :
14261 $as_echo_n "(cached) " >&6
14263 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14264 /* end confdefs.h. */
14265 #include <stdlib.h>
14267 #ifndef tzname /* For SGI. */
14268 extern char *tzname[]; /* RS6000 and others reject char **tzname. */
14279 if ac_fn_c_try_link "$LINENO"; then :
14280 ac_cv_var_tzname=yes
14282 ac_cv_var_tzname=no
14284 rm -f core conftest.err conftest.$ac_objext \
14285 conftest$ac_exeext conftest.$ac_ext
14287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
14288 $as_echo "$ac_cv_var_tzname" >&6; }
14289 if test $ac_cv_var_tzname = yes; then
14291 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
14295 ac_fn_c_check_type "$LINENO" "union semun" "ac_cv_type_union_semun" "#include <sys/types.h>
14296 #ifdef HAVE_SYS_IPC_H
14297 #include <sys/ipc.h>
14299 #ifdef HAVE_SYS_SEM_H
14300 #include <sys/sem.h>
14303 if test "x$ac_cv_type_union_semun" = xyes; then :
14305 cat >>confdefs.h <<_ACEOF
14306 #define HAVE_UNION_SEMUN 1
14312 ac_fn_c_check_type "$LINENO" "struct sockaddr_un" "ac_cv_type_struct_sockaddr_un" "#include <sys/types.h>
14313 #ifdef HAVE_SYS_UN_H
14314 #include <sys/un.h>
14318 if test "x$ac_cv_type_struct_sockaddr_un" = xyes; then :
14320 $as_echo "#define HAVE_UNIX_SOCKETS 1" >>confdefs.h
14324 ac_fn_c_check_type "$LINENO" "struct sockaddr_storage" "ac_cv_type_struct_sockaddr_storage" "#include <sys/types.h>
14325 #include <sys/socket.h>
14328 if test "x$ac_cv_type_struct_sockaddr_storage" = xyes; then :
14330 cat >>confdefs.h <<_ACEOF
14331 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
14337 ac_fn_c_check_member "$LINENO" "struct sockaddr_storage" "ss_family" "ac_cv_member_struct_sockaddr_storage_ss_family" "#include <sys/types.h>
14338 #include <sys/socket.h>
14341 if test "x$ac_cv_member_struct_sockaddr_storage_ss_family" = xyes; then :
14343 cat >>confdefs.h <<_ACEOF
14344 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
14349 ac_fn_c_check_member "$LINENO" "struct sockaddr_storage" "__ss_family" "ac_cv_member_struct_sockaddr_storage___ss_family" "#include <sys/types.h>
14350 #include <sys/socket.h>
14353 if test "x$ac_cv_member_struct_sockaddr_storage___ss_family" = xyes; then :
14355 cat >>confdefs.h <<_ACEOF
14356 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
14361 ac_fn_c_check_member "$LINENO" "struct sockaddr_storage" "ss_len" "ac_cv_member_struct_sockaddr_storage_ss_len" "#include <sys/types.h>
14362 #include <sys/socket.h>
14365 if test "x$ac_cv_member_struct_sockaddr_storage_ss_len" = xyes; then :
14367 cat >>confdefs.h <<_ACEOF
14368 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
14373 ac_fn_c_check_member "$LINENO" "struct sockaddr_storage" "__ss_len" "ac_cv_member_struct_sockaddr_storage___ss_len" "#include <sys/types.h>
14374 #include <sys/socket.h>
14377 if test "x$ac_cv_member_struct_sockaddr_storage___ss_len" = xyes; then :
14379 cat >>confdefs.h <<_ACEOF
14380 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
14385 ac_fn_c_check_member "$LINENO" "struct sockaddr" "sa_len" "ac_cv_member_struct_sockaddr_sa_len" "#include <sys/types.h>
14386 #include <sys/socket.h>
14389 if test "x$ac_cv_member_struct_sockaddr_sa_len" = xyes; then :
14391 cat >>confdefs.h <<_ACEOF
14392 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
14398 ac_fn_c_check_type "$LINENO" "struct addrinfo" "ac_cv_type_struct_addrinfo" "#include <sys/types.h>
14399 #include <sys/socket.h>
14403 if test "x$ac_cv_type_struct_addrinfo" = xyes; then :
14405 cat >>confdefs.h <<_ACEOF
14406 #define HAVE_STRUCT_ADDRINFO 1
14413 ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default"
14414 if test "x$ac_cv_type_intptr_t" = xyes; then :
14416 $as_echo "#define HAVE_INTPTR_T 1" >>confdefs.h
14419 for ac_type in 'int' 'long int' 'long long int'; do
14420 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14421 /* end confdefs.h. */
14422 $ac_includes_default
14426 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
14427 test_array [0] = 0;
14428 return test_array [0];
14434 if ac_fn_c_try_compile "$LINENO"; then :
14436 cat >>confdefs.h <<_ACEOF
14437 #define intptr_t $ac_type
14442 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14443 test -z "$ac_type" && break
14449 ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default"
14450 if test "x$ac_cv_type_uintptr_t" = xyes; then :
14452 $as_echo "#define HAVE_UINTPTR_T 1" >>confdefs.h
14455 for ac_type in 'unsigned int' 'unsigned long int' \
14456 'unsigned long long int'; do
14457 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14458 /* end confdefs.h. */
14459 $ac_includes_default
14463 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
14464 test_array [0] = 0;
14465 return test_array [0];
14471 if ac_fn_c_try_compile "$LINENO"; then :
14473 cat >>confdefs.h <<_ACEOF
14474 #define uintptr_t $ac_type
14479 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14480 test -z "$ac_type" && break
14486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
14487 $as_echo_n "checking for unsigned long long int... " >&6; }
14488 if ${ac_cv_type_unsigned_long_long_int+:} false; then :
14489 $as_echo_n "(cached) " >&6
14491 ac_cv_type_unsigned_long_long_int=yes
14492 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
14493 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14494 /* end confdefs.h. */
14496 /* For now, do not test the preprocessor; as of 2007 there are too many
14497 implementations with broken preprocessors. Perhaps this can
14498 be revisited in 2012. In the meantime, code should not expect
14499 #if to work with literals wider than 32 bits. */
14500 /* Test literals. */
14501 long long int ll = 9223372036854775807ll;
14502 long long int nll = -9223372036854775807LL;
14503 unsigned long long int ull = 18446744073709551615ULL;
14504 /* Test constant expressions. */
14505 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
14507 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
14513 /* Test availability of runtime routines for shift and division. */
14514 long long int llmax = 9223372036854775807ll;
14515 unsigned long long int ullmax = 18446744073709551615ull;
14516 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
14517 | (llmax / ll) | (llmax % ll)
14518 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
14519 | (ullmax / ull) | (ullmax % ull));
14525 if ac_fn_c_try_link "$LINENO"; then :
14528 ac_cv_type_unsigned_long_long_int=no
14530 rm -f core conftest.err conftest.$ac_objext \
14531 conftest$ac_exeext conftest.$ac_ext
14534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
14535 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
14536 if test $ac_cv_type_unsigned_long_long_int = yes; then
14538 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
14544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
14545 $as_echo_n "checking for long long int... " >&6; }
14546 if ${ac_cv_type_long_long_int+:} false; then :
14547 $as_echo_n "(cached) " >&6
14549 ac_cv_type_long_long_int=yes
14550 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
14551 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
14552 if test $ac_cv_type_long_long_int = yes; then
14553 if test "$cross_compiling" = yes; then :
14556 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14557 /* end confdefs.h. */
14558 #include <limits.h>
14561 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
14562 # define LLONG_MAX (HALF - 1 + HALF)
14567 long long int n = 1;
14571 long long int m = n << i;
14574 if (LLONG_MAX / 2 < m)
14582 if ac_fn_c_try_run "$LINENO"; then :
14585 ac_cv_type_long_long_int=no
14587 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14588 conftest.$ac_objext conftest.beam conftest.$ac_ext
14594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
14595 $as_echo "$ac_cv_type_long_long_int" >&6; }
14596 if test $ac_cv_type_long_long_int = yes; then
14598 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
14603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for locale_t" >&5
14604 $as_echo_n "checking for locale_t... " >&6; }
14605 if ${pgac_cv_type_locale_t+:} false; then :
14606 $as_echo_n "(cached) " >&6
14608 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14609 /* end confdefs.h. */
14610 #include <locale.h>
14620 if ac_fn_c_try_compile "$LINENO"; then :
14621 pgac_cv_type_locale_t=yes
14623 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14624 /* end confdefs.h. */
14625 #include <xlocale.h>
14635 if ac_fn_c_try_compile "$LINENO"; then :
14636 pgac_cv_type_locale_t='yes (in xlocale.h)'
14638 pgac_cv_type_locale_t=no
14640 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14642 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_type_locale_t" >&5
14645 $as_echo "$pgac_cv_type_locale_t" >&6; }
14646 if test "$pgac_cv_type_locale_t" != no; then
14648 $as_echo "#define HAVE_LOCALE_T 1" >>confdefs.h
14651 if test "$pgac_cv_type_locale_t" = 'yes (in xlocale.h)'; then
14653 $as_echo "#define LOCALE_T_IN_XLOCALE 1" >>confdefs.h
14659 # MSVC doesn't cope well with defining restrict to __restrict, the
14660 # spelling it understands, because it conflicts with
14661 # __declspec(restrict). Therefore we define pg_restrict to the
14662 # appropriate definition, which presumably won't conflict.
14664 # Allow platforms with buggy compilers to force restrict to not be
14665 # used by setting $FORCE_DISABLE_RESTRICT=yes in the relevant
14667 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
14668 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
14669 if ${ac_cv_c_restrict+:} false; then :
14670 $as_echo_n "(cached) " >&6
14672 ac_cv_c_restrict=no
14673 # The order here caters to the fact that C++ does not require restrict.
14674 for ac_kw in __restrict __restrict__ _Restrict restrict; do
14675 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14676 /* end confdefs.h. */
14677 typedef int * int_ptr;
14678 int foo (int_ptr $ac_kw ip) {
14685 int * $ac_kw t = s;
14692 if ac_fn_c_try_compile "$LINENO"; then :
14693 ac_cv_c_restrict=$ac_kw
14695 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14696 test "$ac_cv_c_restrict" != no && break
14700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
14701 $as_echo "$ac_cv_c_restrict" >&6; }
14703 case $ac_cv_c_restrict in
14705 no) $as_echo "#define restrict /**/" >>confdefs.h
14707 *) cat >>confdefs.h <<_ACEOF
14708 #define restrict $ac_cv_c_restrict
14713 if test "$ac_cv_c_restrict" = "no" -o "x$FORCE_DISABLE_RESTRICT" = "xyes"; then
14716 pg_restrict="$ac_cv_c_restrict"
14719 cat >>confdefs.h <<_ACEOF
14720 #define pg_restrict $pg_restrict
14724 ac_fn_c_check_type "$LINENO" "struct cmsgcred" "ac_cv_type_struct_cmsgcred" "#include <sys/socket.h>
14725 #include <sys/param.h>
14726 #ifdef HAVE_SYS_UCRED_H
14727 #include <sys/ucred.h>
14730 if test "x$ac_cv_type_struct_cmsgcred" = xyes; then :
14732 cat >>confdefs.h <<_ACEOF
14733 #define HAVE_STRUCT_CMSGCRED 1
14740 ac_fn_c_check_type "$LINENO" "struct option" "ac_cv_type_struct_option" "#ifdef HAVE_GETOPT_H
14741 #include <getopt.h>
14744 if test "x$ac_cv_type_struct_option" = xyes; then :
14746 cat >>confdefs.h <<_ACEOF
14747 #define HAVE_STRUCT_OPTION 1
14754 if test "$with_zlib" = yes; then
14755 # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
14756 # did not). While we could work around the lack of z_streamp, it
14757 # seems unwise to encourage people to use such old zlib versions...
14758 ac_fn_c_check_type "$LINENO" "z_streamp" "ac_cv_type_z_streamp" "#include <zlib.h>
14760 if test "x$ac_cv_type_z_streamp" = xyes; then :
14763 as_fn_error $? "zlib version is too old
14764 Use --without-zlib to disable zlib support." "$LINENO" 5
14769 # On PPC, check if assembler supports LWARX instruction's mutex hint bit
14772 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether assembler supports lwarx hint bit" >&5
14773 $as_echo_n "checking whether assembler supports lwarx hint bit... " >&6; }
14774 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14775 /* end confdefs.h. */
14780 int a = 0; int *p = &a; int r;
14781 __asm__ __volatile__ (" lwarx %0,0,%1,1\n" : "=&r"(r) : "r"(p));
14786 if ac_fn_c_try_compile "$LINENO"; then :
14787 pgac_cv_have_ppc_mutex_hint=yes
14789 pgac_cv_have_ppc_mutex_hint=no
14791 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14792 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_have_ppc_mutex_hint" >&5
14793 $as_echo "$pgac_cv_have_ppc_mutex_hint" >&6; }
14794 if test x"$pgac_cv_have_ppc_mutex_hint" = xyes ; then
14796 $as_echo "#define HAVE_PPC_LWARX_MUTEX_HINT 1" >>confdefs.h
14802 # Check largefile support. You might think this is a system service not a
14803 # compiler characteristic, but you'd be wrong. We must check this before
14804 # probing existence of related functions such as fseeko, since the largefile
14805 # defines can affect what is generated for that.
14806 if test "$PORTNAME" != "win32"; then
14807 # Check whether --enable-largefile was given.
14808 if test "${enable_largefile+set}" = set; then :
14809 enableval=$enable_largefile;
14812 if test "$enable_largefile" != no; then
14814 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
14815 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
14816 if ${ac_cv_sys_largefile_CC+:} false; then :
14817 $as_echo_n "(cached) " >&6
14819 ac_cv_sys_largefile_CC=no
14820 if test "$GCC" != yes; then
14823 # IRIX 6.2 and later do not support large files by default,
14824 # so use the C compiler's -n32 option if that helps.
14825 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14826 /* end confdefs.h. */
14827 #include <sys/types.h>
14828 /* Check that off_t can represent 2**63 - 1 correctly.
14829 We can't simply define LARGE_OFF_T to be 9223372036854775807,
14830 since some C++ compilers masquerading as C compilers
14831 incorrectly reject 9223372036854775807. */
14832 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
14833 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
14834 && LARGE_OFF_T % 2147483647 == 1)
14844 if ac_fn_c_try_compile "$LINENO"; then :
14847 rm -f core conftest.err conftest.$ac_objext
14849 if ac_fn_c_try_compile "$LINENO"; then :
14850 ac_cv_sys_largefile_CC=' -n32'; break
14852 rm -f core conftest.err conftest.$ac_objext
14856 rm -f conftest.$ac_ext
14859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
14860 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
14861 if test "$ac_cv_sys_largefile_CC" != no; then
14862 CC=$CC$ac_cv_sys_largefile_CC
14865 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
14866 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
14867 if ${ac_cv_sys_file_offset_bits+:} false; then :
14868 $as_echo_n "(cached) " >&6
14871 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14872 /* end confdefs.h. */
14873 #include <sys/types.h>
14874 /* Check that off_t can represent 2**63 - 1 correctly.
14875 We can't simply define LARGE_OFF_T to be 9223372036854775807,
14876 since some C++ compilers masquerading as C compilers
14877 incorrectly reject 9223372036854775807. */
14878 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
14879 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
14880 && LARGE_OFF_T % 2147483647 == 1)
14890 if ac_fn_c_try_compile "$LINENO"; then :
14891 ac_cv_sys_file_offset_bits=no; break
14893 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14895 /* end confdefs.h. */
14896 #define _FILE_OFFSET_BITS 64
14897 #include <sys/types.h>
14898 /* Check that off_t can represent 2**63 - 1 correctly.
14899 We can't simply define LARGE_OFF_T to be 9223372036854775807,
14900 since some C++ compilers masquerading as C compilers
14901 incorrectly reject 9223372036854775807. */
14902 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
14903 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
14904 && LARGE_OFF_T % 2147483647 == 1)
14914 if ac_fn_c_try_compile "$LINENO"; then :
14915 ac_cv_sys_file_offset_bits=64; break
14917 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14918 ac_cv_sys_file_offset_bits=unknown
14922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
14923 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
14924 case $ac_cv_sys_file_offset_bits in #(
14927 cat >>confdefs.h <<_ACEOF
14928 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
14933 if test $ac_cv_sys_file_offset_bits = unknown; then
14934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
14935 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
14936 if ${ac_cv_sys_large_files+:} false; then :
14937 $as_echo_n "(cached) " >&6
14940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14941 /* end confdefs.h. */
14942 #include <sys/types.h>
14943 /* Check that off_t can represent 2**63 - 1 correctly.
14944 We can't simply define LARGE_OFF_T to be 9223372036854775807,
14945 since some C++ compilers masquerading as C compilers
14946 incorrectly reject 9223372036854775807. */
14947 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
14948 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
14949 && LARGE_OFF_T % 2147483647 == 1)
14959 if ac_fn_c_try_compile "$LINENO"; then :
14960 ac_cv_sys_large_files=no; break
14962 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14963 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14964 /* end confdefs.h. */
14965 #define _LARGE_FILES 1
14966 #include <sys/types.h>
14967 /* Check that off_t can represent 2**63 - 1 correctly.
14968 We can't simply define LARGE_OFF_T to be 9223372036854775807,
14969 since some C++ compilers masquerading as C compilers
14970 incorrectly reject 9223372036854775807. */
14971 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
14972 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
14973 && LARGE_OFF_T % 2147483647 == 1)
14983 if ac_fn_c_try_compile "$LINENO"; then :
14984 ac_cv_sys_large_files=1; break
14986 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14987 ac_cv_sys_large_files=unknown
14991 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
14992 $as_echo "$ac_cv_sys_large_files" >&6; }
14993 case $ac_cv_sys_large_files in #(
14996 cat >>confdefs.h <<_ACEOF
14997 #define _LARGE_FILES $ac_cv_sys_large_files
15010 # The cast to long int works around a bug in the HP C Compiler
15011 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
15012 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
15013 # This bug is HP SR number 8606223364.
15014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5
15015 $as_echo_n "checking size of off_t... " >&6; }
15016 if ${ac_cv_sizeof_off_t+:} false; then :
15017 $as_echo_n "(cached) " >&6
15019 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (off_t))" "ac_cv_sizeof_off_t" "$ac_includes_default"; then :
15022 if test "$ac_cv_type_off_t" = yes; then
15023 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15024 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15025 as_fn_error 77 "cannot compute sizeof (off_t)
15026 See \`config.log' for more details" "$LINENO" 5; }
15028 ac_cv_sizeof_off_t=0
15033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5
15034 $as_echo "$ac_cv_sizeof_off_t" >&6; }
15038 cat >>confdefs.h <<_ACEOF
15039 #define SIZEOF_OFF_T $ac_cv_sizeof_off_t
15044 # If we don't have largefile support, can't handle segsize >= 2GB.
15045 if test "$ac_cv_sizeof_off_t" -lt 8 -a "$segsize" != "1"; then
15046 as_fn_error $? "Large file support is not enabled. Segment size cannot be larger than 1GB." "$LINENO" 5
15049 # The cast to long int works around a bug in the HP C Compiler
15050 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
15051 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
15052 # This bug is HP SR number 8606223364.
15053 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of bool" >&5
15054 $as_echo_n "checking size of bool... " >&6; }
15055 if ${ac_cv_sizeof_bool+:} false; then :
15056 $as_echo_n "(cached) " >&6
15058 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (bool))" "ac_cv_sizeof_bool" "#ifdef HAVE_STDBOOL_H
15059 #include <stdbool.h>
15064 if test "$ac_cv_type_bool" = yes; then
15065 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15066 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15067 as_fn_error 77 "cannot compute sizeof (bool)
15068 See \`config.log' for more details" "$LINENO" 5; }
15070 ac_cv_sizeof_bool=0
15075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_bool" >&5
15076 $as_echo "$ac_cv_sizeof_bool" >&6; }
15080 cat >>confdefs.h <<_ACEOF
15081 #define SIZEOF_BOOL $ac_cv_sizeof_bool
15088 ## Functions, global variables
15091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for int timezone" >&5
15092 $as_echo_n "checking for int timezone... " >&6; }
15093 if ${pgac_cv_var_int_timezone+:} false; then :
15094 $as_echo_n "(cached) " >&6
15096 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15097 /* end confdefs.h. */
15104 res = timezone / 60;
15106 res = _timezone / 60;
15112 if ac_fn_c_try_link "$LINENO"; then :
15113 pgac_cv_var_int_timezone=yes
15115 pgac_cv_var_int_timezone=no
15117 rm -f core conftest.err conftest.$ac_objext \
15118 conftest$ac_exeext conftest.$ac_ext
15120 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_var_int_timezone" >&5
15121 $as_echo "$pgac_cv_var_int_timezone" >&6; }
15122 if test x"$pgac_cv_var_int_timezone" = xyes ; then
15124 $as_echo "#define HAVE_INT_TIMEZONE 1" >>confdefs.h
15127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of arguments for accept()" >&5
15128 $as_echo_n "checking types of arguments for accept()... " >&6; }
15129 if ${ac_cv_func_accept_return+:} false; then :
15130 $as_echo_n "(cached) " >&6
15132 if ${ac_cv_func_accept_arg1+:} false; then :
15133 $as_echo_n "(cached) " >&6
15135 if ${ac_cv_func_accept_arg2+:} false; then :
15136 $as_echo_n "(cached) " >&6
15138 if ${ac_cv_func_accept_arg3+:} false; then :
15139 $as_echo_n "(cached) " >&6
15141 for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL' 'SOCKET WSAAPI'; do
15142 for ac_cv_func_accept_arg1 in 'int' 'unsigned int' 'SOCKET'; do
15143 for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
15144 for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
15145 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15146 /* end confdefs.h. */
15147 #include <sys/types.h>
15148 #include <sys/socket.h>
15149 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
15151 if ac_fn_c_try_compile "$LINENO"; then :
15152 ac_not_found=no; break 4
15156 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15161 if test "$ac_not_found" = yes; then
15162 as_fn_error $? "could not determine argument types" "$LINENO" 5
15164 if test "$ac_cv_func_accept_arg3" = "void"; then
15165 ac_cv_func_accept_arg3=int
15175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&5
15176 $as_echo "$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6; }
15178 cat >>confdefs.h <<_ACEOF
15179 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
15183 cat >>confdefs.h <<_ACEOF
15184 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
15188 cat >>confdefs.h <<_ACEOF
15189 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
15193 cat >>confdefs.h <<_ACEOF
15194 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
15198 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday takes only one argument" >&5
15199 $as_echo_n "checking whether gettimeofday takes only one argument... " >&6; }
15200 if ${pgac_cv_func_gettimeofday_1arg+:} false; then :
15201 $as_echo_n "(cached) " >&6
15203 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15204 /* end confdefs.h. */
15205 #include <sys/time.h>
15209 struct timeval *tp;
15210 struct timezone *tzp;
15211 gettimeofday(tp,tzp);
15216 if ac_fn_c_try_compile "$LINENO"; then :
15217 pgac_cv_func_gettimeofday_1arg=no
15219 pgac_cv_func_gettimeofday_1arg=yes
15221 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_func_gettimeofday_1arg" >&5
15224 $as_echo "$pgac_cv_func_gettimeofday_1arg" >&6; }
15225 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
15227 $as_echo "#define GETTIMEOFDAY_1ARG 1" >>confdefs.h
15231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wcstombs_l declaration" >&5
15232 $as_echo_n "checking for wcstombs_l declaration... " >&6; }
15233 if ${pgac_cv_func_wcstombs_l+:} false; then :
15234 $as_echo_n "(cached) " >&6
15236 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15237 /* end confdefs.h. */
15238 #include <stdlib.h>
15239 #include <locale.h>
15250 if ac_fn_c_try_compile "$LINENO"; then :
15251 pgac_cv_func_wcstombs_l='yes'
15253 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15254 /* end confdefs.h. */
15255 #include <stdlib.h>
15256 #include <locale.h>
15257 #include <xlocale.h>
15268 if ac_fn_c_try_compile "$LINENO"; then :
15269 pgac_cv_func_wcstombs_l='yes (in xlocale.h)'
15271 pgac_cv_func_wcstombs_l='no'
15273 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15275 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_func_wcstombs_l" >&5
15278 $as_echo "$pgac_cv_func_wcstombs_l" >&6; }
15279 if test "$pgac_cv_func_wcstombs_l" = 'yes (in xlocale.h)'; then
15281 $as_echo "#define WCSTOMBS_L_IN_XLOCALE 1" >>confdefs.h
15285 # Some versions of libedit contain strlcpy(), setproctitle(), and other
15286 # symbols that that library has no business exposing to the world. Pending
15287 # acquisition of a clue by those developers, ignore libedit (including its
15288 # possible alias of libreadline) while checking for everything else.
15289 LIBS_including_readline="$LIBS"
15290 LIBS=`echo "$LIBS" | sed -e 's/-ledit//g' -e 's/-lreadline//g'`
15292 for ac_func in cbrt clock_gettime copyfile fdatasync getifaddrs getpeerucred getrlimit mbstowcs_l memmove poll posix_fallocate ppoll pstat pthread_is_threaded_np readlink setproctitle setproctitle_fast setsid shm_open strchrnul strsignal symlink sync_file_range uselocale utime utimes wcstombs_l
15294 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15295 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15296 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
15297 cat >>confdefs.h <<_ACEOF
15298 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15305 ac_fn_c_check_func "$LINENO" "fseeko" "ac_cv_func_fseeko"
15306 if test "x$ac_cv_func_fseeko" = xyes; then :
15307 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
15310 case " $LIBOBJS " in
15311 *" fseeko.$ac_objext "* ) ;;
15312 *) LIBOBJS="$LIBOBJS fseeko.$ac_objext"
15320 # NetBSD uses a custom fseeko/ftello built on fsetpos/fgetpos
15321 # Mingw uses macros to access Win32 API calls
15324 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
15326 ac_cv_func_fseeko=yes;;
15328 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
15329 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
15330 if ${ac_cv_sys_largefile_source+:} false; then :
15331 $as_echo_n "(cached) " >&6
15334 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15335 /* end confdefs.h. */
15336 #include <sys/types.h> /* for off_t */
15341 int (*fp) (FILE *, off_t, int) = fseeko;
15342 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
15347 if ac_fn_c_try_link "$LINENO"; then :
15348 ac_cv_sys_largefile_source=no; break
15350 rm -f core conftest.err conftest.$ac_objext \
15351 conftest$ac_exeext conftest.$ac_ext
15352 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15353 /* end confdefs.h. */
15354 #define _LARGEFILE_SOURCE 1
15355 #include <sys/types.h> /* for off_t */
15360 int (*fp) (FILE *, off_t, int) = fseeko;
15361 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
15366 if ac_fn_c_try_link "$LINENO"; then :
15367 ac_cv_sys_largefile_source=1; break
15369 rm -f core conftest.err conftest.$ac_objext \
15370 conftest$ac_exeext conftest.$ac_ext
15371 ac_cv_sys_largefile_source=unknown
15375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
15376 $as_echo "$ac_cv_sys_largefile_source" >&6; }
15377 case $ac_cv_sys_largefile_source in #(
15380 cat >>confdefs.h <<_ACEOF
15381 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
15387 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
15388 # in glibc 2.1.3, but that breaks too many other things.
15389 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
15390 if test $ac_cv_sys_largefile_source != unknown; then
15392 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
15398 # posix_fadvise() is a no-op on Solaris, so don't incur function overhead
15399 # by calling it, 2009-04-02
15400 # http://src.opensolaris.org/source/xref/onnv/onnv-gate/usr/src/lib/libc/port/gen/posix_fadvise.c
15401 # The Clang compiler raises a warning for an undeclared identifier that matches
15402 # a compiler builtin function. All extant Clang versions are affected, as of
15403 # Clang 3.6.0. Test a builtin known to every version. This problem affects the
15404 # C and Objective C languages, but Clang does report an error under C++ and
15407 # Passing -fno-builtin to the compiler would suppress this problem. That
15408 # strategy would have the advantage of being insensitive to stray warnings, but
15409 # it would make tests less realistic.
15410 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how $CC reports undeclared, standard C functions" >&5
15411 $as_echo_n "checking how $CC reports undeclared, standard C functions... " >&6; }
15412 if ${ac_cv_c_decl_report+:} false; then :
15413 $as_echo_n "(cached) " >&6
15415 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15416 /* end confdefs.h. */
15426 if ac_fn_c_try_compile "$LINENO"; then :
15427 if test -s conftest.err; then :
15428 # For AC_CHECK_DECL to react to warnings, the compiler must be silent on
15429 # valid AC_CHECK_DECL input. No library function is consistently available
15430 # on freestanding implementations, so test against a dummy declaration.
15431 # Include always-available headers on the off chance that they somehow
15433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15434 /* end confdefs.h. */
15436 #include <limits.h>
15437 #include <stdarg.h>
15438 #include <stddef.h>
15439 extern void ac_decl (int, char *);
15444 (void) ac_decl ((int) 0, (char *) 0);
15454 if ac_fn_c_try_compile "$LINENO"; then :
15455 if test -s conftest.err; then :
15456 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15457 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15458 as_fn_error $? "cannot detect from compiler exit status or warnings
15459 See \`config.log' for more details" "$LINENO" 5; }
15461 ac_cv_c_decl_report=warning
15464 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15465 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15466 as_fn_error $? "cannot compile a simple declaration test
15467 See \`config.log' for more details" "$LINENO" 5; }
15469 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15471 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15472 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15473 as_fn_error $? "compiler does not report undeclared identifiers
15474 See \`config.log' for more details" "$LINENO" 5; }
15477 ac_cv_c_decl_report=error
15479 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_decl_report" >&5
15482 $as_echo "$ac_cv_c_decl_report" >&6; }
15484 case $ac_cv_c_decl_report in
15485 warning) ac_c_decl_warn_flag=yes ;;
15486 *) ac_c_decl_warn_flag= ;;
15489 if test "$PORTNAME" != "solaris"; then :
15491 for ac_func in posix_fadvise
15493 ac_fn_c_check_func "$LINENO" "posix_fadvise" "ac_cv_func_posix_fadvise"
15494 if test "x$ac_cv_func_posix_fadvise" = xyes; then :
15495 cat >>confdefs.h <<_ACEOF
15496 #define HAVE_POSIX_FADVISE 1
15502 ac_fn_c_check_decl "$LINENO" "posix_fadvise" "ac_cv_have_decl_posix_fadvise" "#include <fcntl.h>
15504 if test "x$ac_cv_have_decl_posix_fadvise" = xyes; then :
15510 cat >>confdefs.h <<_ACEOF
15511 #define HAVE_DECL_POSIX_FADVISE $ac_have_decl
15517 ac_fn_c_check_decl "$LINENO" "fdatasync" "ac_cv_have_decl_fdatasync" "#include <unistd.h>
15519 if test "x$ac_cv_have_decl_fdatasync" = xyes; then :
15525 cat >>confdefs.h <<_ACEOF
15526 #define HAVE_DECL_FDATASYNC $ac_have_decl
15529 ac_fn_c_check_decl "$LINENO" "strlcat" "ac_cv_have_decl_strlcat" "$ac_includes_default"
15530 if test "x$ac_cv_have_decl_strlcat" = xyes; then :
15536 cat >>confdefs.h <<_ACEOF
15537 #define HAVE_DECL_STRLCAT $ac_have_decl
15539 ac_fn_c_check_decl "$LINENO" "strlcpy" "ac_cv_have_decl_strlcpy" "$ac_includes_default"
15540 if test "x$ac_cv_have_decl_strlcpy" = xyes; then :
15546 cat >>confdefs.h <<_ACEOF
15547 #define HAVE_DECL_STRLCPY $ac_have_decl
15549 ac_fn_c_check_decl "$LINENO" "strnlen" "ac_cv_have_decl_strnlen" "$ac_includes_default"
15550 if test "x$ac_cv_have_decl_strnlen" = xyes; then :
15556 cat >>confdefs.h <<_ACEOF
15557 #define HAVE_DECL_STRNLEN $ac_have_decl
15560 # This is probably only present on macOS, but may as well check always
15561 ac_fn_c_check_decl "$LINENO" "F_FULLFSYNC" "ac_cv_have_decl_F_FULLFSYNC" "#include <fcntl.h>
15563 if test "x$ac_cv_have_decl_F_FULLFSYNC" = xyes; then :
15569 cat >>confdefs.h <<_ACEOF
15570 #define HAVE_DECL_F_FULLFSYNC $ac_have_decl
15574 ac_fn_c_check_decl "$LINENO" "RTLD_GLOBAL" "ac_cv_have_decl_RTLD_GLOBAL" "#include <dlfcn.h>
15576 if test "x$ac_cv_have_decl_RTLD_GLOBAL" = xyes; then :
15582 cat >>confdefs.h <<_ACEOF
15583 #define HAVE_DECL_RTLD_GLOBAL $ac_have_decl
15585 ac_fn_c_check_decl "$LINENO" "RTLD_NOW" "ac_cv_have_decl_RTLD_NOW" "#include <dlfcn.h>
15587 if test "x$ac_cv_have_decl_RTLD_NOW" = xyes; then :
15593 cat >>confdefs.h <<_ACEOF
15594 #define HAVE_DECL_RTLD_NOW $ac_have_decl
15598 ac_fn_c_check_type "$LINENO" "struct sockaddr_in6" "ac_cv_type_struct_sockaddr_in6" "$ac_includes_default
15599 #include <netinet/in.h>
15601 if test "x$ac_cv_type_struct_sockaddr_in6" = xyes; then :
15603 $as_echo "#define HAVE_IPV6 1" >>confdefs.h
15608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PS_STRINGS" >&5
15609 $as_echo_n "checking for PS_STRINGS... " >&6; }
15610 if ${pgac_cv_var_PS_STRINGS+:} false; then :
15611 $as_echo_n "(cached) " >&6
15613 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15614 /* end confdefs.h. */
15615 #include <machine/vmparam.h>
15616 #include <sys/exec.h>
15621 PS_STRINGS->ps_nargvstr = 1;
15622 PS_STRINGS->ps_argvstr = "foo";
15627 if ac_fn_c_try_link "$LINENO"; then :
15628 pgac_cv_var_PS_STRINGS=yes
15630 pgac_cv_var_PS_STRINGS=no
15632 rm -f core conftest.err conftest.$ac_objext \
15633 conftest$ac_exeext conftest.$ac_ext
15635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_var_PS_STRINGS" >&5
15636 $as_echo "$pgac_cv_var_PS_STRINGS" >&6; }
15637 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
15639 $as_echo "#define HAVE_PS_STRINGS 1" >>confdefs.h
15644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for isinf" >&5
15645 $as_echo_n "checking for isinf... " >&6; }
15646 if ${ac_cv_func_isinf+:} false; then :
15647 $as_echo_n "(cached) " >&6
15649 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15650 /* end confdefs.h. */
15653 double glob_double;
15658 return isinf(glob_double) ? 0 : 1;
15663 if ac_fn_c_try_link "$LINENO"; then :
15664 ac_cv_func_isinf=yes
15666 ac_cv_func_isinf=no
15668 rm -f core conftest.err conftest.$ac_objext \
15669 conftest$ac_exeext conftest.$ac_ext
15671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_isinf" >&5
15672 $as_echo "$ac_cv_func_isinf" >&6; }
15674 if test $ac_cv_func_isinf = yes ; then
15676 $as_echo "#define HAVE_ISINF 1" >>confdefs.h
15679 case " $LIBOBJS " in
15680 *" isinf.$ac_objext "* ) ;;
15681 *) LIBOBJS="$LIBOBJS isinf.$ac_objext"
15685 # Look for a way to implement a substitute for isinf()
15686 for ac_func in fpclass fp_class fp_class_d class
15688 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15689 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15690 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
15691 cat >>confdefs.h <<_ACEOF
15692 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15700 ac_fn_c_check_func "$LINENO" "crypt" "ac_cv_func_crypt"
15701 if test "x$ac_cv_func_crypt" = xyes; then :
15702 $as_echo "#define HAVE_CRYPT 1" >>confdefs.h
15705 case " $LIBOBJS " in
15706 *" crypt.$ac_objext "* ) ;;
15707 *) LIBOBJS="$LIBOBJS crypt.$ac_objext"
15713 ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
15714 if test "x$ac_cv_func_dlopen" = xyes; then :
15715 $as_echo "#define HAVE_DLOPEN 1" >>confdefs.h
15718 case " $LIBOBJS " in
15719 *" dlopen.$ac_objext "* ) ;;
15720 *) LIBOBJS="$LIBOBJS dlopen.$ac_objext"
15726 ac_fn_c_check_func "$LINENO" "fls" "ac_cv_func_fls"
15727 if test "x$ac_cv_func_fls" = xyes; then :
15728 $as_echo "#define HAVE_FLS 1" >>confdefs.h
15731 case " $LIBOBJS " in
15732 *" fls.$ac_objext "* ) ;;
15733 *) LIBOBJS="$LIBOBJS fls.$ac_objext"
15739 ac_fn_c_check_func "$LINENO" "getopt" "ac_cv_func_getopt"
15740 if test "x$ac_cv_func_getopt" = xyes; then :
15741 $as_echo "#define HAVE_GETOPT 1" >>confdefs.h
15744 case " $LIBOBJS " in
15745 *" getopt.$ac_objext "* ) ;;
15746 *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
15752 ac_fn_c_check_func "$LINENO" "getrusage" "ac_cv_func_getrusage"
15753 if test "x$ac_cv_func_getrusage" = xyes; then :
15754 $as_echo "#define HAVE_GETRUSAGE 1" >>confdefs.h
15757 case " $LIBOBJS " in
15758 *" getrusage.$ac_objext "* ) ;;
15759 *) LIBOBJS="$LIBOBJS getrusage.$ac_objext"
15765 ac_fn_c_check_func "$LINENO" "inet_aton" "ac_cv_func_inet_aton"
15766 if test "x$ac_cv_func_inet_aton" = xyes; then :
15767 $as_echo "#define HAVE_INET_ATON 1" >>confdefs.h
15770 case " $LIBOBJS " in
15771 *" inet_aton.$ac_objext "* ) ;;
15772 *) LIBOBJS="$LIBOBJS inet_aton.$ac_objext"
15778 ac_fn_c_check_func "$LINENO" "mkdtemp" "ac_cv_func_mkdtemp"
15779 if test "x$ac_cv_func_mkdtemp" = xyes; then :
15780 $as_echo "#define HAVE_MKDTEMP 1" >>confdefs.h
15783 case " $LIBOBJS " in
15784 *" mkdtemp.$ac_objext "* ) ;;
15785 *) LIBOBJS="$LIBOBJS mkdtemp.$ac_objext"
15791 ac_fn_c_check_func "$LINENO" "pread" "ac_cv_func_pread"
15792 if test "x$ac_cv_func_pread" = xyes; then :
15793 $as_echo "#define HAVE_PREAD 1" >>confdefs.h
15796 case " $LIBOBJS " in
15797 *" pread.$ac_objext "* ) ;;
15798 *) LIBOBJS="$LIBOBJS pread.$ac_objext"
15804 ac_fn_c_check_func "$LINENO" "pwrite" "ac_cv_func_pwrite"
15805 if test "x$ac_cv_func_pwrite" = xyes; then :
15806 $as_echo "#define HAVE_PWRITE 1" >>confdefs.h
15809 case " $LIBOBJS " in
15810 *" pwrite.$ac_objext "* ) ;;
15811 *) LIBOBJS="$LIBOBJS pwrite.$ac_objext"
15817 ac_fn_c_check_func "$LINENO" "random" "ac_cv_func_random"
15818 if test "x$ac_cv_func_random" = xyes; then :
15819 $as_echo "#define HAVE_RANDOM 1" >>confdefs.h
15822 case " $LIBOBJS " in
15823 *" random.$ac_objext "* ) ;;
15824 *) LIBOBJS="$LIBOBJS random.$ac_objext"
15830 ac_fn_c_check_func "$LINENO" "rint" "ac_cv_func_rint"
15831 if test "x$ac_cv_func_rint" = xyes; then :
15832 $as_echo "#define HAVE_RINT 1" >>confdefs.h
15835 case " $LIBOBJS " in
15836 *" rint.$ac_objext "* ) ;;
15837 *) LIBOBJS="$LIBOBJS rint.$ac_objext"
15843 ac_fn_c_check_func "$LINENO" "srandom" "ac_cv_func_srandom"
15844 if test "x$ac_cv_func_srandom" = xyes; then :
15845 $as_echo "#define HAVE_SRANDOM 1" >>confdefs.h
15848 case " $LIBOBJS " in
15849 *" srandom.$ac_objext "* ) ;;
15850 *) LIBOBJS="$LIBOBJS srandom.$ac_objext"
15856 ac_fn_c_check_func "$LINENO" "strlcat" "ac_cv_func_strlcat"
15857 if test "x$ac_cv_func_strlcat" = xyes; then :
15858 $as_echo "#define HAVE_STRLCAT 1" >>confdefs.h
15861 case " $LIBOBJS " in
15862 *" strlcat.$ac_objext "* ) ;;
15863 *) LIBOBJS="$LIBOBJS strlcat.$ac_objext"
15869 ac_fn_c_check_func "$LINENO" "strlcpy" "ac_cv_func_strlcpy"
15870 if test "x$ac_cv_func_strlcpy" = xyes; then :
15871 $as_echo "#define HAVE_STRLCPY 1" >>confdefs.h
15874 case " $LIBOBJS " in
15875 *" strlcpy.$ac_objext "* ) ;;
15876 *) LIBOBJS="$LIBOBJS strlcpy.$ac_objext"
15882 ac_fn_c_check_func "$LINENO" "strnlen" "ac_cv_func_strnlen"
15883 if test "x$ac_cv_func_strnlen" = xyes; then :
15884 $as_echo "#define HAVE_STRNLEN 1" >>confdefs.h
15887 case " $LIBOBJS " in
15888 *" strnlen.$ac_objext "* ) ;;
15889 *) LIBOBJS="$LIBOBJS strnlen.$ac_objext"
15895 ac_fn_c_check_func "$LINENO" "strtof" "ac_cv_func_strtof"
15896 if test "x$ac_cv_func_strtof" = xyes; then :
15897 $as_echo "#define HAVE_STRTOF 1" >>confdefs.h
15900 case " $LIBOBJS " in
15901 *" strtof.$ac_objext "* ) ;;
15902 *) LIBOBJS="$LIBOBJS strtof.$ac_objext"
15912 # Windows uses a specialised env handler
15913 # and doesn't need a replacement getpeereid because it doesn't use
15917 $as_echo "#define HAVE_UNSETENV 1" >>confdefs.h
15920 $as_echo "#define HAVE_GETPEEREID 1" >>confdefs.h
15922 ac_cv_func_unsetenv=yes
15923 ac_cv_func_getpeereid=yes;;
15925 ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv"
15926 if test "x$ac_cv_func_unsetenv" = xyes; then :
15927 $as_echo "#define HAVE_UNSETENV 1" >>confdefs.h
15930 case " $LIBOBJS " in
15931 *" unsetenv.$ac_objext "* ) ;;
15932 *) LIBOBJS="$LIBOBJS unsetenv.$ac_objext"
15938 ac_fn_c_check_func "$LINENO" "getpeereid" "ac_cv_func_getpeereid"
15939 if test "x$ac_cv_func_getpeereid" = xyes; then :
15940 $as_echo "#define HAVE_GETPEEREID 1" >>confdefs.h
15943 case " $LIBOBJS " in
15944 *" getpeereid.$ac_objext "* ) ;;
15945 *) LIBOBJS="$LIBOBJS getpeereid.$ac_objext"
15955 # System's version of getaddrinfo(), if any, may be used only if we found
15956 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h.
15957 # We use only our own getaddrinfo.c on Windows, but it's time to revisit that.
15958 if test x"$ac_cv_type_struct_addrinfo" = xyes && \
15959 test "$PORTNAME" != "win32"; then
15960 ac_fn_c_check_func "$LINENO" "getaddrinfo" "ac_cv_func_getaddrinfo"
15961 if test "x$ac_cv_func_getaddrinfo" = xyes; then :
15962 $as_echo "#define HAVE_GETADDRINFO 1" >>confdefs.h
15965 case " $LIBOBJS " in
15966 *" getaddrinfo.$ac_objext "* ) ;;
15967 *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext"
15975 case " $LIBOBJS " in
15976 *" getaddrinfo.$ac_objext "* ) ;;
15977 *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext"
15983 # Similarly, use system's getopt_long() only if system provides struct option.
15984 if test x"$ac_cv_type_struct_option" = xyes ; then
15985 ac_fn_c_check_func "$LINENO" "getopt_long" "ac_cv_func_getopt_long"
15986 if test "x$ac_cv_func_getopt_long" = xyes; then :
15987 $as_echo "#define HAVE_GETOPT_LONG 1" >>confdefs.h
15990 case " $LIBOBJS " in
15991 *" getopt_long.$ac_objext "* ) ;;
15992 *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
16000 case " $LIBOBJS " in
16001 *" getopt_long.$ac_objext "* ) ;;
16002 *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
16008 # On OpenBSD and Solaris, getopt() doesn't do what we want for long options
16009 # (i.e., allow '-' as a flag character), so use our version on those platforms.
16010 if test "$PORTNAME" = "openbsd" -o "$PORTNAME" = "solaris"; then
16011 case " $LIBOBJS " in
16012 *" getopt.$ac_objext "* ) ;;
16013 *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
16019 # mingw has adopted a GNU-centric interpretation of optind/optreset,
16020 # so always use our version on Windows.
16021 if test "$PORTNAME" = "win32"; then
16022 case " $LIBOBJS " in
16023 *" getopt.$ac_objext "* ) ;;
16024 *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
16028 case " $LIBOBJS " in
16029 *" getopt_long.$ac_objext "* ) ;;
16030 *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
16036 # Win32 (really MinGW) support
16037 if test "$PORTNAME" = "win32"; then
16038 for ac_func in _configthreadlocale
16040 ac_fn_c_check_func "$LINENO" "_configthreadlocale" "ac_cv_func__configthreadlocale"
16041 if test "x$ac_cv_func__configthreadlocale" = xyes; then :
16042 cat >>confdefs.h <<_ACEOF
16043 #define HAVE__CONFIGTHREADLOCALE 1
16049 ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday"
16050 if test "x$ac_cv_func_gettimeofday" = xyes; then :
16051 $as_echo "#define HAVE_GETTIMEOFDAY 1" >>confdefs.h
16054 case " $LIBOBJS " in
16055 *" gettimeofday.$ac_objext "* ) ;;
16056 *) LIBOBJS="$LIBOBJS gettimeofday.$ac_objext"
16063 case " $LIBOBJS " in
16064 *" dirmod.$ac_objext "* ) ;;
16065 *) LIBOBJS="$LIBOBJS dirmod.$ac_objext"
16069 case " $LIBOBJS " in
16070 *" kill.$ac_objext "* ) ;;
16071 *) LIBOBJS="$LIBOBJS kill.$ac_objext"
16075 case " $LIBOBJS " in
16076 *" open.$ac_objext "* ) ;;
16077 *) LIBOBJS="$LIBOBJS open.$ac_objext"
16081 case " $LIBOBJS " in
16082 *" system.$ac_objext "* ) ;;
16083 *) LIBOBJS="$LIBOBJS system.$ac_objext"
16087 case " $LIBOBJS " in
16088 *" win32env.$ac_objext "* ) ;;
16089 *) LIBOBJS="$LIBOBJS win32env.$ac_objext"
16093 case " $LIBOBJS " in
16094 *" win32error.$ac_objext "* ) ;;
16095 *) LIBOBJS="$LIBOBJS win32error.$ac_objext"
16099 case " $LIBOBJS " in
16100 *" win32security.$ac_objext "* ) ;;
16101 *) LIBOBJS="$LIBOBJS win32security.$ac_objext"
16105 case " $LIBOBJS " in
16106 *" win32setlocale.$ac_objext "* ) ;;
16107 *) LIBOBJS="$LIBOBJS win32setlocale.$ac_objext"
16112 $as_echo "#define HAVE_SYMLINK 1" >>confdefs.h
16114 ac_fn_c_check_type "$LINENO" "MINIDUMP_TYPE" "ac_cv_type_MINIDUMP_TYPE" "
16115 #define WIN32_LEAN_AND_MEAN
16116 #include <windows.h>
16117 #include <string.h>
16118 #include <dbghelp.h>
16120 if test "x$ac_cv_type_MINIDUMP_TYPE" = xyes; then :
16122 cat >>confdefs.h <<_ACEOF
16123 #define HAVE_MINIDUMP_TYPE 1
16126 pgac_minidump_type=yes
16128 pgac_minidump_type=no
16132 if test x"$pgac_minidump_type" = x"yes" ; then
16133 have_win32_dbghelp=yes
16136 have_win32_dbghelp=no
16140 # Cygwin needs only a bit of that
16141 if test "$PORTNAME" = "cygwin"; then
16142 case " $LIBOBJS " in
16143 *" dirmod.$ac_objext "* ) ;;
16144 *) LIBOBJS="$LIBOBJS dirmod.$ac_objext"
16150 ac_fn_c_check_func "$LINENO" "syslog" "ac_cv_func_syslog"
16151 if test "x$ac_cv_func_syslog" = xyes; then :
16152 ac_fn_c_check_header_mongrel "$LINENO" "syslog.h" "ac_cv_header_syslog_h" "$ac_includes_default"
16153 if test "x$ac_cv_header_syslog_h" = xyes; then :
16155 $as_echo "#define HAVE_SYSLOG 1" >>confdefs.h
16163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for opterr" >&5
16164 $as_echo_n "checking for opterr... " >&6; }
16165 if ${pgac_cv_var_int_opterr+:} false; then :
16166 $as_echo_n "(cached) " >&6
16168 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16169 /* end confdefs.h. */
16170 #include <unistd.h>
16174 extern int opterr; opterr = 1;
16179 if ac_fn_c_try_link "$LINENO"; then :
16180 pgac_cv_var_int_opterr=yes
16182 pgac_cv_var_int_opterr=no
16184 rm -f core conftest.err conftest.$ac_objext \
16185 conftest$ac_exeext conftest.$ac_ext
16187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_var_int_opterr" >&5
16188 $as_echo "$pgac_cv_var_int_opterr" >&6; }
16189 if test x"$pgac_cv_var_int_opterr" = x"yes"; then
16191 $as_echo "#define HAVE_INT_OPTERR 1" >>confdefs.h
16195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for optreset" >&5
16196 $as_echo_n "checking for optreset... " >&6; }
16197 if ${pgac_cv_var_int_optreset+:} false; then :
16198 $as_echo_n "(cached) " >&6
16200 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16201 /* end confdefs.h. */
16202 #include <unistd.h>
16206 extern int optreset; optreset = 1;
16211 if ac_fn_c_try_link "$LINENO"; then :
16212 pgac_cv_var_int_optreset=yes
16214 pgac_cv_var_int_optreset=no
16216 rm -f core conftest.err conftest.$ac_objext \
16217 conftest$ac_exeext conftest.$ac_ext
16219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_var_int_optreset" >&5
16220 $as_echo "$pgac_cv_var_int_optreset" >&6; }
16221 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
16223 $as_echo "#define HAVE_INT_OPTRESET 1" >>confdefs.h
16227 for ac_func in strtoll __strtoll strtoq
16229 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16230 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16231 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
16232 cat >>confdefs.h <<_ACEOF
16233 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16239 for ac_func in strtoull __strtoull strtouq
16241 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16242 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16243 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
16244 cat >>confdefs.h <<_ACEOF
16245 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16251 # strto[u]ll may exist but not be declared
16252 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
16253 if test "x$ac_cv_have_decl_strtoll" = xyes; then :
16259 cat >>confdefs.h <<_ACEOF
16260 #define HAVE_DECL_STRTOLL $ac_have_decl
16262 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
16263 if test "x$ac_cv_have_decl_strtoull" = xyes; then :
16269 cat >>confdefs.h <<_ACEOF
16270 #define HAVE_DECL_STRTOULL $ac_have_decl
16274 if test "$with_icu" = yes; then
16275 ac_save_CPPFLAGS=$CPPFLAGS
16276 CPPFLAGS="$ICU_CFLAGS $CPPFLAGS"
16278 # Verify we have ICU's header files
16279 ac_fn_c_check_header_mongrel "$LINENO" "unicode/ucol.h" "ac_cv_header_unicode_ucol_h" "$ac_includes_default"
16280 if test "x$ac_cv_header_unicode_ucol_h" = xyes; then :
16283 as_fn_error $? "header file <unicode/ucol.h> is required for ICU" "$LINENO" 5
16288 CPPFLAGS=$ac_save_CPPFLAGS
16291 if test "$with_llvm" = yes; then
16293 # Check which functionality is present
16294 SAVE_CPPFLAGS="$CPPFLAGS"
16295 CPPFLAGS="$CPPFLAGS $LLVM_CPPFLAGS"
16296 ac_fn_c_check_decl "$LINENO" "LLVMOrcGetSymbolAddressIn" "ac_cv_have_decl_LLVMOrcGetSymbolAddressIn" "#include <llvm-c/OrcBindings.h>
16298 if test "x$ac_cv_have_decl_LLVMOrcGetSymbolAddressIn" = xyes; then :
16304 cat >>confdefs.h <<_ACEOF
16305 #define HAVE_DECL_LLVMORCGETSYMBOLADDRESSIN $ac_have_decl
16308 ac_fn_c_check_decl "$LINENO" "LLVMGetHostCPUName" "ac_cv_have_decl_LLVMGetHostCPUName" "#include <llvm-c/TargetMachine.h>
16310 if test "x$ac_cv_have_decl_LLVMGetHostCPUName" = xyes; then :
16316 cat >>confdefs.h <<_ACEOF
16317 #define HAVE_DECL_LLVMGETHOSTCPUNAME $ac_have_decl
16319 ac_fn_c_check_decl "$LINENO" "LLVMGetHostCPUFeatures" "ac_cv_have_decl_LLVMGetHostCPUFeatures" "#include <llvm-c/TargetMachine.h>
16321 if test "x$ac_cv_have_decl_LLVMGetHostCPUFeatures" = xyes; then :
16327 cat >>confdefs.h <<_ACEOF
16328 #define HAVE_DECL_LLVMGETHOSTCPUFEATURES $ac_have_decl
16331 ac_fn_c_check_decl "$LINENO" "LLVMCreateGDBRegistrationListener" "ac_cv_have_decl_LLVMCreateGDBRegistrationListener" "#include <llvm-c/ExecutionEngine.h>
16333 if test "x$ac_cv_have_decl_LLVMCreateGDBRegistrationListener" = xyes; then :
16339 cat >>confdefs.h <<_ACEOF
16340 #define HAVE_DECL_LLVMCREATEGDBREGISTRATIONLISTENER $ac_have_decl
16342 ac_fn_c_check_decl "$LINENO" "LLVMCreatePerfJITEventListener" "ac_cv_have_decl_LLVMCreatePerfJITEventListener" "#include <llvm-c/ExecutionEngine.h>
16344 if test "x$ac_cv_have_decl_LLVMCreatePerfJITEventListener" = xyes; then :
16350 cat >>confdefs.h <<_ACEOF
16351 #define HAVE_DECL_LLVMCREATEPERFJITEVENTLISTENER $ac_have_decl
16354 CPPFLAGS="$SAVE_CPPFLAGS"
16358 # Lastly, restore full LIBS list and check for readline/libedit symbols
16359 LIBS="$LIBS_including_readline"
16361 if test "$with_readline" = yes; then
16362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_completion_append_character" >&5
16363 $as_echo_n "checking for rl_completion_append_character... " >&6; }
16364 if ${pgac_cv_var_rl_completion_append_character+:} false; then :
16365 $as_echo_n "(cached) " >&6
16367 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16368 /* end confdefs.h. */
16370 #ifdef HAVE_READLINE_READLINE_H
16371 # include <readline/readline.h>
16372 #elif defined(HAVE_READLINE_H)
16373 # include <readline.h>
16379 rl_completion_append_character = 'x';
16384 if ac_fn_c_try_link "$LINENO"; then :
16385 pgac_cv_var_rl_completion_append_character=yes
16387 pgac_cv_var_rl_completion_append_character=no
16389 rm -f core conftest.err conftest.$ac_objext \
16390 conftest$ac_exeext conftest.$ac_ext
16392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_var_rl_completion_append_character" >&5
16393 $as_echo "$pgac_cv_var_rl_completion_append_character" >&6; }
16394 if test x"$pgac_cv_var_rl_completion_append_character" = x"yes"; then
16396 $as_echo "#define HAVE_RL_COMPLETION_APPEND_CHARACTER 1" >>confdefs.h
16399 for ac_func in rl_completion_matches rl_filename_completion_function rl_reset_screen_size
16401 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16402 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16403 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
16404 cat >>confdefs.h <<_ACEOF
16405 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16411 for ac_func in append_history history_truncate_file
16413 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16414 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16415 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
16416 cat >>confdefs.h <<_ACEOF
16417 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16426 # This test makes sure that run tests work at all. Sometimes a shared
16427 # library is found by the linker, but the runtime linker can't find it.
16428 # This check should come after all modifications of compiler or linker
16429 # variables, and before any other run tests.
16430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking test program" >&5
16431 $as_echo_n "checking test program... " >&6; }
16432 if test "$cross_compiling" = yes; then :
16433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: cross-compiling" >&5
16434 $as_echo "cross-compiling" >&6; }
16436 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16437 /* end confdefs.h. */
16438 int main() { return 0; }
16440 if ac_fn_c_try_run "$LINENO"; then :
16441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
16442 $as_echo "ok" >&6; }
16444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
16445 $as_echo "failed" >&6; }
16447 Could not execute a simple test program. This may be a problem
16448 related to locating shared libraries. Check the file 'config.log'
16449 for the exact reason." "$LINENO" 5
16451 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16452 conftest.$ac_objext conftest.beam conftest.$ac_ext
16456 # --------------------
16457 # Run tests below here
16458 # --------------------
16461 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether long int is 64 bits" >&5
16462 $as_echo_n "checking whether long int is 64 bits... " >&6; }
16463 if ${pgac_cv_type_long_int_64+:} false; then :
16464 $as_echo_n "(cached) " >&6
16466 if test "$cross_compiling" = yes; then :
16467 # If cross-compiling, check the size reported by the compiler and
16468 # trust that the arithmetic works.
16469 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16470 /* end confdefs.h. */
16475 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
16476 test_array [0] = 0;
16477 return test_array [0];
16483 if ac_fn_c_try_compile "$LINENO"; then :
16484 pgac_cv_type_long_int_64=yes
16486 pgac_cv_type_long_int_64=no
16488 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16490 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16491 /* end confdefs.h. */
16492 typedef long int ac_int64;
16495 * These are globals to discourage the compiler from folding all the
16496 * arithmetic tests down to compile-time constants.
16498 ac_int64 a = 20000001;
16499 ac_int64 b = 40000005;
16501 int does_int64_work()
16505 if (sizeof(ac_int64) != 8)
16506 return 0; /* definitely not the right size */
16508 /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
16518 return (! does_int64_work());
16521 if ac_fn_c_try_run "$LINENO"; then :
16522 pgac_cv_type_long_int_64=yes
16524 pgac_cv_type_long_int_64=no
16526 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16527 conftest.$ac_objext conftest.beam conftest.$ac_ext
16531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_type_long_int_64" >&5
16532 $as_echo "$pgac_cv_type_long_int_64" >&6; }
16534 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
16535 if test x"$pgac_cv_type_long_int_64" = xyes ; then
16537 $as_echo "#define HAVE_LONG_INT_64 1" >>confdefs.h
16542 if test x"$HAVE_LONG_INT_64" = x"yes" ; then
16543 pg_int64_type="long int"
16545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether long long int is 64 bits" >&5
16546 $as_echo_n "checking whether long long int is 64 bits... " >&6; }
16547 if ${pgac_cv_type_long_long_int_64+:} false; then :
16548 $as_echo_n "(cached) " >&6
16550 if test "$cross_compiling" = yes; then :
16551 # If cross-compiling, check the size reported by the compiler and
16552 # trust that the arithmetic works.
16553 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16554 /* end confdefs.h. */
16559 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
16560 test_array [0] = 0;
16561 return test_array [0];
16567 if ac_fn_c_try_compile "$LINENO"; then :
16568 pgac_cv_type_long_long_int_64=yes
16570 pgac_cv_type_long_long_int_64=no
16572 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16574 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16575 /* end confdefs.h. */
16576 typedef long long int ac_int64;
16579 * These are globals to discourage the compiler from folding all the
16580 * arithmetic tests down to compile-time constants.
16582 ac_int64 a = 20000001;
16583 ac_int64 b = 40000005;
16585 int does_int64_work()
16589 if (sizeof(ac_int64) != 8)
16590 return 0; /* definitely not the right size */
16592 /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
16602 return (! does_int64_work());
16605 if ac_fn_c_try_run "$LINENO"; then :
16606 pgac_cv_type_long_long_int_64=yes
16608 pgac_cv_type_long_long_int_64=no
16610 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16611 conftest.$ac_objext conftest.beam conftest.$ac_ext
16615 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_type_long_long_int_64" >&5
16616 $as_echo "$pgac_cv_type_long_long_int_64" >&6; }
16618 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
16619 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
16621 $as_echo "#define HAVE_LONG_LONG_INT_64 1" >>confdefs.h
16625 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
16626 pg_int64_type="long long int"
16628 as_fn_error $? "Cannot find a working 64-bit integer type." "$LINENO" 5
16633 cat >>confdefs.h <<_ACEOF
16634 #define PG_INT64_TYPE $pg_int64_type
16638 # Select the printf length modifier that goes with that, too.
16639 if test x"$pg_int64_type" = x"long long int" ; then
16640 INT64_MODIFIER='"ll"'
16642 INT64_MODIFIER='"l"'
16646 cat >>confdefs.h <<_ACEOF
16647 #define INT64_MODIFIER $INT64_MODIFIER
16651 # has to be down here, rather than with the other builtins, because
16652 # the test uses PG_INT64_TYPE.
16653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_mul_overflow" >&5
16654 $as_echo_n "checking for __builtin_mul_overflow... " >&6; }
16655 if ${pgac_cv__builtin_op_overflow+:} false; then :
16656 $as_echo_n "(cached) " >&6
16658 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16659 /* end confdefs.h. */
16661 PG_INT64_TYPE a = 1;
16662 PG_INT64_TYPE b = 1;
16663 PG_INT64_TYPE result;
16669 oflo = __builtin_mul_overflow(a, b, &result);
16674 if ac_fn_c_try_link "$LINENO"; then :
16675 pgac_cv__builtin_op_overflow=yes
16677 pgac_cv__builtin_op_overflow=no
16679 rm -f core conftest.err conftest.$ac_objext \
16680 conftest$ac_exeext conftest.$ac_ext
16682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_op_overflow" >&5
16683 $as_echo "$pgac_cv__builtin_op_overflow" >&6; }
16684 if test x"$pgac_cv__builtin_op_overflow" = xyes ; then
16686 $as_echo "#define HAVE__BUILTIN_OP_OVERFLOW 1" >>confdefs.h
16690 # Check size of void *, size_t (enables tweaks for > 32bit address space)
16691 # The cast to long int works around a bug in the HP C Compiler
16692 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
16693 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
16694 # This bug is HP SR number 8606223364.
16695 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5
16696 $as_echo_n "checking size of void *... " >&6; }
16697 if ${ac_cv_sizeof_void_p+:} false; then :
16698 $as_echo_n "(cached) " >&6
16700 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"; then :
16703 if test "$ac_cv_type_void_p" = yes; then
16704 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16705 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16706 as_fn_error 77 "cannot compute sizeof (void *)
16707 See \`config.log' for more details" "$LINENO" 5; }
16709 ac_cv_sizeof_void_p=0
16714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5
16715 $as_echo "$ac_cv_sizeof_void_p" >&6; }
16719 cat >>confdefs.h <<_ACEOF
16720 #define SIZEOF_VOID_P $ac_cv_sizeof_void_p
16724 # The cast to long int works around a bug in the HP C Compiler
16725 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
16726 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
16727 # This bug is HP SR number 8606223364.
16728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5
16729 $as_echo_n "checking size of size_t... " >&6; }
16730 if ${ac_cv_sizeof_size_t+:} false; then :
16731 $as_echo_n "(cached) " >&6
16733 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (size_t))" "ac_cv_sizeof_size_t" "$ac_includes_default"; then :
16736 if test "$ac_cv_type_size_t" = yes; then
16737 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16738 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16739 as_fn_error 77 "cannot compute sizeof (size_t)
16740 See \`config.log' for more details" "$LINENO" 5; }
16742 ac_cv_sizeof_size_t=0
16747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5
16748 $as_echo "$ac_cv_sizeof_size_t" >&6; }
16752 cat >>confdefs.h <<_ACEOF
16753 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
16757 # The cast to long int works around a bug in the HP C Compiler
16758 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
16759 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
16760 # This bug is HP SR number 8606223364.
16761 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
16762 $as_echo_n "checking size of long... " >&6; }
16763 if ${ac_cv_sizeof_long+:} false; then :
16764 $as_echo_n "(cached) " >&6
16766 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then :
16769 if test "$ac_cv_type_long" = yes; then
16770 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16771 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16772 as_fn_error 77 "cannot compute sizeof (long)
16773 See \`config.log' for more details" "$LINENO" 5; }
16775 ac_cv_sizeof_long=0
16780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
16781 $as_echo "$ac_cv_sizeof_long" >&6; }
16785 cat >>confdefs.h <<_ACEOF
16786 #define SIZEOF_LONG $ac_cv_sizeof_long
16791 # Decide whether float4 is passed by value: user-selectable, enabled by default
16792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with float4 passed by value" >&5
16793 $as_echo_n "checking whether to build with float4 passed by value... " >&6; }
16796 # Check whether --enable-float4-byval was given.
16797 if test "${enable_float4_byval+set}" = set; then :
16798 enableval=$enable_float4_byval;
16802 $as_echo "#define USE_FLOAT4_BYVAL 1" >>confdefs.h
16804 float4passbyval=true
16807 float4passbyval=false
16810 as_fn_error $? "no argument expected for --enable-float4-byval option" "$LINENO" 5
16815 enable_float4_byval=yes
16817 $as_echo "#define USE_FLOAT4_BYVAL 1" >>confdefs.h
16819 float4passbyval=true
16823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_float4_byval" >&5
16824 $as_echo "$enable_float4_byval" >&6; }
16826 cat >>confdefs.h <<_ACEOF
16827 #define FLOAT4PASSBYVAL $float4passbyval
16831 # Decide whether float8 is passed by value.
16832 # Note: this setting also controls int8 and related types such as timestamp.
16833 # If sizeof(Datum) >= 8, this is user-selectable, enabled by default.
16834 # If not, trying to select it is an error.
16835 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with float8 passed by value" >&5
16836 $as_echo_n "checking whether to build with float8 passed by value... " >&6; }
16837 if test $ac_cv_sizeof_void_p -ge 8 ; then
16840 # Check whether --enable-float8-byval was given.
16841 if test "${enable_float8_byval+set}" = set; then :
16842 enableval=$enable_float8_byval;
16851 as_fn_error $? "no argument expected for --enable-float8-byval option" "$LINENO" 5
16856 enable_float8_byval=yes
16864 # Check whether --enable-float8-byval was given.
16865 if test "${enable_float8_byval+set}" = set; then :
16866 enableval=$enable_float8_byval;
16875 as_fn_error $? "no argument expected for --enable-float8-byval option" "$LINENO" 5
16880 enable_float8_byval=no
16885 if test "$enable_float8_byval" = yes ; then
16886 as_fn_error $? "--enable-float8-byval is not supported on 32-bit platforms." "$LINENO" 5
16889 if test "$enable_float8_byval" = yes ; then
16891 $as_echo "#define USE_FLOAT8_BYVAL 1" >>confdefs.h
16893 float8passbyval=true
16895 float8passbyval=false
16897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_float8_byval" >&5
16898 $as_echo "$enable_float8_byval" >&6; }
16900 cat >>confdefs.h <<_ACEOF
16901 #define FLOAT8PASSBYVAL $float8passbyval
16905 # Determine memory alignment requirements for the basic C data types.
16907 # The cast to long int works around a bug in the HP C Compiler,
16908 # see AC_CHECK_SIZEOF for more information.
16909 { $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of short" >&5
16910 $as_echo_n "checking alignment of short... " >&6; }
16911 if ${ac_cv_alignof_short+:} false; then :
16912 $as_echo_n "(cached) " >&6
16914 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_short" "$ac_includes_default
16916 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
16918 typedef struct { char x; short y; } ac__type_alignof_;"; then :
16921 if test "$ac_cv_type_short" = yes; then
16922 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16923 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16924 as_fn_error 77 "cannot compute alignment of short
16925 See \`config.log' for more details" "$LINENO" 5; }
16927 ac_cv_alignof_short=0
16932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_short" >&5
16933 $as_echo "$ac_cv_alignof_short" >&6; }
16937 cat >>confdefs.h <<_ACEOF
16938 #define ALIGNOF_SHORT $ac_cv_alignof_short
16942 # The cast to long int works around a bug in the HP C Compiler,
16943 # see AC_CHECK_SIZEOF for more information.
16944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of int" >&5
16945 $as_echo_n "checking alignment of int... " >&6; }
16946 if ${ac_cv_alignof_int+:} false; then :
16947 $as_echo_n "(cached) " >&6
16949 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_int" "$ac_includes_default
16951 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
16953 typedef struct { char x; int y; } ac__type_alignof_;"; then :
16956 if test "$ac_cv_type_int" = yes; then
16957 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16958 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16959 as_fn_error 77 "cannot compute alignment of int
16960 See \`config.log' for more details" "$LINENO" 5; }
16962 ac_cv_alignof_int=0
16967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_int" >&5
16968 $as_echo "$ac_cv_alignof_int" >&6; }
16972 cat >>confdefs.h <<_ACEOF
16973 #define ALIGNOF_INT $ac_cv_alignof_int
16977 # The cast to long int works around a bug in the HP C Compiler,
16978 # see AC_CHECK_SIZEOF for more information.
16979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of long" >&5
16980 $as_echo_n "checking alignment of long... " >&6; }
16981 if ${ac_cv_alignof_long+:} false; then :
16982 $as_echo_n "(cached) " >&6
16984 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_long" "$ac_includes_default
16986 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
16988 typedef struct { char x; long y; } ac__type_alignof_;"; then :
16991 if test "$ac_cv_type_long" = yes; then
16992 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16993 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16994 as_fn_error 77 "cannot compute alignment of long
16995 See \`config.log' for more details" "$LINENO" 5; }
16997 ac_cv_alignof_long=0
17002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_long" >&5
17003 $as_echo "$ac_cv_alignof_long" >&6; }
17007 cat >>confdefs.h <<_ACEOF
17008 #define ALIGNOF_LONG $ac_cv_alignof_long
17012 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
17013 # The cast to long int works around a bug in the HP C Compiler,
17014 # see AC_CHECK_SIZEOF for more information.
17015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of long long int" >&5
17016 $as_echo_n "checking alignment of long long int... " >&6; }
17017 if ${ac_cv_alignof_long_long_int+:} false; then :
17018 $as_echo_n "(cached) " >&6
17020 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_long_long_int" "$ac_includes_default
17022 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
17024 typedef struct { char x; long long int y; } ac__type_alignof_;"; then :
17027 if test "$ac_cv_type_long_long_int" = yes; then
17028 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17029 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17030 as_fn_error 77 "cannot compute alignment of long long int
17031 See \`config.log' for more details" "$LINENO" 5; }
17033 ac_cv_alignof_long_long_int=0
17038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_long_long_int" >&5
17039 $as_echo "$ac_cv_alignof_long_long_int" >&6; }
17043 cat >>confdefs.h <<_ACEOF
17044 #define ALIGNOF_LONG_LONG_INT $ac_cv_alignof_long_long_int
17049 # The cast to long int works around a bug in the HP C Compiler,
17050 # see AC_CHECK_SIZEOF for more information.
17051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of double" >&5
17052 $as_echo_n "checking alignment of double... " >&6; }
17053 if ${ac_cv_alignof_double+:} false; then :
17054 $as_echo_n "(cached) " >&6
17056 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_double" "$ac_includes_default
17058 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
17060 typedef struct { char x; double y; } ac__type_alignof_;"; then :
17063 if test "$ac_cv_type_double" = yes; then
17064 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17065 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17066 as_fn_error 77 "cannot compute alignment of double
17067 See \`config.log' for more details" "$LINENO" 5; }
17069 ac_cv_alignof_double=0
17074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_double" >&5
17075 $as_echo "$ac_cv_alignof_double" >&6; }
17079 cat >>confdefs.h <<_ACEOF
17080 #define ALIGNOF_DOUBLE $ac_cv_alignof_double
17085 # Compute maximum alignment of any basic type.
17086 # We assume long's alignment is at least as strong as char, short, or int;
17087 # but we must check long long (if it is being used for int64) and double.
17088 # Note that we intentionally do not consider any types wider than 64 bits,
17089 # as allowing MAXIMUM_ALIGNOF to exceed 8 would be too much of a penalty
17090 # for disk and memory space.
17092 MAX_ALIGNOF=$ac_cv_alignof_long
17093 if test $MAX_ALIGNOF -lt $ac_cv_alignof_double ; then
17094 MAX_ALIGNOF=$ac_cv_alignof_double
17096 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $ac_cv_alignof_long_long_int ; then
17097 MAX_ALIGNOF="$ac_cv_alignof_long_long_int"
17100 cat >>confdefs.h <<_ACEOF
17101 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
17106 # Some platforms predefine the types int8, int16, etc. Only check
17107 # a (hopefully) representative subset.
17108 ac_fn_c_check_type "$LINENO" "int8" "ac_cv_type_int8" "#include <stdio.h>
17110 if test "x$ac_cv_type_int8" = xyes; then :
17112 cat >>confdefs.h <<_ACEOF
17113 #define HAVE_INT8 1
17118 ac_fn_c_check_type "$LINENO" "uint8" "ac_cv_type_uint8" "#include <stdio.h>
17120 if test "x$ac_cv_type_uint8" = xyes; then :
17122 cat >>confdefs.h <<_ACEOF
17123 #define HAVE_UINT8 1
17128 ac_fn_c_check_type "$LINENO" "int64" "ac_cv_type_int64" "#include <stdio.h>
17130 if test "x$ac_cv_type_int64" = xyes; then :
17132 cat >>confdefs.h <<_ACEOF
17133 #define HAVE_INT64 1
17138 ac_fn_c_check_type "$LINENO" "uint64" "ac_cv_type_uint64" "#include <stdio.h>
17140 if test "x$ac_cv_type_uint64" = xyes; then :
17142 cat >>confdefs.h <<_ACEOF
17143 #define HAVE_UINT64 1
17150 # Some compilers offer a 128-bit integer scalar type.
17151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __int128" >&5
17152 $as_echo_n "checking for __int128... " >&6; }
17153 if ${pgac_cv__128bit_int+:} false; then :
17154 $as_echo_n "(cached) " >&6
17156 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17157 /* end confdefs.h. */
17160 * We don't actually run this test, just link it to verify that any support
17161 * functions needed for __int128 are present.
17163 * These are globals to discourage the compiler from folding all the
17164 * arithmetic tests down to compile-time constants. We do not have
17165 * convenient support for 128bit literals at this point...
17167 __int128 a = 48828125;
17168 __int128 b = 97656250;
17175 a = (a << 12) + 1; /* 200000000001 */
17176 b = (b << 12) + 5; /* 400000000005 */
17177 /* try the most relevant arithmetic ops */
17180 /* must use the results, else compiler may optimize arithmetic away */
17188 if ac_fn_c_try_link "$LINENO"; then :
17189 pgac_cv__128bit_int=yes
17191 pgac_cv__128bit_int=no
17193 rm -f core conftest.err conftest.$ac_objext \
17194 conftest$ac_exeext conftest.$ac_ext
17196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__128bit_int" >&5
17197 $as_echo "$pgac_cv__128bit_int" >&6; }
17198 if test x"$pgac_cv__128bit_int" = xyes ; then
17199 # Use of non-default alignment with __int128 tickles bugs in some compilers.
17200 # If not cross-compiling, we can test for bugs and disable use of __int128
17201 # with buggy compilers. If cross-compiling, hope for the best.
17202 # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83925
17203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __int128 alignment bug" >&5
17204 $as_echo_n "checking for __int128 alignment bug... " >&6; }
17205 if ${pgac_cv__128bit_int_bug+:} false; then :
17206 $as_echo_n "(cached) " >&6
17208 if test "$cross_compiling" = yes; then :
17209 pgac_cv__128bit_int_bug="assuming ok"
17211 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17212 /* end confdefs.h. */
17214 /* This must match the corresponding code in c.h: */
17215 #if defined(__GNUC__) || defined(__SUNPRO_C) || defined(__IBMC__)
17216 #define pg_attribute_aligned(a) __attribute__((aligned(a)))
17218 typedef __int128 int128a
17219 #if defined(pg_attribute_aligned)
17220 pg_attribute_aligned(8)
17224 void pass_by_val(void *buffer, int128a par) { holder = par; }
17230 long int i64 = 97656225L << 12;
17232 pass_by_val(main, (int128a) i64);
17241 if ac_fn_c_try_run "$LINENO"; then :
17242 pgac_cv__128bit_int_bug=ok
17244 pgac_cv__128bit_int_bug=broken
17246 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17247 conftest.$ac_objext conftest.beam conftest.$ac_ext
17251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__128bit_int_bug" >&5
17252 $as_echo "$pgac_cv__128bit_int_bug" >&6; }
17253 if test x"$pgac_cv__128bit_int_bug" != xbroken ; then
17255 $as_echo "#define PG_INT128_TYPE __int128" >>confdefs.h
17257 # The cast to long int works around a bug in the HP C Compiler,
17258 # see AC_CHECK_SIZEOF for more information.
17259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of PG_INT128_TYPE" >&5
17260 $as_echo_n "checking alignment of PG_INT128_TYPE... " >&6; }
17261 if ${ac_cv_alignof_PG_INT128_TYPE+:} false; then :
17262 $as_echo_n "(cached) " >&6
17264 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_PG_INT128_TYPE" "$ac_includes_default
17266 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
17268 typedef struct { char x; PG_INT128_TYPE y; } ac__type_alignof_;"; then :
17271 if test "$ac_cv_type_PG_INT128_TYPE" = yes; then
17272 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17273 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17274 as_fn_error 77 "cannot compute alignment of PG_INT128_TYPE
17275 See \`config.log' for more details" "$LINENO" 5; }
17277 ac_cv_alignof_PG_INT128_TYPE=0
17282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_PG_INT128_TYPE" >&5
17283 $as_echo "$ac_cv_alignof_PG_INT128_TYPE" >&6; }
17287 cat >>confdefs.h <<_ACEOF
17288 #define ALIGNOF_PG_INT128_TYPE $ac_cv_alignof_PG_INT128_TYPE
17295 # Check for various atomic operations now that we have checked how to declare
17297 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __sync char locking functions" >&5
17298 $as_echo_n "checking for builtin __sync char locking functions... " >&6; }
17299 if ${pgac_cv_gcc_sync_char_tas+:} false; then :
17300 $as_echo_n "(cached) " >&6
17302 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17303 /* end confdefs.h. */
17309 __sync_lock_test_and_set(&lock, 1);
17310 __sync_lock_release(&lock);
17315 if ac_fn_c_try_link "$LINENO"; then :
17316 pgac_cv_gcc_sync_char_tas="yes"
17318 pgac_cv_gcc_sync_char_tas="no"
17320 rm -f core conftest.err conftest.$ac_objext \
17321 conftest$ac_exeext conftest.$ac_ext
17323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_gcc_sync_char_tas" >&5
17324 $as_echo "$pgac_cv_gcc_sync_char_tas" >&6; }
17325 if test x"$pgac_cv_gcc_sync_char_tas" = x"yes"; then
17327 $as_echo "#define HAVE_GCC__SYNC_CHAR_TAS 1" >>confdefs.h
17330 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __sync int32 locking functions" >&5
17331 $as_echo_n "checking for builtin __sync int32 locking functions... " >&6; }
17332 if ${pgac_cv_gcc_sync_int32_tas+:} false; then :
17333 $as_echo_n "(cached) " >&6
17335 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17336 /* end confdefs.h. */
17342 __sync_lock_test_and_set(&lock, 1);
17343 __sync_lock_release(&lock);
17348 if ac_fn_c_try_link "$LINENO"; then :
17349 pgac_cv_gcc_sync_int32_tas="yes"
17351 pgac_cv_gcc_sync_int32_tas="no"
17353 rm -f core conftest.err conftest.$ac_objext \
17354 conftest$ac_exeext conftest.$ac_ext
17356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_gcc_sync_int32_tas" >&5
17357 $as_echo "$pgac_cv_gcc_sync_int32_tas" >&6; }
17358 if test x"$pgac_cv_gcc_sync_int32_tas" = x"yes"; then
17360 $as_echo "#define HAVE_GCC__SYNC_INT32_TAS 1" >>confdefs.h
17363 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __sync int32 atomic operations" >&5
17364 $as_echo_n "checking for builtin __sync int32 atomic operations... " >&6; }
17365 if ${pgac_cv_gcc_sync_int32_cas+:} false; then :
17366 $as_echo_n "(cached) " >&6
17368 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17369 /* end confdefs.h. */
17375 __sync_val_compare_and_swap(&val, 0, 37);
17380 if ac_fn_c_try_link "$LINENO"; then :
17381 pgac_cv_gcc_sync_int32_cas="yes"
17383 pgac_cv_gcc_sync_int32_cas="no"
17385 rm -f core conftest.err conftest.$ac_objext \
17386 conftest$ac_exeext conftest.$ac_ext
17388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_gcc_sync_int32_cas" >&5
17389 $as_echo "$pgac_cv_gcc_sync_int32_cas" >&6; }
17390 if test x"$pgac_cv_gcc_sync_int32_cas" = x"yes"; then
17392 $as_echo "#define HAVE_GCC__SYNC_INT32_CAS 1" >>confdefs.h
17395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __sync int64 atomic operations" >&5
17396 $as_echo_n "checking for builtin __sync int64 atomic operations... " >&6; }
17397 if ${pgac_cv_gcc_sync_int64_cas+:} false; then :
17398 $as_echo_n "(cached) " >&6
17400 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17401 /* end confdefs.h. */
17406 PG_INT64_TYPE lock = 0;
17407 __sync_val_compare_and_swap(&lock, 0, (PG_INT64_TYPE) 37);
17412 if ac_fn_c_try_link "$LINENO"; then :
17413 pgac_cv_gcc_sync_int64_cas="yes"
17415 pgac_cv_gcc_sync_int64_cas="no"
17417 rm -f core conftest.err conftest.$ac_objext \
17418 conftest$ac_exeext conftest.$ac_ext
17420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_gcc_sync_int64_cas" >&5
17421 $as_echo "$pgac_cv_gcc_sync_int64_cas" >&6; }
17422 if test x"$pgac_cv_gcc_sync_int64_cas" = x"yes"; then
17424 $as_echo "#define HAVE_GCC__SYNC_INT64_CAS 1" >>confdefs.h
17427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __atomic int32 atomic operations" >&5
17428 $as_echo_n "checking for builtin __atomic int32 atomic operations... " >&6; }
17429 if ${pgac_cv_gcc_atomic_int32_cas+:} false; then :
17430 $as_echo_n "(cached) " >&6
17432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17433 /* end confdefs.h. */
17440 __atomic_compare_exchange_n(&val, &expect, 37, 0, __ATOMIC_SEQ_CST, __ATOMIC_RELAXED);
17445 if ac_fn_c_try_link "$LINENO"; then :
17446 pgac_cv_gcc_atomic_int32_cas="yes"
17448 pgac_cv_gcc_atomic_int32_cas="no"
17450 rm -f core conftest.err conftest.$ac_objext \
17451 conftest$ac_exeext conftest.$ac_ext
17453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_gcc_atomic_int32_cas" >&5
17454 $as_echo "$pgac_cv_gcc_atomic_int32_cas" >&6; }
17455 if test x"$pgac_cv_gcc_atomic_int32_cas" = x"yes"; then
17457 $as_echo "#define HAVE_GCC__ATOMIC_INT32_CAS 1" >>confdefs.h
17460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __atomic int64 atomic operations" >&5
17461 $as_echo_n "checking for builtin __atomic int64 atomic operations... " >&6; }
17462 if ${pgac_cv_gcc_atomic_int64_cas+:} false; then :
17463 $as_echo_n "(cached) " >&6
17465 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17466 /* end confdefs.h. */
17471 PG_INT64_TYPE val = 0;
17472 PG_INT64_TYPE expect = 0;
17473 __atomic_compare_exchange_n(&val, &expect, 37, 0, __ATOMIC_SEQ_CST, __ATOMIC_RELAXED);
17478 if ac_fn_c_try_link "$LINENO"; then :
17479 pgac_cv_gcc_atomic_int64_cas="yes"
17481 pgac_cv_gcc_atomic_int64_cas="no"
17483 rm -f core conftest.err conftest.$ac_objext \
17484 conftest$ac_exeext conftest.$ac_ext
17486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_gcc_atomic_int64_cas" >&5
17487 $as_echo "$pgac_cv_gcc_atomic_int64_cas" >&6; }
17488 if test x"$pgac_cv_gcc_atomic_int64_cas" = x"yes"; then
17490 $as_echo "#define HAVE_GCC__ATOMIC_INT64_CAS 1" >>confdefs.h
17495 # Check for x86 cpuid instruction
17496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __get_cpuid" >&5
17497 $as_echo_n "checking for __get_cpuid... " >&6; }
17498 if ${pgac_cv__get_cpuid+:} false; then :
17499 $as_echo_n "(cached) " >&6
17501 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17502 /* end confdefs.h. */
17507 unsigned int exx[4] = {0, 0, 0, 0};
17508 __get_cpuid(1, &exx[0], &exx[1], &exx[2], &exx[3]);
17514 if ac_fn_c_try_link "$LINENO"; then :
17515 pgac_cv__get_cpuid="yes"
17517 pgac_cv__get_cpuid="no"
17519 rm -f core conftest.err conftest.$ac_objext \
17520 conftest$ac_exeext conftest.$ac_ext
17522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__get_cpuid" >&5
17523 $as_echo "$pgac_cv__get_cpuid" >&6; }
17524 if test x"$pgac_cv__get_cpuid" = x"yes"; then
17526 $as_echo "#define HAVE__GET_CPUID 1" >>confdefs.h
17530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __cpuid" >&5
17531 $as_echo_n "checking for __cpuid... " >&6; }
17532 if ${pgac_cv__cpuid+:} false; then :
17533 $as_echo_n "(cached) " >&6
17535 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17536 /* end confdefs.h. */
17537 #include <intrin.h>
17541 unsigned int exx[4] = {0, 0, 0, 0};
17542 __get_cpuid(exx[0], 1);
17548 if ac_fn_c_try_link "$LINENO"; then :
17549 pgac_cv__cpuid="yes"
17551 pgac_cv__cpuid="no"
17553 rm -f core conftest.err conftest.$ac_objext \
17554 conftest$ac_exeext conftest.$ac_ext
17556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__cpuid" >&5
17557 $as_echo "$pgac_cv__cpuid" >&6; }
17558 if test x"$pgac_cv__cpuid" = x"yes"; then
17560 $as_echo "#define HAVE__CPUID 1" >>confdefs.h
17564 # Check for Intel SSE 4.2 intrinsics to do CRC calculations.
17566 # First check if the _mm_crc32_u8 and _mm_crc32_u64 intrinsics can be used
17567 # with the default compiler flags. If not, check if adding the -msse4.2
17568 # flag helps. CFLAGS_SSE42 is set to -msse4.2 if that's required.
17569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _mm_crc32_u8 and _mm_crc32_u32 with CFLAGS=" >&5
17570 $as_echo_n "checking for _mm_crc32_u8 and _mm_crc32_u32 with CFLAGS=... " >&6; }
17571 if ${pgac_cv_sse42_crc32_intrinsics_+:} false; then :
17572 $as_echo_n "(cached) " >&6
17574 pgac_save_CFLAGS=$CFLAGS
17575 CFLAGS="$pgac_save_CFLAGS "
17576 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17577 /* end confdefs.h. */
17578 #include <nmmintrin.h>
17582 unsigned int crc = 0;
17583 crc = _mm_crc32_u8(crc, 0);
17584 crc = _mm_crc32_u32(crc, 0);
17585 /* return computed value, to prevent the above being optimized away */
17591 if ac_fn_c_try_link "$LINENO"; then :
17592 pgac_cv_sse42_crc32_intrinsics_=yes
17594 pgac_cv_sse42_crc32_intrinsics_=no
17596 rm -f core conftest.err conftest.$ac_objext \
17597 conftest$ac_exeext conftest.$ac_ext
17598 CFLAGS="$pgac_save_CFLAGS"
17600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_sse42_crc32_intrinsics_" >&5
17601 $as_echo "$pgac_cv_sse42_crc32_intrinsics_" >&6; }
17602 if test x"$pgac_cv_sse42_crc32_intrinsics_" = x"yes"; then
17604 pgac_sse42_crc32_intrinsics=yes
17607 if test x"$pgac_sse42_crc32_intrinsics" != x"yes"; then
17608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _mm_crc32_u8 and _mm_crc32_u32 with CFLAGS=-msse4.2" >&5
17609 $as_echo_n "checking for _mm_crc32_u8 and _mm_crc32_u32 with CFLAGS=-msse4.2... " >&6; }
17610 if ${pgac_cv_sse42_crc32_intrinsics__msse4_2+:} false; then :
17611 $as_echo_n "(cached) " >&6
17613 pgac_save_CFLAGS=$CFLAGS
17614 CFLAGS="$pgac_save_CFLAGS -msse4.2"
17615 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17616 /* end confdefs.h. */
17617 #include <nmmintrin.h>
17621 unsigned int crc = 0;
17622 crc = _mm_crc32_u8(crc, 0);
17623 crc = _mm_crc32_u32(crc, 0);
17624 /* return computed value, to prevent the above being optimized away */
17630 if ac_fn_c_try_link "$LINENO"; then :
17631 pgac_cv_sse42_crc32_intrinsics__msse4_2=yes
17633 pgac_cv_sse42_crc32_intrinsics__msse4_2=no
17635 rm -f core conftest.err conftest.$ac_objext \
17636 conftest$ac_exeext conftest.$ac_ext
17637 CFLAGS="$pgac_save_CFLAGS"
17639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_sse42_crc32_intrinsics__msse4_2" >&5
17640 $as_echo "$pgac_cv_sse42_crc32_intrinsics__msse4_2" >&6; }
17641 if test x"$pgac_cv_sse42_crc32_intrinsics__msse4_2" = x"yes"; then
17642 CFLAGS_SSE42="-msse4.2"
17643 pgac_sse42_crc32_intrinsics=yes
17649 # Are we targeting a processor that supports SSE 4.2? gcc, clang and icc all
17650 # define __SSE4_2__ in that case.
17651 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17652 /* end confdefs.h. */
17659 #error __SSE4_2__ not defined
17666 if ac_fn_c_try_compile "$LINENO"; then :
17669 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17671 # Check for ARMv8 CRC Extension intrinsics to do CRC calculations.
17673 # First check if __crc32c* intrinsics can be used with the default compiler
17674 # flags. If not, check if adding -march=armv8-a+crc flag helps.
17675 # CFLAGS_ARMV8_CRC32C is set if the extra flag is required.
17676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __crc32cb, __crc32ch, __crc32cw, and __crc32cd with CFLAGS=" >&5
17677 $as_echo_n "checking for __crc32cb, __crc32ch, __crc32cw, and __crc32cd with CFLAGS=... " >&6; }
17678 if ${pgac_cv_armv8_crc32c_intrinsics_+:} false; then :
17679 $as_echo_n "(cached) " >&6
17681 pgac_save_CFLAGS=$CFLAGS
17682 CFLAGS="$pgac_save_CFLAGS "
17683 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17684 /* end confdefs.h. */
17685 #include <arm_acle.h>
17689 unsigned int crc = 0;
17690 crc = __crc32cb(crc, 0);
17691 crc = __crc32ch(crc, 0);
17692 crc = __crc32cw(crc, 0);
17693 crc = __crc32cd(crc, 0);
17694 /* return computed value, to prevent the above being optimized away */
17700 if ac_fn_c_try_link "$LINENO"; then :
17701 pgac_cv_armv8_crc32c_intrinsics_=yes
17703 pgac_cv_armv8_crc32c_intrinsics_=no
17705 rm -f core conftest.err conftest.$ac_objext \
17706 conftest$ac_exeext conftest.$ac_ext
17707 CFLAGS="$pgac_save_CFLAGS"
17709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_armv8_crc32c_intrinsics_" >&5
17710 $as_echo "$pgac_cv_armv8_crc32c_intrinsics_" >&6; }
17711 if test x"$pgac_cv_armv8_crc32c_intrinsics_" = x"yes"; then
17712 CFLAGS_ARMV8_CRC32C=""
17713 pgac_armv8_crc32c_intrinsics=yes
17716 if test x"$pgac_armv8_crc32c_intrinsics" != x"yes"; then
17717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __crc32cb, __crc32ch, __crc32cw, and __crc32cd with CFLAGS=-march=armv8-a+crc" >&5
17718 $as_echo_n "checking for __crc32cb, __crc32ch, __crc32cw, and __crc32cd with CFLAGS=-march=armv8-a+crc... " >&6; }
17719 if ${pgac_cv_armv8_crc32c_intrinsics__march_armv8_apcrc+:} false; then :
17720 $as_echo_n "(cached) " >&6
17722 pgac_save_CFLAGS=$CFLAGS
17723 CFLAGS="$pgac_save_CFLAGS -march=armv8-a+crc"
17724 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17725 /* end confdefs.h. */
17726 #include <arm_acle.h>
17730 unsigned int crc = 0;
17731 crc = __crc32cb(crc, 0);
17732 crc = __crc32ch(crc, 0);
17733 crc = __crc32cw(crc, 0);
17734 crc = __crc32cd(crc, 0);
17735 /* return computed value, to prevent the above being optimized away */
17741 if ac_fn_c_try_link "$LINENO"; then :
17742 pgac_cv_armv8_crc32c_intrinsics__march_armv8_apcrc=yes
17744 pgac_cv_armv8_crc32c_intrinsics__march_armv8_apcrc=no
17746 rm -f core conftest.err conftest.$ac_objext \
17747 conftest$ac_exeext conftest.$ac_ext
17748 CFLAGS="$pgac_save_CFLAGS"
17750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_armv8_crc32c_intrinsics__march_armv8_apcrc" >&5
17751 $as_echo "$pgac_cv_armv8_crc32c_intrinsics__march_armv8_apcrc" >&6; }
17752 if test x"$pgac_cv_armv8_crc32c_intrinsics__march_armv8_apcrc" = x"yes"; then
17753 CFLAGS_ARMV8_CRC32C="-march=armv8-a+crc"
17754 pgac_armv8_crc32c_intrinsics=yes
17760 # Select CRC-32C implementation.
17762 # If we are targeting a processor that has Intel SSE 4.2 instructions, we can
17763 # use the special CRC instructions for calculating CRC-32C. If we're not
17764 # targeting such a processor, but we can nevertheless produce code that uses
17765 # the SSE intrinsics, perhaps with some extra CFLAGS, compile both
17766 # implementations and select which one to use at runtime, depending on whether
17767 # SSE 4.2 is supported by the processor we're running on.
17769 # Similarly, if we are targeting an ARM processor that has the CRC
17770 # instructions that are part of the ARMv8 CRC Extension, use them. And if
17771 # we're not targeting such a processor, but can nevertheless produce code that
17772 # uses the CRC instructions, compile both, and select at runtime.
17774 # You can override this logic by setting the appropriate USE_*_CRC32 flag to 1
17775 # in the template or configure command line.
17776 if test x"$USE_SLICING_BY_8_CRC32C" = x"" && test x"$USE_SSE42_CRC32C" = x"" && test x"$USE_SSE42_CRC32C_WITH_RUNTIME_CHECK" = x"" && test x"$USE_ARMV8_CRC32C" = x"" && test x"$USE_ARMV8_CRC32C_WITH_RUNTIME_CHECK" = x""; then
17777 # Use Intel SSE 4.2 if available.
17778 if test x"$pgac_sse42_crc32_intrinsics" = x"yes" && test x"$SSE4_2_TARGETED" = x"1" ; then
17781 # Intel SSE 4.2, with runtime check? The CPUID instruction is needed for
17782 # the runtime check.
17783 if test x"$pgac_sse42_crc32_intrinsics" = x"yes" && (test x"$pgac_cv__get_cpuid" = x"yes" || test x"$pgac_cv__cpuid" = x"yes"); then
17784 USE_SSE42_CRC32C_WITH_RUNTIME_CHECK=1
17786 # Use ARM CRC Extension if available.
17787 if test x"$pgac_armv8_crc32c_intrinsics" = x"yes" && test x"$CFLAGS_ARMV8_CRC32C" = x""; then
17790 # ARM CRC Extension, with runtime check?
17791 if test x"$pgac_armv8_crc32c_intrinsics" = x"yes"; then
17792 USE_ARMV8_CRC32C_WITH_RUNTIME_CHECK=1
17794 # fall back to slicing-by-8 algorithm, which doesn't require any
17795 # special CPU support.
17796 USE_SLICING_BY_8_CRC32C=1
17803 # Set PG_CRC32C_OBJS appropriately depending on the selected implementation.
17804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which CRC-32C implementation to use" >&5
17805 $as_echo_n "checking which CRC-32C implementation to use... " >&6; }
17806 if test x"$USE_SSE42_CRC32C" = x"1"; then
17808 $as_echo "#define USE_SSE42_CRC32C 1" >>confdefs.h
17810 PG_CRC32C_OBJS="pg_crc32c_sse42.o"
17811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: SSE 4.2" >&5
17812 $as_echo "SSE 4.2" >&6; }
17814 if test x"$USE_SSE42_CRC32C_WITH_RUNTIME_CHECK" = x"1"; then
17816 $as_echo "#define USE_SSE42_CRC32C_WITH_RUNTIME_CHECK 1" >>confdefs.h
17818 PG_CRC32C_OBJS="pg_crc32c_sse42.o pg_crc32c_sb8.o pg_crc32c_sse42_choose.o"
17819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: SSE 4.2 with runtime check" >&5
17820 $as_echo "SSE 4.2 with runtime check" >&6; }
17822 if test x"$USE_ARMV8_CRC32C" = x"1"; then
17824 $as_echo "#define USE_ARMV8_CRC32C 1" >>confdefs.h
17826 PG_CRC32C_OBJS="pg_crc32c_armv8.o"
17827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ARMv8 CRC instructions" >&5
17828 $as_echo "ARMv8 CRC instructions" >&6; }
17830 if test x"$USE_ARMV8_CRC32C_WITH_RUNTIME_CHECK" = x"1"; then
17832 $as_echo "#define USE_ARMV8_CRC32C_WITH_RUNTIME_CHECK 1" >>confdefs.h
17834 PG_CRC32C_OBJS="pg_crc32c_armv8.o pg_crc32c_sb8.o pg_crc32c_armv8_choose.o"
17835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ARMv8 CRC instructions with runtime check" >&5
17836 $as_echo "ARMv8 CRC instructions with runtime check" >&6; }
17839 $as_echo "#define USE_SLICING_BY_8_CRC32C 1" >>confdefs.h
17841 PG_CRC32C_OBJS="pg_crc32c_sb8.o"
17842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: slicing-by-8" >&5
17843 $as_echo "slicing-by-8" >&6; }
17851 # Select semaphore implementation type.
17852 if test "$PORTNAME" != "win32"; then
17853 if test x"$PREFERRED_SEMAPHORES" = x"NAMED_POSIX" ; then
17854 # Need sem_open for this
17855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sem_open" >&5
17856 $as_echo_n "checking for library containing sem_open... " >&6; }
17857 if ${ac_cv_search_sem_open+:} false; then :
17858 $as_echo_n "(cached) " >&6
17860 ac_func_search_save_LIBS=$LIBS
17861 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17862 /* end confdefs.h. */
17864 /* Override any GCC internal prototype to avoid an error.
17865 Use char because int might match the return type of a GCC
17866 builtin and then its argument prototype would still apply. */
17874 return sem_open ();
17879 for ac_lib in '' rt pthread; do
17880 if test -z "$ac_lib"; then
17881 ac_res="none required"
17884 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
17886 if ac_fn_c_try_link "$LINENO"; then :
17887 ac_cv_search_sem_open=$ac_res
17889 rm -f core conftest.err conftest.$ac_objext \
17891 if ${ac_cv_search_sem_open+:} false; then :
17895 if ${ac_cv_search_sem_open+:} false; then :
17898 ac_cv_search_sem_open=no
17900 rm conftest.$ac_ext
17901 LIBS=$ac_func_search_save_LIBS
17903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sem_open" >&5
17904 $as_echo "$ac_cv_search_sem_open" >&6; }
17905 ac_res=$ac_cv_search_sem_open
17906 if test "$ac_res" != no; then :
17907 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17908 USE_NAMED_POSIX_SEMAPHORES=1
17912 if test x"$PREFERRED_SEMAPHORES" = x"UNNAMED_POSIX" ; then
17913 # Need sem_init for this
17914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sem_init" >&5
17915 $as_echo_n "checking for library containing sem_init... " >&6; }
17916 if ${ac_cv_search_sem_init+:} false; then :
17917 $as_echo_n "(cached) " >&6
17919 ac_func_search_save_LIBS=$LIBS
17920 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17921 /* end confdefs.h. */
17923 /* Override any GCC internal prototype to avoid an error.
17924 Use char because int might match the return type of a GCC
17925 builtin and then its argument prototype would still apply. */
17933 return sem_init ();
17938 for ac_lib in '' rt pthread; do
17939 if test -z "$ac_lib"; then
17940 ac_res="none required"
17943 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
17945 if ac_fn_c_try_link "$LINENO"; then :
17946 ac_cv_search_sem_init=$ac_res
17948 rm -f core conftest.err conftest.$ac_objext \
17950 if ${ac_cv_search_sem_init+:} false; then :
17954 if ${ac_cv_search_sem_init+:} false; then :
17957 ac_cv_search_sem_init=no
17959 rm conftest.$ac_ext
17960 LIBS=$ac_func_search_save_LIBS
17962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sem_init" >&5
17963 $as_echo "$ac_cv_search_sem_init" >&6; }
17964 ac_res=$ac_cv_search_sem_init
17965 if test "$ac_res" != no; then :
17966 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17967 USE_UNNAMED_POSIX_SEMAPHORES=1
17971 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which semaphore API to use" >&5
17972 $as_echo_n "checking which semaphore API to use... " >&6; }
17973 if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
17975 $as_echo "#define USE_NAMED_POSIX_SEMAPHORES 1" >>confdefs.h
17977 SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
17978 sematype="named POSIX"
17980 if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
17982 $as_echo "#define USE_UNNAMED_POSIX_SEMAPHORES 1" >>confdefs.h
17984 SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
17985 sematype="unnamed POSIX"
17988 $as_echo "#define USE_SYSV_SEMAPHORES 1" >>confdefs.h
17990 SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
17991 sematype="System V"
17994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $sematype" >&5
17995 $as_echo "$sematype" >&6; }
17998 $as_echo "#define USE_WIN32_SEMAPHORES 1" >>confdefs.h
18000 SEMA_IMPLEMENTATION="src/backend/port/win32_sema.c"
18004 # Select shared-memory implementation type.
18005 if test "$PORTNAME" != "win32"; then
18007 $as_echo "#define USE_SYSV_SHARED_MEMORY 1" >>confdefs.h
18009 SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
18012 $as_echo "#define USE_WIN32_SHARED_MEMORY 1" >>confdefs.h
18014 SHMEM_IMPLEMENTATION="src/backend/port/win32_shmem.c"
18017 # Select random number source
18019 # You can override this logic by setting the appropriate USE_*RANDOM flag to 1
18020 # in the template or configure command line.
18022 # If not selected manually, try to select a source automatically.
18023 if test x"$USE_OPENSSL_RANDOM" = x"" && test x"$USE_WIN32_RANDOM" = x"" && test x"$USE_DEV_URANDOM" = x"" ; then
18024 if test x"$with_openssl" = x"yes" ; then
18025 USE_OPENSSL_RANDOM=1
18026 elif test "$PORTNAME" = "win32" ; then
18029 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/urandom" >&5
18030 $as_echo_n "checking for /dev/urandom... " >&6; }
18031 if ${ac_cv_file__dev_urandom+:} false; then :
18032 $as_echo_n "(cached) " >&6
18034 test "$cross_compiling" = yes &&
18035 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
18036 if test -r "/dev/urandom"; then
18037 ac_cv_file__dev_urandom=yes
18039 ac_cv_file__dev_urandom=no
18042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__dev_urandom" >&5
18043 $as_echo "$ac_cv_file__dev_urandom" >&6; }
18044 if test "x$ac_cv_file__dev_urandom" = xyes; then :
18049 if test x"$ac_cv_file__dev_urandom" = x"yes" ; then
18055 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which random number source to use" >&5
18056 $as_echo_n "checking which random number source to use... " >&6; }
18057 if test x"$USE_OPENSSL_RANDOM" = x"1" ; then
18059 $as_echo "#define USE_OPENSSL_RANDOM 1" >>confdefs.h
18061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: OpenSSL" >&5
18062 $as_echo "OpenSSL" >&6; }
18063 elif test x"$USE_WIN32_RANDOM" = x"1" ; then
18065 $as_echo "#define USE_WIN32_RANDOM 1" >>confdefs.h
18067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Windows native" >&5
18068 $as_echo "Windows native" >&6; }
18069 elif test x"$USE_DEV_URANDOM" = x"1" ; then
18071 $as_echo "#define USE_DEV_URANDOM 1" >>confdefs.h
18073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: /dev/urandom" >&5
18074 $as_echo "/dev/urandom" >&6; }
18077 no source of strong random numbers was found
18078 PostgreSQL can use OpenSSL or /dev/urandom as a source of random numbers." "$LINENO" 5
18081 # If not set in template file, set bytes to use libc memset()
18082 if test x"$MEMSET_LOOP_LIMIT" = x"" ; then
18083 MEMSET_LOOP_LIMIT=1024
18086 cat >>confdefs.h <<_ACEOF
18087 #define MEMSET_LOOP_LIMIT ${MEMSET_LOOP_LIMIT}
18092 if test "$enable_nls" = yes ; then
18094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing bind_textdomain_codeset" >&5
18095 $as_echo_n "checking for library containing bind_textdomain_codeset... " >&6; }
18096 if ${ac_cv_search_bind_textdomain_codeset+:} false; then :
18097 $as_echo_n "(cached) " >&6
18099 ac_func_search_save_LIBS=$LIBS
18100 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18101 /* end confdefs.h. */
18103 /* Override any GCC internal prototype to avoid an error.
18104 Use char because int might match the return type of a GCC
18105 builtin and then its argument prototype would still apply. */
18109 char bind_textdomain_codeset ();
18113 return bind_textdomain_codeset ();
18118 for ac_lib in '' intl; do
18119 if test -z "$ac_lib"; then
18120 ac_res="none required"
18123 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
18125 if ac_fn_c_try_link "$LINENO"; then :
18126 ac_cv_search_bind_textdomain_codeset=$ac_res
18128 rm -f core conftest.err conftest.$ac_objext \
18130 if ${ac_cv_search_bind_textdomain_codeset+:} false; then :
18134 if ${ac_cv_search_bind_textdomain_codeset+:} false; then :
18137 ac_cv_search_bind_textdomain_codeset=no
18139 rm conftest.$ac_ext
18140 LIBS=$ac_func_search_save_LIBS
18142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_bind_textdomain_codeset" >&5
18143 $as_echo "$ac_cv_search_bind_textdomain_codeset" >&6; }
18144 ac_res=$ac_cv_search_bind_textdomain_codeset
18145 if test "$ac_res" != no; then :
18146 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
18149 as_fn_error $? "a gettext implementation is required for NLS" "$LINENO" 5
18152 ac_fn_c_check_header_mongrel "$LINENO" "libintl.h" "ac_cv_header_libintl_h" "$ac_includes_default"
18153 if test "x$ac_cv_header_libintl_h" = xyes; then :
18156 as_fn_error $? "header file <libintl.h> is required for NLS" "$LINENO" 5
18160 if test -z "$MSGFMT"; then
18161 for ac_prog in msgfmt
18163 # Extract the first word of "$ac_prog", so it can be a program name with args.
18164 set dummy $ac_prog; ac_word=$2
18165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18166 $as_echo_n "checking for $ac_word... " >&6; }
18167 if ${ac_cv_path_MSGFMT+:} false; then :
18168 $as_echo_n "(cached) " >&6
18172 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
18175 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18176 for as_dir in $PATH
18179 test -z "$as_dir" && as_dir=.
18180 for ac_exec_ext in '' $ac_executable_extensions; do
18181 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18182 ac_cv_path_MSGFMT="$as_dir/$ac_word$ac_exec_ext"
18183 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18193 MSGFMT=$ac_cv_path_MSGFMT
18194 if test -n "$MSGFMT"; then
18195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
18196 $as_echo "$MSGFMT" >&6; }
18198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18199 $as_echo "no" >&6; }
18203 test -n "$MSGFMT" && break
18207 # Report the value of MSGFMT in configure's output in all cases.
18208 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MSGFMT" >&5
18209 $as_echo_n "checking for MSGFMT... " >&6; }
18210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
18211 $as_echo "$MSGFMT" >&6; }
18214 if test -z "$MSGFMT"; then
18215 as_fn_error $? "msgfmt is required for NLS" "$LINENO" 5
18217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msgfmt flags" >&5
18218 $as_echo_n "checking for msgfmt flags... " >&6; }
18219 if ${pgac_cv_msgfmt_flags+:} false; then :
18220 $as_echo_n "(cached) " >&6
18222 if test x"$MSGFMT" != x"" && "$MSGFMT" --version 2>&1 | grep "GNU" >/dev/null; then
18223 pgac_cv_msgfmt_flags=-c
18226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_msgfmt_flags" >&5
18227 $as_echo "$pgac_cv_msgfmt_flags" >&6; }
18228 MSGFMT_FLAGS=$pgac_cv_msgfmt_flags
18230 if test -z "$MSGMERGE"; then
18231 for ac_prog in msgmerge
18233 # Extract the first word of "$ac_prog", so it can be a program name with args.
18234 set dummy $ac_prog; ac_word=$2
18235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18236 $as_echo_n "checking for $ac_word... " >&6; }
18237 if ${ac_cv_path_MSGMERGE+:} false; then :
18238 $as_echo_n "(cached) " >&6
18242 ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
18245 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18246 for as_dir in $PATH
18249 test -z "$as_dir" && as_dir=.
18250 for ac_exec_ext in '' $ac_executable_extensions; do
18251 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18252 ac_cv_path_MSGMERGE="$as_dir/$ac_word$ac_exec_ext"
18253 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18263 MSGMERGE=$ac_cv_path_MSGMERGE
18264 if test -n "$MSGMERGE"; then
18265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
18266 $as_echo "$MSGMERGE" >&6; }
18268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18269 $as_echo "no" >&6; }
18273 test -n "$MSGMERGE" && break
18277 # Report the value of MSGMERGE in configure's output in all cases.
18278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MSGMERGE" >&5
18279 $as_echo_n "checking for MSGMERGE... " >&6; }
18280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
18281 $as_echo "$MSGMERGE" >&6; }
18284 if test -z "$XGETTEXT"; then
18285 for ac_prog in xgettext
18287 # Extract the first word of "$ac_prog", so it can be a program name with args.
18288 set dummy $ac_prog; ac_word=$2
18289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18290 $as_echo_n "checking for $ac_word... " >&6; }
18291 if ${ac_cv_path_XGETTEXT+:} false; then :
18292 $as_echo_n "(cached) " >&6
18296 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
18299 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18300 for as_dir in $PATH
18303 test -z "$as_dir" && as_dir=.
18304 for ac_exec_ext in '' $ac_executable_extensions; do
18305 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18306 ac_cv_path_XGETTEXT="$as_dir/$ac_word$ac_exec_ext"
18307 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18317 XGETTEXT=$ac_cv_path_XGETTEXT
18318 if test -n "$XGETTEXT"; then
18319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
18320 $as_echo "$XGETTEXT" >&6; }
18322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18323 $as_echo "no" >&6; }
18327 test -n "$XGETTEXT" && break
18331 # Report the value of XGETTEXT in configure's output in all cases.
18332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XGETTEXT" >&5
18333 $as_echo_n "checking for XGETTEXT... " >&6; }
18334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
18335 $as_echo "$XGETTEXT" >&6; }
18341 # Check for Tcl configuration script tclConfig.sh
18342 if test "$with_tcl" = yes; then
18343 if test -z "$TCLSH"; then
18344 for ac_prog in tclsh tcl tclsh8.6 tclsh86 tclsh8.5 tclsh85 tclsh8.4 tclsh84
18346 # Extract the first word of "$ac_prog", so it can be a program name with args.
18347 set dummy $ac_prog; ac_word=$2
18348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18349 $as_echo_n "checking for $ac_word... " >&6; }
18350 if ${ac_cv_path_TCLSH+:} false; then :
18351 $as_echo_n "(cached) " >&6
18355 ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
18358 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18359 for as_dir in $PATH
18362 test -z "$as_dir" && as_dir=.
18363 for ac_exec_ext in '' $ac_executable_extensions; do
18364 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18365 ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
18366 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18376 TCLSH=$ac_cv_path_TCLSH
18377 if test -n "$TCLSH"; then
18378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TCLSH" >&5
18379 $as_echo "$TCLSH" >&6; }
18381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18382 $as_echo "no" >&6; }
18386 test -n "$TCLSH" && break
18390 # Report the value of TCLSH in configure's output in all cases.
18391 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TCLSH" >&5
18392 $as_echo_n "checking for TCLSH... " >&6; }
18393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TCLSH" >&5
18394 $as_echo "$TCLSH" >&6; }
18397 if test x"$TCLSH" = x""; then
18398 as_fn_error $? "Tcl shell not found" "$LINENO" 5
18401 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tclConfig.sh" >&5
18402 $as_echo_n "checking for tclConfig.sh... " >&6; }
18403 # Let user override test
18404 if test -z "$TCL_CONFIG_SH"; then
18405 pgac_test_dirs="$with_tclconfig"
18407 set X $pgac_test_dirs; shift
18408 if test $# -eq 0; then
18409 test -z "$TCLSH" && as_fn_error $? "unable to locate tclConfig.sh because no Tcl shell was found" "$LINENO" 5
18410 pgac_test_dirs=`echo 'puts $auto_path' | $TCLSH`
18411 # On newer macOS, $auto_path frequently doesn't include the place
18412 # where tclConfig.sh actually lives. Append that to the end, so as not
18413 # to break cases where a non-default Tcl installation is being used.
18414 if test -d "$PG_SYSROOT/System/Library/Frameworks/Tcl.framework" ; then
18415 pgac_test_dirs="$pgac_test_dirs $PG_SYSROOT/System/Library/Frameworks/Tcl.framework"
18417 set X $pgac_test_dirs; shift
18421 if test -r "$pgac_dir/tclConfig.sh"; then
18422 TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
18428 if test -z "$TCL_CONFIG_SH"; then
18429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18430 $as_echo "no" >&6; }
18431 as_fn_error $? "file 'tclConfig.sh' is required for Tcl" "$LINENO" 5
18433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TCL_CONFIG_SH" >&5
18434 $as_echo "$TCL_CONFIG_SH" >&6; }
18440 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
18441 eval TCL_LIBS=\"$TCL_LIBS\"
18442 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
18443 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
18445 if test "$TCL_SHARED_BUILD" != 1; then
18446 as_fn_error $? "cannot build PL/Tcl because Tcl is not a shared library
18447 Use --without-tcl to disable building PL/Tcl." "$LINENO" 5
18449 # now that we have TCL_INCLUDE_SPEC, we can check for <tcl.h>
18450 ac_save_CPPFLAGS=$CPPFLAGS
18451 CPPFLAGS="$TCL_INCLUDE_SPEC $CPPFLAGS"
18452 ac_fn_c_check_header_mongrel "$LINENO" "tcl.h" "ac_cv_header_tcl_h" "$ac_includes_default"
18453 if test "x$ac_cv_header_tcl_h" = xyes; then :
18456 as_fn_error $? "header file <tcl.h> is required for Tcl" "$LINENO" 5
18460 CPPFLAGS=$ac_save_CPPFLAGS
18463 # check for <perl.h>
18464 if test "$with_perl" = yes; then
18465 ac_save_CPPFLAGS=$CPPFLAGS
18466 CPPFLAGS="$CPPFLAGS $perl_includespec"
18467 ac_fn_c_check_header_compile "$LINENO" "perl.h" "ac_cv_header_perl_h" "#include <EXTERN.h>
18469 if test "x$ac_cv_header_perl_h" = xyes; then :
18472 as_fn_error $? "header file <perl.h> is required for Perl" "$LINENO" 5
18476 # While we're at it, check that we can link to libperl.
18477 # On most platforms, if perl.h is there then libperl.so will be too, but at
18478 # this writing Debian packages them separately. There is no known reason to
18479 # waste cycles on separate probes for the Tcl or Python libraries, though.
18480 pgac_save_LIBS=$LIBS
18481 LIBS="$perl_embed_ldflags"
18482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libperl" >&5
18483 $as_echo_n "checking for libperl... " >&6; }
18484 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18485 /* end confdefs.h. */
18487 #include <EXTERN.h>
18498 if ac_fn_c_try_link "$LINENO"; then :
18499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18500 $as_echo "yes" >&6; }
18502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18503 $as_echo "no" >&6; }
18504 as_fn_error $? "libperl library is required for Perl" "$LINENO" 5
18506 rm -f core conftest.err conftest.$ac_objext \
18507 conftest$ac_exeext conftest.$ac_ext
18508 LIBS=$pgac_save_LIBS
18509 CPPFLAGS=$ac_save_CPPFLAGS
18512 # check for <Python.h>
18513 if test "$with_python" = yes; then
18514 ac_save_CPPFLAGS=$CPPFLAGS
18515 CPPFLAGS="$python_includespec $CPPFLAGS"
18516 ac_fn_c_check_header_mongrel "$LINENO" "Python.h" "ac_cv_header_Python_h" "$ac_includes_default"
18517 if test "x$ac_cv_header_Python_h" = xyes; then :
18520 as_fn_error $? "header file <Python.h> is required for Python" "$LINENO" 5
18524 CPPFLAGS=$ac_save_CPPFLAGS
18528 # Check for DocBook and tools
18530 if test -z "$XMLLINT"; then
18531 for ac_prog in xmllint
18533 # Extract the first word of "$ac_prog", so it can be a program name with args.
18534 set dummy $ac_prog; ac_word=$2
18535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18536 $as_echo_n "checking for $ac_word... " >&6; }
18537 if ${ac_cv_path_XMLLINT+:} false; then :
18538 $as_echo_n "(cached) " >&6
18542 ac_cv_path_XMLLINT="$XMLLINT" # Let the user override the test with a path.
18545 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18546 for as_dir in $PATH
18549 test -z "$as_dir" && as_dir=.
18550 for ac_exec_ext in '' $ac_executable_extensions; do
18551 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18552 ac_cv_path_XMLLINT="$as_dir/$ac_word$ac_exec_ext"
18553 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18563 XMLLINT=$ac_cv_path_XMLLINT
18564 if test -n "$XMLLINT"; then
18565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XMLLINT" >&5
18566 $as_echo "$XMLLINT" >&6; }
18568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18569 $as_echo "no" >&6; }
18573 test -n "$XMLLINT" && break
18577 # Report the value of XMLLINT in configure's output in all cases.
18578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XMLLINT" >&5
18579 $as_echo_n "checking for XMLLINT... " >&6; }
18580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XMLLINT" >&5
18581 $as_echo "$XMLLINT" >&6; }
18585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DocBook XML V4.2" >&5
18586 $as_echo_n "checking for DocBook XML V4.2... " >&6; }
18587 if ${pgac_cv_check_docbook+:} false; then :
18588 $as_echo_n "(cached) " >&6
18590 cat >conftest.xml <<EOF
18591 <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
18593 <title>test</title>
18595 <title>random</title>
18597 <title>testsect</title>
18604 pgac_cv_check_docbook=no
18606 if test -n "$XMLLINT"; then
18607 $XMLLINT --noout --valid conftest.xml 1>&5 2>&1
18608 if test $? -eq 0; then
18609 pgac_cv_check_docbook=yes
18614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_check_docbook" >&5
18615 $as_echo "$pgac_cv_check_docbook" >&6; }
18617 have_docbook=$pgac_cv_check_docbook
18620 if test -z "$DBTOEPUB"; then
18621 for ac_prog in dbtoepub
18623 # Extract the first word of "$ac_prog", so it can be a program name with args.
18624 set dummy $ac_prog; ac_word=$2
18625 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18626 $as_echo_n "checking for $ac_word... " >&6; }
18627 if ${ac_cv_path_DBTOEPUB+:} false; then :
18628 $as_echo_n "(cached) " >&6
18632 ac_cv_path_DBTOEPUB="$DBTOEPUB" # Let the user override the test with a path.
18635 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18636 for as_dir in $PATH
18639 test -z "$as_dir" && as_dir=.
18640 for ac_exec_ext in '' $ac_executable_extensions; do
18641 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18642 ac_cv_path_DBTOEPUB="$as_dir/$ac_word$ac_exec_ext"
18643 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18653 DBTOEPUB=$ac_cv_path_DBTOEPUB
18654 if test -n "$DBTOEPUB"; then
18655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBTOEPUB" >&5
18656 $as_echo "$DBTOEPUB" >&6; }
18658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18659 $as_echo "no" >&6; }
18663 test -n "$DBTOEPUB" && break
18667 # Report the value of DBTOEPUB in configure's output in all cases.
18668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DBTOEPUB" >&5
18669 $as_echo_n "checking for DBTOEPUB... " >&6; }
18670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBTOEPUB" >&5
18671 $as_echo "$DBTOEPUB" >&6; }
18674 if test -z "$XSLTPROC"; then
18675 for ac_prog in xsltproc
18677 # Extract the first word of "$ac_prog", so it can be a program name with args.
18678 set dummy $ac_prog; ac_word=$2
18679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18680 $as_echo_n "checking for $ac_word... " >&6; }
18681 if ${ac_cv_path_XSLTPROC+:} false; then :
18682 $as_echo_n "(cached) " >&6
18686 ac_cv_path_XSLTPROC="$XSLTPROC" # Let the user override the test with a path.
18689 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18690 for as_dir in $PATH
18693 test -z "$as_dir" && as_dir=.
18694 for ac_exec_ext in '' $ac_executable_extensions; do
18695 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18696 ac_cv_path_XSLTPROC="$as_dir/$ac_word$ac_exec_ext"
18697 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18707 XSLTPROC=$ac_cv_path_XSLTPROC
18708 if test -n "$XSLTPROC"; then
18709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XSLTPROC" >&5
18710 $as_echo "$XSLTPROC" >&6; }
18712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18713 $as_echo "no" >&6; }
18717 test -n "$XSLTPROC" && break
18721 # Report the value of XSLTPROC in configure's output in all cases.
18722 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XSLTPROC" >&5
18723 $as_echo_n "checking for XSLTPROC... " >&6; }
18724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XSLTPROC" >&5
18725 $as_echo "$XSLTPROC" >&6; }
18728 if test -z "$FOP"; then
18731 # Extract the first word of "$ac_prog", so it can be a program name with args.
18732 set dummy $ac_prog; ac_word=$2
18733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18734 $as_echo_n "checking for $ac_word... " >&6; }
18735 if ${ac_cv_path_FOP+:} false; then :
18736 $as_echo_n "(cached) " >&6
18740 ac_cv_path_FOP="$FOP" # Let the user override the test with a path.
18743 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18744 for as_dir in $PATH
18747 test -z "$as_dir" && as_dir=.
18748 for ac_exec_ext in '' $ac_executable_extensions; do
18749 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18750 ac_cv_path_FOP="$as_dir/$ac_word$ac_exec_ext"
18751 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18761 FOP=$ac_cv_path_FOP
18762 if test -n "$FOP"; then
18763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FOP" >&5
18764 $as_echo "$FOP" >&6; }
18766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18767 $as_echo "no" >&6; }
18771 test -n "$FOP" && break
18775 # Report the value of FOP in configure's output in all cases.
18776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FOP" >&5
18777 $as_echo_n "checking for FOP... " >&6; }
18778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FOP" >&5
18779 $as_echo "$FOP" >&6; }
18784 # Check for test tools
18786 if test "$enable_tap_tests" = yes; then
18787 # Check for necessary modules, unless user has specified the "prove" to use;
18788 # in that case it's her responsibility to have a working configuration.
18789 # (prove might be part of a different Perl installation than perl, eg on
18790 # MSys, so the result of AX_PROG_PERL_MODULES could be irrelevant anyway.)
18791 if test -z "$PROVE"; then
18792 # Test::More and Time::HiRes are supposed to be part of core Perl,
18793 # but some distros omit them in a minimal installation.
18804 # Make sure we have perl
18805 if test -z "$PERL"; then
18806 # Extract the first word of "perl", so it can be a program name with args.
18807 set dummy perl; ac_word=$2
18808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18809 $as_echo_n "checking for $ac_word... " >&6; }
18810 if ${ac_cv_prog_PERL+:} false; then :
18811 $as_echo_n "(cached) " >&6
18813 if test -n "$PERL"; then
18814 ac_cv_prog_PERL="$PERL" # Let the user override the test.
18816 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18817 for as_dir in $PATH
18820 test -z "$as_dir" && as_dir=.
18821 for ac_exec_ext in '' $ac_executable_extensions; do
18822 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18823 ac_cv_prog_PERL="perl"
18824 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18833 PERL=$ac_cv_prog_PERL
18834 if test -n "$PERL"; then
18835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5
18836 $as_echo "$PERL" >&6; }
18838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18839 $as_echo "no" >&6; }
18845 if test "x$PERL" != x; then
18846 ax_perl_modules_failed=0
18847 for ax_perl_module in 'IPC::Run' 'Test::More 0.87' 'Time::HiRes' ; do
18848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perl module $ax_perl_module" >&5
18849 $as_echo_n "checking for perl module $ax_perl_module... " >&6; }
18851 # Would be nice to log result here, but can't rely on autoconf internals
18852 $PERL -e "use $ax_perl_module; exit" > /dev/null 2>&1
18853 if test $? -ne 0; then
18854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18855 $as_echo "no" >&6; };
18856 ax_perl_modules_failed=1
18858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
18859 $as_echo "ok" >&6; };
18863 # Run optional shell commands
18864 if test "$ax_perl_modules_failed" = 0; then
18869 as_fn_error $? "Additional Perl modules are required to run TAP tests" "$LINENO" 5
18872 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: could not find perl" >&5
18873 $as_echo "$as_me: WARNING: could not find perl" >&2;}
18876 # Now make sure we know where prove is
18877 if test -z "$PROVE"; then
18878 for ac_prog in prove
18880 # Extract the first word of "$ac_prog", so it can be a program name with args.
18881 set dummy $ac_prog; ac_word=$2
18882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18883 $as_echo_n "checking for $ac_word... " >&6; }
18884 if ${ac_cv_path_PROVE+:} false; then :
18885 $as_echo_n "(cached) " >&6
18889 ac_cv_path_PROVE="$PROVE" # Let the user override the test with a path.
18892 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18893 for as_dir in $PATH
18896 test -z "$as_dir" && as_dir=.
18897 for ac_exec_ext in '' $ac_executable_extensions; do
18898 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18899 ac_cv_path_PROVE="$as_dir/$ac_word$ac_exec_ext"
18900 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18910 PROVE=$ac_cv_path_PROVE
18911 if test -n "$PROVE"; then
18912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROVE" >&5
18913 $as_echo "$PROVE" >&6; }
18915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18916 $as_echo "no" >&6; }
18920 test -n "$PROVE" && break
18924 # Report the value of PROVE in configure's output in all cases.
18925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PROVE" >&5
18926 $as_echo_n "checking for PROVE... " >&6; }
18927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROVE" >&5
18928 $as_echo "$PROVE" >&6; }
18931 if test -z "$PROVE"; then
18932 as_fn_error $? "prove not found" "$LINENO" 5
18938 # We have to run the thread test near the end so we have all our symbols
18939 # defined. Cross compiling throws a warning.
18941 if test "$enable_thread_safety" = yes; then
18942 if test "$PORTNAME" != "win32"
18944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking thread safety of required library functions" >&5
18945 $as_echo_n "checking thread safety of required library functions... " >&6; }
18949 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
18950 LIBS="$LIBS $PTHREAD_LIBS"
18951 if test "$cross_compiling" = yes; then :
18952 { $as_echo "$as_me:${as_lineno-$LINENO}: result: maybe" >&5
18953 $as_echo "maybe" >&6; }
18954 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
18955 *** Skipping thread test program because of cross-compile build.
18956 *** Run the program in src/test/thread on the target machine.
18958 $as_echo "$as_me: WARNING:
18959 *** Skipping thread test program because of cross-compile build.
18960 *** Run the program in src/test/thread on the target machine.
18963 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18964 /* end confdefs.h. */
18965 #include "$srcdir/src/test/thread/thread_test.c"
18967 if ac_fn_c_try_run "$LINENO"; then :
18968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18969 $as_echo "yes" >&6; }
18971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18972 $as_echo "no" >&6; }
18973 as_fn_error $? "thread test program failed
18974 This platform is not thread-safe. Check the file 'config.log' or compile
18975 and run src/test/thread/thread_test for the exact reason.
18976 Use --disable-thread-safety to disable thread safety." "$LINENO" 5
18978 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18979 conftest.$ac_objext conftest.beam conftest.$ac_ext
18985 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** skipping thread test on Win32" >&5
18986 $as_echo "$as_me: WARNING: *** skipping thread test on Win32" >&2;}
18990 # If compiler will take -Wl,--as-needed (or various platform-specific
18991 # spellings thereof) then add that to LDFLAGS. This is much easier than
18992 # trying to filter LIBS to the minimum for each executable.
18993 # On (at least) some Red-Hat-derived systems, this switch breaks linking to
18994 # libreadline; therefore we postpone testing it until we know what library
18995 # dependencies readline has. The test code will try to link with $LIBS.
18996 if test "$with_readline" = yes; then
18997 link_test_func=readline
18999 link_test_func=exit
19002 if test "$PORTNAME" = "darwin"; then
19003 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wl,-dead_strip_dylibs" >&5
19004 $as_echo_n "checking whether $CC supports -Wl,-dead_strip_dylibs... " >&6; }
19005 if ${pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs+:} false; then :
19006 $as_echo_n "(cached) " >&6
19008 pgac_save_LDFLAGS=$LDFLAGS
19009 LDFLAGS="$pgac_save_LDFLAGS -Wl,-dead_strip_dylibs"
19010 if test "$cross_compiling" = yes; then :
19011 pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs="assuming no"
19013 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19014 /* end confdefs.h. */
19015 extern void $link_test_func (); void (*fptr) () = $link_test_func;
19024 if ac_fn_c_try_run "$LINENO"; then :
19025 pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs=yes
19027 pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs=no
19029 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19030 conftest.$ac_objext conftest.beam conftest.$ac_ext
19033 LDFLAGS="$pgac_save_LDFLAGS"
19035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" >&5
19036 $as_echo "$pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" >&6; }
19037 if test x"$pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" = x"yes"; then
19038 LDFLAGS="$LDFLAGS -Wl,-dead_strip_dylibs"
19041 elif test "$PORTNAME" = "openbsd"; then
19042 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wl,-Bdynamic" >&5
19043 $as_echo_n "checking whether $CC supports -Wl,-Bdynamic... " >&6; }
19044 if ${pgac_cv_prog_cc_ldflags__Wl__Bdynamic+:} false; then :
19045 $as_echo_n "(cached) " >&6
19047 pgac_save_LDFLAGS=$LDFLAGS
19048 LDFLAGS="$pgac_save_LDFLAGS -Wl,-Bdynamic"
19049 if test "$cross_compiling" = yes; then :
19050 pgac_cv_prog_cc_ldflags__Wl__Bdynamic="assuming no"
19052 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19053 /* end confdefs.h. */
19054 extern void $link_test_func (); void (*fptr) () = $link_test_func;
19063 if ac_fn_c_try_run "$LINENO"; then :
19064 pgac_cv_prog_cc_ldflags__Wl__Bdynamic=yes
19066 pgac_cv_prog_cc_ldflags__Wl__Bdynamic=no
19068 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19069 conftest.$ac_objext conftest.beam conftest.$ac_ext
19072 LDFLAGS="$pgac_save_LDFLAGS"
19074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_cc_ldflags__Wl__Bdynamic" >&5
19075 $as_echo "$pgac_cv_prog_cc_ldflags__Wl__Bdynamic" >&6; }
19076 if test x"$pgac_cv_prog_cc_ldflags__Wl__Bdynamic" = x"yes"; then
19077 LDFLAGS="$LDFLAGS -Wl,-Bdynamic"
19081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wl,--as-needed" >&5
19082 $as_echo_n "checking whether $CC supports -Wl,--as-needed... " >&6; }
19083 if ${pgac_cv_prog_cc_ldflags__Wl___as_needed+:} false; then :
19084 $as_echo_n "(cached) " >&6
19086 pgac_save_LDFLAGS=$LDFLAGS
19087 LDFLAGS="$pgac_save_LDFLAGS -Wl,--as-needed"
19088 if test "$cross_compiling" = yes; then :
19089 pgac_cv_prog_cc_ldflags__Wl___as_needed="assuming no"
19091 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19092 /* end confdefs.h. */
19093 extern void $link_test_func (); void (*fptr) () = $link_test_func;
19102 if ac_fn_c_try_run "$LINENO"; then :
19103 pgac_cv_prog_cc_ldflags__Wl___as_needed=yes
19105 pgac_cv_prog_cc_ldflags__Wl___as_needed=no
19107 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19108 conftest.$ac_objext conftest.beam conftest.$ac_ext
19111 LDFLAGS="$pgac_save_LDFLAGS"
19113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_cc_ldflags__Wl___as_needed" >&5
19114 $as_echo "$pgac_cv_prog_cc_ldflags__Wl___as_needed" >&6; }
19115 if test x"$pgac_cv_prog_cc_ldflags__Wl___as_needed" = x"yes"; then
19116 LDFLAGS="$LDFLAGS -Wl,--as-needed"
19121 # Create compiler version string
19122 if test x"$GCC" = x"yes" ; then
19123 cc_string=`${CC} --version | sed q`
19124 case $cc_string in [A-Za-z]*) ;; *) cc_string="GCC $cc_string";; esac
19125 elif test x"$SUN_STUDIO_CC" = x"yes" ; then
19126 cc_string=`${CC} -V 2>&1 | sed q`
19132 cat >>confdefs.h <<_ACEOF
19133 #define PG_VERSION_STR "PostgreSQL $PG_VERSION on $host, compiled by $cc_string, `expr $ac_cv_sizeof_void_p \* 8`-bit"
19137 # Supply a numeric version string for use by 3rd party add-ons
19138 # awk -F is a regex on some platforms, and not on others, so make "." a tab
19139 PG_VERSION_NUM="`echo "$PACKAGE_VERSION" | sed 's/[A-Za-z].*$//' |
19141 $AWK '{printf "%d%04d", $1, $2}'`"
19143 cat >>confdefs.h <<_ACEOF
19144 #define PG_VERSION_NUM $PG_VERSION_NUM
19149 # If we are inserting PG_SYSROOT into CPPFLAGS, do so symbolically not
19150 # literally, so that it's possible to override it at build time using
19151 # a command like "make ... PG_SYSROOT=path". This has to be done after
19152 # we've finished all configure checks that depend on CPPFLAGS.
19153 if test x"$PG_SYSROOT" != x; then
19154 CPPFLAGS=`echo "$CPPFLAGS" | sed -e "s| $PG_SYSROOT | \\\$(PG_SYSROOT) |"`
19159 # Begin output steps
19161 { $as_echo "$as_me:${as_lineno-$LINENO}: using compiler=$cc_string" >&5
19162 $as_echo "$as_me: using compiler=$cc_string" >&6;}
19163 { $as_echo "$as_me:${as_lineno-$LINENO}: using CFLAGS=$CFLAGS" >&5
19164 $as_echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
19165 { $as_echo "$as_me:${as_lineno-$LINENO}: using CPPFLAGS=$CPPFLAGS" >&5
19166 $as_echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
19167 { $as_echo "$as_me:${as_lineno-$LINENO}: using LDFLAGS=$LDFLAGS" >&5
19168 $as_echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
19169 # Currently only used when LLVM is used
19170 if test "$with_llvm" = yes ; then
19171 { $as_echo "$as_me:${as_lineno-$LINENO}: using CXX=$CXX" >&5
19172 $as_echo "$as_me: using CXX=$CXX" >&6;}
19173 { $as_echo "$as_me:${as_lineno-$LINENO}: using CXXFLAGS=$CXXFLAGS" >&5
19174 $as_echo "$as_me: using CXXFLAGS=$CXXFLAGS" >&6;}
19175 { $as_echo "$as_me:${as_lineno-$LINENO}: using CLANG=$CLANG" >&5
19176 $as_echo "$as_me: using CLANG=$CLANG" >&6;}
19177 { $as_echo "$as_me:${as_lineno-$LINENO}: using BITCODE_CFLAGS=$BITCODE_CFLAGS" >&5
19178 $as_echo "$as_me: using BITCODE_CFLAGS=$BITCODE_CFLAGS" >&6;}
19179 { $as_echo "$as_me:${as_lineno-$LINENO}: using BITCODE_CXXFLAGS=$BITCODE_CXXFLAGS" >&5
19180 $as_echo "$as_me: using BITCODE_CXXFLAGS=$BITCODE_CXXFLAGS" >&6;}
19183 # prepare build tree if outside source tree
19184 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
19185 # Note 2: /bin/pwd might be better than shell's built-in at getting
19186 # a symlink-free name.
19187 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
19191 if test "$no_create" != yes; then
19192 $as_echo_n "preparing build tree... " >&6
19193 pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
19194 $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
19195 || as_fn_error $? "failed" "$LINENO" 5
19196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
19197 $as_echo "done" >&6; }
19203 ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
19206 ac_config_links="$ac_config_links src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION} src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION} src/include/pg_config_os.h:src/include/port/${template}.h src/Makefile.port:src/makefiles/Makefile.${template}"
19209 if test "$PORTNAME" = "win32"; then
19210 ac_config_commands="$ac_config_commands check_win32_symlinks"
19214 ac_config_headers="$ac_config_headers src/include/pg_config.h"
19217 ac_config_headers="$ac_config_headers src/include/pg_config_ext.h"
19220 ac_config_headers="$ac_config_headers src/interfaces/ecpg/include/ecpg_config.h"
19223 cat >confcache <<\_ACEOF
19224 # This file is a shell script that caches the results of configure
19225 # tests run on this system so they can be shared between configure
19226 # scripts and configure runs, see configure's option --config-cache.
19227 # It is not useful on other systems. If it contains results you don't
19228 # want to keep, you may remove or edit it.
19230 # config.status only pays attention to the cache file if you give it
19231 # the --recheck option to rerun configure.
19233 # `ac_cv_env_foo' variables (set or unset) will be overridden when
19234 # loading this file, other *unset* `ac_cv_foo' will be assigned the
19235 # following values.
19239 # The following way of writing the cache mishandles newlines in values,
19240 # but we know of no workaround that is simple, portable, and efficient.
19241 # So, we kill variables containing newlines.
19242 # Ultrix sh set writes to stderr and can't be redirected directly,
19243 # and sets the high bit in the cache file unless we assign to the vars.
19245 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
19246 eval ac_val=\$$ac_var
19250 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
19251 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
19254 _ | IFS | as_nl) ;; #(
19255 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
19256 *) { eval $ac_var=; unset $ac_var;} ;;
19262 case $as_nl`(ac_space=' '; set) 2>&1` in #(
19263 *${as_nl}ac_space=\ *)
19264 # `set' does not quote correctly, so add quotes: double-quote
19265 # substitution turns \\\\ into \\, and sed turns \\ into \.
19268 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
19271 # `set' quotes correctly as required by POSIX, so do not add quotes.
19272 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
19281 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
19283 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
19285 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
19286 if test -w "$cache_file"; then
19287 if test "x$cache_file" != "x/dev/null"; then
19288 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
19289 $as_echo "$as_me: updating cache $cache_file" >&6;}
19290 if test ! -f "$cache_file" || test -h "$cache_file"; then
19291 cat confcache >"$cache_file"
19293 case $cache_file in #(
19295 mv -f confcache "$cache_file"$$ &&
19296 mv -f "$cache_file"$$ "$cache_file" ;; #(
19298 mv -f confcache "$cache_file" ;;
19303 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
19304 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
19309 test "x$prefix" = xNONE && prefix=$ac_default_prefix
19310 # Let make expand exec_prefix.
19311 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
19313 DEFS=-DHAVE_CONFIG_H
19318 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
19319 # 1. Remove the extension, and $U if already installed.
19320 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
19321 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
19322 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
19323 # will be set to the directory where LIBOBJS objects are built.
19324 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
19325 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
19327 LIBOBJS=$ac_libobjs
19329 LTLIBOBJS=$ac_ltlibobjs
19334 : "${CONFIG_STATUS=./config.status}"
19336 ac_clean_files_save=$ac_clean_files
19337 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
19338 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
19339 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
19341 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
19343 # Generated by $as_me.
19344 # Run this file to recreate the current configuration.
19345 # Compiler output produced by configure, useful for debugging
19346 # configure, is in config.log if it exists.
19349 ac_cs_recheck=false
19352 SHELL=\${CONFIG_SHELL-$SHELL}
19355 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
19356 ## -------------------- ##
19357 ## M4sh Initialization. ##
19358 ## -------------------- ##
19360 # Be more Bourne compatible
19361 DUALCASE=1; export DUALCASE # for MKS sh
19362 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
19365 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
19366 # is contrary to our usage. Disable this feature.
19367 alias -g '${1+"$@"}'='"$@"'
19368 setopt NO_GLOB_SUBST
19370 case `(set -o) 2>/dev/null` in #(
19382 # Printing a long string crashes Solaris 7 /usr/bin/printf.
19383 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
19384 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
19385 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
19386 # Prefer a ksh shell builtin over an external printf program on Solaris,
19387 # but without wasting forks for bash or zsh.
19388 if test -z "$BASH_VERSION$ZSH_VERSION" \
19389 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
19390 as_echo='print -r --'
19391 as_echo_n='print -rn --'
19392 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
19393 as_echo='printf %s\n'
19394 as_echo_n='printf %s'
19396 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
19397 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
19398 as_echo_n='/usr/ucb/echo -n'
19400 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
19401 as_echo_n_body='eval
19405 expr "X$arg" : "X\\(.*\\)$as_nl";
19406 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
19408 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
19410 export as_echo_n_body
19411 as_echo_n='sh -c $as_echo_n_body as_echo'
19413 export as_echo_body
19414 as_echo='sh -c $as_echo_body as_echo'
19417 # The user is always right.
19418 if test "${PATH_SEPARATOR+set}" != set; then
19420 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
19421 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
19428 # We need space, tab and new line, in precisely that order. Quoting is
19429 # there to prevent editors from complaining about space-tab.
19430 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
19431 # splitting by setting IFS to empty value.)
19434 # Find who we are. Look in the path if we contain no directory separator.
19437 *[\\/]* ) as_myself=$0 ;;
19438 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19439 for as_dir in $PATH
19442 test -z "$as_dir" && as_dir=.
19443 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
19449 # We did not find ourselves, most probably we were run as `sh COMMAND'
19450 # in which case we are not to be found in the path.
19451 if test "x$as_myself" = x; then
19454 if test ! -f "$as_myself"; then
19455 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
19459 # Unset variables that we do not need and which cause bugs (e.g. in
19460 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
19461 # suppresses any "Segmentation fault" message there. '((' could
19462 # trigger a bug in pdksh 5.2.14.
19463 for as_var in BASH_ENV ENV MAIL MAILPATH
19464 do eval test x\${$as_var+set} = xset \
19465 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
19478 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
19481 # as_fn_error STATUS ERROR [LINENO LOG_FD]
19482 # ----------------------------------------
19483 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
19484 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
19485 # script with STATUS, using 1 if that was 0.
19488 as_status=$1; test $as_status -eq 0 && as_status=1
19490 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
19491 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
19493 $as_echo "$as_me: error: $2" >&2
19494 as_fn_exit $as_status
19498 # as_fn_set_status STATUS
19499 # -----------------------
19500 # Set $? to STATUS, without forking.
19501 as_fn_set_status ()
19504 } # as_fn_set_status
19506 # as_fn_exit STATUS
19507 # -----------------
19508 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
19512 as_fn_set_status $1
19518 # Portably unset VAR.
19521 { eval $1=; unset $1;}
19523 as_unset=as_fn_unset
19524 # as_fn_append VAR VALUE
19525 # ----------------------
19526 # Append the text in VALUE to the end of the definition contained in VAR. Take
19527 # advantage of any shell optimizations that allow amortized linear growth over
19528 # repeated appends, instead of the typical quadratic growth present in naive
19530 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
19531 eval 'as_fn_append ()
19542 # as_fn_arith ARG...
19543 # ------------------
19544 # Perform arithmetic evaluation on the ARGs, and store the result in the
19545 # global $as_val. Take advantage of shells that can avoid forks. The arguments
19546 # must be portable across $(()) and expr.
19547 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
19548 eval 'as_fn_arith ()
19555 as_val=`expr "$@" || test $? -eq 1`
19560 if expr a : '\(a\)' >/dev/null 2>&1 &&
19561 test "X`expr 00001 : '.*\(...\)'`" = X001; then
19567 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
19568 as_basename=basename
19573 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
19579 as_me=`$as_basename -- "$0" ||
19580 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
19581 X"$0" : 'X\(//\)$' \| \
19582 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
19584 sed '/^.*\/\([^/][^/]*\)\/*$/{
19598 # Avoid depending upon Character Ranges.
19599 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
19600 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
19601 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
19602 as_cr_digits='0123456789'
19603 as_cr_alnum=$as_cr_Letters$as_cr_digits
19605 ECHO_C= ECHO_N= ECHO_T=
19606 case `echo -n x` in #(((((
19608 case `echo 'xy\c'` in
19609 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
19611 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
19618 rm -f conf$$ conf$$.exe conf$$.file
19619 if test -d conf$$.dir; then
19620 rm -f conf$$.dir/conf$$.file
19623 mkdir conf$$.dir 2>/dev/null
19625 if (echo >conf$$.file) 2>/dev/null; then
19626 if ln -s conf$$.file conf$$ 2>/dev/null; then
19628 # ... but there are two gotchas:
19629 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
19630 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
19631 # In both cases, we have to default to `cp -pR'.
19632 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
19634 elif ln conf$$.file conf$$ 2>/dev/null; then
19642 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
19643 rmdir conf$$.dir 2>/dev/null
19648 # Create "$as_dir" as a directory, including parents if necessary.
19653 -*) as_dir=./$as_dir;;
19655 test -d "$as_dir" || eval $as_mkdir_p || {
19659 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
19660 *) as_qdir=$as_dir;;
19662 as_dirs="'$as_qdir' $as_dirs"
19663 as_dir=`$as_dirname -- "$as_dir" ||
19664 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19665 X"$as_dir" : 'X\(//\)[^/]' \| \
19666 X"$as_dir" : 'X\(//\)$' \| \
19667 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
19668 $as_echo X"$as_dir" |
19669 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
19673 /^X\(\/\/\)[^/].*/{
19686 test -d "$as_dir" && break
19688 test -z "$as_dirs" || eval "mkdir $as_dirs"
19689 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
19693 if mkdir -p . 2>/dev/null; then
19694 as_mkdir_p='mkdir -p "$as_dir"'
19696 test -d ./-p && rmdir ./-p
19701 # as_fn_executable_p FILE
19702 # -----------------------
19703 # Test if FILE is an executable regular file.
19704 as_fn_executable_p ()
19706 test -f "$1" && test -x "$1"
19707 } # as_fn_executable_p
19708 as_test_x='test -x'
19709 as_executable_p=as_fn_executable_p
19711 # Sed expression to map a string onto a valid CPP name.
19712 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
19714 # Sed expression to map a string onto a valid variable name.
19715 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
19719 ## ----------------------------------- ##
19720 ## Main body of $CONFIG_STATUS script. ##
19721 ## ----------------------------------- ##
19723 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
19725 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19726 # Save the log message, to keep $0 and so on meaningful, and to
19727 # report actual input values of CONFIG_FILES etc. instead of their
19728 # values after options handling.
19730 This file was extended by PostgreSQL $as_me 12devel, which was
19731 generated by GNU Autoconf 2.69. Invocation command line was
19733 CONFIG_FILES = $CONFIG_FILES
19734 CONFIG_HEADERS = $CONFIG_HEADERS
19735 CONFIG_LINKS = $CONFIG_LINKS
19736 CONFIG_COMMANDS = $CONFIG_COMMANDS
19739 on `(hostname || uname -n) 2>/dev/null | sed 1q`
19744 case $ac_config_files in *"
19745 "*) set x $ac_config_files; shift; ac_config_files=$*;;
19748 case $ac_config_headers in *"
19749 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
19753 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19754 # Files that config.status was made for.
19755 config_files="$ac_config_files"
19756 config_headers="$ac_config_headers"
19757 config_links="$ac_config_links"
19758 config_commands="$ac_config_commands"
19762 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19764 \`$as_me' instantiates files and other configuration actions
19765 from templates according to the current configuration. Unless the files
19766 and actions are specified as TAGs, all are instantiated by default.
19768 Usage: $0 [OPTION]... [TAG]...
19770 -h, --help print this help, then exit
19771 -V, --version print version number and configuration settings, then exit
19772 --config print configuration, then exit
19773 -q, --quiet, --silent
19774 do not print progress messages
19775 -d, --debug don't remove temporary files
19776 --recheck update $as_me by reconfiguring in the same conditions
19777 --file=FILE[:TEMPLATE]
19778 instantiate the configuration file FILE
19779 --header=FILE[:TEMPLATE]
19780 instantiate the configuration header FILE
19782 Configuration files:
19785 Configuration headers:
19788 Configuration links:
19791 Configuration commands:
19794 Report bugs to <pgsql-bugs@lists.postgresql.org>."
19797 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19798 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
19800 PostgreSQL config.status 12devel
19801 configured by $0, generated by GNU Autoconf 2.69,
19802 with options \\"\$ac_cs_config\\"
19804 Copyright (C) 2012 Free Software Foundation, Inc.
19805 This config.status script is free software; the Free Software Foundation
19806 gives unlimited permission to copy, distribute and modify it."
19813 test -n "\$AWK" || AWK=awk
19816 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19817 # The default lists apply if the user does not specify any file.
19823 ac_option=`expr "X$1" : 'X\([^=]*\)='`
19824 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
19828 ac_option=`expr "X$1" : 'X\([^=]*\)='`
19840 # Handling of the options.
19841 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
19843 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
19844 $as_echo "$ac_cs_version"; exit ;;
19845 --config | --confi | --conf | --con | --co | --c )
19846 $as_echo "$ac_cs_config"; exit ;;
19847 --debug | --debu | --deb | --de | --d | -d )
19849 --file | --fil | --fi | --f )
19852 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
19853 '') as_fn_error $? "missing file argument" ;;
19855 as_fn_append CONFIG_FILES " '$ac_optarg'"
19856 ac_need_defaults=false;;
19857 --header | --heade | --head | --hea )
19860 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
19862 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
19863 ac_need_defaults=false;;
19865 # Conflict between --help and --header
19866 as_fn_error $? "ambiguous option: \`$1'
19867 Try \`$0 --help' for more information.";;
19868 --help | --hel | -h )
19869 $as_echo "$ac_cs_usage"; exit ;;
19870 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
19871 | -silent | --silent | --silen | --sile | --sil | --si | --s)
19874 # This is an error.
19875 -*) as_fn_error $? "unrecognized option: \`$1'
19876 Try \`$0 --help' for more information." ;;
19878 *) as_fn_append ac_config_targets " $1"
19879 ac_need_defaults=false ;;
19885 ac_configure_extra_args=
19887 if $ac_cs_silent; then
19889 ac_configure_extra_args="$ac_configure_extra_args --silent"
19893 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19894 if \$ac_cs_recheck; then
19895 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
19897 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
19898 CONFIG_SHELL='$SHELL'
19899 export CONFIG_SHELL
19904 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19908 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
19909 ## Running $as_me. ##
19915 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19918 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19920 # Handling of arguments.
19921 for ac_config_target in $ac_config_targets
19923 case $ac_config_target in
19924 "src/backend/port/tas.s") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
19925 "GNUmakefile") CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
19926 "src/Makefile.global") CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
19927 "src/backend/port/pg_sema.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
19928 "src/backend/port/pg_shmem.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
19929 "src/include/pg_config_os.h") CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
19930 "src/Makefile.port") CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
19931 "check_win32_symlinks") CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
19932 "src/include/pg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
19933 "src/include/pg_config_ext.h") CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config_ext.h" ;;
19934 "src/interfaces/ecpg/include/ecpg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/interfaces/ecpg/include/ecpg_config.h" ;;
19936 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
19941 # If the user did not use the arguments to specify the items to instantiate,
19942 # then the envvar interface is used. Set only those that are not.
19943 # We use the long form for the default assignment because of an extremely
19944 # bizarre bug on SunOS 4.1.3.
19945 if $ac_need_defaults; then
19946 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
19947 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
19948 test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
19949 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
19952 # Have a temporary directory for convenience. Make it in the build tree
19953 # simply because there is no reason against having it here, and in addition,
19954 # creating and moving files from /tmp can sometimes cause problems.
19955 # Hook for its removal unless debugging.
19956 # Note that there is a small window in which the directory will not be cleaned:
19957 # after its creation but before its name has been assigned to `$tmp'.
19961 trap 'exit_status=$?
19962 : "${ac_tmp:=$tmp}"
19963 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
19965 trap 'as_fn_exit 1' 1 2 13 15
19967 # Create a (secure) tmp directory for tmp files.
19970 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
19974 tmp=./conf$$-$RANDOM
19975 (umask 077 && mkdir "$tmp")
19976 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
19979 # Set up the scripts for CONFIG_FILES section.
19980 # No need to generate them if there are no CONFIG_FILES.
19981 # This happens for instance with `./config.status config.h'.
19982 if test -n "$CONFIG_FILES"; then
19985 ac_cr=`echo X | tr X '\015'`
19986 # On cygwin, bash can eat \r inside `` if the user requested igncr.
19987 # But we know of no other shell where ac_cr would be empty at this
19988 # point, so we can use a bashism as a fallback.
19989 if test "x$ac_cr" = x; then
19990 eval ac_cr=\$\'\\r\'
19992 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
19993 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
19996 ac_cs_awk_cr=$ac_cr
19999 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
20004 echo "cat >conf$$subs.awk <<_ACEOF" &&
20005 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
20007 } >conf$$subs.sh ||
20008 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
20009 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
20011 for ac_last_try in false false false false false :; do
20012 . ./conf$$subs.sh ||
20013 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
20015 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
20016 if test $ac_delim_n = $ac_delim_num; then
20018 elif $ac_last_try; then
20019 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
20021 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
20024 rm -f conf$$subs.sh
20026 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20027 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
20031 s/^/S["/; s/!.*/"]=/
20041 s/\(.\{148\}\)..*/\1/
20043 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
20048 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
20055 s/\(.\{148\}\)..*/\1/
20057 s/["\\]/\\&/g; s/^/"/; s/$/"/
20061 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
20066 ' <conf$$subs.awk | sed '
20071 ' >>$CONFIG_STATUS || ac_write_fail=1
20072 rm -f conf$$subs.awk
20073 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20075 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
20076 for (key in S) S_is_set[key] = 1
20082 nfields = split(line, field, "@")
20084 len = length(field[1])
20085 for (i = 2; i < nfields; i++) {
20087 keylen = length(key)
20088 if (S_is_set[key]) {
20090 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
20091 len += length(value) + length(field[++i])
20102 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20103 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
20104 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
20107 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
20108 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
20111 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
20112 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
20113 # trailing colons and then remove the whole line if VPATH becomes empty
20114 # (actually we leave an empty line to preserve line numbers).
20115 if test "x$srcdir" = x.; then
20116 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
20134 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20135 fi # test -n "$CONFIG_FILES"
20137 # Set up the scripts for CONFIG_HEADERS section.
20138 # No need to generate them if there are no CONFIG_HEADERS.
20139 # This happens for instance with `./config.status Makefile'.
20140 if test -n "$CONFIG_HEADERS"; then
20141 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
20145 # Transform confdefs.h into an awk script `defines.awk', embedded as
20146 # here-document in config.status, that substitutes the proper values into
20147 # config.h.in to produce config.h.
20149 # Create a delimiter string that does not exist in confdefs.h, to ease
20150 # handling of long lines.
20152 for ac_last_try in false false :; do
20153 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
20154 if test -z "$ac_tt"; then
20156 elif $ac_last_try; then
20157 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
20159 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
20163 # For the awk script, D is an array of macro values keyed by name,
20164 # likewise P contains macro parameters if any. Preserve backslash
20165 # newline sequences.
20167 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
20169 s/.\{148\}/&'"$ac_delim"'/g
20172 s/^[ ]*#[ ]*define[ ][ ]*/ /
20179 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
20181 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
20185 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
20186 D["\1"]=" \3\\\\\\n"\\/p
20188 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
20193 s/.\{148\}/&'"$ac_delim"'/g
20198 s/["\\]/\\&/g; s/^/"/; s/$/"/p
20201 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
20203 ' <confdefs.h | sed '
20204 s/'"$ac_delim"'/"\\\
20205 "/g' >>$CONFIG_STATUS || ac_write_fail=1
20207 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20208 for (key in D) D_is_set[key] = 1
20211 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
20213 split(line, arg, " ")
20214 if (arg[1] == "#") {
20218 defundef = substr(arg[1], 2)
20221 split(mac1, mac2, "(") #)
20223 prefix = substr(line, 1, index(line, defundef) - 1)
20224 if (D_is_set[macro]) {
20225 # Preserve the white space surrounding the "#".
20226 print prefix "define", macro P[macro] D[macro]
20229 # Replace #undef with comments. This is necessary, for example,
20230 # in the case of _POSIX_SOURCE, which is predefined and required
20231 # on some systems where configure will not decide to define it.
20232 if (defundef == "undef") {
20233 print "/*", prefix defundef, macro, "*/"
20241 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20242 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
20243 fi # test -n "$CONFIG_HEADERS"
20246 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :L $CONFIG_LINKS :C $CONFIG_COMMANDS"
20251 :[FHLC]) ac_mode=$ac_tag; continue;;
20253 case $ac_mode$ac_tag in
20255 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
20256 :[FH]-) ac_tag=-:-;;
20257 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
20274 -) ac_f="$ac_tmp/stdin";;
20275 *) # Look for the file first in the build tree, then in the source tree
20276 # (if the path is not absolute). The absolute path cannot be DOS-style,
20277 # because $ac_f cannot contain `:'.
20281 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
20283 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
20285 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
20286 as_fn_append ac_file_inputs " '$ac_f'"
20289 # Let's still pretend it is `configure' which instantiates (i.e., don't
20290 # use $as_me), people would be surprised to read:
20291 # /* config.h. Generated by config.status. */
20292 configure_input='Generated from '`
20293 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
20295 if test x"$ac_file" != x-; then
20296 configure_input="$ac_file. $configure_input"
20297 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
20298 $as_echo "$as_me: creating $ac_file" >&6;}
20300 # Neutralize special characters interpreted by sed in replacement strings.
20301 case $configure_input in #(
20302 *\&* | *\|* | *\\* )
20303 ac_sed_conf_input=`$as_echo "$configure_input" |
20304 sed 's/[\\\\&|]/\\\\&/g'`;; #(
20305 *) ac_sed_conf_input=$configure_input;;
20309 *:-:* | *:-) cat >"$ac_tmp/stdin" \
20310 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
20315 ac_dir=`$as_dirname -- "$ac_file" ||
20316 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20317 X"$ac_file" : 'X\(//\)[^/]' \| \
20318 X"$ac_file" : 'X\(//\)$' \| \
20319 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
20320 $as_echo X"$ac_file" |
20321 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
20325 /^X\(\/\/\)[^/].*/{
20338 as_dir="$ac_dir"; as_fn_mkdir_p
20342 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
20344 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
20345 # A ".." for each directory in $ac_dir_suffix.
20346 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
20347 case $ac_top_builddir_sub in
20348 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
20349 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
20352 ac_abs_top_builddir=$ac_pwd
20353 ac_abs_builddir=$ac_pwd$ac_dir_suffix
20354 # for backward compatibility:
20355 ac_top_builddir=$ac_top_build_prefix
20358 .) # We are building in place.
20360 ac_top_srcdir=$ac_top_builddir_sub
20361 ac_abs_top_srcdir=$ac_pwd ;;
20362 [\\/]* | ?:[\\/]* ) # Absolute name.
20363 ac_srcdir=$srcdir$ac_dir_suffix;
20364 ac_top_srcdir=$srcdir
20365 ac_abs_top_srcdir=$srcdir ;;
20366 *) # Relative name.
20367 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
20368 ac_top_srcdir=$ac_top_build_prefix$srcdir
20369 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
20371 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
20381 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
20382 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
20384 ac_MKDIR_P=$MKDIR_P
20386 [\\/$]* | ?:[\\/]* ) ;;
20387 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
20391 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20392 # If the template does not know about datarootdir, expand it.
20393 # FIXME: This hack should be removed a few years after 2.60.
20394 ac_datarootdir_hack=; ac_datarootdir_seen=
20405 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
20406 *datarootdir*) ac_datarootdir_seen=yes;;
20407 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
20408 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
20409 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
20411 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20412 ac_datarootdir_hack='
20413 s&@datadir@&$datadir&g
20414 s&@docdir@&$docdir&g
20415 s&@infodir@&$infodir&g
20416 s&@localedir@&$localedir&g
20417 s&@mandir@&$mandir&g
20418 s&\\\${datarootdir}&$datarootdir&g' ;;
20422 # Neutralize VPATH when `$srcdir' = `.'.
20423 # Shell code in configure.ac might set extrasub.
20424 # FIXME: do we really want to maintain this feature?
20425 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20426 ac_sed_extra="$ac_vpsub
20429 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20431 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
20432 s|@configure_input@|$ac_sed_conf_input|;t t
20433 s&@top_builddir@&$ac_top_builddir_sub&;t t
20434 s&@top_build_prefix@&$ac_top_build_prefix&;t t
20435 s&@srcdir@&$ac_srcdir&;t t
20436 s&@abs_srcdir@&$ac_abs_srcdir&;t t
20437 s&@top_srcdir@&$ac_top_srcdir&;t t
20438 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
20439 s&@builddir@&$ac_builddir&;t t
20440 s&@abs_builddir@&$ac_abs_builddir&;t t
20441 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
20442 s&@INSTALL@&$ac_INSTALL&;t t
20443 s&@MKDIR_P@&$ac_MKDIR_P&;t t
20444 $ac_datarootdir_hack
20446 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
20447 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
20449 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
20450 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
20451 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
20452 "$ac_tmp/out"`; test -z "$ac_out"; } &&
20453 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
20454 which seems to be undefined. Please make sure it is defined" >&5
20455 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
20456 which seems to be undefined. Please make sure it is defined" >&2;}
20458 rm -f "$ac_tmp/stdin"
20460 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
20461 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
20463 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
20469 if test x"$ac_file" != x-; then
20471 $as_echo "/* $configure_input */" \
20472 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
20473 } >"$ac_tmp/config.h" \
20474 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
20475 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
20476 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
20477 $as_echo "$as_me: $ac_file is unchanged" >&6;}
20480 mv "$ac_tmp/config.h" "$ac_file" \
20481 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
20484 $as_echo "/* $configure_input */" \
20485 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
20486 || as_fn_error $? "could not create -" "$LINENO" 5
20494 if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
20497 # Prefer the file from the source tree if names are identical.
20498 if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
20499 ac_source=$srcdir/$ac_source
20502 { $as_echo "$as_me:${as_lineno-$LINENO}: linking $ac_source to $ac_file" >&5
20503 $as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
20505 if test ! -r "$ac_source"; then
20506 as_fn_error $? "$ac_source: file not found" "$LINENO" 5
20510 # Try a relative symlink, then a hard link, then a copy.
20512 [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
20513 *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
20515 ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
20516 ln "$ac_source" "$ac_file" 2>/dev/null ||
20517 cp -p "$ac_source" "$ac_file" ||
20518 as_fn_error $? "cannot link or copy $ac_source to $ac_file" "$LINENO" 5
20521 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
20522 $as_echo "$as_me: executing $ac_file commands" >&6;}
20527 case $ac_file$ac_mode in
20528 "check_win32_symlinks":C)
20529 # Links sometimes fail undetected on Mingw -
20530 # so here we detect it and warn the user
20531 for FILE in $CONFIG_LINKS
20533 # test -e works for symlinks in the MinGW console
20534 test -e `expr "$FILE" : '\([^:]*\)'` || { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** link for $FILE -- please fix by hand" >&5
20535 $as_echo "$as_me: WARNING: *** link for $FILE -- please fix by hand" >&2;}
20538 "src/include/pg_config.h":H)
20539 # Update timestamp for pg_config.h (see Makefile.global)
20540 echo >src/include/stamp-h
20542 "src/include/pg_config_ext.h":H)
20543 # Update timestamp for pg_config_ext.h (see Makefile.global)
20544 echo >src/include/stamp-ext-h
20546 "src/interfaces/ecpg/include/ecpg_config.h":H) echo >src/interfaces/ecpg/include/stamp-h ;;
20554 ac_clean_files=$ac_clean_files_save
20556 test $ac_write_fail = 0 ||
20557 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
20560 # configure is writing to config.log, and then calls config.status.
20561 # config.status does its own redirection, appending to config.log.
20562 # Unfortunately, on DOS this fails, as config.log is still kept open
20563 # by configure, so config.status won't be able to write to it; its
20564 # output is simply discarded. So we exec the FD to /dev/null,
20565 # effectively closing config.log, so it can be properly (re)opened and
20566 # appended to by config.status. When coming back to configure, we
20567 # need to make the FD available again.
20568 if test "$no_create" != yes; then
20570 ac_config_status_args=
20571 test "$silent" = yes &&
20572 ac_config_status_args="$ac_config_status_args --quiet"
20574 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
20576 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
20577 # would make configure fail if this is the last instruction.
20578 $ac_cs_success || as_fn_exit 1
20580 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
20581 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
20582 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}