2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.69 for PostgreSQL 11.5.
5 # Report bugs to <pgsql-bugs@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-2018, 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@postgresql.org about your system, including
273 $0: any error possibly output before this message. Then
274 $0: install a modern shell, or manually run the script
275 $0: 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='11.5'
586 PACKAGE_STRING='PostgreSQL 11.5'
587 PACKAGE_BUGREPORT='pgsql-bugs@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
663 python_additional_libs
807 program_transform_name
820 enable_option_checking
826 enable_integer_datetimes
861 with_libedit_preferred
873 ac_precious_vars='build_alias
896 # Initialize some variables set by options.
898 ac_init_version=false
899 ac_unrecognized_opts=
901 # The variables have the same names as the options, with
902 # dashes changed to underlines.
910 program_transform_name=s,x,x,
918 # Installation directory options.
919 # These are left unexpanded so users can "make install exec_prefix=/foo"
920 # and all the variables that are supposed to be based on exec_prefix
921 # by default will actually change.
922 # Use braces instead of parens because sh, perl, etc. also accept them.
923 # (The list follows the same order as the GNU Coding Standards.)
924 bindir='${exec_prefix}/bin'
925 sbindir='${exec_prefix}/sbin'
926 libexecdir='${exec_prefix}/libexec'
927 datarootdir='${prefix}/share'
928 datadir='${datarootdir}'
929 sysconfdir='${prefix}/etc'
930 sharedstatedir='${prefix}/com'
931 localstatedir='${prefix}/var'
932 includedir='${prefix}/include'
933 oldincludedir='/usr/include'
934 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
935 infodir='${datarootdir}/info'
940 libdir='${exec_prefix}/lib'
941 localedir='${datarootdir}/locale'
942 mandir='${datarootdir}/man'
948 # If the previous option needs an argument, assign it.
949 if test -n "$ac_prev"; then
950 eval $ac_prev=\$ac_option
956 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
961 # Accept the important Cygnus configure options, so we can diagnose typos.
963 case $ac_dashdash$ac_option in
967 -bindir | --bindir | --bindi | --bind | --bin | --bi)
969 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
972 -build | --build | --buil | --bui | --bu)
973 ac_prev=build_alias ;;
974 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
975 build_alias=$ac_optarg ;;
977 -cache-file | --cache-file | --cache-fil | --cache-fi \
978 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
979 ac_prev=cache_file ;;
980 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
981 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
982 cache_file=$ac_optarg ;;
985 cache_file=config.cache ;;
987 -datadir | --datadir | --datadi | --datad)
989 -datadir=* | --datadir=* | --datadi=* | --datad=*)
990 datadir=$ac_optarg ;;
992 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
993 | --dataroo | --dataro | --datar)
994 ac_prev=datarootdir ;;
995 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
996 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
997 datarootdir=$ac_optarg ;;
999 -disable-* | --disable-*)
1000 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1001 # Reject names that are not valid shell variable names.
1002 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1003 as_fn_error $? "invalid feature name: $ac_useropt"
1004 ac_useropt_orig=$ac_useropt
1005 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1006 case $ac_user_opts in
1008 "enable_$ac_useropt"
1010 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1011 ac_unrecognized_sep=', ';;
1013 eval enable_$ac_useropt=no ;;
1015 -docdir | --docdir | --docdi | --doc | --do)
1017 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1018 docdir=$ac_optarg ;;
1020 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1022 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1023 dvidir=$ac_optarg ;;
1025 -enable-* | --enable-*)
1026 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1027 # Reject names that are not valid shell variable names.
1028 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1029 as_fn_error $? "invalid feature name: $ac_useropt"
1030 ac_useropt_orig=$ac_useropt
1031 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1032 case $ac_user_opts in
1034 "enable_$ac_useropt"
1036 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1037 ac_unrecognized_sep=', ';;
1039 eval enable_$ac_useropt=\$ac_optarg ;;
1041 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1042 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1043 | --exec | --exe | --ex)
1044 ac_prev=exec_prefix ;;
1045 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1046 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1047 | --exec=* | --exe=* | --ex=*)
1048 exec_prefix=$ac_optarg ;;
1050 -gas | --gas | --ga | --g)
1051 # Obsolete; use --with-gas.
1054 -help | --help | --hel | --he | -h)
1055 ac_init_help=long ;;
1056 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1057 ac_init_help=recursive ;;
1058 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1059 ac_init_help=short ;;
1061 -host | --host | --hos | --ho)
1062 ac_prev=host_alias ;;
1063 -host=* | --host=* | --hos=* | --ho=*)
1064 host_alias=$ac_optarg ;;
1066 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1068 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1070 htmldir=$ac_optarg ;;
1072 -includedir | --includedir | --includedi | --included | --include \
1073 | --includ | --inclu | --incl | --inc)
1074 ac_prev=includedir ;;
1075 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1076 | --includ=* | --inclu=* | --incl=* | --inc=*)
1077 includedir=$ac_optarg ;;
1079 -infodir | --infodir | --infodi | --infod | --info | --inf)
1081 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1082 infodir=$ac_optarg ;;
1084 -libdir | --libdir | --libdi | --libd)
1086 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1087 libdir=$ac_optarg ;;
1089 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1090 | --libexe | --libex | --libe)
1091 ac_prev=libexecdir ;;
1092 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1093 | --libexe=* | --libex=* | --libe=*)
1094 libexecdir=$ac_optarg ;;
1096 -localedir | --localedir | --localedi | --localed | --locale)
1097 ac_prev=localedir ;;
1098 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1099 localedir=$ac_optarg ;;
1101 -localstatedir | --localstatedir | --localstatedi | --localstated \
1102 | --localstate | --localstat | --localsta | --localst | --locals)
1103 ac_prev=localstatedir ;;
1104 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1105 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1106 localstatedir=$ac_optarg ;;
1108 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1110 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1111 mandir=$ac_optarg ;;
1113 -nfp | --nfp | --nf)
1114 # Obsolete; use --without-fp.
1117 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1118 | --no-cr | --no-c | -n)
1121 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1122 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1125 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1126 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1127 | --oldin | --oldi | --old | --ol | --o)
1128 ac_prev=oldincludedir ;;
1129 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1130 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1131 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1132 oldincludedir=$ac_optarg ;;
1134 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1136 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1137 prefix=$ac_optarg ;;
1139 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1140 | --program-pre | --program-pr | --program-p)
1141 ac_prev=program_prefix ;;
1142 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1143 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1144 program_prefix=$ac_optarg ;;
1146 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1147 | --program-suf | --program-su | --program-s)
1148 ac_prev=program_suffix ;;
1149 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1150 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1151 program_suffix=$ac_optarg ;;
1153 -program-transform-name | --program-transform-name \
1154 | --program-transform-nam | --program-transform-na \
1155 | --program-transform-n | --program-transform- \
1156 | --program-transform | --program-transfor \
1157 | --program-transfo | --program-transf \
1158 | --program-trans | --program-tran \
1159 | --progr-tra | --program-tr | --program-t)
1160 ac_prev=program_transform_name ;;
1161 -program-transform-name=* | --program-transform-name=* \
1162 | --program-transform-nam=* | --program-transform-na=* \
1163 | --program-transform-n=* | --program-transform-=* \
1164 | --program-transform=* | --program-transfor=* \
1165 | --program-transfo=* | --program-transf=* \
1166 | --program-trans=* | --program-tran=* \
1167 | --progr-tra=* | --program-tr=* | --program-t=*)
1168 program_transform_name=$ac_optarg ;;
1170 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1172 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1173 pdfdir=$ac_optarg ;;
1175 -psdir | --psdir | --psdi | --psd | --ps)
1177 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1180 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1181 | -silent | --silent | --silen | --sile | --sil)
1184 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1186 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1188 sbindir=$ac_optarg ;;
1190 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1191 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1192 | --sharedst | --shareds | --shared | --share | --shar \
1194 ac_prev=sharedstatedir ;;
1195 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1196 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1197 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1199 sharedstatedir=$ac_optarg ;;
1201 -site | --site | --sit)
1203 -site=* | --site=* | --sit=*)
1206 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1208 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1209 srcdir=$ac_optarg ;;
1211 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1212 | --syscon | --sysco | --sysc | --sys | --sy)
1213 ac_prev=sysconfdir ;;
1214 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1215 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1216 sysconfdir=$ac_optarg ;;
1218 -target | --target | --targe | --targ | --tar | --ta | --t)
1219 ac_prev=target_alias ;;
1220 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1221 target_alias=$ac_optarg ;;
1223 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1226 -version | --version | --versio | --versi | --vers | -V)
1227 ac_init_version=: ;;
1230 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1231 # Reject names that are not valid shell variable names.
1232 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1233 as_fn_error $? "invalid package name: $ac_useropt"
1234 ac_useropt_orig=$ac_useropt
1235 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1236 case $ac_user_opts in
1240 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1241 ac_unrecognized_sep=', ';;
1243 eval with_$ac_useropt=\$ac_optarg ;;
1245 -without-* | --without-*)
1246 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1247 # Reject names that are not valid shell variable names.
1248 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1249 as_fn_error $? "invalid package name: $ac_useropt"
1250 ac_useropt_orig=$ac_useropt
1251 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1252 case $ac_user_opts in
1256 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1257 ac_unrecognized_sep=', ';;
1259 eval with_$ac_useropt=no ;;
1262 # Obsolete; use --with-x.
1265 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1266 | --x-incl | --x-inc | --x-in | --x-i)
1267 ac_prev=x_includes ;;
1268 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1269 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1270 x_includes=$ac_optarg ;;
1272 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1273 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1274 ac_prev=x_libraries ;;
1275 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1276 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1277 x_libraries=$ac_optarg ;;
1279 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1280 Try \`$0 --help' for more information"
1284 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1285 # Reject names that are not valid shell variable names.
1286 case $ac_envvar in #(
1287 '' | [0-9]* | *[!_$as_cr_alnum]* )
1288 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1290 eval $ac_envvar=\$ac_optarg
1291 export $ac_envvar ;;
1294 # FIXME: should be removed in autoconf 3.0.
1295 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1296 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1297 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1298 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1304 if test -n "$ac_prev"; then
1305 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1306 as_fn_error $? "missing argument to $ac_option"
1309 if test -n "$ac_unrecognized_opts"; then
1310 case $enable_option_checking in
1312 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1313 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1317 # Check all directory arguments for consistency.
1318 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1319 datadir sysconfdir sharedstatedir localstatedir includedir \
1320 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1321 libdir localedir mandir
1323 eval ac_val=\$$ac_var
1324 # Remove trailing slashes.
1327 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1328 eval $ac_var=\$ac_val;;
1330 # Be sure to have absolute directory names.
1332 [\\/$]* | ?:[\\/]* ) continue;;
1333 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1335 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1338 # There might be people who depend on the old broken behavior: `$host'
1339 # used to hold the argument of --host etc.
1340 # FIXME: To remove some day.
1343 target=$target_alias
1345 # FIXME: To remove some day.
1346 if test "x$host_alias" != x; then
1347 if test "x$build_alias" = x; then
1348 cross_compiling=maybe
1349 elif test "x$build_alias" != "x$host_alias"; then
1355 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1357 test "$silent" = yes && exec 6>/dev/null
1360 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1361 ac_ls_di=`ls -di .` &&
1362 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1363 as_fn_error $? "working directory cannot be determined"
1364 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1365 as_fn_error $? "pwd does not report name of working directory"
1368 # Find the source files, if location was not specified.
1369 if test -z "$srcdir"; then
1370 ac_srcdir_defaulted=yes
1371 # Try the directory containing this script, then the parent directory.
1372 ac_confdir=`$as_dirname -- "$as_myself" ||
1373 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1374 X"$as_myself" : 'X\(//\)[^/]' \| \
1375 X"$as_myself" : 'X\(//\)$' \| \
1376 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1377 $as_echo X"$as_myself" |
1378 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1396 if test ! -r "$srcdir/$ac_unique_file"; then
1400 ac_srcdir_defaulted=no
1402 if test ! -r "$srcdir/$ac_unique_file"; then
1403 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1404 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1406 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1408 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1410 # When building in place, set srcdir=.
1411 if test "$ac_abs_confdir" = "$ac_pwd"; then
1414 # Remove unnecessary trailing slashes from srcdir.
1415 # Double slashes in file names in object file debugging info
1416 # mess up M-x gdb in Emacs.
1418 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1420 for ac_var in $ac_precious_vars; do
1421 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1422 eval ac_env_${ac_var}_value=\$${ac_var}
1423 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1424 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1428 # Report the --help message.
1430 if test "$ac_init_help" = "long"; then
1431 # Omit some internal or obsolete options to make the list less imposing.
1432 # This message is too long to be a string in the A/UX 3.1 sh.
1434 \`configure' configures PostgreSQL 11.5 to adapt to many kinds of systems.
1436 Usage: $0 [OPTION]... [VAR=VALUE]...
1438 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1439 VAR=VALUE. See below for descriptions of some of the useful variables.
1441 Defaults for the options are specified in brackets.
1444 -h, --help display this help and exit
1445 --help=short display options specific to this package
1446 --help=recursive display the short help of all the included packages
1447 -V, --version display version information and exit
1448 -q, --quiet, --silent do not print \`checking ...' messages
1449 --cache-file=FILE cache test results in FILE [disabled]
1450 -C, --config-cache alias for \`--cache-file=config.cache'
1451 -n, --no-create do not create output files
1452 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1454 Installation directories:
1455 --prefix=PREFIX install architecture-independent files in PREFIX
1456 [$ac_default_prefix]
1457 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1460 By default, \`make install' will install all the files in
1461 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1462 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1463 for instance \`--prefix=\$HOME'.
1465 For better control, use the options below.
1467 Fine tuning of the installation directories:
1468 --bindir=DIR user executables [EPREFIX/bin]
1469 --sbindir=DIR system admin executables [EPREFIX/sbin]
1470 --libexecdir=DIR program executables [EPREFIX/libexec]
1471 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1472 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1473 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1474 --libdir=DIR object code libraries [EPREFIX/lib]
1475 --includedir=DIR C header files [PREFIX/include]
1476 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1477 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1478 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1479 --infodir=DIR info documentation [DATAROOTDIR/info]
1480 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1481 --mandir=DIR man documentation [DATAROOTDIR/man]
1482 --docdir=DIR documentation root [DATAROOTDIR/doc/postgresql]
1483 --htmldir=DIR html documentation [DOCDIR]
1484 --dvidir=DIR dvi documentation [DOCDIR]
1485 --pdfdir=DIR pdf documentation [DOCDIR]
1486 --psdir=DIR ps documentation [DOCDIR]
1492 --build=BUILD configure for building on BUILD [guessed]
1493 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1497 if test -n "$ac_init_help"; then
1498 case $ac_init_help in
1499 short | recursive ) echo "Configuration of PostgreSQL 11.5:";;
1504 --disable-option-checking ignore unrecognized --enable/--with options
1505 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1506 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1507 --disable-integer-datetimes
1508 obsolete option, no longer supported
1509 --enable-nls[=LANGUAGES]
1510 enable Native Language Support
1511 --disable-rpath do not embed shared library search path in
1513 --disable-spinlocks do not use spinlocks
1514 --disable-atomics do not use atomic operations
1515 --disable-strong-random do not use a strong random number source
1516 --enable-debug build with debugging symbols (-g)
1517 --enable-profiling build with profiling enabled
1518 --enable-coverage build with coverage testing instrumentation
1519 --enable-dtrace build with DTrace support
1520 --enable-tap-tests enable TAP tests (requires Perl and IPC::Run)
1521 --enable-depend turn on automatic dependency tracking
1522 --enable-cassert enable assertion checks (for debugging)
1523 --disable-thread-safety disable thread-safety in client libraries
1524 --disable-largefile omit support for large files
1525 --disable-float4-byval disable float4 passed by value
1526 --disable-float8-byval disable float8 passed by value
1529 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1530 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1531 --with-extra-version=STRING
1532 append STRING to version
1533 --with-template=NAME override operating system template
1534 --with-includes=DIRS look for additional header files in DIRS
1535 --with-libraries=DIRS look for additional libraries in DIRS
1536 --with-libs=DIRS alternative spelling of --with-libraries
1537 --with-pgport=PORTNUM set default port number [5432]
1538 --with-blocksize=BLOCKSIZE
1539 set table block size in kB [8]
1540 --with-segsize=SEGSIZE set table segment size in GB [1]
1541 --with-wal-blocksize=BLOCKSIZE
1542 set WAL block size in kB [8]
1543 --with-CC=CMD set compiler (deprecated)
1544 --with-llvm build with LLVM based JIT support
1545 --with-icu build with ICU support
1546 --with-tcl build Tcl modules (PL/Tcl)
1547 --with-tclconfig=DIR tclConfig.sh is in DIR
1548 --with-perl build Perl modules (PL/Perl)
1549 --with-python build Python modules (PL/Python)
1550 --with-gssapi build with GSSAPI support
1551 --with-krb-srvnam=NAME default service principal name in Kerberos (GSSAPI)
1553 --with-pam build with PAM support
1554 --with-bsd-auth build with BSD Authentication support
1555 --with-ldap build with LDAP support
1556 --with-bonjour build with Bonjour support
1557 --with-openssl build with OpenSSL support
1558 --with-selinux build with SELinux support
1559 --with-systemd build with systemd support
1560 --without-readline do not use GNU Readline nor BSD Libedit for editing
1561 --with-libedit-preferred
1562 prefer BSD Libedit over GNU Readline
1563 --with-uuid=LIB build contrib/uuid-ossp using LIB (bsd,e2fs,ossp)
1564 --with-ossp-uuid obsolete spelling of --with-uuid=ossp
1565 --with-libxml build with XML support
1566 --with-libxslt use XSLT support when building contrib/xml2
1567 --with-system-tzdata=DIR
1568 use system time zone data in DIR
1569 --without-zlib do not use Zlib
1570 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
1572 Some influential environment variables:
1573 CC C compiler command
1574 CFLAGS C compiler flags
1575 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1576 nonstandard directory <lib dir>
1577 LIBS libraries to pass to the linker, e.g. -l<library>
1578 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1579 you have headers in a nonstandard directory <include dir>
1580 CXX C++ compiler command
1581 CXXFLAGS C++ compiler flags
1582 LLVM_CONFIG path to llvm-config command
1583 CLANG path to clang compiler to generate bitcode
1585 PKG_CONFIG path to pkg-config utility
1587 directories to add to pkg-config's search path
1589 path overriding pkg-config's built-in search path
1590 ICU_CFLAGS C compiler flags for ICU, overriding pkg-config
1591 ICU_LIBS linker flags for ICU, overriding pkg-config
1592 LDFLAGS_EX extra linker flags for linking executables only
1593 LDFLAGS_SL extra linker flags for linking shared libraries only
1595 Use these variables to override the choices made by `configure' or to help
1596 it to find libraries and programs with nonstandard names/locations.
1598 Report bugs to <pgsql-bugs@postgresql.org>.
1603 if test "$ac_init_help" = "recursive"; then
1604 # If there are subdirs, report their specific --help.
1605 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1606 test -d "$ac_dir" ||
1607 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1612 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1614 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1615 # A ".." for each directory in $ac_dir_suffix.
1616 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1617 case $ac_top_builddir_sub in
1618 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1619 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1622 ac_abs_top_builddir=$ac_pwd
1623 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1624 # for backward compatibility:
1625 ac_top_builddir=$ac_top_build_prefix
1628 .) # We are building in place.
1630 ac_top_srcdir=$ac_top_builddir_sub
1631 ac_abs_top_srcdir=$ac_pwd ;;
1632 [\\/]* | ?:[\\/]* ) # Absolute name.
1633 ac_srcdir=$srcdir$ac_dir_suffix;
1634 ac_top_srcdir=$srcdir
1635 ac_abs_top_srcdir=$srcdir ;;
1637 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1638 ac_top_srcdir=$ac_top_build_prefix$srcdir
1639 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1641 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1643 cd "$ac_dir" || { ac_status=$?; continue; }
1644 # Check for guested configure.
1645 if test -f "$ac_srcdir/configure.gnu"; then
1647 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1648 elif test -f "$ac_srcdir/configure"; then
1650 $SHELL "$ac_srcdir/configure" --help=recursive
1652 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1654 cd "$ac_pwd" || { ac_status=$?; break; }
1658 test -n "$ac_init_help" && exit $ac_status
1659 if $ac_init_version; then
1661 PostgreSQL configure 11.5
1662 generated by GNU Autoconf 2.69
1664 Copyright (C) 2012 Free Software Foundation, Inc.
1665 This configure script is free software; the Free Software Foundation
1666 gives unlimited permission to copy, distribute and modify it.
1668 Copyright (c) 1996-2018, PostgreSQL Global Development Group
1673 ## ------------------------ ##
1674 ## Autoconf initialization. ##
1675 ## ------------------------ ##
1677 # ac_fn_c_try_compile LINENO
1678 # --------------------------
1679 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1680 ac_fn_c_try_compile ()
1682 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1683 rm -f conftest.$ac_objext
1684 if { { ac_try="$ac_compile"
1686 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1687 *) ac_try_echo=$ac_try;;
1689 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1690 $as_echo "$ac_try_echo"; } >&5
1691 (eval "$ac_compile") 2>conftest.err
1693 if test -s conftest.err; then
1694 grep -v '^ *+' conftest.err >conftest.er1
1695 cat conftest.er1 >&5
1696 mv -f conftest.er1 conftest.err
1698 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1699 test $ac_status = 0; } && {
1700 test -z "$ac_c_werror_flag" ||
1701 test ! -s conftest.err
1702 } && test -s conftest.$ac_objext; then :
1705 $as_echo "$as_me: failed program was:" >&5
1706 sed 's/^/| /' conftest.$ac_ext >&5
1710 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1711 as_fn_set_status $ac_retval
1713 } # ac_fn_c_try_compile
1715 # ac_fn_cxx_try_compile LINENO
1716 # ----------------------------
1717 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1718 ac_fn_cxx_try_compile ()
1720 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1721 rm -f conftest.$ac_objext
1722 if { { ac_try="$ac_compile"
1724 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1725 *) ac_try_echo=$ac_try;;
1727 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1728 $as_echo "$ac_try_echo"; } >&5
1729 (eval "$ac_compile") 2>conftest.err
1731 if test -s conftest.err; then
1732 grep -v '^ *+' conftest.err >conftest.er1
1733 cat conftest.er1 >&5
1734 mv -f conftest.er1 conftest.err
1736 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1737 test $ac_status = 0; } && {
1738 test -z "$ac_cxx_werror_flag" ||
1739 test ! -s conftest.err
1740 } && test -s conftest.$ac_objext; then :
1743 $as_echo "$as_me: failed program was:" >&5
1744 sed 's/^/| /' conftest.$ac_ext >&5
1748 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1749 as_fn_set_status $ac_retval
1751 } # ac_fn_cxx_try_compile
1753 # ac_fn_c_try_link LINENO
1754 # -----------------------
1755 # Try to link conftest.$ac_ext, and return whether this succeeded.
1758 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1759 rm -f conftest.$ac_objext conftest$ac_exeext
1760 if { { ac_try="$ac_link"
1762 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1763 *) ac_try_echo=$ac_try;;
1765 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1766 $as_echo "$ac_try_echo"; } >&5
1767 (eval "$ac_link") 2>conftest.err
1769 if test -s conftest.err; then
1770 grep -v '^ *+' conftest.err >conftest.er1
1771 cat conftest.er1 >&5
1772 mv -f conftest.er1 conftest.err
1774 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1775 test $ac_status = 0; } && {
1776 test -z "$ac_c_werror_flag" ||
1777 test ! -s conftest.err
1778 } && test -s conftest$ac_exeext && {
1779 test "$cross_compiling" = yes ||
1780 test -x conftest$ac_exeext
1784 $as_echo "$as_me: failed program was:" >&5
1785 sed 's/^/| /' conftest.$ac_ext >&5
1789 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1790 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1791 # interfere with the next link command; also delete a directory that is
1792 # left behind by Apple's compiler. We do this before executing the actions.
1793 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1794 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1795 as_fn_set_status $ac_retval
1797 } # ac_fn_c_try_link
1799 # ac_fn_c_try_cpp LINENO
1800 # ----------------------
1801 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1804 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1805 if { { ac_try="$ac_cpp conftest.$ac_ext"
1807 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1808 *) ac_try_echo=$ac_try;;
1810 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1811 $as_echo "$ac_try_echo"; } >&5
1812 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1814 if test -s conftest.err; then
1815 grep -v '^ *+' conftest.err >conftest.er1
1816 cat conftest.er1 >&5
1817 mv -f conftest.er1 conftest.err
1819 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1820 test $ac_status = 0; } > conftest.i && {
1821 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1822 test ! -s conftest.err
1826 $as_echo "$as_me: failed program was:" >&5
1827 sed 's/^/| /' conftest.$ac_ext >&5
1831 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1832 as_fn_set_status $ac_retval
1836 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1837 # -------------------------------------------------------
1838 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1839 # the include files in INCLUDES and setting the cache variable VAR
1841 ac_fn_c_check_header_mongrel ()
1843 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1844 if eval \${$3+:} false; then :
1845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1846 $as_echo_n "checking for $2... " >&6; }
1847 if eval \${$3+:} false; then :
1848 $as_echo_n "(cached) " >&6
1851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1852 $as_echo "$ac_res" >&6; }
1854 # Is the header compilable?
1855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1856 $as_echo_n "checking $2 usability... " >&6; }
1857 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1858 /* end confdefs.h. */
1862 if ac_fn_c_try_compile "$LINENO"; then :
1863 ac_header_compiler=yes
1865 ac_header_compiler=no
1867 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1869 $as_echo "$ac_header_compiler" >&6; }
1871 # Is the header present?
1872 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1873 $as_echo_n "checking $2 presence... " >&6; }
1874 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1875 /* end confdefs.h. */
1878 if ac_fn_c_try_cpp "$LINENO"; then :
1879 ac_header_preproc=yes
1881 ac_header_preproc=no
1883 rm -f conftest.err conftest.i conftest.$ac_ext
1884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1885 $as_echo "$ac_header_preproc" >&6; }
1887 # So? What about this header?
1888 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1890 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1891 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1892 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1893 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1896 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1897 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1898 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
1899 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
1900 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1901 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1902 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
1903 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
1904 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1905 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1906 ( $as_echo "## ---------------------------------------- ##
1907 ## Report this to pgsql-bugs@postgresql.org ##
1908 ## ---------------------------------------- ##"
1909 ) | sed "s/^/$as_me: WARNING: /" >&2
1912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1913 $as_echo_n "checking for $2... " >&6; }
1914 if eval \${$3+:} false; then :
1915 $as_echo_n "(cached) " >&6
1917 eval "$3=\$ac_header_compiler"
1920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1921 $as_echo "$ac_res" >&6; }
1923 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1925 } # ac_fn_c_check_header_mongrel
1927 # ac_fn_c_try_run LINENO
1928 # ----------------------
1929 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1930 # that executables *can* be run.
1933 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1934 if { { ac_try="$ac_link"
1936 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1937 *) ac_try_echo=$ac_try;;
1939 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1940 $as_echo "$ac_try_echo"; } >&5
1941 (eval "$ac_link") 2>&5
1943 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1944 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1945 { { case "(($ac_try" in
1946 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1947 *) ac_try_echo=$ac_try;;
1949 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1950 $as_echo "$ac_try_echo"; } >&5
1951 (eval "$ac_try") 2>&5
1953 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1954 test $ac_status = 0; }; }; then :
1957 $as_echo "$as_me: program exited with status $ac_status" >&5
1958 $as_echo "$as_me: failed program was:" >&5
1959 sed 's/^/| /' conftest.$ac_ext >&5
1961 ac_retval=$ac_status
1963 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1964 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1965 as_fn_set_status $ac_retval
1969 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1970 # -------------------------------------------------------
1971 # Tests whether HEADER exists and can be compiled using the include files in
1972 # INCLUDES, setting the cache variable VAR accordingly.
1973 ac_fn_c_check_header_compile ()
1975 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1976 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1977 $as_echo_n "checking for $2... " >&6; }
1978 if eval \${$3+:} false; then :
1979 $as_echo_n "(cached) " >&6
1981 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1982 /* end confdefs.h. */
1986 if ac_fn_c_try_compile "$LINENO"; then :
1991 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1995 $as_echo "$ac_res" >&6; }
1996 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1998 } # ac_fn_c_check_header_compile
2000 # ac_fn_c_check_func LINENO FUNC VAR
2001 # ----------------------------------
2002 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2003 ac_fn_c_check_func ()
2005 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2007 $as_echo_n "checking for $2... " >&6; }
2008 if eval \${$3+:} false; then :
2009 $as_echo_n "(cached) " >&6
2011 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2012 /* end confdefs.h. */
2013 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2014 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2015 #define $2 innocuous_$2
2017 /* System header to define __stub macros and hopefully few prototypes,
2018 which can conflict with char $2 (); below.
2019 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2020 <limits.h> exists even on freestanding compilers. */
2023 # include <limits.h>
2025 # include <assert.h>
2030 /* Override any GCC internal prototype to avoid an error.
2031 Use char because int might match the return type of a GCC
2032 builtin and then its argument prototype would still apply. */
2037 /* The GNU C library defines this for functions which it implements
2038 to always fail with ENOSYS. Some functions are actually named
2039 something starting with __ and the normal name is an alias. */
2040 #if defined __stub_$2 || defined __stub___$2
2052 if ac_fn_c_try_link "$LINENO"; then :
2057 rm -f core conftest.err conftest.$ac_objext \
2058 conftest$ac_exeext conftest.$ac_ext
2061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2062 $as_echo "$ac_res" >&6; }
2063 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2065 } # ac_fn_c_check_func
2067 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2068 # -------------------------------------------
2069 # Tests whether TYPE exists after having included INCLUDES, setting cache
2070 # variable VAR accordingly.
2071 ac_fn_c_check_type ()
2073 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2075 $as_echo_n "checking for $2... " >&6; }
2076 if eval \${$3+:} false; then :
2077 $as_echo_n "(cached) " >&6
2080 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2081 /* end confdefs.h. */
2092 if ac_fn_c_try_compile "$LINENO"; then :
2093 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2094 /* end confdefs.h. */
2105 if ac_fn_c_try_compile "$LINENO"; then :
2110 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2112 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2116 $as_echo "$ac_res" >&6; }
2117 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2119 } # ac_fn_c_check_type
2121 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2122 # ----------------------------------------------------
2123 # Tries to find if the field MEMBER exists in type AGGR, after including
2124 # INCLUDES, setting cache variable VAR accordingly.
2125 ac_fn_c_check_member ()
2127 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2128 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2129 $as_echo_n "checking for $2.$3... " >&6; }
2130 if eval \${$4+:} false; then :
2131 $as_echo_n "(cached) " >&6
2133 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2134 /* end confdefs.h. */
2146 if ac_fn_c_try_compile "$LINENO"; then :
2149 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2150 /* end confdefs.h. */
2156 if (sizeof ac_aggr.$3)
2162 if ac_fn_c_try_compile "$LINENO"; then :
2167 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2169 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2173 $as_echo "$ac_res" >&6; }
2174 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2176 } # ac_fn_c_check_member
2178 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2179 # --------------------------------------------
2180 # Tries to find the compile-time value of EXPR in a program that includes
2181 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2183 ac_fn_c_compute_int ()
2185 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2186 if test "$cross_compiling" = yes; then
2187 # Depending upon the size, compute the lo and hi bounds.
2188 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2189 /* end confdefs.h. */
2194 static int test_array [1 - 2 * !(($2) >= 0)];
2196 return test_array [0];
2202 if ac_fn_c_try_compile "$LINENO"; then :
2205 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2206 /* end confdefs.h. */
2211 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2213 return test_array [0];
2219 if ac_fn_c_try_compile "$LINENO"; then :
2220 ac_hi=$ac_mid; break
2222 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2223 if test $ac_lo -le $ac_mid; then
2227 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2229 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2232 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2233 /* end confdefs.h. */
2238 static int test_array [1 - 2 * !(($2) < 0)];
2240 return test_array [0];
2246 if ac_fn_c_try_compile "$LINENO"; then :
2249 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2250 /* end confdefs.h. */
2255 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2257 return test_array [0];
2263 if ac_fn_c_try_compile "$LINENO"; then :
2264 ac_lo=$ac_mid; break
2266 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2267 if test $ac_mid -le $ac_hi; then
2271 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2273 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2278 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2280 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2281 # Binary search between lo and hi bounds.
2282 while test "x$ac_lo" != "x$ac_hi"; do
2283 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2285 /* end confdefs.h. */
2290 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2292 return test_array [0];
2298 if ac_fn_c_try_compile "$LINENO"; then :
2301 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2303 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2306 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2310 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2311 /* end confdefs.h. */
2313 static long int longval () { return $2; }
2314 static unsigned long int ulongval () { return $2; }
2321 FILE *f = fopen ("conftest.val", "w");
2326 long int i = longval ();
2329 fprintf (f, "%ld", i);
2333 unsigned long int i = ulongval ();
2336 fprintf (f, "%lu", i);
2338 /* Do not output a trailing newline, as this causes \r\n confusion
2339 on some platforms. */
2340 return ferror (f) || fclose (f) != 0;
2346 if ac_fn_c_try_run "$LINENO"; then :
2347 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2351 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2352 conftest.$ac_objext conftest.beam conftest.$ac_ext
2356 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2357 as_fn_set_status $ac_retval
2359 } # ac_fn_c_compute_int
2361 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2362 # ---------------------------------------------
2363 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2365 ac_fn_c_check_decl ()
2367 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2368 # Initialize each $ac_[]_AC_LANG_ABBREV[]_decl_warn_flag once.
2369 as_decl_name=`echo $2|sed 's/ *(.*//'`
2370 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2372 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2373 if eval \${$3+:} false; then :
2374 $as_echo_n "(cached) " >&6
2376 ac_save_werror_flag=$ac_c_werror_flag
2377 ac_c_werror_flag="$ac_c_decl_warn_flag$ac_c_werror_flag"
2378 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2379 /* end confdefs.h. */
2384 #ifndef $as_decl_name
2386 (void) $as_decl_use;
2388 (void) $as_decl_name;
2396 if ac_fn_c_try_compile "$LINENO"; then :
2401 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2402 ac_c_werror_flag=$ac_save_werror_flag
2405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2406 $as_echo "$ac_res" >&6; }
2407 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2409 } # ac_fn_c_check_decl
2410 cat >config.log <<_ACEOF
2411 This file contains any messages produced by compilers while
2412 running configure, to aid debugging if configure makes a mistake.
2414 It was created by PostgreSQL $as_me 11.5, which was
2415 generated by GNU Autoconf 2.69. Invocation command line was
2427 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2428 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2429 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2430 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2431 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2433 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2434 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2436 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2437 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2438 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2439 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2440 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2441 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2442 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2446 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2450 test -z "$as_dir" && as_dir=.
2451 $as_echo "PATH: $as_dir"
2467 # Keep a trace of the command line.
2468 # Strip out --no-create and --no-recursion so they do not pile up.
2469 # Strip out --silent because we don't want to record it for future runs.
2470 # Also quote any args containing shell meta-characters.
2471 # Make two passes to allow for proper duplicate-argument suppression.
2475 ac_must_keep_next=false
2481 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2482 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2483 | -silent | --silent | --silen | --sile | --sil)
2486 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2489 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2491 as_fn_append ac_configure_args1 " '$ac_arg'"
2492 if test $ac_must_keep_next = true; then
2493 ac_must_keep_next=false # Got value, back to normal.
2496 *=* | --config-cache | -C | -disable-* | --disable-* \
2497 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2498 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2499 | -with-* | --with-* | -without-* | --without-* | --x)
2500 case "$ac_configure_args0 " in
2501 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2504 -* ) ac_must_keep_next=true ;;
2507 as_fn_append ac_configure_args " '$ac_arg'"
2512 { ac_configure_args0=; unset ac_configure_args0;}
2513 { ac_configure_args1=; unset ac_configure_args1;}
2515 # When interrupted or exit'd, cleanup temporary files, and complete
2516 # config.log. We remove comments because anyway the quotes in there
2517 # would cause problems or look ugly.
2518 # WARNING: Use '\'' to represent an apostrophe within the trap.
2519 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2520 trap 'exit_status=$?
2521 # Save into config.log some information that might help in debugging.
2525 $as_echo "## ---------------- ##
2526 ## Cache variables. ##
2527 ## ---------------- ##"
2529 # The following way of writing the cache mishandles newlines in values,
2531 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2532 eval ac_val=\$$ac_var
2536 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2537 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2540 _ | IFS | as_nl) ;; #(
2541 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2542 *) { eval $ac_var=; unset $ac_var;} ;;
2547 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2548 *${as_nl}ac_space=\ *)
2550 "s/'\''/'\''\\\\'\'''\''/g;
2551 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2554 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2561 $as_echo "## ----------------- ##
2562 ## Output variables. ##
2563 ## ----------------- ##"
2565 for ac_var in $ac_subst_vars
2567 eval ac_val=\$$ac_var
2569 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2571 $as_echo "$ac_var='\''$ac_val'\''"
2575 if test -n "$ac_subst_files"; then
2576 $as_echo "## ------------------- ##
2577 ## File substitutions. ##
2578 ## ------------------- ##"
2580 for ac_var in $ac_subst_files
2582 eval ac_val=\$$ac_var
2584 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2586 $as_echo "$ac_var='\''$ac_val'\''"
2591 if test -s confdefs.h; then
2592 $as_echo "## ----------- ##
2599 test "$ac_signal" != 0 &&
2600 $as_echo "$as_me: caught signal $ac_signal"
2601 $as_echo "$as_me: exit $exit_status"
2603 rm -f core *.core core.conftest.* &&
2604 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2607 for ac_signal in 1 2 13 15; do
2608 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2612 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2613 rm -f -r conftest* confdefs.h
2615 $as_echo "/* confdefs.h */" > confdefs.h
2617 # Predefined preprocessor variables.
2619 cat >>confdefs.h <<_ACEOF
2620 #define PACKAGE_NAME "$PACKAGE_NAME"
2623 cat >>confdefs.h <<_ACEOF
2624 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2627 cat >>confdefs.h <<_ACEOF
2628 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2631 cat >>confdefs.h <<_ACEOF
2632 #define PACKAGE_STRING "$PACKAGE_STRING"
2635 cat >>confdefs.h <<_ACEOF
2636 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2639 cat >>confdefs.h <<_ACEOF
2640 #define PACKAGE_URL "$PACKAGE_URL"
2644 # Let the site file select an alternate cache file if it wants to.
2645 # Prefer an explicitly selected file to automatically selected ones.
2648 if test -n "$CONFIG_SITE"; then
2649 # We do not want a PATH search for config.site.
2650 case $CONFIG_SITE in #((
2651 -*) ac_site_file1=./$CONFIG_SITE;;
2652 */*) ac_site_file1=$CONFIG_SITE;;
2653 *) ac_site_file1=./$CONFIG_SITE;;
2655 elif test "x$prefix" != xNONE; then
2656 ac_site_file1=$prefix/share/config.site
2657 ac_site_file2=$prefix/etc/config.site
2659 ac_site_file1=$ac_default_prefix/share/config.site
2660 ac_site_file2=$ac_default_prefix/etc/config.site
2662 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2664 test "x$ac_site_file" = xNONE && continue
2665 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2666 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2667 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2668 sed 's/^/| /' "$ac_site_file" >&5
2670 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2671 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2672 as_fn_error $? "failed to load site script $ac_site_file
2673 See \`config.log' for more details" "$LINENO" 5; }
2677 if test -r "$cache_file"; then
2678 # Some versions of bash will fail to source /dev/null (special files
2679 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2680 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2681 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2682 $as_echo "$as_me: loading cache $cache_file" >&6;}
2684 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2685 *) . "./$cache_file";;
2689 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2690 $as_echo "$as_me: creating cache $cache_file" >&6;}
2694 # Check that the precious variables saved in the cache have kept the same
2696 ac_cache_corrupted=false
2697 for ac_var in $ac_precious_vars; do
2698 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2699 eval ac_new_set=\$ac_env_${ac_var}_set
2700 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2701 eval ac_new_val=\$ac_env_${ac_var}_value
2702 case $ac_old_set,$ac_new_set in
2704 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2705 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2706 ac_cache_corrupted=: ;;
2708 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2709 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2710 ac_cache_corrupted=: ;;
2713 if test "x$ac_old_val" != "x$ac_new_val"; then
2714 # differences in whitespace do not lead to failure.
2715 ac_old_val_w=`echo x $ac_old_val`
2716 ac_new_val_w=`echo x $ac_new_val`
2717 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2718 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2719 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2720 ac_cache_corrupted=:
2722 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2723 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2724 eval $ac_var=\$ac_old_val
2726 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2727 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2728 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2729 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2732 # Pass precious variables to config.status.
2733 if test "$ac_new_set" = set; then
2735 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2736 *) ac_arg=$ac_var=$ac_new_val ;;
2738 case " $ac_configure_args " in
2739 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2740 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2744 if $ac_cache_corrupted; then
2745 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2746 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2747 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2748 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2749 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2751 ## -------------------- ##
2752 ## Main body of script. ##
2753 ## -------------------- ##
2756 ac_cpp='$CPP $CPPFLAGS'
2757 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2758 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2759 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2767 for ac_dir in config "$srcdir"/config; do
2768 if test -f "$ac_dir/install-sh"; then
2770 ac_install_sh="$ac_aux_dir/install-sh -c"
2772 elif test -f "$ac_dir/install.sh"; then
2774 ac_install_sh="$ac_aux_dir/install.sh -c"
2776 elif test -f "$ac_dir/shtool"; then
2778 ac_install_sh="$ac_aux_dir/shtool install -c"
2782 if test -z "$ac_aux_dir"; then
2783 as_fn_error $? "cannot find install-sh, install.sh, or shtool in config \"$srcdir\"/config" "$LINENO" 5
2786 # These three variables are undocumented and unsupported,
2787 # and are intended to be withdrawn in a future Autoconf release.
2788 # They can cause serious problems if a builder's source tree is in a directory
2789 # whose full name contains unusual characters.
2790 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
2791 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
2792 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
2796 configure_args=$ac_configure_args
2799 PG_MAJORVERSION=`expr "$PACKAGE_VERSION" : '\([0-9][0-9]*\)'`
2802 cat >>confdefs.h <<_ACEOF
2803 #define PG_MAJORVERSION "$PG_MAJORVERSION"
2810 # Check whether --with-extra-version was given.
2811 if test "${with_extra_version+set}" = set; then :
2812 withval=$with_extra_version;
2815 as_fn_error $? "argument required for --with-extra-version option" "$LINENO" 5
2818 as_fn_error $? "argument required for --with-extra-version option" "$LINENO" 5
2821 PG_VERSION="$PACKAGE_VERSION$withval"
2826 PG_VERSION="$PACKAGE_VERSION"
2831 cat >>confdefs.h <<_ACEOF
2832 #define PG_VERSION "$PG_VERSION"
2836 # Make sure we can run config.sub.
2837 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2838 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
2840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
2841 $as_echo_n "checking build system type... " >&6; }
2842 if ${ac_cv_build+:} false; then :
2843 $as_echo_n "(cached) " >&6
2845 ac_build_alias=$build_alias
2846 test "x$ac_build_alias" = x &&
2847 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2848 test "x$ac_build_alias" = x &&
2849 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
2850 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2851 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
2854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
2855 $as_echo "$ac_cv_build" >&6; }
2856 case $ac_cv_build in
2858 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
2861 ac_save_IFS=$IFS; IFS='-'
2867 # Remember, the first character of IFS is used to create $*,
2868 # except with old shells:
2871 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
2874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
2875 $as_echo_n "checking host system type... " >&6; }
2876 if ${ac_cv_host+:} false; then :
2877 $as_echo_n "(cached) " >&6
2879 if test "x$host_alias" = x; then
2880 ac_cv_host=$ac_cv_build
2882 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2883 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
2887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
2888 $as_echo "$ac_cv_host" >&6; }
2891 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
2894 ac_save_IFS=$IFS; IFS='-'
2900 # Remember, the first character of IFS is used to create $*,
2901 # except with old shells:
2904 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2909 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which template to use" >&5
2910 $as_echo_n "checking which template to use... " >&6; }
2915 # Check whether --with-template was given.
2916 if test "${with_template+set}" = set; then :
2917 withval=$with_template;
2920 as_fn_error $? "argument required for --with-template option" "$LINENO" 5
2923 as_fn_error $? "argument required for --with-template option" "$LINENO" 5
2928 list) echo; ls "$srcdir/src/template"; exit;;
2929 *) if test -f "$srcdir/src/template/$with_template" ; then
2932 as_fn_error $? "'$withval' is not a valid template name. Use 'list' for a list." "$LINENO" 5
2941 # --with-template not given
2944 aix*) template=aix ;;
2945 cygwin*) template=cygwin ;;
2946 darwin*) template=darwin ;;
2947 dragonfly*) template=netbsd ;;
2948 freebsd*) template=freebsd ;;
2949 hpux*) template=hpux ;;
2950 linux*|gnu*|k*bsd*-gnu)
2952 mingw*) template=win32 ;;
2953 netbsd*) template=netbsd ;;
2954 openbsd*) template=openbsd ;;
2955 solaris*) template=solaris ;;
2958 if test x"$template" = x"" ; then
2960 *******************************************************************
2961 PostgreSQL has apparently not been ported to your platform yet.
2962 To try a manual configuration, look into the src/template directory
2963 for a similar platform and use the '--with-template=' option.
2965 Please also contact <pgsql-bugs@postgresql.org> to see about
2966 rectifying this. Include the above 'checking host system type...'
2968 *******************************************************************
2977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $template" >&5
2978 $as_echo "$template" >&6; }
2983 # Initialize default assumption that we do not need separate assembly code
2984 # for TAS (test-and-set). This can be overridden by the template file
2985 # when it's executed.
2992 ## Command line options
2996 # Add non-standard directories to the include path
3001 # Check whether --with-includes was given.
3002 if test "${with_includes+set}" = set; then :
3003 withval=$with_includes;
3006 as_fn_error $? "argument required for --with-includes option" "$LINENO" 5
3009 as_fn_error $? "argument required for --with-includes option" "$LINENO" 5
3022 # Add non-standard directories to the library search path
3027 # Check whether --with-libraries was given.
3028 if test "${with_libraries+set}" = set; then :
3029 withval=$with_libraries;
3032 as_fn_error $? "argument required for --with-libraries option" "$LINENO" 5
3035 as_fn_error $? "argument required for --with-libraries option" "$LINENO" 5
3038 LIBRARY_DIRS=$withval
3049 # Check whether --with-libs was given.
3050 if test "${with_libs+set}" = set; then :
3054 as_fn_error $? "argument required for --with-libs option" "$LINENO" 5
3057 as_fn_error $? "argument required for --with-libs option" "$LINENO" 5
3060 LIBRARY_DIRS=$withval
3070 # 64-bit integer date/time storage is now the only option, but to avoid
3071 # unnecessary breakage of build scripts, continue to accept an explicit
3072 # "--enable-integer-datetimes" switch.
3076 # Check whether --enable-integer-datetimes was given.
3077 if test "${enable_integer_datetimes+set}" = set; then :
3078 enableval=$enable_integer_datetimes;
3084 as_fn_error $? "--disable-integer-datetimes is no longer supported" "$LINENO" 5
3087 as_fn_error $? "no argument expected for --enable-integer-datetimes option" "$LINENO" 5
3092 enable_integer_datetimes=yes
3102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is wanted" >&5
3103 $as_echo_n "checking whether NLS is wanted... " >&6; }
3106 # Check whether --enable-nls was given.
3107 if test "${enable_nls+set}" = set; then :
3108 enableval=$enable_nls;
3118 WANTED_LANGUAGES=$enableval
3128 if test "$enable_nls" = yes; then
3130 $as_echo "#define ENABLE_NLS 1" >>confdefs.h
3134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_nls" >&5
3135 $as_echo "$enable_nls" >&6; }
3140 # Default port number (--with-pgport), default 5432
3142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default port number" >&5
3143 $as_echo_n "checking for default port number... " >&6; }
3147 # Check whether --with-pgport was given.
3148 if test "${with_pgport+set}" = set; then :
3149 withval=$with_pgport;
3152 as_fn_error $? "argument required for --with-pgport option" "$LINENO" 5
3155 as_fn_error $? "argument required for --with-pgport option" "$LINENO" 5
3158 default_port=$withval
3167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $default_port" >&5
3168 $as_echo "$default_port" >&6; }
3169 # Need both of these because some places want an integer and some a string
3171 cat >>confdefs.h <<_ACEOF
3172 #define DEF_PGPORT ${default_port}
3176 cat >>confdefs.h <<_ACEOF
3177 #define DEF_PGPORT_STR "${default_port}"
3182 # It's worth validating port; you can get very confusing errors otherwise
3183 if test x"$default_port" = x""; then
3184 as_fn_error $? "invalid --with-pgport specification: empty string" "$LINENO" 5
3185 elif test ! x`echo "$default_port" | sed -e 's/[0-9]*//'` = x""; then
3186 as_fn_error $? "invalid --with-pgport specification: must be a number" "$LINENO" 5
3187 elif test ! x`echo "$default_port" | sed -e 's/^0.//'` = x"$default_port"; then
3188 as_fn_error $? "invalid --with-pgport specification: must not have leading 0" "$LINENO" 5
3189 elif test "$default_port" -lt "1" -o "$default_port" -gt "65535"; then
3190 as_fn_error $? "invalid --with-pgport specification: must be between 1 and 65535" "$LINENO" 5
3194 # '-rpath'-like feature can be disabled
3198 # Check whether --enable-rpath was given.
3199 if test "${enable_rpath+set}" = set; then :
3200 enableval=$enable_rpath;
3209 as_fn_error $? "no argument expected for --enable-rpath option" "$LINENO" 5
3226 # Check whether --enable-spinlocks was given.
3227 if test "${enable_spinlocks+set}" = set; then :
3228 enableval=$enable_spinlocks;
3237 as_fn_error $? "no argument expected for --enable-spinlocks option" "$LINENO" 5
3242 enable_spinlocks=yes
3253 # Check whether --enable-atomics was given.
3254 if test "${enable_atomics+set}" = set; then :
3255 enableval=$enable_atomics;
3264 as_fn_error $? "no argument expected for --enable-atomics option" "$LINENO" 5
3276 # Random number generation
3280 # Check whether --enable-strong-random was given.
3281 if test "${enable_strong_random+set}" = set; then :
3282 enableval=$enable_strong_random;
3291 as_fn_error $? "no argument expected for --enable-strong-random option" "$LINENO" 5
3296 enable_strong_random=yes
3304 # --enable-debug adds -g to compiler flags
3308 # Check whether --enable-debug was given.
3309 if test "${enable_debug+set}" = set; then :
3310 enableval=$enable_debug;
3319 as_fn_error $? "no argument expected for --enable-debug option" "$LINENO" 5
3332 # --enable-profiling enables gcc profiling
3336 # Check whether --enable-profiling was given.
3337 if test "${enable_profiling+set}" = set; then :
3338 enableval=$enable_profiling;
3347 as_fn_error $? "no argument expected for --enable-profiling option" "$LINENO" 5
3359 # --enable-coverage enables generation of code coverage metrics with gcov
3363 # Check whether --enable-coverage was given.
3364 if test "${enable_coverage+set}" = set; then :
3365 enableval=$enable_coverage;
3368 if test -z "$GCOV"; then
3371 # Extract the first word of "$ac_prog", so it can be a program name with args.
3372 set dummy $ac_prog; ac_word=$2
3373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3374 $as_echo_n "checking for $ac_word... " >&6; }
3375 if ${ac_cv_path_GCOV+:} false; then :
3376 $as_echo_n "(cached) " >&6
3380 ac_cv_path_GCOV="$GCOV" # Let the user override the test with a path.
3383 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3387 test -z "$as_dir" && as_dir=.
3388 for ac_exec_ext in '' $ac_executable_extensions; do
3389 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3390 ac_cv_path_GCOV="$as_dir/$ac_word$ac_exec_ext"
3391 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3401 GCOV=$ac_cv_path_GCOV
3402 if test -n "$GCOV"; then
3403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCOV" >&5
3404 $as_echo "$GCOV" >&6; }
3406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3407 $as_echo "no" >&6; }
3411 test -n "$GCOV" && break
3415 # Report the value of GCOV in configure's output in all cases.
3416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GCOV" >&5
3417 $as_echo_n "checking for GCOV... " >&6; }
3418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCOV" >&5
3419 $as_echo "$GCOV" >&6; }
3422 if test -z "$GCOV"; then
3423 as_fn_error $? "gcov not found" "$LINENO" 5
3425 if test -z "$LCOV"; then
3428 # Extract the first word of "$ac_prog", so it can be a program name with args.
3429 set dummy $ac_prog; ac_word=$2
3430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3431 $as_echo_n "checking for $ac_word... " >&6; }
3432 if ${ac_cv_path_LCOV+:} false; then :
3433 $as_echo_n "(cached) " >&6
3437 ac_cv_path_LCOV="$LCOV" # Let the user override the test with a path.
3440 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3444 test -z "$as_dir" && as_dir=.
3445 for ac_exec_ext in '' $ac_executable_extensions; do
3446 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3447 ac_cv_path_LCOV="$as_dir/$ac_word$ac_exec_ext"
3448 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3458 LCOV=$ac_cv_path_LCOV
3459 if test -n "$LCOV"; then
3460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LCOV" >&5
3461 $as_echo "$LCOV" >&6; }
3463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3464 $as_echo "no" >&6; }
3468 test -n "$LCOV" && break
3472 # Report the value of LCOV in configure's output in all cases.
3473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LCOV" >&5
3474 $as_echo_n "checking for LCOV... " >&6; }
3475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LCOV" >&5
3476 $as_echo "$LCOV" >&6; }
3479 if test -z "$LCOV"; then
3480 as_fn_error $? "lcov not found" "$LINENO" 5
3482 if test -z "$GENHTML"; then
3483 for ac_prog in genhtml
3485 # Extract the first word of "$ac_prog", so it can be a program name with args.
3486 set dummy $ac_prog; ac_word=$2
3487 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3488 $as_echo_n "checking for $ac_word... " >&6; }
3489 if ${ac_cv_path_GENHTML+:} false; then :
3490 $as_echo_n "(cached) " >&6
3494 ac_cv_path_GENHTML="$GENHTML" # Let the user override the test with a path.
3497 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3501 test -z "$as_dir" && as_dir=.
3502 for ac_exec_ext in '' $ac_executable_extensions; do
3503 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3504 ac_cv_path_GENHTML="$as_dir/$ac_word$ac_exec_ext"
3505 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3515 GENHTML=$ac_cv_path_GENHTML
3516 if test -n "$GENHTML"; then
3517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GENHTML" >&5
3518 $as_echo "$GENHTML" >&6; }
3520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3521 $as_echo "no" >&6; }
3525 test -n "$GENHTML" && break
3529 # Report the value of GENHTML in configure's output in all cases.
3530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GENHTML" >&5
3531 $as_echo_n "checking for GENHTML... " >&6; }
3532 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GENHTML" >&5
3533 $as_echo "$GENHTML" >&6; }
3536 if test -z "$GENHTML"; then
3537 as_fn_error $? "genhtml not found" "$LINENO" 5
3544 as_fn_error $? "no argument expected for --enable-coverage option" "$LINENO" 5
3561 # Check whether --enable-dtrace was given.
3562 if test "${enable_dtrace+set}" = set; then :
3563 enableval=$enable_dtrace;
3566 if test -z "$DTRACE"; then
3567 for ac_prog in dtrace
3569 # Extract the first word of "$ac_prog", so it can be a program name with args.
3570 set dummy $ac_prog; ac_word=$2
3571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3572 $as_echo_n "checking for $ac_word... " >&6; }
3573 if ${ac_cv_path_DTRACE+:} false; then :
3574 $as_echo_n "(cached) " >&6
3578 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path.
3581 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3585 test -z "$as_dir" && as_dir=.
3586 for ac_exec_ext in '' $ac_executable_extensions; do
3587 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3588 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext"
3589 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3599 DTRACE=$ac_cv_path_DTRACE
3600 if test -n "$DTRACE"; then
3601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5
3602 $as_echo "$DTRACE" >&6; }
3604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3605 $as_echo "no" >&6; }
3609 test -n "$DTRACE" && break
3613 # Report the value of DTRACE in configure's output in all cases.
3614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DTRACE" >&5
3615 $as_echo_n "checking for DTRACE... " >&6; }
3616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5
3617 $as_echo "$DTRACE" >&6; }
3620 if test -z "$DTRACE"; then
3621 as_fn_error $? "dtrace not found" "$LINENO" 5
3629 as_fn_error $? "no argument expected for --enable-dtrace option" "$LINENO" 5
3646 # Check whether --enable-tap-tests was given.
3647 if test "${enable_tap_tests+set}" = set; then :
3648 enableval=$enable_tap_tests;
3657 as_fn_error $? "no argument expected for --enable-tap-tests option" "$LINENO" 5
3672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for block size" >&5
3673 $as_echo_n "checking for block size... " >&6; }
3677 # Check whether --with-blocksize was given.
3678 if test "${with_blocksize+set}" = set; then :
3679 withval=$with_blocksize;
3682 as_fn_error $? "argument required for --with-blocksize option" "$LINENO" 5
3685 as_fn_error $? "argument required for --with-blocksize option" "$LINENO" 5
3697 case ${blocksize} in
3704 *) as_fn_error $? "Invalid block size. Allowed values are 1,2,4,8,16,32." "$LINENO" 5
3706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${blocksize}kB" >&5
3707 $as_echo "${blocksize}kB" >&6; }
3710 cat >>confdefs.h <<_ACEOF
3711 #define BLCKSZ ${BLCKSZ}
3716 # Relation segment size
3718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for segment size" >&5
3719 $as_echo_n "checking for segment size... " >&6; }
3723 # Check whether --with-segsize was given.
3724 if test "${with_segsize+set}" = set; then :
3725 withval=$with_segsize;
3728 as_fn_error $? "argument required for --with-segsize option" "$LINENO" 5
3731 as_fn_error $? "argument required for --with-segsize option" "$LINENO" 5
3743 # this expression is set up to avoid unnecessary integer overflow
3744 # blocksize is already guaranteed to be a factor of 1024
3745 RELSEG_SIZE=`expr '(' 1024 / ${blocksize} ')' '*' ${segsize} '*' 1024`
3746 test $? -eq 0 || exit 1
3747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${segsize}GB" >&5
3748 $as_echo "${segsize}GB" >&6; }
3751 cat >>confdefs.h <<_ACEOF
3752 #define RELSEG_SIZE ${RELSEG_SIZE}
3759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WAL block size" >&5
3760 $as_echo_n "checking for WAL block size... " >&6; }
3764 # Check whether --with-wal-blocksize was given.
3765 if test "${with_wal_blocksize+set}" = set; then :
3766 withval=$with_wal_blocksize;
3769 as_fn_error $? "argument required for --with-wal-blocksize option" "$LINENO" 5
3772 as_fn_error $? "argument required for --with-wal-blocksize option" "$LINENO" 5
3775 wal_blocksize=$withval
3784 case ${wal_blocksize} in
3785 1) XLOG_BLCKSZ=1024;;
3786 2) XLOG_BLCKSZ=2048;;
3787 4) XLOG_BLCKSZ=4096;;
3788 8) XLOG_BLCKSZ=8192;;
3789 16) XLOG_BLCKSZ=16384;;
3790 32) XLOG_BLCKSZ=32768;;
3791 64) XLOG_BLCKSZ=65536;;
3792 *) as_fn_error $? "Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." "$LINENO" 5
3794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${wal_blocksize}kB" >&5
3795 $as_echo "${wal_blocksize}kB" >&6; }
3798 cat >>confdefs.h <<_ACEOF
3799 #define XLOG_BLCKSZ ${XLOG_BLCKSZ}
3807 # For historical reasons you can also use --with-CC to specify the C compiler
3808 # to use, although the standard way to do this is to set the CC environment
3813 # Check whether --with-CC was given.
3814 if test "${with_CC+set}" = set; then :
3818 as_fn_error $? "argument required for --with-CC option" "$LINENO" 5
3821 as_fn_error $? "argument required for --with-CC option" "$LINENO" 5
3833 aix) pgac_cc_list="gcc xlc"; pgac_cxx_list="g++ xlC";;
3834 *) pgac_cc_list="gcc cc"; pgac_cxx_list="g++ c++";;
3838 ac_cpp='$CPP $CPPFLAGS'
3839 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3840 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3841 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3842 if test -n "$ac_tool_prefix"; then
3843 for ac_prog in $pgac_cc_list
3845 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3846 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3848 $as_echo_n "checking for $ac_word... " >&6; }
3849 if ${ac_cv_prog_CC+:} false; then :
3850 $as_echo_n "(cached) " >&6
3852 if test -n "$CC"; then
3853 ac_cv_prog_CC="$CC" # Let the user override the test.
3855 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3859 test -z "$as_dir" && as_dir=.
3860 for ac_exec_ext in '' $ac_executable_extensions; do
3861 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3862 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3863 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3873 if test -n "$CC"; then
3874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3875 $as_echo "$CC" >&6; }
3877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3878 $as_echo "no" >&6; }
3882 test -n "$CC" && break
3885 if test -z "$CC"; then
3887 for ac_prog in $pgac_cc_list
3889 # Extract the first word of "$ac_prog", so it can be a program name with args.
3890 set dummy $ac_prog; ac_word=$2
3891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3892 $as_echo_n "checking for $ac_word... " >&6; }
3893 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3894 $as_echo_n "(cached) " >&6
3896 if test -n "$ac_ct_CC"; then
3897 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3899 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3903 test -z "$as_dir" && as_dir=.
3904 for ac_exec_ext in '' $ac_executable_extensions; do
3905 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3906 ac_cv_prog_ac_ct_CC="$ac_prog"
3907 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3916 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3917 if test -n "$ac_ct_CC"; then
3918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3919 $as_echo "$ac_ct_CC" >&6; }
3921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3922 $as_echo "no" >&6; }
3926 test -n "$ac_ct_CC" && break
3929 if test "x$ac_ct_CC" = x; then
3932 case $cross_compiling:$ac_tool_warned in
3934 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3935 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3936 ac_tool_warned=yes ;;
3943 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3944 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3945 as_fn_error $? "no acceptable C compiler found in \$PATH
3946 See \`config.log' for more details" "$LINENO" 5; }
3948 # Provide some information about the compiler.
3949 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3952 for ac_option in --version -v -V -qversion; do
3953 { { ac_try="$ac_compiler $ac_option >&5"
3955 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3956 *) ac_try_echo=$ac_try;;
3958 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3959 $as_echo "$ac_try_echo"; } >&5
3960 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3962 if test -s conftest.err; then
3964 ... rest of stderr output deleted ...
3965 10q' conftest.err >conftest.er1
3966 cat conftest.er1 >&5
3968 rm -f conftest.er1 conftest.err
3969 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3970 test $ac_status = 0; }
3973 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3974 /* end confdefs.h. */
3984 ac_clean_files_save=$ac_clean_files
3985 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3986 # Try to create an executable without -o first, disregard a.out.
3987 # It will help us diagnose broken compilers, and finding out an intuition
3989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3990 $as_echo_n "checking whether the C compiler works... " >&6; }
3991 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3993 # The possible output files:
3994 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3997 for ac_file in $ac_files
4000 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4001 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4006 if { { ac_try="$ac_link_default"
4008 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4009 *) ac_try_echo=$ac_try;;
4011 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4012 $as_echo "$ac_try_echo"; } >&5
4013 (eval "$ac_link_default") 2>&5
4015 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4016 test $ac_status = 0; }; then :
4017 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4018 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4019 # in a Makefile. We should not override ac_cv_exeext if it was cached,
4020 # so that the user can short-circuit this test for compilers unknown to
4022 for ac_file in $ac_files ''
4024 test -f "$ac_file" || continue
4026 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
4029 # We found the default executable, but exeext='' is most
4033 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
4035 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4037 # We set ac_cv_exeext here because the later test for it is not
4038 # safe: cross compilers may not add the suffix if given an `-o'
4039 # argument, so we may need to know it at that point already.
4040 # Even if this section looks crufty: it has the advantage of
4047 test "$ac_cv_exeext" = no && ac_cv_exeext=
4052 if test -z "$ac_file"; then :
4053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4054 $as_echo "no" >&6; }
4055 $as_echo "$as_me: failed program was:" >&5
4056 sed 's/^/| /' conftest.$ac_ext >&5
4058 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4059 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4060 as_fn_error 77 "C compiler cannot create executables
4061 See \`config.log' for more details" "$LINENO" 5; }
4063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4064 $as_echo "yes" >&6; }
4066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4067 $as_echo_n "checking for C compiler default output file name... " >&6; }
4068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4069 $as_echo "$ac_file" >&6; }
4070 ac_exeext=$ac_cv_exeext
4072 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
4073 ac_clean_files=$ac_clean_files_save
4074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4075 $as_echo_n "checking for suffix of executables... " >&6; }
4076 if { { ac_try="$ac_link"
4078 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4079 *) ac_try_echo=$ac_try;;
4081 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4082 $as_echo "$ac_try_echo"; } >&5
4083 (eval "$ac_link") 2>&5
4085 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4086 test $ac_status = 0; }; then :
4087 # If both `conftest.exe' and `conftest' are `present' (well, observable)
4088 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
4089 # work properly (i.e., refer to `conftest.exe'), while it won't with
4091 for ac_file in conftest.exe conftest conftest.*; do
4092 test -f "$ac_file" || continue
4094 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4095 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4101 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4102 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4103 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
4104 See \`config.log' for more details" "$LINENO" 5; }
4106 rm -f conftest conftest$ac_cv_exeext
4107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4108 $as_echo "$ac_cv_exeext" >&6; }
4110 rm -f conftest.$ac_ext
4111 EXEEXT=$ac_cv_exeext
4113 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4114 /* end confdefs.h. */
4119 FILE *f = fopen ("conftest.out", "w");
4120 return ferror (f) || fclose (f) != 0;
4126 ac_clean_files="$ac_clean_files conftest.out"
4127 # Check that the compiler produces executables we can run. If not, either
4128 # the compiler is broken, or we cross compile.
4129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4130 $as_echo_n "checking whether we are cross compiling... " >&6; }
4131 if test "$cross_compiling" != yes; then
4132 { { ac_try="$ac_link"
4134 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4135 *) ac_try_echo=$ac_try;;
4137 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4138 $as_echo "$ac_try_echo"; } >&5
4139 (eval "$ac_link") 2>&5
4141 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4142 test $ac_status = 0; }
4143 if { ac_try='./conftest$ac_cv_exeext'
4144 { { case "(($ac_try" in
4145 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4146 *) ac_try_echo=$ac_try;;
4148 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4149 $as_echo "$ac_try_echo"; } >&5
4150 (eval "$ac_try") 2>&5
4152 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4153 test $ac_status = 0; }; }; then
4156 if test "$cross_compiling" = maybe; then
4159 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4160 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4161 as_fn_error $? "cannot run C compiled programs.
4162 If you meant to cross compile, use \`--host'.
4163 See \`config.log' for more details" "$LINENO" 5; }
4167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4168 $as_echo "$cross_compiling" >&6; }
4170 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4171 ac_clean_files=$ac_clean_files_save
4172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4173 $as_echo_n "checking for suffix of object files... " >&6; }
4174 if ${ac_cv_objext+:} false; then :
4175 $as_echo_n "(cached) " >&6
4177 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4178 /* end confdefs.h. */
4188 rm -f conftest.o conftest.obj
4189 if { { ac_try="$ac_compile"
4191 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4192 *) ac_try_echo=$ac_try;;
4194 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4195 $as_echo "$ac_try_echo"; } >&5
4196 (eval "$ac_compile") 2>&5
4198 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4199 test $ac_status = 0; }; then :
4200 for ac_file in conftest.o conftest.obj conftest.*; do
4201 test -f "$ac_file" || continue;
4203 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
4204 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4209 $as_echo "$as_me: failed program was:" >&5
4210 sed 's/^/| /' conftest.$ac_ext >&5
4212 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4213 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4214 as_fn_error $? "cannot compute suffix of object files: cannot compile
4215 See \`config.log' for more details" "$LINENO" 5; }
4217 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4220 $as_echo "$ac_cv_objext" >&6; }
4221 OBJEXT=$ac_cv_objext
4223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4224 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4225 if ${ac_cv_c_compiler_gnu+:} false; then :
4226 $as_echo_n "(cached) " >&6
4228 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4229 /* end confdefs.h. */
4242 if ac_fn_c_try_compile "$LINENO"; then :
4247 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4248 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4252 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
4253 if test $ac_compiler_gnu = yes; then
4258 ac_test_CFLAGS=${CFLAGS+set}
4259 ac_save_CFLAGS=$CFLAGS
4260 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4261 $as_echo_n "checking whether $CC accepts -g... " >&6; }
4262 if ${ac_cv_prog_cc_g+:} false; then :
4263 $as_echo_n "(cached) " >&6
4265 ac_save_c_werror_flag=$ac_c_werror_flag
4266 ac_c_werror_flag=yes
4269 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4270 /* end confdefs.h. */
4280 if ac_fn_c_try_compile "$LINENO"; then :
4284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4285 /* end confdefs.h. */
4295 if ac_fn_c_try_compile "$LINENO"; then :
4298 ac_c_werror_flag=$ac_save_c_werror_flag
4300 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4301 /* end confdefs.h. */
4311 if ac_fn_c_try_compile "$LINENO"; then :
4314 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4316 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4318 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4319 ac_c_werror_flag=$ac_save_c_werror_flag
4321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4322 $as_echo "$ac_cv_prog_cc_g" >&6; }
4323 if test "$ac_test_CFLAGS" = set; then
4324 CFLAGS=$ac_save_CFLAGS
4325 elif test $ac_cv_prog_cc_g = yes; then
4326 if test "$GCC" = yes; then
4332 if test "$GCC" = yes; then
4338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4339 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4340 if ${ac_cv_prog_cc_c89+:} false; then :
4341 $as_echo_n "(cached) " >&6
4343 ac_cv_prog_cc_c89=no
4345 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4346 /* end confdefs.h. */
4350 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4351 struct buf { int x; };
4352 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4353 static char *e (p, i)
4359 static char *f (char * (*g) (char **, int), char **p, ...)
4364 s = g (p, va_arg (v,int));
4369 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
4370 function prototypes and stuff, but not '\xHH' hex character constants.
4371 These don't provoke an error unfortunately, instead are silently treated
4372 as 'x'. The following induces an error, until -std is added to get
4373 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
4374 array size at least. It's necessary to write '\x00'==0 to get something
4375 that's true only with -std. */
4376 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4378 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4379 inside strings and character constants. */
4381 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4383 int test (int i, double x);
4384 struct s1 {int (*f) (int a);};
4385 struct s2 {int (*f) (double a);};
4386 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4392 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4397 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4398 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4400 CC="$ac_save_CC $ac_arg"
4401 if ac_fn_c_try_compile "$LINENO"; then :
4402 ac_cv_prog_cc_c89=$ac_arg
4404 rm -f core conftest.err conftest.$ac_objext
4405 test "x$ac_cv_prog_cc_c89" != "xno" && break
4407 rm -f conftest.$ac_ext
4412 case "x$ac_cv_prog_cc_c89" in
4414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4415 $as_echo "none needed" >&6; } ;;
4417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4418 $as_echo "unsupported" >&6; } ;;
4420 CC="$CC $ac_cv_prog_cc_c89"
4421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4422 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4424 if test "x$ac_cv_prog_cc_c89" != xno; then :
4429 ac_cpp='$CPP $CPPFLAGS'
4430 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4431 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4432 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4435 ac_cpp='$CXXCPP $CPPFLAGS'
4436 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4437 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4438 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
4439 if test -z "$CXX"; then
4440 if test -n "$CCC"; then
4443 if test -n "$ac_tool_prefix"; then
4444 for ac_prog in $pgac_cxx_list
4446 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4447 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4448 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4449 $as_echo_n "checking for $ac_word... " >&6; }
4450 if ${ac_cv_prog_CXX+:} false; then :
4451 $as_echo_n "(cached) " >&6
4453 if test -n "$CXX"; then
4454 ac_cv_prog_CXX="$CXX" # Let the user override the test.
4456 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4460 test -z "$as_dir" && as_dir=.
4461 for ac_exec_ext in '' $ac_executable_extensions; do
4462 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4463 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
4464 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4474 if test -n "$CXX"; then
4475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
4476 $as_echo "$CXX" >&6; }
4478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4479 $as_echo "no" >&6; }
4483 test -n "$CXX" && break
4486 if test -z "$CXX"; then
4488 for ac_prog in $pgac_cxx_list
4490 # Extract the first word of "$ac_prog", so it can be a program name with args.
4491 set dummy $ac_prog; ac_word=$2
4492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4493 $as_echo_n "checking for $ac_word... " >&6; }
4494 if ${ac_cv_prog_ac_ct_CXX+:} false; then :
4495 $as_echo_n "(cached) " >&6
4497 if test -n "$ac_ct_CXX"; then
4498 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
4500 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4504 test -z "$as_dir" && as_dir=.
4505 for ac_exec_ext in '' $ac_executable_extensions; do
4506 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4507 ac_cv_prog_ac_ct_CXX="$ac_prog"
4508 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4517 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
4518 if test -n "$ac_ct_CXX"; then
4519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
4520 $as_echo "$ac_ct_CXX" >&6; }
4522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4523 $as_echo "no" >&6; }
4527 test -n "$ac_ct_CXX" && break
4530 if test "x$ac_ct_CXX" = x; then
4533 case $cross_compiling:$ac_tool_warned in
4535 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4536 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4537 ac_tool_warned=yes ;;
4545 # Provide some information about the compiler.
4546 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
4549 for ac_option in --version -v -V -qversion; do
4550 { { ac_try="$ac_compiler $ac_option >&5"
4552 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4553 *) ac_try_echo=$ac_try;;
4555 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4556 $as_echo "$ac_try_echo"; } >&5
4557 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4559 if test -s conftest.err; then
4561 ... rest of stderr output deleted ...
4562 10q' conftest.err >conftest.er1
4563 cat conftest.er1 >&5
4565 rm -f conftest.er1 conftest.err
4566 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4567 test $ac_status = 0; }
4570 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
4571 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
4572 if ${ac_cv_cxx_compiler_gnu+:} false; then :
4573 $as_echo_n "(cached) " >&6
4575 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4576 /* end confdefs.h. */
4589 if ac_fn_cxx_try_compile "$LINENO"; then :
4594 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4595 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
4598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
4599 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
4600 if test $ac_compiler_gnu = yes; then
4605 ac_test_CXXFLAGS=${CXXFLAGS+set}
4606 ac_save_CXXFLAGS=$CXXFLAGS
4607 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
4608 $as_echo_n "checking whether $CXX accepts -g... " >&6; }
4609 if ${ac_cv_prog_cxx_g+:} false; then :
4610 $as_echo_n "(cached) " >&6
4612 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
4613 ac_cxx_werror_flag=yes
4616 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4617 /* end confdefs.h. */
4627 if ac_fn_cxx_try_compile "$LINENO"; then :
4628 ac_cv_prog_cxx_g=yes
4631 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4632 /* end confdefs.h. */
4642 if ac_fn_cxx_try_compile "$LINENO"; then :
4645 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
4647 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4648 /* end confdefs.h. */
4658 if ac_fn_cxx_try_compile "$LINENO"; then :
4659 ac_cv_prog_cxx_g=yes
4661 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4663 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4665 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4666 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
4668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
4669 $as_echo "$ac_cv_prog_cxx_g" >&6; }
4670 if test "$ac_test_CXXFLAGS" = set; then
4671 CXXFLAGS=$ac_save_CXXFLAGS
4672 elif test $ac_cv_prog_cxx_g = yes; then
4673 if test "$GXX" = yes; then
4679 if test "$GXX" = yes; then
4686 ac_cpp='$CPP $CPPFLAGS'
4687 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4688 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4689 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4692 # Check if it's Intel's compiler, which (usually) pretends to be gcc,
4693 # but has idiosyncrasies of its own. We assume icc will define
4694 # __INTEL_COMPILER regardless of CFLAGS.
4696 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4697 /* end confdefs.h. */
4702 #ifndef __INTEL_COMPILER
4709 if ac_fn_c_try_compile "$LINENO"; then :
4714 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4716 # Check if it's Sun Studio compiler. We assume that
4717 # __SUNPRO_C will be defined for Sun Studio compilers
4718 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4719 /* end confdefs.h. */
4731 if ac_fn_c_try_compile "$LINENO"; then :
4736 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4744 # Checked early because subsequent tests depend on it.
4748 # Check whether --with-llvm was given.
4749 if test "${with_llvm+set}" = set; then :
4754 $as_echo "#define USE_LLVM 1" >>confdefs.h
4761 as_fn_error $? "no argument expected for --with-llvm option" "$LINENO" 5
4772 for ac_prog in gawk mawk nawk awk
4774 # Extract the first word of "$ac_prog", so it can be a program name with args.
4775 set dummy $ac_prog; ac_word=$2
4776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4777 $as_echo_n "checking for $ac_word... " >&6; }
4778 if ${ac_cv_prog_AWK+:} false; then :
4779 $as_echo_n "(cached) " >&6
4781 if test -n "$AWK"; then
4782 ac_cv_prog_AWK="$AWK" # Let the user override the test.
4784 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4788 test -z "$as_dir" && as_dir=.
4789 for ac_exec_ext in '' $ac_executable_extensions; do
4790 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4791 ac_cv_prog_AWK="$ac_prog"
4792 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4802 if test -n "$AWK"; then
4803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
4804 $as_echo "$AWK" >&6; }
4806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4807 $as_echo "no" >&6; }
4811 test -n "$AWK" && break
4814 if test "$with_llvm" = yes; then :
4820 if test -z "$LLVM_CONFIG"; then
4821 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
4823 # Extract the first word of "$ac_prog", so it can be a program name with args.
4824 set dummy $ac_prog; ac_word=$2
4825 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4826 $as_echo_n "checking for $ac_word... " >&6; }
4827 if ${ac_cv_path_LLVM_CONFIG+:} false; then :
4828 $as_echo_n "(cached) " >&6
4830 case $LLVM_CONFIG in
4832 ac_cv_path_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test with a path.
4835 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4839 test -z "$as_dir" && as_dir=.
4840 for ac_exec_ext in '' $ac_executable_extensions; do
4841 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4842 ac_cv_path_LLVM_CONFIG="$as_dir/$ac_word$ac_exec_ext"
4843 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4853 LLVM_CONFIG=$ac_cv_path_LLVM_CONFIG
4854 if test -n "$LLVM_CONFIG"; then
4855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
4856 $as_echo "$LLVM_CONFIG" >&6; }
4858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4859 $as_echo "no" >&6; }
4863 test -n "$LLVM_CONFIG" && break
4867 # Report the value of LLVM_CONFIG in configure's output in all cases.
4868 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LLVM_CONFIG" >&5
4869 $as_echo_n "checking for LLVM_CONFIG... " >&6; }
4870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
4871 $as_echo "$LLVM_CONFIG" >&6; }
4875 # no point continuing if llvm wasn't found
4876 if test -z "$LLVM_CONFIG"; then
4877 as_fn_error $? "llvm-config not found, but required when compiling --with-llvm, specify with LLVM_CONFIG=" "$LINENO" 5
4879 # check if detected $LLVM_CONFIG is executable
4880 pgac_llvm_version="$($LLVM_CONFIG --version 2> /dev/null || echo no)"
4881 if test "x$pgac_llvm_version" = "xno"; then
4882 as_fn_error $? "$LLVM_CONFIG does not work" "$LINENO" 5
4884 # and whether the version is supported
4885 if echo $pgac_llvm_version | $AWK -F '.' '{ if ($1 >= 4 || ($1 == 3 && $2 >= 9)) exit 1; else exit 0;}';then
4886 as_fn_error $? "$LLVM_CONFIG version is $pgac_llvm_version but at least 3.9 is required" "$LINENO" 5
4889 # need clang to create some bitcode files
4891 if test -z "$CLANG"; then
4892 for ac_prog in clang clang-7 clang-6.0 clang-5.0 clang-4.0 clang-3.9
4894 # Extract the first word of "$ac_prog", so it can be a program name with args.
4895 set dummy $ac_prog; ac_word=$2
4896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4897 $as_echo_n "checking for $ac_word... " >&6; }
4898 if ${ac_cv_path_CLANG+:} false; then :
4899 $as_echo_n "(cached) " >&6
4903 ac_cv_path_CLANG="$CLANG" # Let the user override the test with a path.
4906 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4910 test -z "$as_dir" && as_dir=.
4911 for ac_exec_ext in '' $ac_executable_extensions; do
4912 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4913 ac_cv_path_CLANG="$as_dir/$ac_word$ac_exec_ext"
4914 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4924 CLANG=$ac_cv_path_CLANG
4925 if test -n "$CLANG"; then
4926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CLANG" >&5
4927 $as_echo "$CLANG" >&6; }
4929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4930 $as_echo "no" >&6; }
4934 test -n "$CLANG" && break
4938 # Report the value of CLANG in configure's output in all cases.
4939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CLANG" >&5
4940 $as_echo_n "checking for CLANG... " >&6; }
4941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CLANG" >&5
4942 $as_echo "$CLANG" >&6; }
4945 if test -z "$CLANG"; then
4946 as_fn_error $? "clang not found, but required when compiling --with-llvm, specify with CLANG=" "$LINENO" 5
4948 # make sure clang is executable
4949 if test "x$($CLANG --version 2> /dev/null || echo no)" = "xno"; then
4950 as_fn_error $? "$CLANG does not work" "$LINENO" 5
4952 # Could check clang version, but it doesn't seem that
4953 # important. Systems with a new enough LLVM version are usually
4954 # going to have a decent clang version too. It's also not entirely
4955 # clear what the minimum version is.
4957 # Collect compiler flags necessary to build the LLVM dependent
4959 for pgac_option in `$LLVM_CONFIG --cppflags`; do
4960 case $pgac_option in
4961 -I*|-D*) LLVM_CPPFLAGS="$pgac_option $LLVM_CPPFLAGS";;
4965 for pgac_option in `$LLVM_CONFIG --ldflags`; do
4966 case $pgac_option in
4967 -L*) LDFLAGS="$LDFLAGS $pgac_option";;
4971 # ABI influencing options, standard influencing options
4972 for pgac_option in `$LLVM_CONFIG --cxxflags`; do
4973 case $pgac_option in
4974 -fno-rtti*) LLVM_CXXFLAGS="$LLVM_CXXFLAGS $pgac_option";;
4975 -std=*) LLVM_CXXFLAGS="$LLVM_CXXFLAGS $pgac_option";;
4979 # Look for components we're interested in, collect necessary
4980 # libs. As some components are optional, we can't just list all of
4981 # them as it'd raise an error.
4983 for pgac_component in `$LLVM_CONFIG --components`; do
4984 case $pgac_component in
4985 engine) pgac_components="$pgac_components $pgac_component";;
4986 debuginfodwarf) pgac_components="$pgac_components $pgac_component";;
4987 orcjit) pgac_components="$pgac_components $pgac_component";;
4988 passes) pgac_components="$pgac_components $pgac_component";;
4989 perfjitevents) pgac_components="$pgac_components $pgac_component";;
4993 # And then get the libraries that need to be linked in for the
4994 # selected components. They're large libraries, we only want to
4995 # link them into the LLVM using shared library.
4996 for pgac_option in `$LLVM_CONFIG --libs --system-libs $pgac_components`; do
4997 case $pgac_option in
4998 -l*) LLVM_LIBS="$LLVM_LIBS $pgac_option";;
5002 LLVM_BINPATH=`$LLVM_CONFIG --bindir`
5004 # LLVM_CONFIG, CLANG are already output via AC_ARG_VAR
5022 . "$srcdir/src/template/$template" || exit
5024 # C[XX]FLAGS are selected so:
5025 # If the user specifies something in the environment, that is used.
5026 # else: If the template file set something, that is used.
5027 # else: If coverage was enabled, don't set anything.
5028 # else: If the compiler is GCC, then we use -O2.
5029 # else: If the compiler is something else, then we use -O, unless debugging.
5031 if test "$ac_env_CFLAGS_set" = set; then
5032 CFLAGS=$ac_env_CFLAGS_value
5033 elif test "${CFLAGS+set}" = set; then
5034 : # (keep what template set)
5035 elif test "$enable_coverage" = yes; then
5036 : # no optimization by default
5037 elif test "$GCC" = yes; then
5040 # if the user selected debug mode, don't use -O
5041 if test "$enable_debug" != yes; then
5046 if test "$ac_env_CXXFLAGS_set" = set; then
5047 CXXFLAGS=$ac_env_CXXFLAGS_value
5048 elif test "${CXXFLAGS+set}" = set; then
5049 : # (keep what template set)
5050 elif test "$enable_coverage" = yes; then
5051 : # no optimization by default
5052 elif test "$GCC" = yes; then
5055 # if the user selected debug mode, don't use -O
5056 if test "$enable_debug" != yes; then
5061 # When generating bitcode (for inlining) we always want to use -O2
5062 # even when --enable-debug is specified. The bitcode it's not going to
5063 # be used for line-by-line debugging, and JIT inlining doesn't work
5064 # without at least -O1 (otherwise clang will emit 'noinline'
5065 # attributes everywhere), which is bad for testing. Still allow the
5066 # environment to override if done explicitly.
5067 if test "$ac_env_BITCODE_CFLAGS_set" = set; then
5068 BITCODE_CFLAGS=$ac_env_BITCODE_CFLAGS_value
5070 BITCODE_CFLAGS="-O2 $BITCODE_CFLAGS"
5072 if test "$ac_env_BITCODE_CXXFLAGS_set" = set; then
5073 BITCODE_CXXFLAGS=$ac_env_BITCODE_CXXFLAGS_value
5075 BITCODE_CXXFLAGS="-O2 $BITCODE_CXXFLAGS"
5078 # C[XX]FLAGS we determined above will be added back at the end
5081 user_CXXFLAGS=$CXXFLAGS
5083 user_BITCODE_CFLAGS=$BITCODE_CFLAGS
5085 user_BITCODE_CXXFLAGS=$BITCODE_CXXFLAGS
5088 # set CFLAGS_VECTOR from the environment, if available
5089 if test "$ac_env_CFLAGS_VECTOR_set" = set; then
5090 CFLAGS_VECTOR=$ac_env_CFLAGS_VECTOR_value
5093 # Some versions of GCC support some additional useful warning flags.
5094 # Check whether they are supported, and add them to CFLAGS if so.
5095 # ICC pretends to be GCC but it's lying; it doesn't support these flags,
5096 # but has its own. Also check other compiler-specific flags here.
5098 if test "$GCC" = yes -a "$ICC" = no; then
5099 CFLAGS="-Wall -Wmissing-prototypes -Wpointer-arith"
5100 CXXFLAGS="-Wall -Wpointer-arith"
5101 # These work in some but not all gcc versions
5103 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wdeclaration-after-statement, for CFLAGS" >&5
5104 $as_echo_n "checking whether ${CC} supports -Wdeclaration-after-statement, for CFLAGS... " >&6; }
5105 if ${pgac_cv_prog_CC_cflags__Wdeclaration_after_statement+:} false; then :
5106 $as_echo_n "(cached) " >&6
5108 pgac_save_CFLAGS=$CFLAGS
5111 CFLAGS="${CFLAGS} -Wdeclaration-after-statement"
5112 ac_save_c_werror_flag=$ac_c_werror_flag
5113 ac_c_werror_flag=yes
5114 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5115 /* end confdefs.h. */
5125 if ac_fn_c_try_compile "$LINENO"; then :
5126 pgac_cv_prog_CC_cflags__Wdeclaration_after_statement=yes
5128 pgac_cv_prog_CC_cflags__Wdeclaration_after_statement=no
5130 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5131 ac_c_werror_flag=$ac_save_c_werror_flag
5132 CFLAGS="$pgac_save_CFLAGS"
5135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wdeclaration_after_statement" >&5
5136 $as_echo "$pgac_cv_prog_CC_cflags__Wdeclaration_after_statement" >&6; }
5137 if test x"$pgac_cv_prog_CC_cflags__Wdeclaration_after_statement" = x"yes"; then
5138 CFLAGS="${CFLAGS} -Wdeclaration-after-statement"
5142 # -Wdeclaration-after-statement isn't applicable for C++
5144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wendif-labels, for CFLAGS" >&5
5145 $as_echo_n "checking whether ${CC} supports -Wendif-labels, for CFLAGS... " >&6; }
5146 if ${pgac_cv_prog_CC_cflags__Wendif_labels+:} false; then :
5147 $as_echo_n "(cached) " >&6
5149 pgac_save_CFLAGS=$CFLAGS
5152 CFLAGS="${CFLAGS} -Wendif-labels"
5153 ac_save_c_werror_flag=$ac_c_werror_flag
5154 ac_c_werror_flag=yes
5155 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5156 /* end confdefs.h. */
5166 if ac_fn_c_try_compile "$LINENO"; then :
5167 pgac_cv_prog_CC_cflags__Wendif_labels=yes
5169 pgac_cv_prog_CC_cflags__Wendif_labels=no
5171 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5172 ac_c_werror_flag=$ac_save_c_werror_flag
5173 CFLAGS="$pgac_save_CFLAGS"
5176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wendif_labels" >&5
5177 $as_echo "$pgac_cv_prog_CC_cflags__Wendif_labels" >&6; }
5178 if test x"$pgac_cv_prog_CC_cflags__Wendif_labels" = x"yes"; then
5179 CFLAGS="${CFLAGS} -Wendif-labels"
5183 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -Wendif-labels, for CXXFLAGS" >&5
5184 $as_echo_n "checking whether ${CXX} supports -Wendif-labels, for CXXFLAGS... " >&6; }
5185 if ${pgac_cv_prog_CXX_cxxflags__Wendif_labels+:} false; then :
5186 $as_echo_n "(cached) " >&6
5188 pgac_save_CXXFLAGS=$CXXFLAGS
5191 CXXFLAGS="${CXXFLAGS} -Wendif-labels"
5192 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5193 ac_cxx_werror_flag=yes
5195 ac_cpp='$CXXCPP $CPPFLAGS'
5196 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5197 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5198 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5200 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5201 /* end confdefs.h. */
5211 if ac_fn_cxx_try_compile "$LINENO"; then :
5212 pgac_cv_prog_CXX_cxxflags__Wendif_labels=yes
5214 pgac_cv_prog_CXX_cxxflags__Wendif_labels=no
5216 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5218 ac_cpp='$CPP $CPPFLAGS'
5219 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5220 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5221 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5223 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5224 CXXFLAGS="$pgac_save_CXXFLAGS"
5225 CXX="$pgac_save_CXX"
5227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__Wendif_labels" >&5
5228 $as_echo "$pgac_cv_prog_CXX_cxxflags__Wendif_labels" >&6; }
5229 if test x"$pgac_cv_prog_CXX_cxxflags__Wendif_labels" = x"yes"; then
5230 CXXFLAGS="${CXXFLAGS} -Wendif-labels"
5235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wmissing-format-attribute, for CFLAGS" >&5
5236 $as_echo_n "checking whether ${CC} supports -Wmissing-format-attribute, for CFLAGS... " >&6; }
5237 if ${pgac_cv_prog_CC_cflags__Wmissing_format_attribute+:} false; then :
5238 $as_echo_n "(cached) " >&6
5240 pgac_save_CFLAGS=$CFLAGS
5243 CFLAGS="${CFLAGS} -Wmissing-format-attribute"
5244 ac_save_c_werror_flag=$ac_c_werror_flag
5245 ac_c_werror_flag=yes
5246 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5247 /* end confdefs.h. */
5257 if ac_fn_c_try_compile "$LINENO"; then :
5258 pgac_cv_prog_CC_cflags__Wmissing_format_attribute=yes
5260 pgac_cv_prog_CC_cflags__Wmissing_format_attribute=no
5262 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5263 ac_c_werror_flag=$ac_save_c_werror_flag
5264 CFLAGS="$pgac_save_CFLAGS"
5267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wmissing_format_attribute" >&5
5268 $as_echo "$pgac_cv_prog_CC_cflags__Wmissing_format_attribute" >&6; }
5269 if test x"$pgac_cv_prog_CC_cflags__Wmissing_format_attribute" = x"yes"; then
5270 CFLAGS="${CFLAGS} -Wmissing-format-attribute"
5274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -Wmissing-format-attribute, for CXXFLAGS" >&5
5275 $as_echo_n "checking whether ${CXX} supports -Wmissing-format-attribute, for CXXFLAGS... " >&6; }
5276 if ${pgac_cv_prog_CXX_cxxflags__Wmissing_format_attribute+:} false; then :
5277 $as_echo_n "(cached) " >&6
5279 pgac_save_CXXFLAGS=$CXXFLAGS
5282 CXXFLAGS="${CXXFLAGS} -Wmissing-format-attribute"
5283 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5284 ac_cxx_werror_flag=yes
5286 ac_cpp='$CXXCPP $CPPFLAGS'
5287 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5288 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5289 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5291 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5292 /* end confdefs.h. */
5302 if ac_fn_cxx_try_compile "$LINENO"; then :
5303 pgac_cv_prog_CXX_cxxflags__Wmissing_format_attribute=yes
5305 pgac_cv_prog_CXX_cxxflags__Wmissing_format_attribute=no
5307 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5309 ac_cpp='$CPP $CPPFLAGS'
5310 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5311 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5312 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5314 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5315 CXXFLAGS="$pgac_save_CXXFLAGS"
5316 CXX="$pgac_save_CXX"
5318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__Wmissing_format_attribute" >&5
5319 $as_echo "$pgac_cv_prog_CXX_cxxflags__Wmissing_format_attribute" >&6; }
5320 if test x"$pgac_cv_prog_CXX_cxxflags__Wmissing_format_attribute" = x"yes"; then
5321 CXXFLAGS="${CXXFLAGS} -Wmissing-format-attribute"
5325 # This was included in -Wall/-Wformat in older GCC versions
5327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wformat-security, for CFLAGS" >&5
5328 $as_echo_n "checking whether ${CC} supports -Wformat-security, for CFLAGS... " >&6; }
5329 if ${pgac_cv_prog_CC_cflags__Wformat_security+:} false; then :
5330 $as_echo_n "(cached) " >&6
5332 pgac_save_CFLAGS=$CFLAGS
5335 CFLAGS="${CFLAGS} -Wformat-security"
5336 ac_save_c_werror_flag=$ac_c_werror_flag
5337 ac_c_werror_flag=yes
5338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5339 /* end confdefs.h. */
5349 if ac_fn_c_try_compile "$LINENO"; then :
5350 pgac_cv_prog_CC_cflags__Wformat_security=yes
5352 pgac_cv_prog_CC_cflags__Wformat_security=no
5354 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5355 ac_c_werror_flag=$ac_save_c_werror_flag
5356 CFLAGS="$pgac_save_CFLAGS"
5359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wformat_security" >&5
5360 $as_echo "$pgac_cv_prog_CC_cflags__Wformat_security" >&6; }
5361 if test x"$pgac_cv_prog_CC_cflags__Wformat_security" = x"yes"; then
5362 CFLAGS="${CFLAGS} -Wformat-security"
5366 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -Wformat-security, for CXXFLAGS" >&5
5367 $as_echo_n "checking whether ${CXX} supports -Wformat-security, for CXXFLAGS... " >&6; }
5368 if ${pgac_cv_prog_CXX_cxxflags__Wformat_security+:} false; then :
5369 $as_echo_n "(cached) " >&6
5371 pgac_save_CXXFLAGS=$CXXFLAGS
5374 CXXFLAGS="${CXXFLAGS} -Wformat-security"
5375 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5376 ac_cxx_werror_flag=yes
5378 ac_cpp='$CXXCPP $CPPFLAGS'
5379 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5380 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5381 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5383 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5384 /* end confdefs.h. */
5394 if ac_fn_cxx_try_compile "$LINENO"; then :
5395 pgac_cv_prog_CXX_cxxflags__Wformat_security=yes
5397 pgac_cv_prog_CXX_cxxflags__Wformat_security=no
5399 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5401 ac_cpp='$CPP $CPPFLAGS'
5402 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5403 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5404 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5406 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5407 CXXFLAGS="$pgac_save_CXXFLAGS"
5408 CXX="$pgac_save_CXX"
5410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__Wformat_security" >&5
5411 $as_echo "$pgac_cv_prog_CXX_cxxflags__Wformat_security" >&6; }
5412 if test x"$pgac_cv_prog_CXX_cxxflags__Wformat_security" = x"yes"; then
5413 CXXFLAGS="${CXXFLAGS} -Wformat-security"
5417 # Disable strict-aliasing rules; needed for gcc 3.3+
5419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -fno-strict-aliasing, for CFLAGS" >&5
5420 $as_echo_n "checking whether ${CC} supports -fno-strict-aliasing, for CFLAGS... " >&6; }
5421 if ${pgac_cv_prog_CC_cflags__fno_strict_aliasing+:} false; then :
5422 $as_echo_n "(cached) " >&6
5424 pgac_save_CFLAGS=$CFLAGS
5427 CFLAGS="${CFLAGS} -fno-strict-aliasing"
5428 ac_save_c_werror_flag=$ac_c_werror_flag
5429 ac_c_werror_flag=yes
5430 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5431 /* end confdefs.h. */
5441 if ac_fn_c_try_compile "$LINENO"; then :
5442 pgac_cv_prog_CC_cflags__fno_strict_aliasing=yes
5444 pgac_cv_prog_CC_cflags__fno_strict_aliasing=no
5446 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5447 ac_c_werror_flag=$ac_save_c_werror_flag
5448 CFLAGS="$pgac_save_CFLAGS"
5451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__fno_strict_aliasing" >&5
5452 $as_echo "$pgac_cv_prog_CC_cflags__fno_strict_aliasing" >&6; }
5453 if test x"$pgac_cv_prog_CC_cflags__fno_strict_aliasing" = x"yes"; then
5454 CFLAGS="${CFLAGS} -fno-strict-aliasing"
5458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -fno-strict-aliasing, for CXXFLAGS" >&5
5459 $as_echo_n "checking whether ${CXX} supports -fno-strict-aliasing, for CXXFLAGS... " >&6; }
5460 if ${pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing+:} false; then :
5461 $as_echo_n "(cached) " >&6
5463 pgac_save_CXXFLAGS=$CXXFLAGS
5466 CXXFLAGS="${CXXFLAGS} -fno-strict-aliasing"
5467 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5468 ac_cxx_werror_flag=yes
5470 ac_cpp='$CXXCPP $CPPFLAGS'
5471 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5472 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5473 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5475 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5476 /* end confdefs.h. */
5486 if ac_fn_cxx_try_compile "$LINENO"; then :
5487 pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing=yes
5489 pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing=no
5491 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5493 ac_cpp='$CPP $CPPFLAGS'
5494 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5495 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5496 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5498 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5499 CXXFLAGS="$pgac_save_CXXFLAGS"
5500 CXX="$pgac_save_CXX"
5502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing" >&5
5503 $as_echo "$pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing" >&6; }
5504 if test x"$pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing" = x"yes"; then
5505 CXXFLAGS="${CXXFLAGS} -fno-strict-aliasing"
5509 # Disable optimizations that assume no overflow; needed for gcc 4.3+
5511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -fwrapv, for CFLAGS" >&5
5512 $as_echo_n "checking whether ${CC} supports -fwrapv, for CFLAGS... " >&6; }
5513 if ${pgac_cv_prog_CC_cflags__fwrapv+:} false; then :
5514 $as_echo_n "(cached) " >&6
5516 pgac_save_CFLAGS=$CFLAGS
5519 CFLAGS="${CFLAGS} -fwrapv"
5520 ac_save_c_werror_flag=$ac_c_werror_flag
5521 ac_c_werror_flag=yes
5522 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5523 /* end confdefs.h. */
5533 if ac_fn_c_try_compile "$LINENO"; then :
5534 pgac_cv_prog_CC_cflags__fwrapv=yes
5536 pgac_cv_prog_CC_cflags__fwrapv=no
5538 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5539 ac_c_werror_flag=$ac_save_c_werror_flag
5540 CFLAGS="$pgac_save_CFLAGS"
5543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__fwrapv" >&5
5544 $as_echo "$pgac_cv_prog_CC_cflags__fwrapv" >&6; }
5545 if test x"$pgac_cv_prog_CC_cflags__fwrapv" = x"yes"; then
5546 CFLAGS="${CFLAGS} -fwrapv"
5550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -fwrapv, for CXXFLAGS" >&5
5551 $as_echo_n "checking whether ${CXX} supports -fwrapv, for CXXFLAGS... " >&6; }
5552 if ${pgac_cv_prog_CXX_cxxflags__fwrapv+:} false; then :
5553 $as_echo_n "(cached) " >&6
5555 pgac_save_CXXFLAGS=$CXXFLAGS
5558 CXXFLAGS="${CXXFLAGS} -fwrapv"
5559 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5560 ac_cxx_werror_flag=yes
5562 ac_cpp='$CXXCPP $CPPFLAGS'
5563 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5564 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5565 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5567 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5568 /* end confdefs.h. */
5578 if ac_fn_cxx_try_compile "$LINENO"; then :
5579 pgac_cv_prog_CXX_cxxflags__fwrapv=yes
5581 pgac_cv_prog_CXX_cxxflags__fwrapv=no
5583 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5585 ac_cpp='$CPP $CPPFLAGS'
5586 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5587 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5588 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5590 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5591 CXXFLAGS="$pgac_save_CXXFLAGS"
5592 CXX="$pgac_save_CXX"
5594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__fwrapv" >&5
5595 $as_echo "$pgac_cv_prog_CXX_cxxflags__fwrapv" >&6; }
5596 if test x"$pgac_cv_prog_CXX_cxxflags__fwrapv" = x"yes"; then
5597 CXXFLAGS="${CXXFLAGS} -fwrapv"
5601 # Disable FP optimizations that cause various errors on gcc 4.5+ or maybe 4.6+
5603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -fexcess-precision=standard, for CFLAGS" >&5
5604 $as_echo_n "checking whether ${CC} supports -fexcess-precision=standard, for CFLAGS... " >&6; }
5605 if ${pgac_cv_prog_CC_cflags__fexcess_precision_standard+:} false; then :
5606 $as_echo_n "(cached) " >&6
5608 pgac_save_CFLAGS=$CFLAGS
5611 CFLAGS="${CFLAGS} -fexcess-precision=standard"
5612 ac_save_c_werror_flag=$ac_c_werror_flag
5613 ac_c_werror_flag=yes
5614 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5615 /* end confdefs.h. */
5625 if ac_fn_c_try_compile "$LINENO"; then :
5626 pgac_cv_prog_CC_cflags__fexcess_precision_standard=yes
5628 pgac_cv_prog_CC_cflags__fexcess_precision_standard=no
5630 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5631 ac_c_werror_flag=$ac_save_c_werror_flag
5632 CFLAGS="$pgac_save_CFLAGS"
5635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__fexcess_precision_standard" >&5
5636 $as_echo "$pgac_cv_prog_CC_cflags__fexcess_precision_standard" >&6; }
5637 if test x"$pgac_cv_prog_CC_cflags__fexcess_precision_standard" = x"yes"; then
5638 CFLAGS="${CFLAGS} -fexcess-precision=standard"
5642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -fexcess-precision=standard, for CXXFLAGS" >&5
5643 $as_echo_n "checking whether ${CXX} supports -fexcess-precision=standard, for CXXFLAGS... " >&6; }
5644 if ${pgac_cv_prog_CXX_cxxflags__fexcess_precision_standard+:} false; then :
5645 $as_echo_n "(cached) " >&6
5647 pgac_save_CXXFLAGS=$CXXFLAGS
5650 CXXFLAGS="${CXXFLAGS} -fexcess-precision=standard"
5651 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5652 ac_cxx_werror_flag=yes
5654 ac_cpp='$CXXCPP $CPPFLAGS'
5655 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5656 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5657 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5659 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5660 /* end confdefs.h. */
5670 if ac_fn_cxx_try_compile "$LINENO"; then :
5671 pgac_cv_prog_CXX_cxxflags__fexcess_precision_standard=yes
5673 pgac_cv_prog_CXX_cxxflags__fexcess_precision_standard=no
5675 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5677 ac_cpp='$CPP $CPPFLAGS'
5678 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5679 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5680 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5682 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5683 CXXFLAGS="$pgac_save_CXXFLAGS"
5684 CXX="$pgac_save_CXX"
5686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__fexcess_precision_standard" >&5
5687 $as_echo "$pgac_cv_prog_CXX_cxxflags__fexcess_precision_standard" >&6; }
5688 if test x"$pgac_cv_prog_CXX_cxxflags__fexcess_precision_standard" = x"yes"; then
5689 CXXFLAGS="${CXXFLAGS} -fexcess-precision=standard"
5693 # Optimization flags for specific files that benefit from vectorization
5694 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -funroll-loops, for CFLAGS_VECTOR" >&5
5695 $as_echo_n "checking whether ${CC} supports -funroll-loops, for CFLAGS_VECTOR... " >&6; }
5696 if ${pgac_cv_prog_CC_cflags__funroll_loops+:} false; then :
5697 $as_echo_n "(cached) " >&6
5699 pgac_save_CFLAGS=$CFLAGS
5702 CFLAGS="${CFLAGS_VECTOR} -funroll-loops"
5703 ac_save_c_werror_flag=$ac_c_werror_flag
5704 ac_c_werror_flag=yes
5705 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5706 /* end confdefs.h. */
5716 if ac_fn_c_try_compile "$LINENO"; then :
5717 pgac_cv_prog_CC_cflags__funroll_loops=yes
5719 pgac_cv_prog_CC_cflags__funroll_loops=no
5721 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5722 ac_c_werror_flag=$ac_save_c_werror_flag
5723 CFLAGS="$pgac_save_CFLAGS"
5726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__funroll_loops" >&5
5727 $as_echo "$pgac_cv_prog_CC_cflags__funroll_loops" >&6; }
5728 if test x"$pgac_cv_prog_CC_cflags__funroll_loops" = x"yes"; then
5729 CFLAGS_VECTOR="${CFLAGS_VECTOR} -funroll-loops"
5733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -ftree-vectorize, for CFLAGS_VECTOR" >&5
5734 $as_echo_n "checking whether ${CC} supports -ftree-vectorize, for CFLAGS_VECTOR... " >&6; }
5735 if ${pgac_cv_prog_CC_cflags__ftree_vectorize+:} false; then :
5736 $as_echo_n "(cached) " >&6
5738 pgac_save_CFLAGS=$CFLAGS
5741 CFLAGS="${CFLAGS_VECTOR} -ftree-vectorize"
5742 ac_save_c_werror_flag=$ac_c_werror_flag
5743 ac_c_werror_flag=yes
5744 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5745 /* end confdefs.h. */
5755 if ac_fn_c_try_compile "$LINENO"; then :
5756 pgac_cv_prog_CC_cflags__ftree_vectorize=yes
5758 pgac_cv_prog_CC_cflags__ftree_vectorize=no
5760 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5761 ac_c_werror_flag=$ac_save_c_werror_flag
5762 CFLAGS="$pgac_save_CFLAGS"
5765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__ftree_vectorize" >&5
5766 $as_echo "$pgac_cv_prog_CC_cflags__ftree_vectorize" >&6; }
5767 if test x"$pgac_cv_prog_CC_cflags__ftree_vectorize" = x"yes"; then
5768 CFLAGS_VECTOR="${CFLAGS_VECTOR} -ftree-vectorize"
5772 # We want to suppress clang's unhelpful unused-command-line-argument warnings
5773 # but gcc won't complain about unrecognized -Wno-foo switches, so we have to
5774 # test for the positive form and if that works, add the negative form
5776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wunused-command-line-argument, for NOT_THE_CFLAGS" >&5
5777 $as_echo_n "checking whether ${CC} supports -Wunused-command-line-argument, for NOT_THE_CFLAGS... " >&6; }
5778 if ${pgac_cv_prog_CC_cflags__Wunused_command_line_argument+:} false; then :
5779 $as_echo_n "(cached) " >&6
5781 pgac_save_CFLAGS=$CFLAGS
5784 CFLAGS="${NOT_THE_CFLAGS} -Wunused-command-line-argument"
5785 ac_save_c_werror_flag=$ac_c_werror_flag
5786 ac_c_werror_flag=yes
5787 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5788 /* end confdefs.h. */
5798 if ac_fn_c_try_compile "$LINENO"; then :
5799 pgac_cv_prog_CC_cflags__Wunused_command_line_argument=yes
5801 pgac_cv_prog_CC_cflags__Wunused_command_line_argument=no
5803 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5804 ac_c_werror_flag=$ac_save_c_werror_flag
5805 CFLAGS="$pgac_save_CFLAGS"
5808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wunused_command_line_argument" >&5
5809 $as_echo "$pgac_cv_prog_CC_cflags__Wunused_command_line_argument" >&6; }
5810 if test x"$pgac_cv_prog_CC_cflags__Wunused_command_line_argument" = x"yes"; then
5811 NOT_THE_CFLAGS="${NOT_THE_CFLAGS} -Wunused-command-line-argument"
5815 if test -n "$NOT_THE_CFLAGS"; then
5816 CFLAGS="$CFLAGS -Wno-unused-command-line-argument"
5818 # Similarly disable useless truncation warnings from gcc 8+
5820 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wformat-truncation, for NOT_THE_CFLAGS" >&5
5821 $as_echo_n "checking whether ${CC} supports -Wformat-truncation, for NOT_THE_CFLAGS... " >&6; }
5822 if ${pgac_cv_prog_CC_cflags__Wformat_truncation+:} false; then :
5823 $as_echo_n "(cached) " >&6
5825 pgac_save_CFLAGS=$CFLAGS
5828 CFLAGS="${NOT_THE_CFLAGS} -Wformat-truncation"
5829 ac_save_c_werror_flag=$ac_c_werror_flag
5830 ac_c_werror_flag=yes
5831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5832 /* end confdefs.h. */
5842 if ac_fn_c_try_compile "$LINENO"; then :
5843 pgac_cv_prog_CC_cflags__Wformat_truncation=yes
5845 pgac_cv_prog_CC_cflags__Wformat_truncation=no
5847 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5848 ac_c_werror_flag=$ac_save_c_werror_flag
5849 CFLAGS="$pgac_save_CFLAGS"
5852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wformat_truncation" >&5
5853 $as_echo "$pgac_cv_prog_CC_cflags__Wformat_truncation" >&6; }
5854 if test x"$pgac_cv_prog_CC_cflags__Wformat_truncation" = x"yes"; then
5855 NOT_THE_CFLAGS="${NOT_THE_CFLAGS} -Wformat-truncation"
5859 if test -n "$NOT_THE_CFLAGS"; then
5860 CFLAGS="$CFLAGS -Wno-format-truncation"
5863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wstringop-truncation, for NOT_THE_CFLAGS" >&5
5864 $as_echo_n "checking whether ${CC} supports -Wstringop-truncation, for NOT_THE_CFLAGS... " >&6; }
5865 if ${pgac_cv_prog_CC_cflags__Wstringop_truncation+:} false; then :
5866 $as_echo_n "(cached) " >&6
5868 pgac_save_CFLAGS=$CFLAGS
5871 CFLAGS="${NOT_THE_CFLAGS} -Wstringop-truncation"
5872 ac_save_c_werror_flag=$ac_c_werror_flag
5873 ac_c_werror_flag=yes
5874 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5875 /* end confdefs.h. */
5885 if ac_fn_c_try_compile "$LINENO"; then :
5886 pgac_cv_prog_CC_cflags__Wstringop_truncation=yes
5888 pgac_cv_prog_CC_cflags__Wstringop_truncation=no
5890 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5891 ac_c_werror_flag=$ac_save_c_werror_flag
5892 CFLAGS="$pgac_save_CFLAGS"
5895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wstringop_truncation" >&5
5896 $as_echo "$pgac_cv_prog_CC_cflags__Wstringop_truncation" >&6; }
5897 if test x"$pgac_cv_prog_CC_cflags__Wstringop_truncation" = x"yes"; then
5898 NOT_THE_CFLAGS="${NOT_THE_CFLAGS} -Wstringop-truncation"
5902 if test -n "$NOT_THE_CFLAGS"; then
5903 CFLAGS="$CFLAGS -Wno-stringop-truncation"
5905 elif test "$ICC" = yes; then
5906 # Intel's compiler has a bug/misoptimization in checking for
5907 # division by NAN (NaN == 0), -mp1 fixes it, so add it to the CFLAGS.
5909 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -mp1, for CFLAGS" >&5
5910 $as_echo_n "checking whether ${CC} supports -mp1, for CFLAGS... " >&6; }
5911 if ${pgac_cv_prog_CC_cflags__mp1+:} false; then :
5912 $as_echo_n "(cached) " >&6
5914 pgac_save_CFLAGS=$CFLAGS
5917 CFLAGS="${CFLAGS} -mp1"
5918 ac_save_c_werror_flag=$ac_c_werror_flag
5919 ac_c_werror_flag=yes
5920 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5921 /* end confdefs.h. */
5931 if ac_fn_c_try_compile "$LINENO"; then :
5932 pgac_cv_prog_CC_cflags__mp1=yes
5934 pgac_cv_prog_CC_cflags__mp1=no
5936 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5937 ac_c_werror_flag=$ac_save_c_werror_flag
5938 CFLAGS="$pgac_save_CFLAGS"
5941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__mp1" >&5
5942 $as_echo "$pgac_cv_prog_CC_cflags__mp1" >&6; }
5943 if test x"$pgac_cv_prog_CC_cflags__mp1" = x"yes"; then
5944 CFLAGS="${CFLAGS} -mp1"
5948 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -mp1, for CXXFLAGS" >&5
5949 $as_echo_n "checking whether ${CXX} supports -mp1, for CXXFLAGS... " >&6; }
5950 if ${pgac_cv_prog_CXX_cxxflags__mp1+:} false; then :
5951 $as_echo_n "(cached) " >&6
5953 pgac_save_CXXFLAGS=$CXXFLAGS
5956 CXXFLAGS="${CXXFLAGS} -mp1"
5957 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5958 ac_cxx_werror_flag=yes
5960 ac_cpp='$CXXCPP $CPPFLAGS'
5961 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5962 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5963 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5965 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5966 /* end confdefs.h. */
5976 if ac_fn_cxx_try_compile "$LINENO"; then :
5977 pgac_cv_prog_CXX_cxxflags__mp1=yes
5979 pgac_cv_prog_CXX_cxxflags__mp1=no
5981 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5983 ac_cpp='$CPP $CPPFLAGS'
5984 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5985 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5986 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5988 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5989 CXXFLAGS="$pgac_save_CXXFLAGS"
5990 CXX="$pgac_save_CXX"
5992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__mp1" >&5
5993 $as_echo "$pgac_cv_prog_CXX_cxxflags__mp1" >&6; }
5994 if test x"$pgac_cv_prog_CXX_cxxflags__mp1" = x"yes"; then
5995 CXXFLAGS="${CXXFLAGS} -mp1"
5999 # Make sure strict aliasing is off (though this is said to be the default)
6001 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -fno-strict-aliasing, for CFLAGS" >&5
6002 $as_echo_n "checking whether ${CC} supports -fno-strict-aliasing, for CFLAGS... " >&6; }
6003 if ${pgac_cv_prog_CC_cflags__fno_strict_aliasing+:} false; then :
6004 $as_echo_n "(cached) " >&6
6006 pgac_save_CFLAGS=$CFLAGS
6009 CFLAGS="${CFLAGS} -fno-strict-aliasing"
6010 ac_save_c_werror_flag=$ac_c_werror_flag
6011 ac_c_werror_flag=yes
6012 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6013 /* end confdefs.h. */
6023 if ac_fn_c_try_compile "$LINENO"; then :
6024 pgac_cv_prog_CC_cflags__fno_strict_aliasing=yes
6026 pgac_cv_prog_CC_cflags__fno_strict_aliasing=no
6028 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6029 ac_c_werror_flag=$ac_save_c_werror_flag
6030 CFLAGS="$pgac_save_CFLAGS"
6033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__fno_strict_aliasing" >&5
6034 $as_echo "$pgac_cv_prog_CC_cflags__fno_strict_aliasing" >&6; }
6035 if test x"$pgac_cv_prog_CC_cflags__fno_strict_aliasing" = x"yes"; then
6036 CFLAGS="${CFLAGS} -fno-strict-aliasing"
6040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -fno-strict-aliasing, for CXXFLAGS" >&5
6041 $as_echo_n "checking whether ${CXX} supports -fno-strict-aliasing, for CXXFLAGS... " >&6; }
6042 if ${pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing+:} false; then :
6043 $as_echo_n "(cached) " >&6
6045 pgac_save_CXXFLAGS=$CXXFLAGS
6048 CXXFLAGS="${CXXFLAGS} -fno-strict-aliasing"
6049 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6050 ac_cxx_werror_flag=yes
6052 ac_cpp='$CXXCPP $CPPFLAGS'
6053 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6054 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6055 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6057 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6058 /* end confdefs.h. */
6068 if ac_fn_cxx_try_compile "$LINENO"; then :
6069 pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing=yes
6071 pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing=no
6073 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6075 ac_cpp='$CPP $CPPFLAGS'
6076 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6077 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6078 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6080 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6081 CXXFLAGS="$pgac_save_CXXFLAGS"
6082 CXX="$pgac_save_CXX"
6084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing" >&5
6085 $as_echo "$pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing" >&6; }
6086 if test x"$pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing" = x"yes"; then
6087 CXXFLAGS="${CXXFLAGS} -fno-strict-aliasing"
6091 elif test "$PORTNAME" = "aix"; then
6092 # AIX's xlc has to have strict aliasing turned off too
6094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -qnoansialias, for CFLAGS" >&5
6095 $as_echo_n "checking whether ${CC} supports -qnoansialias, for CFLAGS... " >&6; }
6096 if ${pgac_cv_prog_CC_cflags__qnoansialias+:} false; then :
6097 $as_echo_n "(cached) " >&6
6099 pgac_save_CFLAGS=$CFLAGS
6102 CFLAGS="${CFLAGS} -qnoansialias"
6103 ac_save_c_werror_flag=$ac_c_werror_flag
6104 ac_c_werror_flag=yes
6105 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6106 /* end confdefs.h. */
6116 if ac_fn_c_try_compile "$LINENO"; then :
6117 pgac_cv_prog_CC_cflags__qnoansialias=yes
6119 pgac_cv_prog_CC_cflags__qnoansialias=no
6121 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6122 ac_c_werror_flag=$ac_save_c_werror_flag
6123 CFLAGS="$pgac_save_CFLAGS"
6126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__qnoansialias" >&5
6127 $as_echo "$pgac_cv_prog_CC_cflags__qnoansialias" >&6; }
6128 if test x"$pgac_cv_prog_CC_cflags__qnoansialias" = x"yes"; then
6129 CFLAGS="${CFLAGS} -qnoansialias"
6133 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -qnoansialias, for CXXFLAGS" >&5
6134 $as_echo_n "checking whether ${CXX} supports -qnoansialias, for CXXFLAGS... " >&6; }
6135 if ${pgac_cv_prog_CXX_cxxflags__qnoansialias+:} false; then :
6136 $as_echo_n "(cached) " >&6
6138 pgac_save_CXXFLAGS=$CXXFLAGS
6141 CXXFLAGS="${CXXFLAGS} -qnoansialias"
6142 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6143 ac_cxx_werror_flag=yes
6145 ac_cpp='$CXXCPP $CPPFLAGS'
6146 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6147 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6148 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6150 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6151 /* end confdefs.h. */
6161 if ac_fn_cxx_try_compile "$LINENO"; then :
6162 pgac_cv_prog_CXX_cxxflags__qnoansialias=yes
6164 pgac_cv_prog_CXX_cxxflags__qnoansialias=no
6166 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6168 ac_cpp='$CPP $CPPFLAGS'
6169 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6170 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6171 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6173 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6174 CXXFLAGS="$pgac_save_CXXFLAGS"
6175 CXX="$pgac_save_CXX"
6177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__qnoansialias" >&5
6178 $as_echo "$pgac_cv_prog_CXX_cxxflags__qnoansialias" >&6; }
6179 if test x"$pgac_cv_prog_CXX_cxxflags__qnoansialias" = x"yes"; then
6180 CXXFLAGS="${CXXFLAGS} -qnoansialias"
6185 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -qlonglong, for CFLAGS" >&5
6186 $as_echo_n "checking whether ${CC} supports -qlonglong, for CFLAGS... " >&6; }
6187 if ${pgac_cv_prog_CC_cflags__qlonglong+:} false; then :
6188 $as_echo_n "(cached) " >&6
6190 pgac_save_CFLAGS=$CFLAGS
6193 CFLAGS="${CFLAGS} -qlonglong"
6194 ac_save_c_werror_flag=$ac_c_werror_flag
6195 ac_c_werror_flag=yes
6196 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6197 /* end confdefs.h. */
6207 if ac_fn_c_try_compile "$LINENO"; then :
6208 pgac_cv_prog_CC_cflags__qlonglong=yes
6210 pgac_cv_prog_CC_cflags__qlonglong=no
6212 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6213 ac_c_werror_flag=$ac_save_c_werror_flag
6214 CFLAGS="$pgac_save_CFLAGS"
6217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__qlonglong" >&5
6218 $as_echo "$pgac_cv_prog_CC_cflags__qlonglong" >&6; }
6219 if test x"$pgac_cv_prog_CC_cflags__qlonglong" = x"yes"; then
6220 CFLAGS="${CFLAGS} -qlonglong"
6224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -qlonglong, for CXXFLAGS" >&5
6225 $as_echo_n "checking whether ${CXX} supports -qlonglong, for CXXFLAGS... " >&6; }
6226 if ${pgac_cv_prog_CXX_cxxflags__qlonglong+:} false; then :
6227 $as_echo_n "(cached) " >&6
6229 pgac_save_CXXFLAGS=$CXXFLAGS
6232 CXXFLAGS="${CXXFLAGS} -qlonglong"
6233 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6234 ac_cxx_werror_flag=yes
6236 ac_cpp='$CXXCPP $CPPFLAGS'
6237 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6238 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6239 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6241 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6242 /* end confdefs.h. */
6252 if ac_fn_cxx_try_compile "$LINENO"; then :
6253 pgac_cv_prog_CXX_cxxflags__qlonglong=yes
6255 pgac_cv_prog_CXX_cxxflags__qlonglong=no
6257 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6259 ac_cpp='$CPP $CPPFLAGS'
6260 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6261 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6262 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6264 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6265 CXXFLAGS="$pgac_save_CXXFLAGS"
6266 CXX="$pgac_save_CXX"
6268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__qlonglong" >&5
6269 $as_echo "$pgac_cv_prog_CXX_cxxflags__qlonglong" >&6; }
6270 if test x"$pgac_cv_prog_CXX_cxxflags__qlonglong" = x"yes"; then
6271 CXXFLAGS="${CXXFLAGS} -qlonglong"
6275 elif test "$PORTNAME" = "hpux"; then
6276 # On some versions of HP-UX, libm functions do not set errno by default.
6277 # Fix that by using +Olibmerrno if the compiler recognizes it.
6279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports +Olibmerrno, for CFLAGS" >&5
6280 $as_echo_n "checking whether ${CC} supports +Olibmerrno, for CFLAGS... " >&6; }
6281 if ${pgac_cv_prog_CC_cflags_pOlibmerrno+:} false; then :
6282 $as_echo_n "(cached) " >&6
6284 pgac_save_CFLAGS=$CFLAGS
6287 CFLAGS="${CFLAGS} +Olibmerrno"
6288 ac_save_c_werror_flag=$ac_c_werror_flag
6289 ac_c_werror_flag=yes
6290 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6291 /* end confdefs.h. */
6301 if ac_fn_c_try_compile "$LINENO"; then :
6302 pgac_cv_prog_CC_cflags_pOlibmerrno=yes
6304 pgac_cv_prog_CC_cflags_pOlibmerrno=no
6306 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6307 ac_c_werror_flag=$ac_save_c_werror_flag
6308 CFLAGS="$pgac_save_CFLAGS"
6311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags_pOlibmerrno" >&5
6312 $as_echo "$pgac_cv_prog_CC_cflags_pOlibmerrno" >&6; }
6313 if test x"$pgac_cv_prog_CC_cflags_pOlibmerrno" = x"yes"; then
6314 CFLAGS="${CFLAGS} +Olibmerrno"
6318 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports +Olibmerrno, for CXXFLAGS" >&5
6319 $as_echo_n "checking whether ${CXX} supports +Olibmerrno, for CXXFLAGS... " >&6; }
6320 if ${pgac_cv_prog_CXX_cxxflags_pOlibmerrno+:} false; then :
6321 $as_echo_n "(cached) " >&6
6323 pgac_save_CXXFLAGS=$CXXFLAGS
6326 CXXFLAGS="${CXXFLAGS} +Olibmerrno"
6327 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6328 ac_cxx_werror_flag=yes
6330 ac_cpp='$CXXCPP $CPPFLAGS'
6331 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6332 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6333 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6335 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6336 /* end confdefs.h. */
6346 if ac_fn_cxx_try_compile "$LINENO"; then :
6347 pgac_cv_prog_CXX_cxxflags_pOlibmerrno=yes
6349 pgac_cv_prog_CXX_cxxflags_pOlibmerrno=no
6351 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6353 ac_cpp='$CPP $CPPFLAGS'
6354 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6355 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6356 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6358 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6359 CXXFLAGS="$pgac_save_CXXFLAGS"
6360 CXX="$pgac_save_CXX"
6362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags_pOlibmerrno" >&5
6363 $as_echo "$pgac_cv_prog_CXX_cxxflags_pOlibmerrno" >&6; }
6364 if test x"$pgac_cv_prog_CXX_cxxflags_pOlibmerrno" = x"yes"; then
6365 CXXFLAGS="${CXXFLAGS} +Olibmerrno"
6371 CFLAGS_VECTOR=$CFLAGS_VECTOR
6374 # Determine flags used to emit bitcode for JIT inlining. Need to test
6375 # for behaviour changing compiler flags, to keep compatibility with
6376 # compiler used for normal postgres code.
6377 if test "$with_llvm" = yes ; then
6378 CLANGXX="$CLANG -xc++"
6380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CLANG} supports -fno-strict-aliasing, for BITCODE_CFLAGS" >&5
6381 $as_echo_n "checking whether ${CLANG} supports -fno-strict-aliasing, for BITCODE_CFLAGS... " >&6; }
6382 if ${pgac_cv_prog_CLANG_cflags__fno_strict_aliasing+:} false; then :
6383 $as_echo_n "(cached) " >&6
6385 pgac_save_CFLAGS=$CFLAGS
6388 CFLAGS="${BITCODE_CFLAGS} -fno-strict-aliasing"
6389 ac_save_c_werror_flag=$ac_c_werror_flag
6390 ac_c_werror_flag=yes
6391 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6392 /* end confdefs.h. */
6402 if ac_fn_c_try_compile "$LINENO"; then :
6403 pgac_cv_prog_CLANG_cflags__fno_strict_aliasing=yes
6405 pgac_cv_prog_CLANG_cflags__fno_strict_aliasing=no
6407 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6408 ac_c_werror_flag=$ac_save_c_werror_flag
6409 CFLAGS="$pgac_save_CFLAGS"
6412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CLANG_cflags__fno_strict_aliasing" >&5
6413 $as_echo "$pgac_cv_prog_CLANG_cflags__fno_strict_aliasing" >&6; }
6414 if test x"$pgac_cv_prog_CLANG_cflags__fno_strict_aliasing" = x"yes"; then
6415 BITCODE_CFLAGS="${BITCODE_CFLAGS} -fno-strict-aliasing"
6418 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CLANGXX} supports -fno-strict-aliasing, for BITCODE_CXXFLAGS" >&5
6419 $as_echo_n "checking whether ${CLANGXX} supports -fno-strict-aliasing, for BITCODE_CXXFLAGS... " >&6; }
6420 if ${pgac_cv_prog_CLANGXX_cxxflags__fno_strict_aliasing+:} false; then :
6421 $as_echo_n "(cached) " >&6
6423 pgac_save_CXXFLAGS=$CXXFLAGS
6426 CXXFLAGS="${BITCODE_CXXFLAGS} -fno-strict-aliasing"
6427 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6428 ac_cxx_werror_flag=yes
6430 ac_cpp='$CXXCPP $CPPFLAGS'
6431 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6432 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6433 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6435 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6436 /* end confdefs.h. */
6446 if ac_fn_cxx_try_compile "$LINENO"; then :
6447 pgac_cv_prog_CLANGXX_cxxflags__fno_strict_aliasing=yes
6449 pgac_cv_prog_CLANGXX_cxxflags__fno_strict_aliasing=no
6451 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6453 ac_cpp='$CPP $CPPFLAGS'
6454 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6455 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6456 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6458 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6459 CXXFLAGS="$pgac_save_CXXFLAGS"
6460 CXX="$pgac_save_CXX"
6462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CLANGXX_cxxflags__fno_strict_aliasing" >&5
6463 $as_echo "$pgac_cv_prog_CLANGXX_cxxflags__fno_strict_aliasing" >&6; }
6464 if test x"$pgac_cv_prog_CLANGXX_cxxflags__fno_strict_aliasing" = x"yes"; then
6465 BITCODE_CXXFLAGS="${BITCODE_CXXFLAGS} -fno-strict-aliasing"
6468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CLANG} supports -fwrapv, for BITCODE_CFLAGS" >&5
6469 $as_echo_n "checking whether ${CLANG} supports -fwrapv, for BITCODE_CFLAGS... " >&6; }
6470 if ${pgac_cv_prog_CLANG_cflags__fwrapv+:} false; then :
6471 $as_echo_n "(cached) " >&6
6473 pgac_save_CFLAGS=$CFLAGS
6476 CFLAGS="${BITCODE_CFLAGS} -fwrapv"
6477 ac_save_c_werror_flag=$ac_c_werror_flag
6478 ac_c_werror_flag=yes
6479 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6480 /* end confdefs.h. */
6490 if ac_fn_c_try_compile "$LINENO"; then :
6491 pgac_cv_prog_CLANG_cflags__fwrapv=yes
6493 pgac_cv_prog_CLANG_cflags__fwrapv=no
6495 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6496 ac_c_werror_flag=$ac_save_c_werror_flag
6497 CFLAGS="$pgac_save_CFLAGS"
6500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CLANG_cflags__fwrapv" >&5
6501 $as_echo "$pgac_cv_prog_CLANG_cflags__fwrapv" >&6; }
6502 if test x"$pgac_cv_prog_CLANG_cflags__fwrapv" = x"yes"; then
6503 BITCODE_CFLAGS="${BITCODE_CFLAGS} -fwrapv"
6506 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CLANGXX} supports -fwrapv, for BITCODE_CXXFLAGS" >&5
6507 $as_echo_n "checking whether ${CLANGXX} supports -fwrapv, for BITCODE_CXXFLAGS... " >&6; }
6508 if ${pgac_cv_prog_CLANGXX_cxxflags__fwrapv+:} false; then :
6509 $as_echo_n "(cached) " >&6
6511 pgac_save_CXXFLAGS=$CXXFLAGS
6514 CXXFLAGS="${BITCODE_CXXFLAGS} -fwrapv"
6515 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6516 ac_cxx_werror_flag=yes
6518 ac_cpp='$CXXCPP $CPPFLAGS'
6519 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6520 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6521 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6524 /* end confdefs.h. */
6534 if ac_fn_cxx_try_compile "$LINENO"; then :
6535 pgac_cv_prog_CLANGXX_cxxflags__fwrapv=yes
6537 pgac_cv_prog_CLANGXX_cxxflags__fwrapv=no
6539 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6541 ac_cpp='$CPP $CPPFLAGS'
6542 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6543 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6544 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6546 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6547 CXXFLAGS="$pgac_save_CXXFLAGS"
6548 CXX="$pgac_save_CXX"
6550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CLANGXX_cxxflags__fwrapv" >&5
6551 $as_echo "$pgac_cv_prog_CLANGXX_cxxflags__fwrapv" >&6; }
6552 if test x"$pgac_cv_prog_CLANGXX_cxxflags__fwrapv" = x"yes"; then
6553 BITCODE_CXXFLAGS="${BITCODE_CXXFLAGS} -fwrapv"
6556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CLANG} supports -fexcess-precision=standard, for BITCODE_CFLAGS" >&5
6557 $as_echo_n "checking whether ${CLANG} supports -fexcess-precision=standard, for BITCODE_CFLAGS... " >&6; }
6558 if ${pgac_cv_prog_CLANG_cflags__fexcess_precision_standard+:} false; then :
6559 $as_echo_n "(cached) " >&6
6561 pgac_save_CFLAGS=$CFLAGS
6564 CFLAGS="${BITCODE_CFLAGS} -fexcess-precision=standard"
6565 ac_save_c_werror_flag=$ac_c_werror_flag
6566 ac_c_werror_flag=yes
6567 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6568 /* end confdefs.h. */
6578 if ac_fn_c_try_compile "$LINENO"; then :
6579 pgac_cv_prog_CLANG_cflags__fexcess_precision_standard=yes
6581 pgac_cv_prog_CLANG_cflags__fexcess_precision_standard=no
6583 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6584 ac_c_werror_flag=$ac_save_c_werror_flag
6585 CFLAGS="$pgac_save_CFLAGS"
6588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CLANG_cflags__fexcess_precision_standard" >&5
6589 $as_echo "$pgac_cv_prog_CLANG_cflags__fexcess_precision_standard" >&6; }
6590 if test x"$pgac_cv_prog_CLANG_cflags__fexcess_precision_standard" = x"yes"; then
6591 BITCODE_CFLAGS="${BITCODE_CFLAGS} -fexcess-precision=standard"
6594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CLANGXX} supports -fexcess-precision=standard, for BITCODE_CXXFLAGS" >&5
6595 $as_echo_n "checking whether ${CLANGXX} supports -fexcess-precision=standard, for BITCODE_CXXFLAGS... " >&6; }
6596 if ${pgac_cv_prog_CLANGXX_cxxflags__fexcess_precision_standard+:} false; then :
6597 $as_echo_n "(cached) " >&6
6599 pgac_save_CXXFLAGS=$CXXFLAGS
6602 CXXFLAGS="${BITCODE_CXXFLAGS} -fexcess-precision=standard"
6603 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6604 ac_cxx_werror_flag=yes
6606 ac_cpp='$CXXCPP $CPPFLAGS'
6607 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6608 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6609 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6611 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6612 /* end confdefs.h. */
6622 if ac_fn_cxx_try_compile "$LINENO"; then :
6623 pgac_cv_prog_CLANGXX_cxxflags__fexcess_precision_standard=yes
6625 pgac_cv_prog_CLANGXX_cxxflags__fexcess_precision_standard=no
6627 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6629 ac_cpp='$CPP $CPPFLAGS'
6630 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6631 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6632 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6634 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6635 CXXFLAGS="$pgac_save_CXXFLAGS"
6636 CXX="$pgac_save_CXX"
6638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CLANGXX_cxxflags__fexcess_precision_standard" >&5
6639 $as_echo "$pgac_cv_prog_CLANGXX_cxxflags__fexcess_precision_standard" >&6; }
6640 if test x"$pgac_cv_prog_CLANGXX_cxxflags__fexcess_precision_standard" = x"yes"; then
6641 BITCODE_CXXFLAGS="${BITCODE_CXXFLAGS} -fexcess-precision=standard"
6646 # supply -g if --enable-debug
6647 if test "$enable_debug" = yes && test "$ac_cv_prog_cc_g" = yes; then
6651 if test "$enable_debug" = yes && test "$ac_cv_prog_cxx_g" = yes; then
6652 CXXFLAGS="$CXXFLAGS -g"
6655 # enable code coverage if --enable-coverage
6656 if test "$enable_coverage" = yes; then
6657 if test "$GCC" = yes; then
6658 CFLAGS="$CFLAGS -fprofile-arcs -ftest-coverage"
6659 CXXFLAGS="$CXXFLAGS -fprofile-arcs -ftest-coverage"
6661 as_fn_error $? "--enable-coverage is supported only when using GCC" "$LINENO" 5
6665 # enable profiling if --enable-profiling
6666 if test "$enable_profiling" = yes && test "$ac_cv_prog_cc_g" = yes; then
6667 if test "$GCC" = yes; then
6669 $as_echo "#define PROFILE_PID_DIR 1" >>confdefs.h
6671 CFLAGS="$CFLAGS -pg $PLATFORM_PROFILE_FLAGS"
6672 CXXFLAGS="$CXXFLAGS -pg $PLATFORM_PROFILE_FLAGS"
6674 as_fn_error $? "--enable-profiling is supported only when using GCC" "$LINENO" 5
6678 # We already have this in Makefile.win32, but configure needs it too
6679 if test "$PORTNAME" = "win32"; then
6680 CPPFLAGS="$CPPFLAGS -I$srcdir/src/include/port/win32 -DEXEC_BACKEND"
6683 # Now that we're done automatically adding stuff to C[XX]FLAGS, put back the
6684 # user-specified flags (if any) at the end. This lets users override
6685 # the automatic additions.
6686 CFLAGS="$CFLAGS $user_CFLAGS"
6687 CXXFLAGS="$CXXFLAGS $user_CXXFLAGS"
6688 BITCODE_CFLAGS="$BITCODE_CFLAGS $user_BITCODE_CFLAGS"
6689 BITCODE_CXXFLAGS="$BITCODE_CXXFLAGS $user_BITCODE_CXXFLAGS"
6691 BITCODE_CFLAGS=$BITCODE_CFLAGS
6693 BITCODE_CXXFLAGS=$BITCODE_CXXFLAGS
6696 # Check if the compiler still works with the final flag settings
6697 # (note, we're not checking that for CXX, which is optional)
6698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler still works" >&5
6699 $as_echo_n "checking whether the C compiler still works... " >&6; }
6700 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6701 /* end confdefs.h. */
6711 if ac_fn_c_try_link "$LINENO"; then :
6712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6713 $as_echo "yes" >&6; }
6715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6716 $as_echo "no" >&6; }
6717 as_fn_error $? "cannot proceed" "$LINENO" 5
6719 rm -f core conftest.err conftest.$ac_objext \
6720 conftest$ac_exeext conftest.$ac_ext
6722 # Defend against gcc -ffast-math
6723 if test "$GCC" = yes; then
6724 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6725 /* end confdefs.h. */
6730 #ifdef __FAST_MATH__
6737 if ac_fn_c_try_compile "$LINENO"; then :
6740 as_fn_error $? "do not put -ffast-math in CFLAGS" "$LINENO" 5
6742 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6745 # Defend against clang being used on x86-32 without SSE2 enabled. As current
6746 # versions of clang do not understand -fexcess-precision=standard, the use of
6747 # x87 floating point operations leads to problems like isinf possibly returning
6748 # false for a value that is infinite when converted from the 80bit register to
6749 # the 8byte memory representation.
6751 # Only perform the test if the compiler doesn't understand
6752 # -fexcess-precision=standard, that way a potentially fixed compiler will work
6754 if test "$pgac_cv_prog_CC_cflags__fexcess_precision_standard" = no; then
6755 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6756 /* end confdefs.h. */
6762 #if defined(__clang__) && defined(__i386__) && !defined(__SSE2_MATH__)
6770 if ac_fn_c_try_compile "$LINENO"; then :
6773 as_fn_error $? "Compiling PostgreSQL with clang, on 32bit x86, requires SSE2 support. Use -msse2 or use gcc." "$LINENO" 5
6775 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6779 ac_cpp='$CPP $CPPFLAGS'
6780 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6781 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6782 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
6784 $as_echo_n "checking how to run the C preprocessor... " >&6; }
6785 # On Suns, sometimes $CPP names a directory.
6786 if test -n "$CPP" && test -d "$CPP"; then
6789 if test -z "$CPP"; then
6790 if ${ac_cv_prog_CPP+:} false; then :
6791 $as_echo_n "(cached) " >&6
6793 # Double quotes because CPP needs to be expanded
6794 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
6797 for ac_c_preproc_warn_flag in '' yes
6799 # Use a header file that comes with gcc, so configuring glibc
6800 # with a fresh cross-compiler works.
6801 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6802 # <limits.h> exists even on freestanding compilers.
6803 # On the NeXT, cc -E runs the code through the compiler's parser,
6804 # not just through cpp. "Syntax error" is here to catch this case.
6805 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6806 /* end confdefs.h. */
6808 # include <limits.h>
6810 # include <assert.h>
6814 if ac_fn_c_try_cpp "$LINENO"; then :
6817 # Broken: fails on valid input.
6820 rm -f conftest.err conftest.i conftest.$ac_ext
6822 # OK, works on sane cases. Now check whether nonexistent headers
6823 # can be detected and how.
6824 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6825 /* end confdefs.h. */
6826 #include <ac_nonexistent.h>
6828 if ac_fn_c_try_cpp "$LINENO"; then :
6829 # Broken: success on invalid input.
6832 # Passes both tests.
6836 rm -f conftest.err conftest.i conftest.$ac_ext
6839 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6840 rm -f conftest.i conftest.err conftest.$ac_ext
6841 if $ac_preproc_ok; then :
6853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
6854 $as_echo "$CPP" >&6; }
6856 for ac_c_preproc_warn_flag in '' yes
6858 # Use a header file that comes with gcc, so configuring glibc
6859 # with a fresh cross-compiler works.
6860 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6861 # <limits.h> exists even on freestanding compilers.
6862 # On the NeXT, cc -E runs the code through the compiler's parser,
6863 # not just through cpp. "Syntax error" is here to catch this case.
6864 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6865 /* end confdefs.h. */
6867 # include <limits.h>
6869 # include <assert.h>
6873 if ac_fn_c_try_cpp "$LINENO"; then :
6876 # Broken: fails on valid input.
6879 rm -f conftest.err conftest.i conftest.$ac_ext
6881 # OK, works on sane cases. Now check whether nonexistent headers
6882 # can be detected and how.
6883 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6884 /* end confdefs.h. */
6885 #include <ac_nonexistent.h>
6887 if ac_fn_c_try_cpp "$LINENO"; then :
6888 # Broken: success on invalid input.
6891 # Passes both tests.
6895 rm -f conftest.err conftest.i conftest.$ac_ext
6898 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6899 rm -f conftest.i conftest.err conftest.$ac_ext
6900 if $ac_preproc_ok; then :
6903 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6904 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6905 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
6906 See \`config.log' for more details" "$LINENO" 5; }
6910 ac_cpp='$CPP $CPPFLAGS'
6911 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6912 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6913 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6919 # Set up TAS assembly code if needed; the template file has now had its
6920 # chance to request this.
6922 ac_config_links="$ac_config_links src/backend/port/tas.s:src/backend/port/tas/${tas_file}"
6925 if test "$need_tas" = yes ; then
6934 # Automatic dependency tracking
6938 # Check whether --enable-depend was given.
6939 if test "${enable_depend+set}" = set; then :
6940 enableval=$enable_depend;
6949 as_fn_error $? "no argument expected for --enable-depend option" "$LINENO" 5
6963 # Enable assert checks
6967 # Check whether --enable-cassert was given.
6968 if test "${enable_cassert+set}" = set; then :
6969 enableval=$enable_cassert;
6973 $as_echo "#define USE_ASSERT_CHECKING 1" >>confdefs.h
6980 as_fn_error $? "no argument expected for --enable-cassert option" "$LINENO" 5
6993 # Include directories
6996 IFS="${IFS}${PATH_SEPARATOR}"
6997 # SRCH_INC comes from the template file
6998 for dir in $with_includes $SRCH_INC; do
6999 if test -d "$dir"; then
7000 INCLUDES="$INCLUDES -I$dir"
7002 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** Include directory $dir does not exist." >&5
7003 $as_echo "$as_me: WARNING: *** Include directory $dir does not exist." >&2;}
7011 # Library directories
7014 IFS="${IFS}${PATH_SEPARATOR}"
7015 # LIBRARY_DIRS comes from command line, SRCH_LIB from template file.
7016 for dir in $LIBRARY_DIRS $SRCH_LIB; do
7017 if test -d "$dir"; then
7018 LIBDIRS="$LIBDIRS -L$dir"
7020 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** Library directory $dir does not exist." >&5
7021 $as_echo "$as_me: WARNING: *** Library directory $dir does not exist." >&2;}
7027 # Enable thread-safe client libraries
7029 { $as_echo "$as_me:${as_lineno-$LINENO}: checking allow thread-safe client libraries" >&5
7030 $as_echo_n "checking allow thread-safe client libraries... " >&6; }
7033 # Check whether --enable-thread-safety was given.
7034 if test "${enable_thread_safety+set}" = set; then :
7035 enableval=$enable_thread_safety;
7044 as_fn_error $? "no argument expected for --enable-thread-safety option" "$LINENO" 5
7049 enable_thread_safety=yes
7054 if test "$enable_thread_safety" = yes; then
7056 $as_echo "#define ENABLE_THREAD_SAFETY 1" >>confdefs.h
7059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_thread_safety" >&5
7060 $as_echo "$enable_thread_safety" >&6; }
7066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with ICU support" >&5
7067 $as_echo_n "checking whether to build with ICU support... " >&6; }
7071 # Check whether --with-icu was given.
7072 if test "${with_icu+set}" = set; then :
7077 $as_echo "#define USE_ICU 1" >>confdefs.h
7084 as_fn_error $? "no argument expected for --with-icu option" "$LINENO" 5
7094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_icu" >&5
7095 $as_echo "$with_icu" >&6; }
7098 if test "$with_icu" = yes; then
7106 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
7107 if test -n "$ac_tool_prefix"; then
7108 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
7109 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
7110 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7111 $as_echo_n "checking for $ac_word... " >&6; }
7112 if ${ac_cv_path_PKG_CONFIG+:} false; then :
7113 $as_echo_n "(cached) " >&6
7117 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
7120 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7124 test -z "$as_dir" && as_dir=.
7125 for ac_exec_ext in '' $ac_executable_extensions; do
7126 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7127 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
7128 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7138 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
7139 if test -n "$PKG_CONFIG"; then
7140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
7141 $as_echo "$PKG_CONFIG" >&6; }
7143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7144 $as_echo "no" >&6; }
7149 if test -z "$ac_cv_path_PKG_CONFIG"; then
7150 ac_pt_PKG_CONFIG=$PKG_CONFIG
7151 # Extract the first word of "pkg-config", so it can be a program name with args.
7152 set dummy pkg-config; ac_word=$2
7153 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7154 $as_echo_n "checking for $ac_word... " >&6; }
7155 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
7156 $as_echo_n "(cached) " >&6
7158 case $ac_pt_PKG_CONFIG in
7160 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
7163 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7167 test -z "$as_dir" && as_dir=.
7168 for ac_exec_ext in '' $ac_executable_extensions; do
7169 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7170 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
7171 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7181 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
7182 if test -n "$ac_pt_PKG_CONFIG"; then
7183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
7184 $as_echo "$ac_pt_PKG_CONFIG" >&6; }
7186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7187 $as_echo "no" >&6; }
7190 if test "x$ac_pt_PKG_CONFIG" = x; then
7193 case $cross_compiling:$ac_tool_warned in
7195 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7196 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7197 ac_tool_warned=yes ;;
7199 PKG_CONFIG=$ac_pt_PKG_CONFIG
7202 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
7206 if test -n "$PKG_CONFIG"; then
7207 _pkg_min_version=0.9.0
7208 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
7209 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
7210 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
7211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7212 $as_echo "yes" >&6; }
7214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7215 $as_echo "no" >&6; }
7221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icu-uc icu-i18n" >&5
7222 $as_echo_n "checking for icu-uc icu-i18n... " >&6; }
7224 if test -n "$ICU_CFLAGS"; then
7225 pkg_cv_ICU_CFLAGS="$ICU_CFLAGS"
7226 elif test -n "$PKG_CONFIG"; then
7227 if test -n "$PKG_CONFIG" && \
7228 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"icu-uc icu-i18n\""; } >&5
7229 ($PKG_CONFIG --exists --print-errors "icu-uc icu-i18n") 2>&5
7231 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7232 test $ac_status = 0; }; then
7233 pkg_cv_ICU_CFLAGS=`$PKG_CONFIG --cflags "icu-uc icu-i18n" 2>/dev/null`
7234 test "x$?" != "x0" && pkg_failed=yes
7241 if test -n "$ICU_LIBS"; then
7242 pkg_cv_ICU_LIBS="$ICU_LIBS"
7243 elif test -n "$PKG_CONFIG"; then
7244 if test -n "$PKG_CONFIG" && \
7245 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"icu-uc icu-i18n\""; } >&5
7246 ($PKG_CONFIG --exists --print-errors "icu-uc icu-i18n") 2>&5
7248 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7249 test $ac_status = 0; }; then
7250 pkg_cv_ICU_LIBS=`$PKG_CONFIG --libs "icu-uc icu-i18n" 2>/dev/null`
7251 test "x$?" != "x0" && pkg_failed=yes
7261 if test $pkg_failed = yes; then
7262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7263 $as_echo "no" >&6; }
7265 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
7266 _pkg_short_errors_supported=yes
7268 _pkg_short_errors_supported=no
7270 if test $_pkg_short_errors_supported = yes; then
7271 ICU_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "icu-uc icu-i18n" 2>&1`
7273 ICU_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "icu-uc icu-i18n" 2>&1`
7275 # Put the nasty error message in config.log where it belongs
7276 echo "$ICU_PKG_ERRORS" >&5
7278 as_fn_error $? "Package requirements (icu-uc icu-i18n) were not met:
7282 Consider adjusting the PKG_CONFIG_PATH environment variable if you
7283 installed software in a non-standard prefix.
7285 Alternatively, you may set the environment variables ICU_CFLAGS
7286 and ICU_LIBS to avoid the need to call pkg-config.
7287 See the pkg-config man page for more details." "$LINENO" 5
7288 elif test $pkg_failed = untried; then
7289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7290 $as_echo "no" >&6; }
7291 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
7292 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
7293 as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it
7294 is in your PATH or set the PKG_CONFIG environment variable to the full
7297 Alternatively, you may set the environment variables ICU_CFLAGS
7298 and ICU_LIBS to avoid the need to call pkg-config.
7299 See the pkg-config man page for more details.
7301 To get pkg-config, see <http://pkg-config.freedesktop.org/>.
7302 See \`config.log' for more details" "$LINENO" 5; }
7304 ICU_CFLAGS=$pkg_cv_ICU_CFLAGS
7305 ICU_LIBS=$pkg_cv_ICU_LIBS
7306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7307 $as_echo "yes" >&6; }
7313 # Optionally build Tcl modules (PL/Tcl)
7315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with Tcl" >&5
7316 $as_echo_n "checking whether to build with Tcl... " >&6; }
7320 # Check whether --with-tcl was given.
7321 if test "${with_tcl+set}" = set; then :
7331 as_fn_error $? "no argument expected for --with-tcl option" "$LINENO" 5
7341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_tcl" >&5
7342 $as_echo "$with_tcl" >&6; }
7345 # We see if the path to the Tcl/Tk configuration scripts is specified.
7346 # This will override the use of tclsh to find the paths to search.
7351 # Check whether --with-tclconfig was given.
7352 if test "${with_tclconfig+set}" = set; then :
7353 withval=$with_tclconfig;
7356 as_fn_error $? "argument required for --with-tclconfig option" "$LINENO" 5
7359 as_fn_error $? "argument required for --with-tclconfig option" "$LINENO" 5
7371 # Optionally build Perl modules (PL/Perl)
7373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build Perl modules" >&5
7374 $as_echo_n "checking whether to build Perl modules... " >&6; }
7378 # Check whether --with-perl was given.
7379 if test "${with_perl+set}" = set; then :
7389 as_fn_error $? "no argument expected for --with-perl option" "$LINENO" 5
7399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_perl" >&5
7400 $as_echo "$with_perl" >&6; }
7404 # Optionally build Python modules (PL/Python)
7406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build Python modules" >&5
7407 $as_echo_n "checking whether to build Python modules... " >&6; }
7411 # Check whether --with-python was given.
7412 if test "${with_python+set}" = set; then :
7413 withval=$with_python;
7422 as_fn_error $? "no argument expected for --with-python option" "$LINENO" 5
7432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_python" >&5
7433 $as_echo "$with_python" >&6; }
7439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with GSSAPI support" >&5
7440 $as_echo_n "checking whether to build with GSSAPI support... " >&6; }
7444 # Check whether --with-gssapi was given.
7445 if test "${with_gssapi+set}" = set; then :
7446 withval=$with_gssapi;
7451 $as_echo "#define ENABLE_GSS 1" >>confdefs.h
7453 krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
7460 as_fn_error $? "no argument expected for --with-gssapi option" "$LINENO" 5
7470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_gssapi" >&5
7471 $as_echo "$with_gssapi" >&6; }
7479 # Kerberos configuration parameters
7484 # Check whether --with-krb-srvnam was given.
7485 if test "${with_krb_srvnam+set}" = set; then :
7486 withval=$with_krb_srvnam;
7489 as_fn_error $? "argument required for --with-krb-srvnam option" "$LINENO" 5
7492 as_fn_error $? "argument required for --with-krb-srvnam option" "$LINENO" 5
7500 with_krb_srvnam="postgres"
7506 cat >>confdefs.h <<_ACEOF
7507 #define PG_KRB_SRVNAM "$with_krb_srvnam"
7515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with PAM support" >&5
7516 $as_echo_n "checking whether to build with PAM support... " >&6; }
7520 # Check whether --with-pam was given.
7521 if test "${with_pam+set}" = set; then :
7526 $as_echo "#define USE_PAM 1" >>confdefs.h
7533 as_fn_error $? "no argument expected for --with-pam option" "$LINENO" 5
7543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_pam" >&5
7544 $as_echo "$with_pam" >&6; }
7550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with BSD Authentication support" >&5
7551 $as_echo_n "checking whether to build with BSD Authentication support... " >&6; }
7555 # Check whether --with-bsd-auth was given.
7556 if test "${with_bsd_auth+set}" = set; then :
7557 withval=$with_bsd_auth;
7561 $as_echo "#define USE_BSD_AUTH 1" >>confdefs.h
7568 as_fn_error $? "no argument expected for --with-bsd-auth option" "$LINENO" 5
7578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_bsd_auth" >&5
7579 $as_echo "$with_bsd_auth" >&6; }
7585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with LDAP support" >&5
7586 $as_echo_n "checking whether to build with LDAP support... " >&6; }
7590 # Check whether --with-ldap was given.
7591 if test "${with_ldap+set}" = set; then :
7596 $as_echo "#define USE_LDAP 1" >>confdefs.h
7603 as_fn_error $? "no argument expected for --with-ldap option" "$LINENO" 5
7613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_ldap" >&5
7614 $as_echo "$with_ldap" >&6; }
7621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with Bonjour support" >&5
7622 $as_echo_n "checking whether to build with Bonjour support... " >&6; }
7626 # Check whether --with-bonjour was given.
7627 if test "${with_bonjour+set}" = set; then :
7628 withval=$with_bonjour;
7632 $as_echo "#define USE_BONJOUR 1" >>confdefs.h
7639 as_fn_error $? "no argument expected for --with-bonjour option" "$LINENO" 5
7649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_bonjour" >&5
7650 $as_echo "$with_bonjour" >&6; }
7656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with OpenSSL support" >&5
7657 $as_echo_n "checking whether to build with OpenSSL support... " >&6; }
7661 # Check whether --with-openssl was given.
7662 if test "${with_openssl+set}" = set; then :
7663 withval=$with_openssl;
7667 $as_echo "#define USE_OPENSSL 1" >>confdefs.h
7674 as_fn_error $? "no argument expected for --with-openssl option" "$LINENO" 5
7684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_openssl" >&5
7685 $as_echo "$with_openssl" >&6; }
7691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with SELinux support" >&5
7692 $as_echo_n "checking whether to build with SELinux support... " >&6; }
7696 # Check whether --with-selinux was given.
7697 if test "${with_selinux+set}" = set; then :
7698 withval=$with_selinux;
7707 as_fn_error $? "no argument expected for --with-selinux option" "$LINENO" 5
7718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_selinux" >&5
7719 $as_echo "$with_selinux" >&6; }
7724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with systemd support" >&5
7725 $as_echo_n "checking whether to build with systemd support... " >&6; }
7729 # Check whether --with-systemd was given.
7730 if test "${with_systemd+set}" = set; then :
7731 withval=$with_systemd;
7735 $as_echo "#define USE_SYSTEMD 1" >>confdefs.h
7742 as_fn_error $? "no argument expected for --with-systemd option" "$LINENO" 5
7753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_systemd" >&5
7754 $as_echo "$with_systemd" >&6; }
7762 # Check whether --with-readline was given.
7763 if test "${with_readline+set}" = set; then :
7764 withval=$with_readline;
7773 as_fn_error $? "no argument expected for --with-readline option" "$LINENO" 5
7783 # readline on MinGW has problems with backslashes in psql and other bugs.
7784 # This is particularly a problem with non-US code pages.
7785 # Therefore disable its use until we understand the cause. 2004-07-20
7786 if test "$PORTNAME" = "win32"; then
7787 if test "$with_readline" = yes; then
7788 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** Readline does not work on MinGW --- disabling" >&5
7789 $as_echo "$as_me: WARNING: *** Readline does not work on MinGW --- disabling" >&2;}
7801 # Check whether --with-libedit-preferred was given.
7802 if test "${with_libedit_preferred+set}" = set; then :
7803 withval=$with_libedit_preferred;
7812 as_fn_error $? "no argument expected for --with-libedit-preferred option" "$LINENO" 5
7817 with_libedit_preferred=no
7827 # There are at least three UUID libraries in common use: the FreeBSD/NetBSD
7828 # library, the e2fsprogs libuuid (now part of util-linux-ng), and the OSSP
7829 # UUID library. More than one of these might be present on a given platform,
7830 # so we make the user say which one she wants.
7835 # Check whether --with-uuid was given.
7836 if test "${with_uuid+set}" = set; then :
7840 as_fn_error $? "argument required for --with-uuid option" "$LINENO" 5
7843 as_fn_error $? "argument required for --with-uuid option" "$LINENO" 5
7853 if test x"$with_uuid" = x"" ; then
7859 # Check whether --with-ossp-uuid was given.
7860 if test "${with_ossp_uuid+set}" = set; then :
7861 withval=$with_ossp_uuid;
7870 as_fn_error $? "no argument expected for --with-ossp-uuid option" "$LINENO" 5
7880 if test "$with_ossp_uuid" = yes ; then
7884 if test "$with_uuid" = bsd ; then
7886 $as_echo "#define HAVE_UUID_BSD 1" >>confdefs.h
7888 UUID_EXTRA_OBJS="md5.o sha1.o"
7889 elif test "$with_uuid" = e2fs ; then
7891 $as_echo "#define HAVE_UUID_E2FS 1" >>confdefs.h
7893 UUID_EXTRA_OBJS="md5.o sha1.o"
7894 elif test "$with_uuid" = ossp ; then
7896 $as_echo "#define HAVE_UUID_OSSP 1" >>confdefs.h
7899 elif test "$with_uuid" = no ; then
7902 as_fn_error $? "--with-uuid must specify one of bsd, e2fs, or ossp" "$LINENO" 5
7914 # Check whether --with-libxml was given.
7915 if test "${with_libxml+set}" = set; then :
7916 withval=$with_libxml;
7920 $as_echo "#define USE_LIBXML 1" >>confdefs.h
7927 as_fn_error $? "no argument expected for --with-libxml option" "$LINENO" 5
7938 if test "$with_libxml" = yes ; then
7939 if test -z "$XML2_CONFIG"; then
7940 for ac_prog in xml2-config
7942 # Extract the first word of "$ac_prog", so it can be a program name with args.
7943 set dummy $ac_prog; ac_word=$2
7944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7945 $as_echo_n "checking for $ac_word... " >&6; }
7946 if ${ac_cv_path_XML2_CONFIG+:} false; then :
7947 $as_echo_n "(cached) " >&6
7949 case $XML2_CONFIG in
7951 ac_cv_path_XML2_CONFIG="$XML2_CONFIG" # Let the user override the test with a path.
7954 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7958 test -z "$as_dir" && as_dir=.
7959 for ac_exec_ext in '' $ac_executable_extensions; do
7960 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7961 ac_cv_path_XML2_CONFIG="$as_dir/$ac_word$ac_exec_ext"
7962 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7972 XML2_CONFIG=$ac_cv_path_XML2_CONFIG
7973 if test -n "$XML2_CONFIG"; then
7974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XML2_CONFIG" >&5
7975 $as_echo "$XML2_CONFIG" >&6; }
7977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7978 $as_echo "no" >&6; }
7982 test -n "$XML2_CONFIG" && break
7986 # Report the value of XML2_CONFIG in configure's output in all cases.
7987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XML2_CONFIG" >&5
7988 $as_echo_n "checking for XML2_CONFIG... " >&6; }
7989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XML2_CONFIG" >&5
7990 $as_echo "$XML2_CONFIG" >&6; }
7993 if test -n "$XML2_CONFIG"; then
7994 for pgac_option in `$XML2_CONFIG --cflags`; do
7995 case $pgac_option in
7996 -I*|-D*) CPPFLAGS="$CPPFLAGS $pgac_option";;
7999 for pgac_option in `$XML2_CONFIG --libs`; do
8000 case $pgac_option in
8001 -L*) LDFLAGS="$LDFLAGS $pgac_option";;
8015 # Check whether --with-libxslt was given.
8016 if test "${with_libxslt+set}" = set; then :
8017 withval=$with_libxslt;
8021 $as_echo "#define USE_LIBXSLT 1" >>confdefs.h
8028 as_fn_error $? "no argument expected for --with-libxslt option" "$LINENO" 5
8048 # Check whether --with-system-tzdata was given.
8049 if test "${with_system_tzdata+set}" = set; then :
8050 withval=$with_system_tzdata;
8053 as_fn_error $? "argument required for --with-system-tzdata option" "$LINENO" 5
8056 as_fn_error $? "argument required for --with-system-tzdata option" "$LINENO" 5
8074 # Check whether --with-zlib was given.
8075 if test "${with_zlib+set}" = set; then :
8085 as_fn_error $? "no argument expected for --with-zlib option" "$LINENO" 5
8101 # Assume system is ELF if it predefines __ELF__ as 1,
8102 # otherwise believe host_os based default.
8104 freebsd1*|freebsd2*) elf=no;;
8105 freebsd3*|freebsd4*) elf=yes;;
8109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
8110 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
8111 if ${ac_cv_path_GREP+:} false; then :
8112 $as_echo_n "(cached) " >&6
8114 if test -z "$GREP"; then
8115 ac_path_GREP_found=false
8116 # Loop through the user's path and test for each of PROGNAME-LIST
8117 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8118 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
8121 test -z "$as_dir" && as_dir=.
8122 for ac_prog in grep ggrep; do
8123 for ac_exec_ext in '' $ac_executable_extensions; do
8124 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
8125 as_fn_executable_p "$ac_path_GREP" || continue
8126 # Check for GNU ac_path_GREP and select it if it is found.
8127 # Check for GNU $ac_path_GREP
8128 case `"$ac_path_GREP" --version 2>&1` in
8130 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
8133 $as_echo_n 0123456789 >"conftest.in"
8136 cat "conftest.in" "conftest.in" >"conftest.tmp"
8137 mv "conftest.tmp" "conftest.in"
8138 cp "conftest.in" "conftest.nl"
8139 $as_echo 'GREP' >> "conftest.nl"
8140 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
8141 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
8142 as_fn_arith $ac_count + 1 && ac_count=$as_val
8143 if test $ac_count -gt ${ac_path_GREP_max-0}; then
8144 # Best one so far, save it but keep looking for a better one
8145 ac_cv_path_GREP="$ac_path_GREP"
8146 ac_path_GREP_max=$ac_count
8148 # 10*(2^10) chars as input seems more than enough
8149 test $ac_count -gt 10 && break
8151 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
8154 $ac_path_GREP_found && break 3
8159 if test -z "$ac_cv_path_GREP"; then
8160 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
8163 ac_cv_path_GREP=$GREP
8167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
8168 $as_echo "$ac_cv_path_GREP" >&6; }
8169 GREP="$ac_cv_path_GREP"
8172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
8173 $as_echo_n "checking for egrep... " >&6; }
8174 if ${ac_cv_path_EGREP+:} false; then :
8175 $as_echo_n "(cached) " >&6
8177 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
8178 then ac_cv_path_EGREP="$GREP -E"
8180 if test -z "$EGREP"; then
8181 ac_path_EGREP_found=false
8182 # Loop through the user's path and test for each of PROGNAME-LIST
8183 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8184 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
8187 test -z "$as_dir" && as_dir=.
8188 for ac_prog in egrep; do
8189 for ac_exec_ext in '' $ac_executable_extensions; do
8190 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
8191 as_fn_executable_p "$ac_path_EGREP" || continue
8192 # Check for GNU ac_path_EGREP and select it if it is found.
8193 # Check for GNU $ac_path_EGREP
8194 case `"$ac_path_EGREP" --version 2>&1` in
8196 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
8199 $as_echo_n 0123456789 >"conftest.in"
8202 cat "conftest.in" "conftest.in" >"conftest.tmp"
8203 mv "conftest.tmp" "conftest.in"
8204 cp "conftest.in" "conftest.nl"
8205 $as_echo 'EGREP' >> "conftest.nl"
8206 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
8207 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
8208 as_fn_arith $ac_count + 1 && ac_count=$as_val
8209 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
8210 # Best one so far, save it but keep looking for a better one
8211 ac_cv_path_EGREP="$ac_path_EGREP"
8212 ac_path_EGREP_max=$ac_count
8214 # 10*(2^10) chars as input seems more than enough
8215 test $ac_count -gt 10 && break
8217 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
8220 $ac_path_EGREP_found && break 3
8225 if test -z "$ac_cv_path_EGREP"; then
8226 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
8229 ac_cv_path_EGREP=$EGREP
8234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
8235 $as_echo "$ac_cv_path_EGREP" >&6; }
8236 EGREP="$ac_cv_path_EGREP"
8239 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8240 /* end confdefs.h. */
8246 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8247 $EGREP "yes" >/dev/null 2>&1; then :
8250 if test "X$elf" = "Xyes" ; then
8264 CPPFLAGS="$CPPFLAGS $INCLUDES"
8265 LDFLAGS="$LDFLAGS $LIBDIRS"
8271 # Check whether --with-gnu-ld was given.
8272 if test "${with_gnu_ld+set}" = set; then :
8273 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
8279 if test "$GCC" = yes; then
8280 # Check if gcc -print-prog-name=ld gives a path.
8281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
8282 $as_echo_n "checking for ld used by GCC... " >&6; }
8285 # gcc leaves a trailing carriage return which upsets mingw
8286 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
8288 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
8291 # Accept absolute paths.
8292 [\\/]* | [A-Za-z]:[\\/]*)
8293 re_direlt='/[^/][^/]*/\.\./'
8294 # Canonicalize the path of ld
8295 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
8296 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
8297 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
8299 test -z "$LD" && LD="$ac_prog"
8302 # If it fails, then pretend we aren't using GCC.
8306 # If it is relative, then search for the first ld in PATH.
8310 elif test "$with_gnu_ld" = yes; then
8311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
8312 $as_echo_n "checking for GNU ld... " >&6; }
8314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
8315 $as_echo_n "checking for non-GNU ld... " >&6; }
8317 if ${ac_cv_path_LD+:} false; then :
8318 $as_echo_n "(cached) " >&6
8320 if test -z "$LD"; then
8321 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
8322 for ac_dir in $PATH; do
8323 test -z "$ac_dir" && ac_dir=.
8324 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
8325 ac_cv_path_LD="$ac_dir/$ac_prog"
8326 # Check to see if the program is GNU ld. I'd rather use --version,
8327 # but apparently some GNU ld's only accept -v.
8328 # Break only if it was the GNU/non-GNU ld that we prefer.
8329 if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
8330 test "$with_gnu_ld" != no && break
8332 test "$with_gnu_ld" != yes && break
8338 ac_cv_path_LD="$LD" # Let the user override the test with a path.
8343 if test -n "$LD"; then
8344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
8345 $as_echo "$LD" >&6; }
8347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8348 $as_echo "no" >&6; }
8350 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
8351 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
8352 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
8353 if ${ac_cv_prog_gnu_ld+:} false; then :
8354 $as_echo_n "(cached) " >&6
8356 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
8357 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
8358 ac_cv_prog_gnu_ld=yes
8360 ac_cv_prog_gnu_ld=no
8363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_gnu_ld" >&5
8364 $as_echo "$ac_cv_prog_gnu_ld" >&6; }
8365 with_gnu_ld=$ac_cv_prog_gnu_ld
8370 if test -n "$ac_tool_prefix"; then
8371 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
8372 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
8373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8374 $as_echo_n "checking for $ac_word... " >&6; }
8375 if ${ac_cv_prog_RANLIB+:} false; then :
8376 $as_echo_n "(cached) " >&6
8378 if test -n "$RANLIB"; then
8379 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
8381 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8385 test -z "$as_dir" && as_dir=.
8386 for ac_exec_ext in '' $ac_executable_extensions; do
8387 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8388 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
8389 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8398 RANLIB=$ac_cv_prog_RANLIB
8399 if test -n "$RANLIB"; then
8400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
8401 $as_echo "$RANLIB" >&6; }
8403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8404 $as_echo "no" >&6; }
8409 if test -z "$ac_cv_prog_RANLIB"; then
8410 ac_ct_RANLIB=$RANLIB
8411 # Extract the first word of "ranlib", so it can be a program name with args.
8412 set dummy ranlib; ac_word=$2
8413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8414 $as_echo_n "checking for $ac_word... " >&6; }
8415 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
8416 $as_echo_n "(cached) " >&6
8418 if test -n "$ac_ct_RANLIB"; then
8419 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
8421 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8425 test -z "$as_dir" && as_dir=.
8426 for ac_exec_ext in '' $ac_executable_extensions; do
8427 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8428 ac_cv_prog_ac_ct_RANLIB="ranlib"
8429 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8438 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
8439 if test -n "$ac_ct_RANLIB"; then
8440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
8441 $as_echo "$ac_ct_RANLIB" >&6; }
8443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8444 $as_echo "no" >&6; }
8447 if test "x$ac_ct_RANLIB" = x; then
8450 case $cross_compiling:$ac_tool_warned in
8452 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8453 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8454 ac_tool_warned=yes ;;
8456 RANLIB=$ac_ct_RANLIB
8459 RANLIB="$ac_cv_prog_RANLIB"
8463 if test -n "$ac_tool_prefix"; then
8464 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
8465 set dummy ${ac_tool_prefix}strip; ac_word=$2
8466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8467 $as_echo_n "checking for $ac_word... " >&6; }
8468 if ${ac_cv_prog_STRIP+:} false; then :
8469 $as_echo_n "(cached) " >&6
8471 if test -n "$STRIP"; then
8472 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
8474 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8478 test -z "$as_dir" && as_dir=.
8479 for ac_exec_ext in '' $ac_executable_extensions; do
8480 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8481 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
8482 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8491 STRIP=$ac_cv_prog_STRIP
8492 if test -n "$STRIP"; then
8493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
8494 $as_echo "$STRIP" >&6; }
8496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8497 $as_echo "no" >&6; }
8502 if test -z "$ac_cv_prog_STRIP"; then
8504 # Extract the first word of "strip", so it can be a program name with args.
8505 set dummy strip; ac_word=$2
8506 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8507 $as_echo_n "checking for $ac_word... " >&6; }
8508 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
8509 $as_echo_n "(cached) " >&6
8511 if test -n "$ac_ct_STRIP"; then
8512 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
8514 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8518 test -z "$as_dir" && as_dir=.
8519 for ac_exec_ext in '' $ac_executable_extensions; do
8520 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8521 ac_cv_prog_ac_ct_STRIP="strip"
8522 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8531 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
8532 if test -n "$ac_ct_STRIP"; then
8533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
8534 $as_echo "$ac_ct_STRIP" >&6; }
8536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8537 $as_echo "no" >&6; }
8540 if test "x$ac_ct_STRIP" = x; then
8543 case $cross_compiling:$ac_tool_warned in
8545 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8546 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8547 ac_tool_warned=yes ;;
8552 STRIP="$ac_cv_prog_STRIP"
8556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is possible to strip libraries" >&5
8557 $as_echo_n "checking whether it is possible to strip libraries... " >&6; }
8558 if test x"$STRIP" != x"" && "$STRIP" -V 2>&1 | grep "GNU strip" >/dev/null; then
8559 STRIP_STATIC_LIB="$STRIP -x"
8560 STRIP_SHARED_LIB="$STRIP --strip-unneeded"
8561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8562 $as_echo "yes" >&6; }
8567 STRIP_STATIC_LIB=$STRIP
8568 STRIP_SHARED_LIB=$STRIP
8569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8570 $as_echo "yes" >&6; }
8575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8576 $as_echo "no" >&6; }
8583 if test -n "$ac_tool_prefix"; then
8584 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
8585 set dummy ${ac_tool_prefix}ar; 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_AR+:} false; then :
8589 $as_echo_n "(cached) " >&6
8591 if test -n "$AR"; then
8592 ac_cv_prog_AR="$AR" # 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_AR="${ac_tool_prefix}ar"
8602 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8612 if test -n "$AR"; then
8613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
8614 $as_echo "$AR" >&6; }
8616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8617 $as_echo "no" >&6; }
8622 if test -z "$ac_cv_prog_AR"; then
8624 # Extract the first word of "ar", so it can be a program name with args.
8625 set dummy ar; 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_AR+:} false; then :
8629 $as_echo_n "(cached) " >&6
8631 if test -n "$ac_ct_AR"; then
8632 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # 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_AR="ar"
8642 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8651 ac_ct_AR=$ac_cv_prog_ac_ct_AR
8652 if test -n "$ac_ct_AR"; then
8653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
8654 $as_echo "$ac_ct_AR" >&6; }
8656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8657 $as_echo "no" >&6; }
8660 if test "x$ac_ct_AR" = 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 ;;
8675 if test "$PORTNAME" = "win32"; then
8676 if test -n "$ac_tool_prefix"; then
8677 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
8678 set dummy ${ac_tool_prefix}dlltool; 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_DLLTOOL+:} false; then :
8682 $as_echo_n "(cached) " >&6
8684 if test -n "$DLLTOOL"; then
8685 ac_cv_prog_DLLTOOL="$DLLTOOL" # 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_DLLTOOL="${ac_tool_prefix}dlltool"
8695 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8704 DLLTOOL=$ac_cv_prog_DLLTOOL
8705 if test -n "$DLLTOOL"; then
8706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
8707 $as_echo "$DLLTOOL" >&6; }
8709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8710 $as_echo "no" >&6; }
8715 if test -z "$ac_cv_prog_DLLTOOL"; then
8716 ac_ct_DLLTOOL=$DLLTOOL
8717 # Extract the first word of "dlltool", so it can be a program name with args.
8718 set dummy dlltool; 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_DLLTOOL+:} false; then :
8722 $as_echo_n "(cached) " >&6
8724 if test -n "$ac_ct_DLLTOOL"; then
8725 ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # 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_DLLTOOL="dlltool"
8735 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8744 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
8745 if test -n "$ac_ct_DLLTOOL"; then
8746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
8747 $as_echo "$ac_ct_DLLTOOL" >&6; }
8749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8750 $as_echo "no" >&6; }
8753 if test "x$ac_ct_DLLTOOL" = 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 ;;
8762 DLLTOOL=$ac_ct_DLLTOOL
8765 DLLTOOL="$ac_cv_prog_DLLTOOL"
8768 if test -n "$ac_tool_prefix"; then
8769 # Extract the first word of "${ac_tool_prefix}dllwrap", so it can be a program name with args.
8770 set dummy ${ac_tool_prefix}dllwrap; ac_word=$2
8771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8772 $as_echo_n "checking for $ac_word... " >&6; }
8773 if ${ac_cv_prog_DLLWRAP+:} false; then :
8774 $as_echo_n "(cached) " >&6
8776 if test -n "$DLLWRAP"; then
8777 ac_cv_prog_DLLWRAP="$DLLWRAP" # Let the user override the test.
8779 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8783 test -z "$as_dir" && as_dir=.
8784 for ac_exec_ext in '' $ac_executable_extensions; do
8785 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8786 ac_cv_prog_DLLWRAP="${ac_tool_prefix}dllwrap"
8787 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8796 DLLWRAP=$ac_cv_prog_DLLWRAP
8797 if test -n "$DLLWRAP"; then
8798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLWRAP" >&5
8799 $as_echo "$DLLWRAP" >&6; }
8801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8802 $as_echo "no" >&6; }
8807 if test -z "$ac_cv_prog_DLLWRAP"; then
8808 ac_ct_DLLWRAP=$DLLWRAP
8809 # Extract the first word of "dllwrap", so it can be a program name with args.
8810 set dummy dllwrap; ac_word=$2
8811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8812 $as_echo_n "checking for $ac_word... " >&6; }
8813 if ${ac_cv_prog_ac_ct_DLLWRAP+:} false; then :
8814 $as_echo_n "(cached) " >&6
8816 if test -n "$ac_ct_DLLWRAP"; then
8817 ac_cv_prog_ac_ct_DLLWRAP="$ac_ct_DLLWRAP" # Let the user override the test.
8819 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8823 test -z "$as_dir" && as_dir=.
8824 for ac_exec_ext in '' $ac_executable_extensions; do
8825 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8826 ac_cv_prog_ac_ct_DLLWRAP="dllwrap"
8827 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8836 ac_ct_DLLWRAP=$ac_cv_prog_ac_ct_DLLWRAP
8837 if test -n "$ac_ct_DLLWRAP"; then
8838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLWRAP" >&5
8839 $as_echo "$ac_ct_DLLWRAP" >&6; }
8841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8842 $as_echo "no" >&6; }
8845 if test "x$ac_ct_DLLWRAP" = x; then
8848 case $cross_compiling:$ac_tool_warned in
8850 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8851 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8852 ac_tool_warned=yes ;;
8854 DLLWRAP=$ac_ct_DLLWRAP
8857 DLLWRAP="$ac_cv_prog_DLLWRAP"
8860 if test -n "$ac_tool_prefix"; then
8861 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
8862 set dummy ${ac_tool_prefix}windres; ac_word=$2
8863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8864 $as_echo_n "checking for $ac_word... " >&6; }
8865 if ${ac_cv_prog_WINDRES+:} false; then :
8866 $as_echo_n "(cached) " >&6
8868 if test -n "$WINDRES"; then
8869 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
8871 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8875 test -z "$as_dir" && as_dir=.
8876 for ac_exec_ext in '' $ac_executable_extensions; do
8877 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8878 ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
8879 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8888 WINDRES=$ac_cv_prog_WINDRES
8889 if test -n "$WINDRES"; then
8890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
8891 $as_echo "$WINDRES" >&6; }
8893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8894 $as_echo "no" >&6; }
8899 if test -z "$ac_cv_prog_WINDRES"; then
8900 ac_ct_WINDRES=$WINDRES
8901 # Extract the first word of "windres", so it can be a program name with args.
8902 set dummy windres; ac_word=$2
8903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8904 $as_echo_n "checking for $ac_word... " >&6; }
8905 if ${ac_cv_prog_ac_ct_WINDRES+:} false; then :
8906 $as_echo_n "(cached) " >&6
8908 if test -n "$ac_ct_WINDRES"; then
8909 ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
8911 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8915 test -z "$as_dir" && as_dir=.
8916 for ac_exec_ext in '' $ac_executable_extensions; do
8917 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8918 ac_cv_prog_ac_ct_WINDRES="windres"
8919 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8928 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
8929 if test -n "$ac_ct_WINDRES"; then
8930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
8931 $as_echo "$ac_ct_WINDRES" >&6; }
8933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8934 $as_echo "no" >&6; }
8937 if test "x$ac_ct_WINDRES" = x; then
8940 case $cross_compiling:$ac_tool_warned in
8942 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8943 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8944 ac_tool_warned=yes ;;
8946 WINDRES=$ac_ct_WINDRES
8949 WINDRES="$ac_cv_prog_WINDRES"
8954 # Find a good install program. We prefer a C program (faster),
8955 # so one script is as good as another. But avoid the broken or
8956 # incompatible versions:
8957 # SysV /etc/install, /usr/sbin/install
8958 # SunOS /usr/etc/install
8959 # IRIX /sbin/install
8961 # AmigaOS /C/install, which installs bootblocks on floppy discs
8962 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
8963 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
8964 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
8965 # OS/2's system install, which has a completely different semantic
8966 # ./install, which can be erroneously created by make from ./install.sh.
8967 # Reject install programs that cannot install multiple files.
8968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
8969 $as_echo_n "checking for a BSD-compatible install... " >&6; }
8970 if test -z "$INSTALL"; then
8971 if ${ac_cv_path_install+:} false; then :
8972 $as_echo_n "(cached) " >&6
8974 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8978 test -z "$as_dir" && as_dir=.
8979 # Account for people who put trailing slashes in PATH elements.
8980 case $as_dir/ in #((
8981 ./ | .// | /[cC]/* | \
8982 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
8983 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
8986 # OSF1 and SCO ODT 3.0 have their own names for install.
8987 # Don't use installbsd from OSF since it installs stuff as root
8989 for ac_prog in ginstall scoinst install; do
8990 for ac_exec_ext in '' $ac_executable_extensions; do
8991 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
8992 if test $ac_prog = install &&
8993 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
8994 # AIX install. It has an incompatible calling convention.
8996 elif test $ac_prog = install &&
8997 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
8998 # program-specific install script used by HP pwplus--don't use.
9001 rm -rf conftest.one conftest.two conftest.dir
9002 echo one > conftest.one
9003 echo two > conftest.two
9005 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
9006 test -s conftest.one && test -s conftest.two &&
9007 test -s conftest.dir/conftest.one &&
9008 test -s conftest.dir/conftest.two
9010 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
9023 rm -rf conftest.one conftest.two conftest.dir
9026 if test "${ac_cv_path_install+set}" = set; then
9027 INSTALL=$ac_cv_path_install
9029 # As a last resort, use the slow shell script. Don't cache a
9030 # value for INSTALL within a source directory, because that will
9031 # break other packages using the cache if that directory is
9032 # removed, or if the value is a relative name.
9033 INSTALL=$ac_install_sh
9036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
9037 $as_echo "$INSTALL" >&6; }
9039 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
9040 # It thinks the first close brace ends the variable substitution.
9041 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
9043 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
9045 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
9047 # When Autoconf chooses install-sh as install program it tries to generate
9048 # a relative path to it in each makefile where it substitutes it. This clashes
9049 # with our Makefile.global concept. This workaround helps.
9051 *install-sh*) install_bin='';;
9052 *) install_bin=$INSTALL;;
9056 if test -z "$TAR"; then
9059 # Extract the first word of "$ac_prog", so it can be a program name with args.
9060 set dummy $ac_prog; ac_word=$2
9061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9062 $as_echo_n "checking for $ac_word... " >&6; }
9063 if ${ac_cv_path_TAR+:} false; then :
9064 $as_echo_n "(cached) " >&6
9068 ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
9071 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9075 test -z "$as_dir" && as_dir=.
9076 for ac_exec_ext in '' $ac_executable_extensions; do
9077 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9078 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
9079 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9090 if test -n "$TAR"; then
9091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9092 $as_echo "$TAR" >&6; }
9094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9095 $as_echo "no" >&6; }
9099 test -n "$TAR" && break
9103 # Report the value of TAR in configure's output in all cases.
9104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5
9105 $as_echo_n "checking for TAR... " >&6; }
9106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9107 $as_echo "$TAR" >&6; }
9110 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
9111 $as_echo_n "checking whether ln -s works... " >&6; }
9113 if test "$LN_S" = "ln -s"; then
9114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9115 $as_echo "yes" >&6; }
9117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
9118 $as_echo "no, using $LN_S" >&6; }
9121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
9122 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
9123 if test -z "$MKDIR_P"; then
9124 if ${ac_cv_path_mkdir+:} false; then :
9125 $as_echo_n "(cached) " >&6
9127 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9128 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
9131 test -z "$as_dir" && as_dir=.
9132 for ac_prog in mkdir gmkdir; do
9133 for ac_exec_ext in '' $ac_executable_extensions; do
9134 as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
9135 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
9136 'mkdir (GNU coreutils) '* | \
9137 'mkdir (coreutils) '* | \
9138 'mkdir (fileutils) '4.1*)
9139 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
9149 test -d ./--version && rmdir ./--version
9150 if test "${ac_cv_path_mkdir+set}" = set; then
9151 MKDIR_P="$ac_cv_path_mkdir -p"
9153 # As a last resort, use the slow shell script. Don't cache a
9154 # value for MKDIR_P within a source directory, because that will
9155 # break other packages using the cache if that directory is
9156 # removed, or if the value is a relative name.
9157 MKDIR_P="$ac_install_sh -d"
9160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
9161 $as_echo "$MKDIR_P" >&6; }
9163 # When Autoconf chooses install-sh as mkdir -p program it tries to generate
9164 # a relative path to it in each makefile where it substitutes it. This clashes
9165 # with our Makefile.global concept. This workaround helps.
9167 *install-sh*) MKDIR_P='\${SHELL} \${top_srcdir}/config/install-sh -c -d';;
9170 if test -z "$BISON"; then
9171 for ac_prog in bison
9173 # Extract the first word of "$ac_prog", so it can be a program name with args.
9174 set dummy $ac_prog; ac_word=$2
9175 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9176 $as_echo_n "checking for $ac_word... " >&6; }
9177 if ${ac_cv_path_BISON+:} false; then :
9178 $as_echo_n "(cached) " >&6
9182 ac_cv_path_BISON="$BISON" # Let the user override the test with a path.
9185 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9189 test -z "$as_dir" && as_dir=.
9190 for ac_exec_ext in '' $ac_executable_extensions; do
9191 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9192 ac_cv_path_BISON="$as_dir/$ac_word$ac_exec_ext"
9193 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9203 BISON=$ac_cv_path_BISON
9204 if test -n "$BISON"; then
9205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BISON" >&5
9206 $as_echo "$BISON" >&6; }
9208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9209 $as_echo "no" >&6; }
9213 test -n "$BISON" && break
9217 # Report the value of BISON in configure's output in all cases.
9218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BISON" >&5
9219 $as_echo_n "checking for BISON... " >&6; }
9220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BISON" >&5
9221 $as_echo "$BISON" >&6; }
9225 if test "$BISON"; then
9226 pgac_bison_version=`$BISON --version 2>/dev/null | sed q`
9227 { $as_echo "$as_me:${as_lineno-$LINENO}: using $pgac_bison_version" >&5
9228 $as_echo "$as_me: using $pgac_bison_version" >&6;}
9229 if echo "$pgac_bison_version" | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'
9231 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
9232 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
9233 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&5
9234 $as_echo "$as_me: WARNING:
9235 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
9236 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&2;}
9239 # Bison >=3.0 issues warnings about %name-prefix="base_yy", instead
9240 # of the now preferred %name-prefix "base_yy", but the latter
9241 # doesn't work with Bison 2.3 or less. So for now we silence the
9242 # deprecation warnings.
9243 if echo "$pgac_bison_version" | $AWK '{ if ($4 >= 3) exit 0; else exit 1;}'
9245 BISONFLAGS="$BISONFLAGS -Wno-deprecated"
9249 if test -z "$BISON"; then
9250 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
9251 *** Without Bison you will not be able to build PostgreSQL from Git nor
9252 *** change any of the parser definition files. You can obtain Bison from
9253 *** a GNU mirror site. (If you are using the official distribution of
9254 *** PostgreSQL then you do not need to worry about this, because the Bison
9255 *** output is pre-generated.)" >&5
9256 $as_echo "$as_me: WARNING:
9257 *** Without Bison you will not be able to build PostgreSQL from Git nor
9258 *** change any of the parser definition files. You can obtain Bison from
9259 *** a GNU mirror site. (If you are using the official distribution of
9260 *** PostgreSQL then you do not need to worry about this, because the Bison
9261 *** output is pre-generated.)" >&2;}
9263 # We don't need AC_SUBST(BISON) because PGAC_PATH_PROGS did it
9266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flex" >&5
9267 $as_echo_n "checking for flex... " >&6; }
9268 if ${pgac_cv_path_flex+:} false; then :
9269 $as_echo_n "(cached) " >&6
9271 # Let the user override the test
9272 if test -n "$FLEX"; then
9273 pgac_cv_path_flex=$FLEX
9277 for pgac_dir in $PATH; do
9279 if test -z "$pgac_dir" || test x"$pgac_dir" = x"."; then
9282 for pgac_prog in flex lex; do
9283 pgac_candidate="$pgac_dir/$pgac_prog"
9284 if test -f "$pgac_candidate" \
9285 && $pgac_candidate --version </dev/null >/dev/null 2>&1
9287 echo '%%' > conftest.l
9288 if $pgac_candidate -t conftest.l 2>/dev/null | grep FLEX_SCANNER >/dev/null 2>&1; then
9289 pgac_flex_version=`$pgac_candidate --version 2>/dev/null`
9290 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;}'
9292 pgac_cv_path_flex=$pgac_candidate
9295 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
9296 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
9297 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&5
9298 $as_echo "$as_me: WARNING:
9299 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
9300 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&2;}
9306 rm -f conftest.l lex.yy.c
9307 : ${pgac_cv_path_flex=no}
9311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_path_flex" >&5
9312 $as_echo "$pgac_cv_path_flex" >&6; }
9313 if test x"$pgac_cv_path_flex" = x"no"; then
9314 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
9315 *** Without Flex you will not be able to build PostgreSQL from Git nor
9316 *** change any of the scanner definition files. You can obtain Flex from
9317 *** a GNU mirror site. (If you are using the official distribution of
9318 *** PostgreSQL then you do not need to worry about this because the Flex
9319 *** output is pre-generated.)" >&5
9320 $as_echo "$as_me: WARNING:
9321 *** Without Flex you will not be able to build PostgreSQL from Git nor
9322 *** change any of the scanner definition files. You can obtain Flex from
9323 *** a GNU mirror site. (If you are using the official distribution of
9324 *** PostgreSQL then you do not need to worry about this because the Flex
9325 *** output is pre-generated.)" >&2;}
9329 FLEX=$pgac_cv_path_flex
9330 pgac_flex_version=`$FLEX --version 2>/dev/null`
9331 { $as_echo "$as_me:${as_lineno-$LINENO}: using $pgac_flex_version" >&5
9332 $as_echo "$as_me: using $pgac_flex_version" >&6;}
9339 if test -z "$PERL"; then
9342 # Extract the first word of "$ac_prog", so it can be a program name with args.
9343 set dummy $ac_prog; ac_word=$2
9344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9345 $as_echo_n "checking for $ac_word... " >&6; }
9346 if ${ac_cv_path_PERL+:} false; then :
9347 $as_echo_n "(cached) " >&6
9351 ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
9354 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9358 test -z "$as_dir" && as_dir=.
9359 for ac_exec_ext in '' $ac_executable_extensions; do
9360 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9361 ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
9362 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9372 PERL=$ac_cv_path_PERL
9373 if test -n "$PERL"; then
9374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5
9375 $as_echo "$PERL" >&6; }
9377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9378 $as_echo "no" >&6; }
9382 test -n "$PERL" && break
9386 # Report the value of PERL in configure's output in all cases.
9387 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PERL" >&5
9388 $as_echo_n "checking for PERL... " >&6; }
9389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5
9390 $as_echo "$PERL" >&6; }
9394 if test "$PERL"; then
9395 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'`
9396 { $as_echo "$as_me:${as_lineno-$LINENO}: using perl $pgac_perl_version" >&5
9397 $as_echo "$as_me: using perl $pgac_perl_version" >&6;}
9398 if echo "$pgac_perl_version" | sed 's/[.a-z_]/ /g' | \
9399 $AWK '{ if ($1 == 5 && $2 >= 8) exit 1; else exit 0;}'
9401 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
9402 *** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
9403 *** Perl version 5.8 or later is required, but this is $pgac_perl_version." >&5
9404 $as_echo "$as_me: WARNING:
9405 *** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
9406 *** Perl version 5.8 or later is required, but this is $pgac_perl_version." >&2;}
9411 if test -z "$PERL"; then
9412 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
9413 *** Without Perl you will not be able to build PostgreSQL from Git.
9414 *** You can obtain Perl from any CPAN mirror site.
9415 *** (If you are using the official distribution of PostgreSQL then you do not
9416 *** need to worry about this, because the Perl output is pre-generated.)" >&5
9417 $as_echo "$as_me: WARNING:
9418 *** Without Perl you will not be able to build PostgreSQL from Git.
9419 *** You can obtain Perl from any CPAN mirror site.
9420 *** (If you are using the official distribution of PostgreSQL then you do not
9421 *** need to worry about this, because the Perl output is pre-generated.)" >&2;}
9424 if test "$with_perl" = yes; then
9425 if test -z "$PERL"; then
9426 as_fn_error $? "Perl not found" "$LINENO" 5
9429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Perl archlibexp" >&5
9430 $as_echo_n "checking for Perl archlibexp... " >&6; }
9431 perl_archlibexp=`$PERL -MConfig -e 'print $Config{archlibexp}'`
9432 test "$PORTNAME" = "win32" && perl_archlibexp=`echo $perl_archlibexp | sed 's,\\\\,/,g'`
9433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_archlibexp" >&5
9434 $as_echo "$perl_archlibexp" >&6; }
9435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Perl privlibexp" >&5
9436 $as_echo_n "checking for Perl privlibexp... " >&6; }
9437 perl_privlibexp=`$PERL -MConfig -e 'print $Config{privlibexp}'`
9438 test "$PORTNAME" = "win32" && perl_privlibexp=`echo $perl_privlibexp | sed 's,\\\\,/,g'`
9439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_privlibexp" >&5
9440 $as_echo "$perl_privlibexp" >&6; }
9441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Perl useshrplib" >&5
9442 $as_echo_n "checking for Perl useshrplib... " >&6; }
9443 perl_useshrplib=`$PERL -MConfig -e 'print $Config{useshrplib}'`
9444 test "$PORTNAME" = "win32" && perl_useshrplib=`echo $perl_useshrplib | sed 's,\\\\,/,g'`
9445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_useshrplib" >&5
9446 $as_echo "$perl_useshrplib" >&6; }
9447 if test "$perl_useshrplib" != yes && test "$perl_useshrplib" != true; then
9448 as_fn_error $? "cannot build PL/Perl because libperl is not a shared library
9449 You might have to rebuild your Perl installation. Refer to the
9450 documentation for details. Use --without-perl to disable building
9451 PL/Perl." "$LINENO" 5
9453 # On most platforms, archlibexp is also where the Perl include files live ...
9454 perl_includespec="-I$perl_archlibexp/CORE"
9455 # ... but on newer macOS versions, we must use -iwithsysroot to look
9457 if test \! -f "$perl_archlibexp/CORE/perl.h" ; then
9458 if test -f "$PG_SYSROOT$perl_archlibexp/CORE/perl.h" ; then
9459 perl_includespec="-iwithsysroot $perl_archlibexp/CORE"
9463 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLAGS recommended by Perl" >&5
9464 $as_echo_n "checking for CFLAGS recommended by Perl... " >&6; }
9465 perl_ccflags=`$PERL -MConfig -e 'print $Config{ccflags}'`
9466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_ccflags" >&5
9467 $as_echo "$perl_ccflags" >&6; }
9468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLAGS to compile embedded Perl" >&5
9469 $as_echo_n "checking for CFLAGS to compile embedded Perl... " >&6; }
9470 perl_embed_ccflags=`$PERL -MConfig -e 'foreach $f (split(" ",$Config{ccflags})) {print $f, " " if ($f =~ /^-D[^_]/ || $f =~ /^-D_USE_32BIT_TIME_T/)}'`
9471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_embed_ccflags" >&5
9472 $as_echo "$perl_embed_ccflags" >&6; }
9475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flags to link embedded Perl" >&5
9476 $as_echo_n "checking for flags to link embedded Perl... " >&6; }
9477 if test "$PORTNAME" = "win32" ; then
9478 perl_lib=`basename $perl_archlibexp/CORE/perl[5-9]*.lib .lib`
9479 if test -e "$perl_archlibexp/CORE/$perl_lib.lib"; then
9480 perl_embed_ldflags="-L$perl_archlibexp/CORE -l$perl_lib"
9482 perl_lib=`basename $perl_archlibexp/CORE/libperl[5-9]*.a .a | sed 's/^lib//'`
9483 if test -e "$perl_archlibexp/CORE/lib$perl_lib.a"; then
9484 perl_embed_ldflags="-L$perl_archlibexp/CORE -l$perl_lib"
9488 pgac_tmp1=`$PERL -MExtUtils::Embed -e ldopts`
9489 pgac_tmp2=`$PERL -MConfig -e 'print $Config{ccdlflags}'`
9490 perl_embed_ldflags=`echo X"$pgac_tmp1" | sed -e "s/^X//" -e "s%$pgac_tmp2%%" -e "s/ -arch [-a-zA-Z0-9_]*//g"`
9492 if test -z "$perl_embed_ldflags" ; then
9493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9494 $as_echo "no" >&6; }
9495 as_fn_error $? "could not determine flags for linking embedded Perl.
9496 This probably means that ExtUtils::Embed or ExtUtils::MakeMaker is not
9497 installed." "$LINENO" 5
9499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_embed_ldflags" >&5
9500 $as_echo "$perl_embed_ldflags" >&6; }
9505 if test "$with_python" = yes; then
9506 if test -z "$PYTHON"; then
9507 for ac_prog in python python3 python2
9509 # Extract the first word of "$ac_prog", so it can be a program name with args.
9510 set dummy $ac_prog; ac_word=$2
9511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9512 $as_echo_n "checking for $ac_word... " >&6; }
9513 if ${ac_cv_path_PYTHON+:} false; then :
9514 $as_echo_n "(cached) " >&6
9518 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
9521 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9525 test -z "$as_dir" && as_dir=.
9526 for ac_exec_ext in '' $ac_executable_extensions; do
9527 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9528 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
9529 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9539 PYTHON=$ac_cv_path_PYTHON
9540 if test -n "$PYTHON"; then
9541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
9542 $as_echo "$PYTHON" >&6; }
9544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9545 $as_echo "no" >&6; }
9549 test -n "$PYTHON" && break
9553 # Report the value of PYTHON in configure's output in all cases.
9554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PYTHON" >&5
9555 $as_echo_n "checking for PYTHON... " >&6; }
9556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
9557 $as_echo "$PYTHON" >&6; }
9560 if test x"$PYTHON" = x""; then
9561 as_fn_error $? "Python not found" "$LINENO" 5
9565 python_fullversion=`${PYTHON} -c "import sys; print(sys.version)" | sed q`
9566 { $as_echo "$as_me:${as_lineno-$LINENO}: using python $python_fullversion" >&5
9567 $as_echo "$as_me: using python $python_fullversion" >&6;}
9568 # python_fullversion is typically n.n.n plus some trailing junk
9569 python_majorversion=`echo "$python_fullversion" | sed 's/^\([0-9]*\).*/\1/'`
9570 python_minorversion=`echo "$python_fullversion" | sed 's/^[0-9]*\.\([0-9]*\).*/\1/'`
9571 python_version=`echo "$python_fullversion" | sed 's/^\([0-9]*\.[0-9]*\).*/\1/'`
9572 # Reject unsupported Python versions as soon as practical.
9573 if test "$python_majorversion" -lt 3 -a "$python_minorversion" -lt 4; then
9574 as_fn_error $? "Python version $python_version is too old (version 2.4 or later is required)" "$LINENO" 5
9577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python distutils module" >&5
9578 $as_echo_n "checking for Python distutils module... " >&6; }
9579 if "${PYTHON}" -c 'import distutils' 2>&5
9581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9582 $as_echo "yes" >&6; }
9584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9585 $as_echo "no" >&6; }
9586 as_fn_error $? "distutils module not found" "$LINENO" 5
9589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python configuration directory" >&5
9590 $as_echo_n "checking Python configuration directory... " >&6; }
9591 python_configdir=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBPL'))))"`
9592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_configdir" >&5
9593 $as_echo "$python_configdir" >&6; }
9595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python include directories" >&5
9596 $as_echo_n "checking Python include directories... " >&6; }
9597 python_includespec=`${PYTHON} -c "
9598 import distutils.sysconfig
9599 a = '-I' + distutils.sysconfig.get_python_inc(False)
9600 b = '-I' + distutils.sysconfig.get_python_inc(True)
9604 print(a + ' ' + b)"`
9605 if test "$PORTNAME" = win32 ; then
9606 python_includespec=`echo $python_includespec | sed 's,[\],/,g'`
9608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_includespec" >&5
9609 $as_echo "$python_includespec" >&6; }
9613 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link an embedded Python application" >&5
9614 $as_echo_n "checking how to link an embedded Python application... " >&6; }
9616 python_libdir=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBDIR'))))"`
9617 python_ldlibrary=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LDLIBRARY'))))"`
9619 # If LDLIBRARY exists and has a shlib extension, use it verbatim.
9620 ldlibrary=`echo "${python_ldlibrary}" | sed -e 's/\.so$//' -e 's/\.dll$//' -e 's/\.dylib$//' -e 's/\.sl$//'`
9621 if test -e "${python_libdir}/${python_ldlibrary}" -a x"${python_ldlibrary}" != x"${ldlibrary}"
9623 ldlibrary=`echo "${ldlibrary}" | sed "s/^lib//"`
9626 # Otherwise, guess the base name of the shlib.
9627 # LDVERSION was added in Python 3.2, before that use VERSION,
9628 # or failing that, $python_version from _PGAC_CHECK_PYTHON_DIRS.
9629 python_ldversion=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LDVERSION'))))"`
9630 if test x"${python_ldversion}" != x""; then
9631 ldlibrary="python${python_ldversion}"
9633 python_version_var=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('VERSION'))))"`
9634 if test x"${python_version_var}" != x""; then
9635 ldlibrary="python${python_version_var}"
9637 ldlibrary="python${python_version}"
9640 # Search for a likely-looking file.
9642 for d in "${python_libdir}" "${python_configdir}" /usr/lib64 /usr/lib
9644 # We don't know the platform DLSUFFIX here, so check 'em all.
9645 for e in .so .dll .dylib .sl; do
9646 if test -e "$d/lib${ldlibrary}$e"; then
9653 # Some platforms (OpenBSD) require us to accept a bare versioned shlib
9654 # (".so.n.n") as well. However, check this only after failing to find
9655 # ".so" anywhere, because yet other platforms (Debian) put the .so
9656 # symlink in a different directory from the underlying versioned shlib.
9657 if test "$found_shlib" != 1; then
9658 for d in "${python_libdir}" "${python_configdir}" /usr/lib64 /usr/lib
9660 for f in "$d/lib${ldlibrary}.so."* ; do
9661 if test -e "$f"; then
9669 # As usual, Windows has its own ideas. Possible default library
9670 # locations include c:/Windows/System32 and (for Cygwin) /usr/bin,
9671 # and the "lib" prefix might not be there.
9672 if test "$found_shlib" != 1 -a \( "$PORTNAME" = win32 -o "$PORTNAME" = cygwin \); then
9673 for d in "${python_libdir}" "${python_configdir}" c:/Windows/System32 /usr/bin
9675 for f in "$d/lib${ldlibrary}.dll" "$d/${ldlibrary}.dll" ; do
9676 if test -e "$f"; then
9685 if test "$found_shlib" != 1; then
9686 as_fn_error $? "could not find shared library for Python
9687 You might have to rebuild your Python installation. Refer to the
9688 documentation for details. Use --without-python to disable building
9689 PL/Python." "$LINENO" 5
9691 python_libspec="-L${python_libdir} -l${ldlibrary}"
9693 python_additional_libs=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBS','LIBC','LIBM','BASEMODLIBS'))))"`
9695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${python_libspec} ${python_additional_libs}" >&5
9696 $as_echo "${python_libspec} ${python_additional_libs}" >&6; }
9702 if test "$cross_compiling" = yes && test -z "$with_system_tzdata"; then
9703 if test -z "$ZIC"; then
9706 # Extract the first word of "$ac_prog", so it can be a program name with args.
9707 set dummy $ac_prog; ac_word=$2
9708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9709 $as_echo_n "checking for $ac_word... " >&6; }
9710 if ${ac_cv_path_ZIC+:} false; then :
9711 $as_echo_n "(cached) " >&6
9715 ac_cv_path_ZIC="$ZIC" # Let the user override the test with a path.
9718 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9722 test -z "$as_dir" && as_dir=.
9723 for ac_exec_ext in '' $ac_executable_extensions; do
9724 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9725 ac_cv_path_ZIC="$as_dir/$ac_word$ac_exec_ext"
9726 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9737 if test -n "$ZIC"; then
9738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIC" >&5
9739 $as_echo "$ZIC" >&6; }
9741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9742 $as_echo "no" >&6; }
9746 test -n "$ZIC" && break
9750 # Report the value of ZIC in configure's output in all cases.
9751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIC" >&5
9752 $as_echo_n "checking for ZIC... " >&6; }
9753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIC" >&5
9754 $as_echo "$ZIC" >&6; }
9757 if test -z "$ZIC"; then
9759 When cross-compiling, either use the option --with-system-tzdata to use
9760 existing time-zone data, or set the environment variable ZIC to a zic
9761 program to use during the build." "$LINENO" 5
9768 # For each platform, we need to know about any special compile and link
9769 # libraries, and whether the normal C function names are thread-safe.
9770 # See the comment at the top of src/port/thread.c for more information.
9771 # WIN32 doesn't need the pthread tests; it always uses threads
9773 # These tests are run before the library-tests, because linking with the
9774 # other libraries can pull in the pthread functions as a side-effect. We
9775 # want to use the -pthread or similar flags directly, and not rely on
9776 # the side-effects of linking with some other library.
9778 # note: We have to use AS_IF here rather than plain if. The AC_CHECK_HEADER
9779 # invocation below is the first one in the script, and autoconf generates
9780 # additional code for that, which must not be inside the if-block. AS_IF
9781 # knows how to do that.
9782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
9783 $as_echo_n "checking for ANSI C header files... " >&6; }
9784 if ${ac_cv_header_stdc+:} false; then :
9785 $as_echo_n "(cached) " >&6
9787 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9788 /* end confdefs.h. */
9802 if ac_fn_c_try_compile "$LINENO"; then :
9803 ac_cv_header_stdc=yes
9805 ac_cv_header_stdc=no
9807 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9809 if test $ac_cv_header_stdc = yes; then
9810 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
9811 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9812 /* end confdefs.h. */
9816 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9817 $EGREP "memchr" >/dev/null 2>&1; then :
9820 ac_cv_header_stdc=no
9826 if test $ac_cv_header_stdc = yes; then
9827 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
9828 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9829 /* end confdefs.h. */
9833 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9834 $EGREP "free" >/dev/null 2>&1; then :
9837 ac_cv_header_stdc=no
9843 if test $ac_cv_header_stdc = yes; then
9844 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
9845 if test "$cross_compiling" = yes; then :
9848 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9849 /* end confdefs.h. */
9852 #if ((' ' & 0x0FF) == 0x020)
9853 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
9854 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
9856 # define ISLOWER(c) \
9857 (('a' <= (c) && (c) <= 'i') \
9858 || ('j' <= (c) && (c) <= 'r') \
9859 || ('s' <= (c) && (c) <= 'z'))
9860 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
9863 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
9868 for (i = 0; i < 256; i++)
9869 if (XOR (islower (i), ISLOWER (i))
9870 || toupper (i) != TOUPPER (i))
9875 if ac_fn_c_try_run "$LINENO"; then :
9878 ac_cv_header_stdc=no
9880 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9881 conftest.$ac_objext conftest.beam conftest.$ac_ext
9886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
9887 $as_echo "$ac_cv_header_stdc" >&6; }
9888 if test $ac_cv_header_stdc = yes; then
9890 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
9894 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
9895 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
9896 inttypes.h stdint.h unistd.h
9898 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9899 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
9901 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
9902 cat >>confdefs.h <<_ACEOF
9903 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9911 if test "$enable_thread_safety" = yes -a "$PORTNAME" != "win32"; then :
9917 ac_cpp='$CPP $CPPFLAGS'
9918 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9919 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9920 ac_compiler_gnu=$ac_cv_c_compiler_gnu
9924 # We used to check for pthread.h first, but this fails if pthread.h
9925 # requires special compiler flags (e.g. on Tru64 or Sequent).
9926 # It gets checked for in the link test anyway.
9928 # First of all, check if the user has set any of the PTHREAD_LIBS,
9929 # etcetera environment variables, and if threads linking works using
9931 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
9932 save_CFLAGS="$CFLAGS"
9933 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
9935 LIBS="$PTHREAD_LIBS $LIBS"
9936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS" >&5
9937 $as_echo_n "checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS... " >&6; }
9938 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9939 /* end confdefs.h. */
9941 /* Override any GCC internal prototype to avoid an error.
9942 Use char because int might match the return type of a GCC
9943 builtin and then its argument prototype would still apply. */
9947 char pthread_join ();
9951 return pthread_join ();
9956 if ac_fn_c_try_link "$LINENO"; then :
9959 rm -f core conftest.err conftest.$ac_objext \
9960 conftest$ac_exeext conftest.$ac_ext
9961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
9962 $as_echo "$ax_pthread_ok" >&6; }
9963 if test x"$ax_pthread_ok" = xno; then
9968 CFLAGS="$save_CFLAGS"
9971 # We must check for the threads library under a number of different
9972 # names; the ordering is very important because some systems
9973 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
9974 # libraries is broken (non-POSIX).
9976 # Create a list of thread flags to try. Items starting with a "-" are
9977 # C compiler flags, and other items are library names, except for "none"
9978 # which indicates that we try without any flags at all, and "pthread-config"
9979 # which is a program returning the flags for the Pth emulation library.
9981 ax_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mt -mthreads pthread --thread-safe pthread-config"
9983 # The ordering *is* (sometimes) important. Some notes on the
9984 # individual items follow:
9986 # pthreads: AIX (must check this before -lpthread)
9987 # none: in case threads are in libc; should be tried before -Kthread and
9988 # other compiler flags to prevent continual compiler warnings
9989 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
9990 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
9991 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
9992 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads), Tru64
9993 # -pthreads: Solaris/gcc
9994 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
9995 # doesn't hurt to check since this sometimes defines pthreads and
9996 # -D_REENTRANT too), HP C (must be checked before -lpthread, which
9997 # is present but should not be used directly)
9998 # -mthreads: Mingw32/gcc, Lynx/gcc
9999 # pthread: Linux, etcetera
10000 # --thread-safe: KAI C++
10001 # pthread-config: use pthread-config program (for GNU Pth library)
10007 # From the cc(1) man page: "[-mt] Sets various -D flags to enable
10008 # multi-threading and also sets -lpthread."
10010 ax_pthread_flags="-mt -pthread pthread $ax_pthread_flags"
10015 # IBM z/OS requires a feature-test macro to be defined in order to
10016 # enable POSIX threads at all, so give the user a hint if this is
10017 # not set. (We don't define these ourselves, as they can affect
10018 # other portions of the system API in unpredictable ways.)
10020 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10021 /* end confdefs.h. */
10023 # if !defined(_OPEN_THREADS) && !defined(_UNIX03_THREADS)
10024 AX_PTHREAD_ZOS_MISSING
10028 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10029 $EGREP "AX_PTHREAD_ZOS_MISSING" >/dev/null 2>&1; then :
10030 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&5
10031 $as_echo "$as_me: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&2;}
10039 # Newer versions of Solaris require the "-mt -lpthread" pair, and we
10040 # check that first. On some older versions, libc contains stubbed
10041 # (non-functional) versions of the pthreads routines, so link-based
10042 # tests will erroneously succeed. (We need to link with -pthreads/-mt/
10043 # -lpthread.) (The stubs are missing pthread_cleanup_push, or rather
10044 # a function called by this macro, so we could check for that, but
10045 # who knows whether they'll stub that too in a future libc.) So
10046 # we'll look for -pthreads and -lpthread shortly thereafter.
10048 ax_pthread_flags="-mt,pthread -pthreads -pthread pthread $ax_pthread_flags"
10052 # Older versions of Clang only give a warning instead of an error for an
10053 # unrecognized option, unless we specify -Werror. (We throw in some extra
10054 # Clang warning flags for good measure.)
10056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler needs certain flags to reject unknown flags" >&5
10057 $as_echo_n "checking if compiler needs certain flags to reject unknown flags... " >&6; }
10058 if ${ax_cv_PTHREAD_REJECT_UNKNOWN+:} false; then :
10059 $as_echo_n "(cached) " >&6
10061 ax_cv_PTHREAD_REJECT_UNKNOWN=unknown
10062 save_CFLAGS="$CFLAGS"
10063 ax_pthread_extra_flags="-Wunknown-warning-option -Wunused-command-line-argument"
10064 CFLAGS="$CFLAGS $ax_pthread_extra_flags -Wfoobaz -foobaz"
10065 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10066 /* end confdefs.h. */
10076 if ac_fn_c_try_compile "$LINENO"; then :
10077 ax_cv_PTHREAD_REJECT_UNKNOWN="-Werror $ax_pthread_extra_flags"
10079 ax_cv_PTHREAD_REJECT_UNKNOWN=no
10081 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10082 CFLAGS="$save_CFLAGS"
10085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_REJECT_UNKNOWN" >&5
10086 $as_echo "$ax_cv_PTHREAD_REJECT_UNKNOWN" >&6; }
10087 ax_pthread_extra_flags=
10088 if test "x$ax_cv_PTHREAD_REJECT_UNKNOWN" != "xno"; then :
10089 ax_pthread_extra_flags="$ax_cv_PTHREAD_REJECT_UNKNOWN"
10092 if test x"$ax_pthread_ok" = xno; then
10093 for flag in $ax_pthread_flags; do
10097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5
10098 $as_echo_n "checking whether pthreads work without any flags... " >&6; }
10102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with -mt -lpthread" >&5
10103 $as_echo_n "checking whether pthreads work with -mt -lpthread... " >&6; }
10104 PTHREAD_CFLAGS="-mt"
10105 PTHREAD_LIBS="-lpthread"
10109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $flag" >&5
10110 $as_echo_n "checking whether pthreads work with $flag... " >&6; }
10111 PTHREAD_CFLAGS="$flag"
10115 # Extract the first word of "pthread-config", so it can be a program name with args.
10116 set dummy pthread-config; ac_word=$2
10117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10118 $as_echo_n "checking for $ac_word... " >&6; }
10119 if ${ac_cv_prog_ax_pthread_config+:} false; then :
10120 $as_echo_n "(cached) " >&6
10122 if test -n "$ax_pthread_config"; then
10123 ac_cv_prog_ax_pthread_config="$ax_pthread_config" # Let the user override the test.
10125 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10126 for as_dir in $PATH
10129 test -z "$as_dir" && as_dir=.
10130 for ac_exec_ext in '' $ac_executable_extensions; do
10131 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10132 ac_cv_prog_ax_pthread_config="yes"
10133 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10140 test -z "$ac_cv_prog_ax_pthread_config" && ac_cv_prog_ax_pthread_config="no"
10143 ax_pthread_config=$ac_cv_prog_ax_pthread_config
10144 if test -n "$ax_pthread_config"; then
10145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_config" >&5
10146 $as_echo "$ax_pthread_config" >&6; }
10148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10149 $as_echo "no" >&6; }
10153 if test x"$ax_pthread_config" = xno; then continue; fi
10154 PTHREAD_CFLAGS="`pthread-config --cflags`"
10155 PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
10159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$flag" >&5
10160 $as_echo_n "checking for the pthreads library -l$flag... " >&6; }
10161 PTHREAD_LIBS="-l$flag"
10166 save_CFLAGS="$CFLAGS"
10167 LIBS="$PTHREAD_LIBS $LIBS"
10168 CFLAGS="$CFLAGS $PTHREAD_CFLAGS $ax_pthread_extra_flags"
10170 # Check for various functions. We must include pthread.h,
10171 # since some functions may be macros. (On the Sequent, we
10172 # need a special flag -Kthread to make this header compile.)
10173 # We check for pthread_join because it is in -lpthread on IRIX
10174 # while pthread_create is in libc. We check for pthread_attr_init
10175 # due to DEC craziness with -lpthreads. We check for
10176 # pthread_cleanup_push because it is one of the few pthread
10177 # functions on Solaris that doesn't have a non-functional libc stub.
10178 # We try pthread_create on general principles.
10179 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10180 /* end confdefs.h. */
10181 #include <pthread.h>
10182 static void routine(void *a) { a = 0; }
10183 static void *start_routine(void *a) { return a; }
10187 pthread_t th; pthread_attr_t attr;
10188 pthread_create(&th, 0, start_routine, 0);
10189 pthread_join(th, 0);
10190 pthread_attr_init(&attr);
10191 pthread_cleanup_push(routine, 0);
10192 pthread_cleanup_pop(0) /* ; */
10197 if ac_fn_c_try_link "$LINENO"; then :
10200 rm -f core conftest.err conftest.$ac_objext \
10201 conftest$ac_exeext conftest.$ac_ext
10204 CFLAGS="$save_CFLAGS"
10206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
10207 $as_echo "$ax_pthread_ok" >&6; }
10208 if test "x$ax_pthread_ok" = xyes; then
10217 # Various other checks:
10218 if test "x$ax_pthread_ok" = xyes; then
10220 LIBS="$PTHREAD_LIBS $LIBS"
10221 save_CFLAGS="$CFLAGS"
10222 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
10224 # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
10225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5
10226 $as_echo_n "checking for joinable pthread attribute... " >&6; }
10227 if ${ax_cv_PTHREAD_JOINABLE_ATTR+:} false; then :
10228 $as_echo_n "(cached) " >&6
10230 ax_cv_PTHREAD_JOINABLE_ATTR=unknown
10231 for attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
10232 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10233 /* end confdefs.h. */
10234 #include <pthread.h>
10238 int attr = $attr; return attr /* ; */
10243 if ac_fn_c_try_link "$LINENO"; then :
10244 ax_cv_PTHREAD_JOINABLE_ATTR=$attr; break
10246 rm -f core conftest.err conftest.$ac_objext \
10247 conftest$ac_exeext conftest.$ac_ext
10251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_JOINABLE_ATTR" >&5
10252 $as_echo "$ax_cv_PTHREAD_JOINABLE_ATTR" >&6; }
10253 if test "$ax_cv_PTHREAD_JOINABLE_ATTR" != unknown && \
10254 test "$ax_cv_PTHREAD_JOINABLE_ATTR" != PTHREAD_CREATE_JOINABLE; then :
10256 cat >>confdefs.h <<_ACEOF
10257 #define PTHREAD_CREATE_JOINABLE $ax_cv_PTHREAD_JOINABLE_ATTR
10262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if more special flags are required for pthreads" >&5
10263 $as_echo_n "checking if more special flags are required for pthreads... " >&6; }
10264 if ${ax_cv_PTHREAD_SPECIAL_FLAGS+:} false; then :
10265 $as_echo_n "(cached) " >&6
10267 ax_cv_PTHREAD_SPECIAL_FLAGS=no
10268 ax_pthread_special_flags_added=no
10269 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10270 /* end confdefs.h. */
10272 # if !defined(_REENTRANT) && !defined(_THREAD_SAFE)
10273 AX_PTHREAD_NEED_SPECIAL_FLAG
10277 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10278 $EGREP "AX_PTHREAD_NEED_SPECIAL_FLAG" >/dev/null 2>&1; then :
10281 ax_cv_PTHREAD_SPECIAL_FLAGS="-D_THREAD_SAFE"
10283 darwin* | hpux* | osf* | solaris*)
10284 ax_cv_PTHREAD_SPECIAL_FLAGS="-D_REENTRANT"
10293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_SPECIAL_FLAGS" >&5
10294 $as_echo "$ax_cv_PTHREAD_SPECIAL_FLAGS" >&6; }
10295 if test "x$ax_cv_PTHREAD_SPECIAL_FLAGS" != "xno" && \
10296 test "x$ax_pthread_special_flags_added" != "xyes"; then :
10297 PTHREAD_CFLAGS="$ax_cv_PTHREAD_SPECIAL_FLAGS $PTHREAD_CFLAGS"
10298 ax_pthread_special_flags_added=yes
10301 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_PRIO_INHERIT" >&5
10302 $as_echo_n "checking for PTHREAD_PRIO_INHERIT... " >&6; }
10303 if ${ax_cv_PTHREAD_PRIO_INHERIT+:} false; then :
10304 $as_echo_n "(cached) " >&6
10306 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10307 /* end confdefs.h. */
10308 #include <pthread.h>
10312 int i = PTHREAD_PRIO_INHERIT;
10317 if ac_fn_c_try_link "$LINENO"; then :
10318 ax_cv_PTHREAD_PRIO_INHERIT=yes
10320 ax_cv_PTHREAD_PRIO_INHERIT=no
10322 rm -f core conftest.err conftest.$ac_objext \
10323 conftest$ac_exeext conftest.$ac_ext
10326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_PRIO_INHERIT" >&5
10327 $as_echo "$ax_cv_PTHREAD_PRIO_INHERIT" >&6; }
10328 if test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes"; then :
10330 $as_echo "#define HAVE_PTHREAD_PRIO_INHERIT 1" >>confdefs.h
10335 CFLAGS="$save_CFLAGS"
10337 # More AIX lossage: compile with *_r variant
10338 if test "x$GCC" != xyes; then
10342 x*/c89|x*/c89_128|x*/c99|x*/c99_128|x*/cc|x*/cc128|x*/xlc|x*/xlc_v6|x*/xlc128|x*/xlc128_v6) :
10343 #handle absolute path differently from PATH based program lookup
10346 if as_fn_executable_p ${CC}_r; then :
10347 PTHREAD_CC="${CC}_r"
10350 for ac_prog in ${CC}_r
10352 # Extract the first word of "$ac_prog", so it can be a program name with args.
10353 set dummy $ac_prog; ac_word=$2
10354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10355 $as_echo_n "checking for $ac_word... " >&6; }
10356 if ${ac_cv_prog_PTHREAD_CC+:} false; then :
10357 $as_echo_n "(cached) " >&6
10359 if test -n "$PTHREAD_CC"; then
10360 ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
10362 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10363 for as_dir in $PATH
10366 test -z "$as_dir" && as_dir=.
10367 for ac_exec_ext in '' $ac_executable_extensions; do
10368 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10369 ac_cv_prog_PTHREAD_CC="$ac_prog"
10370 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10379 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
10380 if test -n "$PTHREAD_CC"; then
10381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5
10382 $as_echo "$PTHREAD_CC" >&6; }
10384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10385 $as_echo "no" >&6; }
10389 test -n "$PTHREAD_CC" && break
10391 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
10402 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
10408 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
10409 if test x"$ax_pthread_ok" = xyes; then
10411 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
10419 ac_cpp='$CPP $CPPFLAGS'
10420 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10421 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10422 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10426 # Some platforms use these, so just define them. They can't hurt if they
10427 # are not supported. For example, on Solaris -D_POSIX_PTHREAD_SEMANTICS
10428 # enables 5-arg getpwuid_r, among other things.
10429 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
10431 # Check for *_r functions
10434 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
10435 LIBS="$LIBS $PTHREAD_LIBS"
10437 ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
10438 if test "x$ac_cv_header_pthread_h" = xyes; then :
10442 pthread.h not found; use --disable-thread-safety to disable thread safety" "$LINENO" 5
10447 for ac_func in strerror_r getpwuid_r gethostbyname_r
10449 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10450 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10451 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
10452 cat >>confdefs.h <<_ACEOF
10453 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10460 # Do test here with the proper thread flags
10461 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror_r returns int" >&5
10462 $as_echo_n "checking whether strerror_r returns int... " >&6; }
10463 if ${pgac_cv_func_strerror_r_int+:} false; then :
10464 $as_echo_n "(cached) " >&6
10466 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10467 /* end confdefs.h. */
10468 #include <string.h>
10473 switch (strerror_r(1, buf, sizeof(buf)))
10474 { case 0: break; default: break; }
10480 if ac_fn_c_try_compile "$LINENO"; then :
10481 pgac_cv_func_strerror_r_int=yes
10483 pgac_cv_func_strerror_r_int=no
10485 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_func_strerror_r_int" >&5
10488 $as_echo "$pgac_cv_func_strerror_r_int" >&6; }
10489 if test x"$pgac_cv_func_strerror_r_int" = xyes ; then
10491 $as_echo "#define STRERROR_R_INT 1" >>confdefs.h
10502 # do not use values from template file
10515 ## Most libraries are included only if they demonstrably provide a function
10516 ## we need, but libm is an exception: always include it, because there are
10517 ## too many compilers that play cute optimization games that will break
10518 ## probes for standard functions such as pow().
10521 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lm" >&5
10522 $as_echo_n "checking for main in -lm... " >&6; }
10523 if ${ac_cv_lib_m_main+:} false; then :
10524 $as_echo_n "(cached) " >&6
10526 ac_check_lib_save_LIBS=$LIBS
10528 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10529 /* end confdefs.h. */
10540 if ac_fn_c_try_link "$LINENO"; then :
10541 ac_cv_lib_m_main=yes
10543 ac_cv_lib_m_main=no
10545 rm -f core conftest.err conftest.$ac_objext \
10546 conftest$ac_exeext conftest.$ac_ext
10547 LIBS=$ac_check_lib_save_LIBS
10549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_main" >&5
10550 $as_echo "$ac_cv_lib_m_main" >&6; }
10551 if test "x$ac_cv_lib_m_main" = xyes; then :
10552 cat >>confdefs.h <<_ACEOF
10553 #define HAVE_LIBM 1
10560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setproctitle" >&5
10561 $as_echo_n "checking for library containing setproctitle... " >&6; }
10562 if ${ac_cv_search_setproctitle+:} false; then :
10563 $as_echo_n "(cached) " >&6
10565 ac_func_search_save_LIBS=$LIBS
10566 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10567 /* end confdefs.h. */
10569 /* Override any GCC internal prototype to avoid an error.
10570 Use char because int might match the return type of a GCC
10571 builtin and then its argument prototype would still apply. */
10575 char setproctitle ();
10579 return setproctitle ();
10584 for ac_lib in '' util; do
10585 if test -z "$ac_lib"; then
10586 ac_res="none required"
10589 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
10591 if ac_fn_c_try_link "$LINENO"; then :
10592 ac_cv_search_setproctitle=$ac_res
10594 rm -f core conftest.err conftest.$ac_objext \
10596 if ${ac_cv_search_setproctitle+:} false; then :
10600 if ${ac_cv_search_setproctitle+:} false; then :
10603 ac_cv_search_setproctitle=no
10605 rm conftest.$ac_ext
10606 LIBS=$ac_func_search_save_LIBS
10608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setproctitle" >&5
10609 $as_echo "$ac_cv_search_setproctitle" >&6; }
10610 ac_res=$ac_cv_search_setproctitle
10611 if test "$ac_res" != no; then :
10612 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
10616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
10617 $as_echo_n "checking for library containing dlopen... " >&6; }
10618 if ${ac_cv_search_dlopen+:} false; then :
10619 $as_echo_n "(cached) " >&6
10621 ac_func_search_save_LIBS=$LIBS
10622 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10623 /* end confdefs.h. */
10625 /* Override any GCC internal prototype to avoid an error.
10626 Use char because int might match the return type of a GCC
10627 builtin and then its argument prototype would still apply. */
10640 for ac_lib in '' dl; do
10641 if test -z "$ac_lib"; then
10642 ac_res="none required"
10645 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
10647 if ac_fn_c_try_link "$LINENO"; then :
10648 ac_cv_search_dlopen=$ac_res
10650 rm -f core conftest.err conftest.$ac_objext \
10652 if ${ac_cv_search_dlopen+:} false; then :
10656 if ${ac_cv_search_dlopen+:} false; then :
10659 ac_cv_search_dlopen=no
10661 rm conftest.$ac_ext
10662 LIBS=$ac_func_search_save_LIBS
10664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
10665 $as_echo "$ac_cv_search_dlopen" >&6; }
10666 ac_res=$ac_cv_search_dlopen
10667 if test "$ac_res" != no; then :
10668 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
10672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socket" >&5
10673 $as_echo_n "checking for library containing socket... " >&6; }
10674 if ${ac_cv_search_socket+:} false; then :
10675 $as_echo_n "(cached) " >&6
10677 ac_func_search_save_LIBS=$LIBS
10678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10679 /* end confdefs.h. */
10681 /* Override any GCC internal prototype to avoid an error.
10682 Use char because int might match the return type of a GCC
10683 builtin and then its argument prototype would still apply. */
10696 for ac_lib in '' socket ws2_32; do
10697 if test -z "$ac_lib"; then
10698 ac_res="none required"
10701 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
10703 if ac_fn_c_try_link "$LINENO"; then :
10704 ac_cv_search_socket=$ac_res
10706 rm -f core conftest.err conftest.$ac_objext \
10708 if ${ac_cv_search_socket+:} false; then :
10712 if ${ac_cv_search_socket+:} false; then :
10715 ac_cv_search_socket=no
10717 rm conftest.$ac_ext
10718 LIBS=$ac_func_search_save_LIBS
10720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socket" >&5
10721 $as_echo "$ac_cv_search_socket" >&6; }
10722 ac_res=$ac_cv_search_socket
10723 if test "$ac_res" != no; then :
10724 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
10728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing shl_load" >&5
10729 $as_echo_n "checking for library containing shl_load... " >&6; }
10730 if ${ac_cv_search_shl_load+:} false; then :
10731 $as_echo_n "(cached) " >&6
10733 ac_func_search_save_LIBS=$LIBS
10734 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10735 /* end confdefs.h. */
10737 /* Override any GCC internal prototype to avoid an error.
10738 Use char because int might match the return type of a GCC
10739 builtin and then its argument prototype would still apply. */
10747 return shl_load ();
10752 for ac_lib in '' dld; do
10753 if test -z "$ac_lib"; then
10754 ac_res="none required"
10757 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
10759 if ac_fn_c_try_link "$LINENO"; then :
10760 ac_cv_search_shl_load=$ac_res
10762 rm -f core conftest.err conftest.$ac_objext \
10764 if ${ac_cv_search_shl_load+:} false; then :
10768 if ${ac_cv_search_shl_load+:} false; then :
10771 ac_cv_search_shl_load=no
10773 rm conftest.$ac_ext
10774 LIBS=$ac_func_search_save_LIBS
10776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_shl_load" >&5
10777 $as_echo "$ac_cv_search_shl_load" >&6; }
10778 ac_res=$ac_cv_search_shl_load
10779 if test "$ac_res" != no; then :
10780 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
10784 # We only use libld in port/dynloader/aix.c
10787 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing ldopen" >&5
10788 $as_echo_n "checking for library containing ldopen... " >&6; }
10789 if ${ac_cv_search_ldopen+:} false; then :
10790 $as_echo_n "(cached) " >&6
10792 ac_func_search_save_LIBS=$LIBS
10793 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10794 /* end confdefs.h. */
10796 /* Override any GCC internal prototype to avoid an error.
10797 Use char because int might match the return type of a GCC
10798 builtin and then its argument prototype would still apply. */
10811 for ac_lib in '' ld; do
10812 if test -z "$ac_lib"; then
10813 ac_res="none required"
10816 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
10818 if ac_fn_c_try_link "$LINENO"; then :
10819 ac_cv_search_ldopen=$ac_res
10821 rm -f core conftest.err conftest.$ac_objext \
10823 if ${ac_cv_search_ldopen+:} false; then :
10827 if ${ac_cv_search_ldopen+:} false; then :
10830 ac_cv_search_ldopen=no
10832 rm conftest.$ac_ext
10833 LIBS=$ac_func_search_save_LIBS
10835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_ldopen" >&5
10836 $as_echo "$ac_cv_search_ldopen" >&6; }
10837 ac_res=$ac_cv_search_ldopen
10838 if test "$ac_res" != no; then :
10839 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
10845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing getopt_long" >&5
10846 $as_echo_n "checking for library containing getopt_long... " >&6; }
10847 if ${ac_cv_search_getopt_long+:} false; then :
10848 $as_echo_n "(cached) " >&6
10850 ac_func_search_save_LIBS=$LIBS
10851 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10852 /* end confdefs.h. */
10854 /* Override any GCC internal prototype to avoid an error.
10855 Use char because int might match the return type of a GCC
10856 builtin and then its argument prototype would still apply. */
10860 char getopt_long ();
10864 return getopt_long ();
10869 for ac_lib in '' getopt gnugetopt; do
10870 if test -z "$ac_lib"; then
10871 ac_res="none required"
10874 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
10876 if ac_fn_c_try_link "$LINENO"; then :
10877 ac_cv_search_getopt_long=$ac_res
10879 rm -f core conftest.err conftest.$ac_objext \
10881 if ${ac_cv_search_getopt_long+:} false; then :
10885 if ${ac_cv_search_getopt_long+:} false; then :
10888 ac_cv_search_getopt_long=no
10890 rm conftest.$ac_ext
10891 LIBS=$ac_func_search_save_LIBS
10893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getopt_long" >&5
10894 $as_echo "$ac_cv_search_getopt_long" >&6; }
10895 ac_res=$ac_cv_search_getopt_long
10896 if test "$ac_res" != no; then :
10897 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
10901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing crypt" >&5
10902 $as_echo_n "checking for library containing crypt... " >&6; }
10903 if ${ac_cv_search_crypt+:} false; then :
10904 $as_echo_n "(cached) " >&6
10906 ac_func_search_save_LIBS=$LIBS
10907 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10908 /* end confdefs.h. */
10910 /* Override any GCC internal prototype to avoid an error.
10911 Use char because int might match the return type of a GCC
10912 builtin and then its argument prototype would still apply. */
10925 for ac_lib in '' crypt; do
10926 if test -z "$ac_lib"; then
10927 ac_res="none required"
10930 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
10932 if ac_fn_c_try_link "$LINENO"; then :
10933 ac_cv_search_crypt=$ac_res
10935 rm -f core conftest.err conftest.$ac_objext \
10937 if ${ac_cv_search_crypt+:} false; then :
10941 if ${ac_cv_search_crypt+:} false; then :
10944 ac_cv_search_crypt=no
10946 rm conftest.$ac_ext
10947 LIBS=$ac_func_search_save_LIBS
10949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_crypt" >&5
10950 $as_echo "$ac_cv_search_crypt" >&6; }
10951 ac_res=$ac_cv_search_crypt
10952 if test "$ac_res" != no; then :
10953 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
10957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing shm_open" >&5
10958 $as_echo_n "checking for library containing shm_open... " >&6; }
10959 if ${ac_cv_search_shm_open+:} false; then :
10960 $as_echo_n "(cached) " >&6
10962 ac_func_search_save_LIBS=$LIBS
10963 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10964 /* end confdefs.h. */
10966 /* Override any GCC internal prototype to avoid an error.
10967 Use char because int might match the return type of a GCC
10968 builtin and then its argument prototype would still apply. */
10976 return shm_open ();
10981 for ac_lib in '' rt; do
10982 if test -z "$ac_lib"; then
10983 ac_res="none required"
10986 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
10988 if ac_fn_c_try_link "$LINENO"; then :
10989 ac_cv_search_shm_open=$ac_res
10991 rm -f core conftest.err conftest.$ac_objext \
10993 if ${ac_cv_search_shm_open+:} false; then :
10997 if ${ac_cv_search_shm_open+:} false; then :
11000 ac_cv_search_shm_open=no
11002 rm conftest.$ac_ext
11003 LIBS=$ac_func_search_save_LIBS
11005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_shm_open" >&5
11006 $as_echo "$ac_cv_search_shm_open" >&6; }
11007 ac_res=$ac_cv_search_shm_open
11008 if test "$ac_res" != no; then :
11009 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing shm_unlink" >&5
11014 $as_echo_n "checking for library containing shm_unlink... " >&6; }
11015 if ${ac_cv_search_shm_unlink+:} false; then :
11016 $as_echo_n "(cached) " >&6
11018 ac_func_search_save_LIBS=$LIBS
11019 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11020 /* end confdefs.h. */
11022 /* Override any GCC internal prototype to avoid an error.
11023 Use char because int might match the return type of a GCC
11024 builtin and then its argument prototype would still apply. */
11028 char shm_unlink ();
11032 return shm_unlink ();
11037 for ac_lib in '' rt; do
11038 if test -z "$ac_lib"; then
11039 ac_res="none required"
11042 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11044 if ac_fn_c_try_link "$LINENO"; then :
11045 ac_cv_search_shm_unlink=$ac_res
11047 rm -f core conftest.err conftest.$ac_objext \
11049 if ${ac_cv_search_shm_unlink+:} false; then :
11053 if ${ac_cv_search_shm_unlink+:} false; then :
11056 ac_cv_search_shm_unlink=no
11058 rm conftest.$ac_ext
11059 LIBS=$ac_func_search_save_LIBS
11061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_shm_unlink" >&5
11062 $as_echo "$ac_cv_search_shm_unlink" >&6; }
11063 ac_res=$ac_cv_search_shm_unlink
11064 if test "$ac_res" != no; then :
11065 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
11070 $as_echo_n "checking for library containing clock_gettime... " >&6; }
11071 if ${ac_cv_search_clock_gettime+:} false; then :
11072 $as_echo_n "(cached) " >&6
11074 ac_func_search_save_LIBS=$LIBS
11075 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11076 /* end confdefs.h. */
11078 /* Override any GCC internal prototype to avoid an error.
11079 Use char because int might match the return type of a GCC
11080 builtin and then its argument prototype would still apply. */
11084 char clock_gettime ();
11088 return clock_gettime ();
11093 for ac_lib in '' rt posix4; do
11094 if test -z "$ac_lib"; then
11095 ac_res="none required"
11098 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11100 if ac_fn_c_try_link "$LINENO"; then :
11101 ac_cv_search_clock_gettime=$ac_res
11103 rm -f core conftest.err conftest.$ac_objext \
11105 if ${ac_cv_search_clock_gettime+:} false; then :
11109 if ${ac_cv_search_clock_gettime+:} false; then :
11112 ac_cv_search_clock_gettime=no
11114 rm conftest.$ac_ext
11115 LIBS=$ac_func_search_save_LIBS
11117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
11118 $as_echo "$ac_cv_search_clock_gettime" >&6; }
11119 ac_res=$ac_cv_search_clock_gettime
11120 if test "$ac_res" != no; then :
11121 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing fdatasync" >&5
11127 $as_echo_n "checking for library containing fdatasync... " >&6; }
11128 if ${ac_cv_search_fdatasync+:} false; then :
11129 $as_echo_n "(cached) " >&6
11131 ac_func_search_save_LIBS=$LIBS
11132 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11133 /* end confdefs.h. */
11135 /* Override any GCC internal prototype to avoid an error.
11136 Use char because int might match the return type of a GCC
11137 builtin and then its argument prototype would still apply. */
11145 return fdatasync ();
11150 for ac_lib in '' rt posix4; do
11151 if test -z "$ac_lib"; then
11152 ac_res="none required"
11155 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11157 if ac_fn_c_try_link "$LINENO"; then :
11158 ac_cv_search_fdatasync=$ac_res
11160 rm -f core conftest.err conftest.$ac_objext \
11162 if ${ac_cv_search_fdatasync+:} false; then :
11166 if ${ac_cv_search_fdatasync+:} false; then :
11169 ac_cv_search_fdatasync=no
11171 rm conftest.$ac_ext
11172 LIBS=$ac_func_search_save_LIBS
11174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_fdatasync" >&5
11175 $as_echo "$ac_cv_search_fdatasync" >&6; }
11176 ac_res=$ac_cv_search_fdatasync
11177 if test "$ac_res" != no; then :
11178 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11182 # Required for thread_test.c on Solaris
11183 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sched_yield" >&5
11184 $as_echo_n "checking for library containing sched_yield... " >&6; }
11185 if ${ac_cv_search_sched_yield+:} false; then :
11186 $as_echo_n "(cached) " >&6
11188 ac_func_search_save_LIBS=$LIBS
11189 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11190 /* end confdefs.h. */
11192 /* Override any GCC internal prototype to avoid an error.
11193 Use char because int might match the return type of a GCC
11194 builtin and then its argument prototype would still apply. */
11198 char sched_yield ();
11202 return sched_yield ();
11207 for ac_lib in '' rt; do
11208 if test -z "$ac_lib"; then
11209 ac_res="none required"
11212 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11214 if ac_fn_c_try_link "$LINENO"; then :
11215 ac_cv_search_sched_yield=$ac_res
11217 rm -f core conftest.err conftest.$ac_objext \
11219 if ${ac_cv_search_sched_yield+:} false; then :
11223 if ${ac_cv_search_sched_yield+:} false; then :
11226 ac_cv_search_sched_yield=no
11228 rm conftest.$ac_ext
11229 LIBS=$ac_func_search_save_LIBS
11231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sched_yield" >&5
11232 $as_echo "$ac_cv_search_sched_yield" >&6; }
11233 ac_res=$ac_cv_search_sched_yield
11234 if test "$ac_res" != no; then :
11235 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11239 # Required for thread_test.c on Solaris 2.5:
11240 # Other ports use it too (HP-UX) so test unconditionally
11241 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname_r" >&5
11242 $as_echo_n "checking for library containing gethostbyname_r... " >&6; }
11243 if ${ac_cv_search_gethostbyname_r+:} false; then :
11244 $as_echo_n "(cached) " >&6
11246 ac_func_search_save_LIBS=$LIBS
11247 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11248 /* end confdefs.h. */
11250 /* Override any GCC internal prototype to avoid an error.
11251 Use char because int might match the return type of a GCC
11252 builtin and then its argument prototype would still apply. */
11256 char gethostbyname_r ();
11260 return gethostbyname_r ();
11265 for ac_lib in '' nsl; do
11266 if test -z "$ac_lib"; then
11267 ac_res="none required"
11270 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11272 if ac_fn_c_try_link "$LINENO"; then :
11273 ac_cv_search_gethostbyname_r=$ac_res
11275 rm -f core conftest.err conftest.$ac_objext \
11277 if ${ac_cv_search_gethostbyname_r+:} false; then :
11281 if ${ac_cv_search_gethostbyname_r+:} false; then :
11284 ac_cv_search_gethostbyname_r=no
11286 rm conftest.$ac_ext
11287 LIBS=$ac_func_search_save_LIBS
11289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname_r" >&5
11290 $as_echo "$ac_cv_search_gethostbyname_r" >&6; }
11291 ac_res=$ac_cv_search_gethostbyname_r
11292 if test "$ac_res" != no; then :
11293 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11298 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing shmget" >&5
11299 $as_echo_n "checking for library containing shmget... " >&6; }
11300 if ${ac_cv_search_shmget+:} false; then :
11301 $as_echo_n "(cached) " >&6
11303 ac_func_search_save_LIBS=$LIBS
11304 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11305 /* end confdefs.h. */
11307 /* Override any GCC internal prototype to avoid an error.
11308 Use char because int might match the return type of a GCC
11309 builtin and then its argument prototype would still apply. */
11322 for ac_lib in '' cygipc; do
11323 if test -z "$ac_lib"; then
11324 ac_res="none required"
11327 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11329 if ac_fn_c_try_link "$LINENO"; then :
11330 ac_cv_search_shmget=$ac_res
11332 rm -f core conftest.err conftest.$ac_objext \
11334 if ${ac_cv_search_shmget+:} false; then :
11338 if ${ac_cv_search_shmget+:} false; then :
11341 ac_cv_search_shmget=no
11343 rm conftest.$ac_ext
11344 LIBS=$ac_func_search_save_LIBS
11346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_shmget" >&5
11347 $as_echo "$ac_cv_search_shmget" >&6; }
11348 ac_res=$ac_cv_search_shmget
11349 if test "$ac_res" != no; then :
11350 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11355 if test "$with_readline" = yes; then
11358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing readline" >&5
11359 $as_echo_n "checking for library containing readline... " >&6; }
11360 if ${pgac_cv_check_readline+:} false; then :
11361 $as_echo_n "(cached) " >&6
11363 pgac_cv_check_readline=no
11364 pgac_save_LIBS=$LIBS
11365 if test x"$with_libedit_preferred" != x"yes"
11366 then READLINE_ORDER="-lreadline -ledit"
11367 else READLINE_ORDER="-ledit -lreadline"
11369 for pgac_rllib in $READLINE_ORDER ; do
11370 for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
11371 LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
11372 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11373 /* end confdefs.h. */
11375 /* Override any GCC internal prototype to avoid an error.
11376 Use char because int might match the return type of a GCC
11377 builtin and then its argument prototype would still apply. */
11385 return readline ();
11390 if ac_fn_c_try_link "$LINENO"; then :
11392 # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
11393 # recognize dependent libraries; assume curses is needed if we didn't
11394 # find any dependency.
11396 netbsd* | openbsd* | irix*)
11397 if test x"$pgac_lib" = x"" ; then
11398 pgac_lib=" -lcurses"
11402 pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
11406 rm -f core conftest.err conftest.$ac_objext \
11407 conftest$ac_exeext conftest.$ac_ext
11409 if test "$pgac_cv_check_readline" != no ; then
11413 LIBS=$pgac_save_LIBS
11416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_check_readline" >&5
11417 $as_echo "$pgac_cv_check_readline" >&6; }
11418 if test "$pgac_cv_check_readline" != no ; then
11419 LIBS="$pgac_cv_check_readline $LIBS"
11421 $as_echo "#define HAVE_LIBREADLINE 1" >>confdefs.h
11426 if test x"$pgac_cv_check_readline" = x"no"; then
11427 as_fn_error $? "readline library not found
11428 If you have readline already installed, see config.log for details on the
11429 failure. It is possible the compiler isn't looking in the proper directory.
11430 Use --without-readline to disable readline support." "$LINENO" 5
11434 if test "$with_zlib" = yes; then
11435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inflate in -lz" >&5
11436 $as_echo_n "checking for inflate in -lz... " >&6; }
11437 if ${ac_cv_lib_z_inflate+:} false; then :
11438 $as_echo_n "(cached) " >&6
11440 ac_check_lib_save_LIBS=$LIBS
11442 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11443 /* end confdefs.h. */
11445 /* Override any GCC internal prototype to avoid an error.
11446 Use char because int might match the return type of a GCC
11447 builtin and then its argument prototype would still apply. */
11460 if ac_fn_c_try_link "$LINENO"; then :
11461 ac_cv_lib_z_inflate=yes
11463 ac_cv_lib_z_inflate=no
11465 rm -f core conftest.err conftest.$ac_objext \
11466 conftest$ac_exeext conftest.$ac_ext
11467 LIBS=$ac_check_lib_save_LIBS
11469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_inflate" >&5
11470 $as_echo "$ac_cv_lib_z_inflate" >&6; }
11471 if test "x$ac_cv_lib_z_inflate" = xyes; then :
11472 cat >>confdefs.h <<_ACEOF
11473 #define HAVE_LIBZ 1
11479 as_fn_error $? "zlib library not found
11480 If you have zlib already installed, see config.log for details on the
11481 failure. It is possible the compiler isn't looking in the proper directory.
11482 Use --without-zlib to disable zlib support." "$LINENO" 5
11487 if test "$enable_spinlocks" = yes; then
11489 $as_echo "#define HAVE_SPINLOCKS 1" >>confdefs.h
11492 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
11493 *** Not using spinlocks will cause poor performance." >&5
11494 $as_echo "$as_me: WARNING:
11495 *** Not using spinlocks will cause poor performance." >&2;}
11498 if test "$enable_atomics" = yes; then
11500 $as_echo "#define HAVE_ATOMICS 1" >>confdefs.h
11503 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
11504 *** Not using atomic operations will cause poor performance." >&5
11505 $as_echo "$as_me: WARNING:
11506 *** Not using atomic operations will cause poor performance." >&2;}
11509 if test "$with_gssapi" = yes ; then
11510 if test "$PORTNAME" != "win32"; then
11511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gss_init_sec_context" >&5
11512 $as_echo_n "checking for library containing gss_init_sec_context... " >&6; }
11513 if ${ac_cv_search_gss_init_sec_context+:} false; then :
11514 $as_echo_n "(cached) " >&6
11516 ac_func_search_save_LIBS=$LIBS
11517 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11518 /* end confdefs.h. */
11520 /* Override any GCC internal prototype to avoid an error.
11521 Use char because int might match the return type of a GCC
11522 builtin and then its argument prototype would still apply. */
11526 char gss_init_sec_context ();
11530 return gss_init_sec_context ();
11535 for ac_lib in '' gssapi_krb5 gss 'gssapi -lkrb5 -lcrypto'; do
11536 if test -z "$ac_lib"; then
11537 ac_res="none required"
11540 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11542 if ac_fn_c_try_link "$LINENO"; then :
11543 ac_cv_search_gss_init_sec_context=$ac_res
11545 rm -f core conftest.err conftest.$ac_objext \
11547 if ${ac_cv_search_gss_init_sec_context+:} false; then :
11551 if ${ac_cv_search_gss_init_sec_context+:} false; then :
11554 ac_cv_search_gss_init_sec_context=no
11556 rm conftest.$ac_ext
11557 LIBS=$ac_func_search_save_LIBS
11559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gss_init_sec_context" >&5
11560 $as_echo "$ac_cv_search_gss_init_sec_context" >&6; }
11561 ac_res=$ac_cv_search_gss_init_sec_context
11562 if test "$ac_res" != no; then :
11563 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11566 as_fn_error $? "could not find function 'gss_init_sec_context' required for GSSAPI" "$LINENO" 5
11570 LIBS="$LIBS -lgssapi32"
11574 if test "$with_openssl" = yes ; then
11575 if test "$PORTNAME" != "win32"; then
11576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CRYPTO_new_ex_data in -lcrypto" >&5
11577 $as_echo_n "checking for CRYPTO_new_ex_data in -lcrypto... " >&6; }
11578 if ${ac_cv_lib_crypto_CRYPTO_new_ex_data+:} false; then :
11579 $as_echo_n "(cached) " >&6
11581 ac_check_lib_save_LIBS=$LIBS
11582 LIBS="-lcrypto $LIBS"
11583 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11584 /* end confdefs.h. */
11586 /* Override any GCC internal prototype to avoid an error.
11587 Use char because int might match the return type of a GCC
11588 builtin and then its argument prototype would still apply. */
11592 char CRYPTO_new_ex_data ();
11596 return CRYPTO_new_ex_data ();
11601 if ac_fn_c_try_link "$LINENO"; then :
11602 ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
11604 ac_cv_lib_crypto_CRYPTO_new_ex_data=no
11606 rm -f core conftest.err conftest.$ac_objext \
11607 conftest$ac_exeext conftest.$ac_ext
11608 LIBS=$ac_check_lib_save_LIBS
11610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
11611 $as_echo "$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6; }
11612 if test "x$ac_cv_lib_crypto_CRYPTO_new_ex_data" = xyes; then :
11613 cat >>confdefs.h <<_ACEOF
11614 #define HAVE_LIBCRYPTO 1
11617 LIBS="-lcrypto $LIBS"
11620 as_fn_error $? "library 'crypto' is required for OpenSSL" "$LINENO" 5
11623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL_new in -lssl" >&5
11624 $as_echo_n "checking for SSL_new in -lssl... " >&6; }
11625 if ${ac_cv_lib_ssl_SSL_new+:} false; then :
11626 $as_echo_n "(cached) " >&6
11628 ac_check_lib_save_LIBS=$LIBS
11630 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11631 /* end confdefs.h. */
11633 /* Override any GCC internal prototype to avoid an error.
11634 Use char because int might match the return type of a GCC
11635 builtin and then its argument prototype would still apply. */
11648 if ac_fn_c_try_link "$LINENO"; then :
11649 ac_cv_lib_ssl_SSL_new=yes
11651 ac_cv_lib_ssl_SSL_new=no
11653 rm -f core conftest.err conftest.$ac_objext \
11654 conftest$ac_exeext conftest.$ac_ext
11655 LIBS=$ac_check_lib_save_LIBS
11657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ssl_SSL_new" >&5
11658 $as_echo "$ac_cv_lib_ssl_SSL_new" >&6; }
11659 if test "x$ac_cv_lib_ssl_SSL_new" = xyes; then :
11660 cat >>confdefs.h <<_ACEOF
11661 #define HAVE_LIBSSL 1
11667 as_fn_error $? "library 'ssl' is required for OpenSSL" "$LINENO" 5
11671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing CRYPTO_new_ex_data" >&5
11672 $as_echo_n "checking for library containing CRYPTO_new_ex_data... " >&6; }
11673 if ${ac_cv_search_CRYPTO_new_ex_data+:} false; then :
11674 $as_echo_n "(cached) " >&6
11676 ac_func_search_save_LIBS=$LIBS
11677 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11678 /* end confdefs.h. */
11680 /* Override any GCC internal prototype to avoid an error.
11681 Use char because int might match the return type of a GCC
11682 builtin and then its argument prototype would still apply. */
11686 char CRYPTO_new_ex_data ();
11690 return CRYPTO_new_ex_data ();
11695 for ac_lib in '' eay32 crypto; do
11696 if test -z "$ac_lib"; then
11697 ac_res="none required"
11700 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11702 if ac_fn_c_try_link "$LINENO"; then :
11703 ac_cv_search_CRYPTO_new_ex_data=$ac_res
11705 rm -f core conftest.err conftest.$ac_objext \
11707 if ${ac_cv_search_CRYPTO_new_ex_data+:} false; then :
11711 if ${ac_cv_search_CRYPTO_new_ex_data+:} false; then :
11714 ac_cv_search_CRYPTO_new_ex_data=no
11716 rm conftest.$ac_ext
11717 LIBS=$ac_func_search_save_LIBS
11719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_CRYPTO_new_ex_data" >&5
11720 $as_echo "$ac_cv_search_CRYPTO_new_ex_data" >&6; }
11721 ac_res=$ac_cv_search_CRYPTO_new_ex_data
11722 if test "$ac_res" != no; then :
11723 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11726 as_fn_error $? "library 'eay32' or 'crypto' is required for OpenSSL" "$LINENO" 5
11729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing SSL_new" >&5
11730 $as_echo_n "checking for library containing SSL_new... " >&6; }
11731 if ${ac_cv_search_SSL_new+:} false; then :
11732 $as_echo_n "(cached) " >&6
11734 ac_func_search_save_LIBS=$LIBS
11735 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11736 /* end confdefs.h. */
11738 /* Override any GCC internal prototype to avoid an error.
11739 Use char because int might match the return type of a GCC
11740 builtin and then its argument prototype would still apply. */
11753 for ac_lib in '' ssleay32 ssl; do
11754 if test -z "$ac_lib"; then
11755 ac_res="none required"
11758 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11760 if ac_fn_c_try_link "$LINENO"; then :
11761 ac_cv_search_SSL_new=$ac_res
11763 rm -f core conftest.err conftest.$ac_objext \
11765 if ${ac_cv_search_SSL_new+:} false; then :
11769 if ${ac_cv_search_SSL_new+:} false; then :
11772 ac_cv_search_SSL_new=no
11774 rm conftest.$ac_ext
11775 LIBS=$ac_func_search_save_LIBS
11777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_SSL_new" >&5
11778 $as_echo "$ac_cv_search_SSL_new" >&6; }
11779 ac_res=$ac_cv_search_SSL_new
11780 if test "$ac_res" != no; then :
11781 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11784 as_fn_error $? "library 'ssleay32' or 'ssl' is required for OpenSSL" "$LINENO" 5
11788 for ac_func in SSL_clear_options SSL_get_current_compression X509_get_signature_nid
11790 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11791 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11792 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
11793 cat >>confdefs.h <<_ACEOF
11794 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11800 # Functions introduced in OpenSSL 1.1.0. We used to check for
11801 # OPENSSL_VERSION_NUMBER, but that didn't work with 1.1.0, because LibreSSL
11802 # defines OPENSSL_VERSION_NUMBER to claim version 2.0.0, even though it
11803 # doesn't have these OpenSSL 1.1.0 functions. So check for individual
11805 for ac_func in OPENSSL_init_ssl BIO_get_data BIO_meth_new ASN1_STRING_get0_data RAND_OpenSSL
11807 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11808 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11809 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
11810 cat >>confdefs.h <<_ACEOF
11811 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11817 # OpenSSL versions before 1.1.0 required setting callback functions, for
11818 # thread-safety. In 1.1.0, it's no longer required, and CRYPTO_lock()
11819 # function was removed.
11820 for ac_func in CRYPTO_lock
11822 ac_fn_c_check_func "$LINENO" "CRYPTO_lock" "ac_cv_func_CRYPTO_lock"
11823 if test "x$ac_cv_func_CRYPTO_lock" = xyes; then :
11824 cat >>confdefs.h <<_ACEOF
11825 #define HAVE_CRYPTO_LOCK 1
11833 if test "$with_pam" = yes ; then
11834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pam_start in -lpam" >&5
11835 $as_echo_n "checking for pam_start in -lpam... " >&6; }
11836 if ${ac_cv_lib_pam_pam_start+:} false; then :
11837 $as_echo_n "(cached) " >&6
11839 ac_check_lib_save_LIBS=$LIBS
11841 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11842 /* end confdefs.h. */
11844 /* Override any GCC internal prototype to avoid an error.
11845 Use char because int might match the return type of a GCC
11846 builtin and then its argument prototype would still apply. */
11854 return pam_start ();
11859 if ac_fn_c_try_link "$LINENO"; then :
11860 ac_cv_lib_pam_pam_start=yes
11862 ac_cv_lib_pam_pam_start=no
11864 rm -f core conftest.err conftest.$ac_objext \
11865 conftest$ac_exeext conftest.$ac_ext
11866 LIBS=$ac_check_lib_save_LIBS
11868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pam_pam_start" >&5
11869 $as_echo "$ac_cv_lib_pam_pam_start" >&6; }
11870 if test "x$ac_cv_lib_pam_pam_start" = xyes; then :
11871 cat >>confdefs.h <<_ACEOF
11872 #define HAVE_LIBPAM 1
11878 as_fn_error $? "library 'pam' is required for PAM" "$LINENO" 5
11883 if test "$with_libxml" = yes ; then
11884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xmlSaveToBuffer in -lxml2" >&5
11885 $as_echo_n "checking for xmlSaveToBuffer in -lxml2... " >&6; }
11886 if ${ac_cv_lib_xml2_xmlSaveToBuffer+:} false; then :
11887 $as_echo_n "(cached) " >&6
11889 ac_check_lib_save_LIBS=$LIBS
11890 LIBS="-lxml2 $LIBS"
11891 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11892 /* end confdefs.h. */
11894 /* Override any GCC internal prototype to avoid an error.
11895 Use char because int might match the return type of a GCC
11896 builtin and then its argument prototype would still apply. */
11900 char xmlSaveToBuffer ();
11904 return xmlSaveToBuffer ();
11909 if ac_fn_c_try_link "$LINENO"; then :
11910 ac_cv_lib_xml2_xmlSaveToBuffer=yes
11912 ac_cv_lib_xml2_xmlSaveToBuffer=no
11914 rm -f core conftest.err conftest.$ac_objext \
11915 conftest$ac_exeext conftest.$ac_ext
11916 LIBS=$ac_check_lib_save_LIBS
11918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_xmlSaveToBuffer" >&5
11919 $as_echo "$ac_cv_lib_xml2_xmlSaveToBuffer" >&6; }
11920 if test "x$ac_cv_lib_xml2_xmlSaveToBuffer" = xyes; then :
11921 cat >>confdefs.h <<_ACEOF
11922 #define HAVE_LIBXML2 1
11925 LIBS="-lxml2 $LIBS"
11928 as_fn_error $? "library 'xml2' (version >= 2.6.23) is required for XML support" "$LINENO" 5
11933 if test "$with_libxslt" = yes ; then
11934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xsltCleanupGlobals in -lxslt" >&5
11935 $as_echo_n "checking for xsltCleanupGlobals in -lxslt... " >&6; }
11936 if ${ac_cv_lib_xslt_xsltCleanupGlobals+:} false; then :
11937 $as_echo_n "(cached) " >&6
11939 ac_check_lib_save_LIBS=$LIBS
11940 LIBS="-lxslt $LIBS"
11941 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11942 /* end confdefs.h. */
11944 /* Override any GCC internal prototype to avoid an error.
11945 Use char because int might match the return type of a GCC
11946 builtin and then its argument prototype would still apply. */
11950 char xsltCleanupGlobals ();
11954 return xsltCleanupGlobals ();
11959 if ac_fn_c_try_link "$LINENO"; then :
11960 ac_cv_lib_xslt_xsltCleanupGlobals=yes
11962 ac_cv_lib_xslt_xsltCleanupGlobals=no
11964 rm -f core conftest.err conftest.$ac_objext \
11965 conftest$ac_exeext conftest.$ac_ext
11966 LIBS=$ac_check_lib_save_LIBS
11968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xslt_xsltCleanupGlobals" >&5
11969 $as_echo "$ac_cv_lib_xslt_xsltCleanupGlobals" >&6; }
11970 if test "x$ac_cv_lib_xslt_xsltCleanupGlobals" = xyes; then :
11971 cat >>confdefs.h <<_ACEOF
11972 #define HAVE_LIBXSLT 1
11975 LIBS="-lxslt $LIBS"
11978 as_fn_error $? "library 'xslt' is required for XSLT support" "$LINENO" 5
11983 # Note: We can test for libldap_r only after we know PTHREAD_LIBS
11984 if test "$with_ldap" = yes ; then
11986 if test "$PORTNAME" != "win32"; then
11987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ldap_bind in -lldap" >&5
11988 $as_echo_n "checking for ldap_bind in -lldap... " >&6; }
11989 if ${ac_cv_lib_ldap_ldap_bind+:} false; then :
11990 $as_echo_n "(cached) " >&6
11992 ac_check_lib_save_LIBS=$LIBS
11993 LIBS="-lldap $EXTRA_LDAP_LIBS $LIBS"
11994 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11995 /* end confdefs.h. */
11997 /* Override any GCC internal prototype to avoid an error.
11998 Use char because int might match the return type of a GCC
11999 builtin and then its argument prototype would still apply. */
12007 return ldap_bind ();
12012 if ac_fn_c_try_link "$LINENO"; then :
12013 ac_cv_lib_ldap_ldap_bind=yes
12015 ac_cv_lib_ldap_ldap_bind=no
12017 rm -f core conftest.err conftest.$ac_objext \
12018 conftest$ac_exeext conftest.$ac_ext
12019 LIBS=$ac_check_lib_save_LIBS
12021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ldap_ldap_bind" >&5
12022 $as_echo "$ac_cv_lib_ldap_ldap_bind" >&6; }
12023 if test "x$ac_cv_lib_ldap_ldap_bind" = xyes; then :
12024 cat >>confdefs.h <<_ACEOF
12025 #define HAVE_LIBLDAP 1
12028 LIBS="-lldap $LIBS"
12031 as_fn_error $? "library 'ldap' is required for LDAP" "$LINENO" 5
12034 LDAP_LIBS_BE="-lldap $EXTRA_LDAP_LIBS"
12035 if test "$enable_thread_safety" = yes; then
12036 # on some platforms ldap_r fails to link without PTHREAD_LIBS
12037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ldap_simple_bind in -lldap_r" >&5
12038 $as_echo_n "checking for ldap_simple_bind in -lldap_r... " >&6; }
12039 if ${ac_cv_lib_ldap_r_ldap_simple_bind+:} false; then :
12040 $as_echo_n "(cached) " >&6
12042 ac_check_lib_save_LIBS=$LIBS
12043 LIBS="-lldap_r $PTHREAD_CFLAGS $PTHREAD_LIBS $EXTRA_LDAP_LIBS $LIBS"
12044 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12045 /* end confdefs.h. */
12047 /* Override any GCC internal prototype to avoid an error.
12048 Use char because int might match the return type of a GCC
12049 builtin and then its argument prototype would still apply. */
12053 char ldap_simple_bind ();
12057 return ldap_simple_bind ();
12062 if ac_fn_c_try_link "$LINENO"; then :
12063 ac_cv_lib_ldap_r_ldap_simple_bind=yes
12065 ac_cv_lib_ldap_r_ldap_simple_bind=no
12067 rm -f core conftest.err conftest.$ac_objext \
12068 conftest$ac_exeext conftest.$ac_ext
12069 LIBS=$ac_check_lib_save_LIBS
12071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ldap_r_ldap_simple_bind" >&5
12072 $as_echo "$ac_cv_lib_ldap_r_ldap_simple_bind" >&6; }
12073 if test "x$ac_cv_lib_ldap_r_ldap_simple_bind" = xyes; then :
12074 cat >>confdefs.h <<_ACEOF
12075 #define HAVE_LIBLDAP_R 1
12078 LIBS="-lldap_r $LIBS"
12081 as_fn_error $? "library 'ldap_r' is required for LDAP" "$LINENO" 5
12084 LDAP_LIBS_FE="-lldap_r $EXTRA_LDAP_LIBS"
12086 LDAP_LIBS_FE="-lldap $EXTRA_LDAP_LIBS"
12088 for ac_func in ldap_initialize
12090 ac_fn_c_check_func "$LINENO" "ldap_initialize" "ac_cv_func_ldap_initialize"
12091 if test "x$ac_cv_func_ldap_initialize" = xyes; then :
12092 cat >>confdefs.h <<_ACEOF
12093 #define HAVE_LDAP_INITIALIZE 1
12100 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ldap_bind in -lwldap32" >&5
12101 $as_echo_n "checking for ldap_bind in -lwldap32... " >&6; }
12102 if ${ac_cv_lib_wldap32_ldap_bind+:} false; then :
12103 $as_echo_n "(cached) " >&6
12105 ac_check_lib_save_LIBS=$LIBS
12106 LIBS="-lwldap32 $LIBS"
12107 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12108 /* end confdefs.h. */
12110 /* Override any GCC internal prototype to avoid an error.
12111 Use char because int might match the return type of a GCC
12112 builtin and then its argument prototype would still apply. */
12120 return ldap_bind ();
12125 if ac_fn_c_try_link "$LINENO"; then :
12126 ac_cv_lib_wldap32_ldap_bind=yes
12128 ac_cv_lib_wldap32_ldap_bind=no
12130 rm -f core conftest.err conftest.$ac_objext \
12131 conftest$ac_exeext conftest.$ac_ext
12132 LIBS=$ac_check_lib_save_LIBS
12134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_wldap32_ldap_bind" >&5
12135 $as_echo "$ac_cv_lib_wldap32_ldap_bind" >&6; }
12136 if test "x$ac_cv_lib_wldap32_ldap_bind" = xyes; then :
12137 cat >>confdefs.h <<_ACEOF
12138 #define HAVE_LIBWLDAP32 1
12141 LIBS="-lwldap32 $LIBS"
12144 as_fn_error $? "library 'wldap32' is required for LDAP" "$LINENO" 5
12147 LDAP_LIBS_FE="-lwldap32"
12148 LDAP_LIBS_BE="-lwldap32"
12155 # for contrib/sepgsql
12156 if test "$with_selinux" = yes; then
12157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for security_compute_create_name in -lselinux" >&5
12158 $as_echo_n "checking for security_compute_create_name in -lselinux... " >&6; }
12159 if ${ac_cv_lib_selinux_security_compute_create_name+:} false; then :
12160 $as_echo_n "(cached) " >&6
12162 ac_check_lib_save_LIBS=$LIBS
12163 LIBS="-lselinux $LIBS"
12164 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12165 /* end confdefs.h. */
12167 /* Override any GCC internal prototype to avoid an error.
12168 Use char because int might match the return type of a GCC
12169 builtin and then its argument prototype would still apply. */
12173 char security_compute_create_name ();
12177 return security_compute_create_name ();
12182 if ac_fn_c_try_link "$LINENO"; then :
12183 ac_cv_lib_selinux_security_compute_create_name=yes
12185 ac_cv_lib_selinux_security_compute_create_name=no
12187 rm -f core conftest.err conftest.$ac_objext \
12188 conftest$ac_exeext conftest.$ac_ext
12189 LIBS=$ac_check_lib_save_LIBS
12191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_security_compute_create_name" >&5
12192 $as_echo "$ac_cv_lib_selinux_security_compute_create_name" >&6; }
12193 if test "x$ac_cv_lib_selinux_security_compute_create_name" = xyes; then :
12194 cat >>confdefs.h <<_ACEOF
12195 #define HAVE_LIBSELINUX 1
12198 LIBS="-lselinux $LIBS"
12201 as_fn_error $? "library 'libselinux', version 2.1.10 or newer, is required for SELinux support" "$LINENO" 5
12206 # for contrib/uuid-ossp
12207 if test "$with_uuid" = bsd ; then
12208 # On BSD, the UUID functions are in libc
12209 ac_fn_c_check_func "$LINENO" "uuid_to_string" "ac_cv_func_uuid_to_string"
12210 if test "x$ac_cv_func_uuid_to_string" = xyes; then :
12213 as_fn_error $? "BSD UUID functions are not present" "$LINENO" 5
12216 elif test "$with_uuid" = e2fs ; then
12217 # On macOS, the UUID functions are in libc
12218 ac_fn_c_check_func "$LINENO" "uuid_generate" "ac_cv_func_uuid_generate"
12219 if test "x$ac_cv_func_uuid_generate" = xyes; then :
12222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uuid_generate in -luuid" >&5
12223 $as_echo_n "checking for uuid_generate in -luuid... " >&6; }
12224 if ${ac_cv_lib_uuid_uuid_generate+:} false; then :
12225 $as_echo_n "(cached) " >&6
12227 ac_check_lib_save_LIBS=$LIBS
12228 LIBS="-luuid $LIBS"
12229 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12230 /* end confdefs.h. */
12232 /* Override any GCC internal prototype to avoid an error.
12233 Use char because int might match the return type of a GCC
12234 builtin and then its argument prototype would still apply. */
12238 char uuid_generate ();
12242 return uuid_generate ();
12247 if ac_fn_c_try_link "$LINENO"; then :
12248 ac_cv_lib_uuid_uuid_generate=yes
12250 ac_cv_lib_uuid_uuid_generate=no
12252 rm -f core conftest.err conftest.$ac_objext \
12253 conftest$ac_exeext conftest.$ac_ext
12254 LIBS=$ac_check_lib_save_LIBS
12256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_uuid_uuid_generate" >&5
12257 $as_echo "$ac_cv_lib_uuid_uuid_generate" >&6; }
12258 if test "x$ac_cv_lib_uuid_uuid_generate" = xyes; then :
12261 as_fn_error $? "library 'uuid' is required for E2FS UUID" "$LINENO" 5
12266 elif test "$with_uuid" = ossp ; then
12267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uuid_export in -lossp-uuid" >&5
12268 $as_echo_n "checking for uuid_export in -lossp-uuid... " >&6; }
12269 if ${ac_cv_lib_ossp_uuid_uuid_export+:} false; then :
12270 $as_echo_n "(cached) " >&6
12272 ac_check_lib_save_LIBS=$LIBS
12273 LIBS="-lossp-uuid $LIBS"
12274 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12275 /* end confdefs.h. */
12277 /* Override any GCC internal prototype to avoid an error.
12278 Use char because int might match the return type of a GCC
12279 builtin and then its argument prototype would still apply. */
12283 char uuid_export ();
12287 return uuid_export ();
12292 if ac_fn_c_try_link "$LINENO"; then :
12293 ac_cv_lib_ossp_uuid_uuid_export=yes
12295 ac_cv_lib_ossp_uuid_uuid_export=no
12297 rm -f core conftest.err conftest.$ac_objext \
12298 conftest$ac_exeext conftest.$ac_ext
12299 LIBS=$ac_check_lib_save_LIBS
12301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossp_uuid_uuid_export" >&5
12302 $as_echo "$ac_cv_lib_ossp_uuid_uuid_export" >&6; }
12303 if test "x$ac_cv_lib_ossp_uuid_uuid_export" = xyes; then :
12304 UUID_LIBS="-lossp-uuid"
12306 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uuid_export in -luuid" >&5
12307 $as_echo_n "checking for uuid_export in -luuid... " >&6; }
12308 if ${ac_cv_lib_uuid_uuid_export+:} false; then :
12309 $as_echo_n "(cached) " >&6
12311 ac_check_lib_save_LIBS=$LIBS
12312 LIBS="-luuid $LIBS"
12313 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12314 /* end confdefs.h. */
12316 /* Override any GCC internal prototype to avoid an error.
12317 Use char because int might match the return type of a GCC
12318 builtin and then its argument prototype would still apply. */
12322 char uuid_export ();
12326 return uuid_export ();
12331 if ac_fn_c_try_link "$LINENO"; then :
12332 ac_cv_lib_uuid_uuid_export=yes
12334 ac_cv_lib_uuid_uuid_export=no
12336 rm -f core conftest.err conftest.$ac_objext \
12337 conftest$ac_exeext conftest.$ac_ext
12338 LIBS=$ac_check_lib_save_LIBS
12340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_uuid_uuid_export" >&5
12341 $as_echo "$ac_cv_lib_uuid_uuid_export" >&6; }
12342 if test "x$ac_cv_lib_uuid_uuid_export" = xyes; then :
12345 as_fn_error $? "library 'ossp-uuid' or 'uuid' is required for OSSP UUID" "$LINENO" 5
12358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
12359 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
12360 if ${ac_cv_header_stdbool_h+:} false; then :
12361 $as_echo_n "(cached) " >&6
12363 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12364 /* end confdefs.h. */
12366 #include <stdbool.h>
12368 "error: bool is not defined"
12371 "error: false is not defined"
12374 "error: false is not 0"
12377 "error: true is not defined"
12380 "error: true is not 1"
12382 #ifndef __bool_true_false_are_defined
12383 "error: __bool_true_false_are_defined is not defined"
12386 struct s { _Bool s: 1; _Bool t; } s;
12388 char a[true == 1 ? 1 : -1];
12389 char b[false == 0 ? 1 : -1];
12390 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
12391 char d[(bool) 0.5 == true ? 1 : -1];
12392 /* See body of main program for 'e'. */
12393 char f[(_Bool) 0.0 == false ? 1 : -1];
12395 char h[sizeof (_Bool)];
12396 char i[sizeof s.t];
12397 enum { j = false, k = true, l = false * true, m = true * 256 };
12398 /* The following fails for
12399 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
12401 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
12402 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
12403 /* Catch a bug in an HP-UX C compiler. See
12404 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
12405 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
12417 /* Refer to every declared value, to avoid compiler optimizations. */
12418 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
12419 + !m + !n + !o + !p + !q + !pq);
12425 if ac_fn_c_try_compile "$LINENO"; then :
12426 ac_cv_header_stdbool_h=yes
12428 ac_cv_header_stdbool_h=no
12430 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
12433 $as_echo "$ac_cv_header_stdbool_h" >&6; }
12434 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
12435 if test "x$ac_cv_type__Bool" = xyes; then :
12437 cat >>confdefs.h <<_ACEOF
12438 #define HAVE__BOOL 1
12445 if test $ac_cv_header_stdbool_h = yes; then
12447 $as_echo "#define HAVE_STDBOOL_H 1" >>confdefs.h
12452 for ac_header in atomic.h crypt.h dld.h fp_class.h getopt.h ieeefp.h ifaddrs.h langinfo.h mbarrier.h poll.h sys/epoll.h sys/ipc.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
12454 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12455 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12456 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
12457 cat >>confdefs.h <<_ACEOF
12458 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12466 # On BSD, test for net/if.h will fail unless sys/socket.h
12467 # is included first.
12468 for ac_header in net/if.h
12470 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
12471 #include <sys/socket.h>
12474 if test "x$ac_cv_header_net_if_h" = xyes; then :
12475 cat >>confdefs.h <<_ACEOF
12476 #define HAVE_NET_IF_H 1
12484 # On OpenBSD, test for sys/ucred.h will fail unless sys/param.h
12485 # is included first.
12486 for ac_header in sys/ucred.h
12488 ac_fn_c_check_header_compile "$LINENO" "sys/ucred.h" "ac_cv_header_sys_ucred_h" "$ac_includes_default
12489 #include <sys/param.h>
12492 if test "x$ac_cv_header_sys_ucred_h" = xyes; then :
12493 cat >>confdefs.h <<_ACEOF
12494 #define HAVE_SYS_UCRED_H 1
12502 # At least on IRIX, test for netinet/tcp.h will fail unless
12503 # netinet/in.h is included first.
12504 for ac_header in netinet/tcp.h
12506 ac_fn_c_check_header_compile "$LINENO" "netinet/tcp.h" "ac_cv_header_netinet_tcp_h" "$ac_includes_default
12507 #include <netinet/in.h>
12510 if test "x$ac_cv_header_netinet_tcp_h" = xyes; then :
12511 cat >>confdefs.h <<_ACEOF
12512 #define HAVE_NETINET_TCP_H 1
12520 if expr x"$pgac_cv_check_readline" : 'x-lreadline' >/dev/null ; then
12521 for ac_header in readline/readline.h
12523 ac_fn_c_check_header_mongrel "$LINENO" "readline/readline.h" "ac_cv_header_readline_readline_h" "$ac_includes_default"
12524 if test "x$ac_cv_header_readline_readline_h" = xyes; then :
12525 cat >>confdefs.h <<_ACEOF
12526 #define HAVE_READLINE_READLINE_H 1
12530 for ac_header in readline.h
12532 ac_fn_c_check_header_mongrel "$LINENO" "readline.h" "ac_cv_header_readline_h" "$ac_includes_default"
12533 if test "x$ac_cv_header_readline_h" = xyes; then :
12534 cat >>confdefs.h <<_ACEOF
12535 #define HAVE_READLINE_H 1
12539 as_fn_error $? "readline header not found
12540 If you have readline already installed, see config.log for details on the
12541 failure. It is possible the compiler isn't looking in the proper directory.
12542 Use --without-readline to disable readline support." "$LINENO" 5
12551 for ac_header in readline/history.h
12553 ac_fn_c_check_header_mongrel "$LINENO" "readline/history.h" "ac_cv_header_readline_history_h" "$ac_includes_default"
12554 if test "x$ac_cv_header_readline_history_h" = xyes; then :
12555 cat >>confdefs.h <<_ACEOF
12556 #define HAVE_READLINE_HISTORY_H 1
12560 for ac_header in history.h
12562 ac_fn_c_check_header_mongrel "$LINENO" "history.h" "ac_cv_header_history_h" "$ac_includes_default"
12563 if test "x$ac_cv_header_history_h" = xyes; then :
12564 cat >>confdefs.h <<_ACEOF
12565 #define HAVE_HISTORY_H 1
12569 as_fn_error $? "history header not found
12570 If you have readline already installed, see config.log for details on the
12571 failure. It is possible the compiler isn't looking in the proper directory.
12572 Use --without-readline to disable readline support." "$LINENO" 5
12583 if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then
12584 # Some installations of libedit usurp /usr/include/readline/, which seems
12585 # bad practice, since in combined installations readline will have its headers
12586 # there. We might have to resort to AC_EGREP checks to make sure we found
12587 # the proper header...
12588 for ac_header in editline/readline.h
12590 ac_fn_c_check_header_mongrel "$LINENO" "editline/readline.h" "ac_cv_header_editline_readline_h" "$ac_includes_default"
12591 if test "x$ac_cv_header_editline_readline_h" = xyes; then :
12592 cat >>confdefs.h <<_ACEOF
12593 #define HAVE_EDITLINE_READLINE_H 1
12597 for ac_header in readline.h
12599 ac_fn_c_check_header_mongrel "$LINENO" "readline.h" "ac_cv_header_readline_h" "$ac_includes_default"
12600 if test "x$ac_cv_header_readline_h" = xyes; then :
12601 cat >>confdefs.h <<_ACEOF
12602 #define HAVE_READLINE_H 1
12606 for ac_header in readline/readline.h
12608 ac_fn_c_check_header_mongrel "$LINENO" "readline/readline.h" "ac_cv_header_readline_readline_h" "$ac_includes_default"
12609 if test "x$ac_cv_header_readline_readline_h" = xyes; then :
12610 cat >>confdefs.h <<_ACEOF
12611 #define HAVE_READLINE_READLINE_H 1
12615 as_fn_error $? "readline header not found
12616 If you have libedit already installed, see config.log for details on the
12617 failure. It is possible the compiler isn't looking in the proper directory.
12618 Use --without-readline to disable libedit support." "$LINENO" 5
12631 # Note: in a libedit installation, history.h is sometimes a dummy, and may
12632 # not be there at all. Hence, don't complain if not found. We must check
12633 # though, since in yet other versions it is an independent header.
12634 for ac_header in editline/history.h
12636 ac_fn_c_check_header_mongrel "$LINENO" "editline/history.h" "ac_cv_header_editline_history_h" "$ac_includes_default"
12637 if test "x$ac_cv_header_editline_history_h" = xyes; then :
12638 cat >>confdefs.h <<_ACEOF
12639 #define HAVE_EDITLINE_HISTORY_H 1
12643 for ac_header in history.h
12645 ac_fn_c_check_header_mongrel "$LINENO" "history.h" "ac_cv_header_history_h" "$ac_includes_default"
12646 if test "x$ac_cv_header_history_h" = xyes; then :
12647 cat >>confdefs.h <<_ACEOF
12648 #define HAVE_HISTORY_H 1
12652 for ac_header in readline/history.h
12654 ac_fn_c_check_header_mongrel "$LINENO" "readline/history.h" "ac_cv_header_readline_history_h" "$ac_includes_default"
12655 if test "x$ac_cv_header_readline_history_h" = xyes; then :
12656 cat >>confdefs.h <<_ACEOF
12657 #define HAVE_READLINE_HISTORY_H 1
12674 if test "$with_zlib" = yes; then
12675 ac_fn_c_check_header_mongrel "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default"
12676 if test "x$ac_cv_header_zlib_h" = xyes; then :
12679 as_fn_error $? "zlib header not found
12680 If you have zlib already installed, see config.log for details on the
12681 failure. It is possible the compiler isn't looking in the proper directory.
12682 Use --without-zlib to disable zlib support." "$LINENO" 5
12688 if test "$with_gssapi" = yes ; then
12689 for ac_header in gssapi/gssapi.h
12691 ac_fn_c_check_header_mongrel "$LINENO" "gssapi/gssapi.h" "ac_cv_header_gssapi_gssapi_h" "$ac_includes_default"
12692 if test "x$ac_cv_header_gssapi_gssapi_h" = xyes; then :
12693 cat >>confdefs.h <<_ACEOF
12694 #define HAVE_GSSAPI_GSSAPI_H 1
12698 for ac_header in gssapi.h
12700 ac_fn_c_check_header_mongrel "$LINENO" "gssapi.h" "ac_cv_header_gssapi_h" "$ac_includes_default"
12701 if test "x$ac_cv_header_gssapi_h" = xyes; then :
12702 cat >>confdefs.h <<_ACEOF
12703 #define HAVE_GSSAPI_H 1
12707 as_fn_error $? "gssapi.h header file is required for GSSAPI" "$LINENO" 5
12718 if test "$with_openssl" = yes ; then
12719 ac_fn_c_check_header_mongrel "$LINENO" "openssl/ssl.h" "ac_cv_header_openssl_ssl_h" "$ac_includes_default"
12720 if test "x$ac_cv_header_openssl_ssl_h" = xyes; then :
12723 as_fn_error $? "header file <openssl/ssl.h> is required for OpenSSL" "$LINENO" 5
12727 ac_fn_c_check_header_mongrel "$LINENO" "openssl/err.h" "ac_cv_header_openssl_err_h" "$ac_includes_default"
12728 if test "x$ac_cv_header_openssl_err_h" = xyes; then :
12731 as_fn_error $? "header file <openssl/err.h> is required for OpenSSL" "$LINENO" 5
12737 if test "$with_pam" = yes ; then
12738 for ac_header in security/pam_appl.h
12740 ac_fn_c_check_header_mongrel "$LINENO" "security/pam_appl.h" "ac_cv_header_security_pam_appl_h" "$ac_includes_default"
12741 if test "x$ac_cv_header_security_pam_appl_h" = xyes; then :
12742 cat >>confdefs.h <<_ACEOF
12743 #define HAVE_SECURITY_PAM_APPL_H 1
12747 for ac_header in pam/pam_appl.h
12749 ac_fn_c_check_header_mongrel "$LINENO" "pam/pam_appl.h" "ac_cv_header_pam_pam_appl_h" "$ac_includes_default"
12750 if test "x$ac_cv_header_pam_pam_appl_h" = xyes; then :
12751 cat >>confdefs.h <<_ACEOF
12752 #define HAVE_PAM_PAM_APPL_H 1
12756 as_fn_error $? "header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." "$LINENO" 5
12767 if test "$with_bsd_auth" = yes ; then
12768 ac_fn_c_check_header_mongrel "$LINENO" "bsd_auth.h" "ac_cv_header_bsd_auth_h" "$ac_includes_default"
12769 if test "x$ac_cv_header_bsd_auth_h" = xyes; then :
12772 as_fn_error $? "header file <bsd_auth.h> is required for BSD Authentication support" "$LINENO" 5
12778 if test "$with_systemd" = yes ; then
12779 ac_fn_c_check_header_mongrel "$LINENO" "systemd/sd-daemon.h" "ac_cv_header_systemd_sd_daemon_h" "$ac_includes_default"
12780 if test "x$ac_cv_header_systemd_sd_daemon_h" = xyes; then :
12783 as_fn_error $? "header file <systemd/sd-daemon.h> is required for systemd support" "$LINENO" 5
12789 if test "$with_libxml" = yes ; then
12790 ac_fn_c_check_header_mongrel "$LINENO" "libxml/parser.h" "ac_cv_header_libxml_parser_h" "$ac_includes_default"
12791 if test "x$ac_cv_header_libxml_parser_h" = xyes; then :
12794 as_fn_error $? "header file <libxml/parser.h> is required for XML support" "$LINENO" 5
12800 if test "$with_libxslt" = yes ; then
12801 ac_fn_c_check_header_mongrel "$LINENO" "libxslt/xslt.h" "ac_cv_header_libxslt_xslt_h" "$ac_includes_default"
12802 if test "x$ac_cv_header_libxslt_xslt_h" = xyes; then :
12805 as_fn_error $? "header file <libxslt/xslt.h> is required for XSLT support" "$LINENO" 5
12811 if test "$with_ldap" = yes ; then
12812 if test "$PORTNAME" != "win32"; then
12813 for ac_header in ldap.h
12815 ac_fn_c_check_header_mongrel "$LINENO" "ldap.h" "ac_cv_header_ldap_h" "$ac_includes_default"
12816 if test "x$ac_cv_header_ldap_h" = xyes; then :
12817 cat >>confdefs.h <<_ACEOF
12818 #define HAVE_LDAP_H 1
12822 as_fn_error $? "header file <ldap.h> is required for LDAP" "$LINENO" 5
12827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compatible LDAP implementation" >&5
12828 $as_echo_n "checking for compatible LDAP implementation... " >&6; }
12829 if ${pgac_cv_ldap_safe+:} false; then :
12830 $as_echo_n "(cached) " >&6
12832 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12833 /* end confdefs.h. */
12835 #if !defined(LDAP_VENDOR_VERSION) || \
12836 (defined(LDAP_API_FEATURE_X_OPENLDAP) && \
12837 LDAP_VENDOR_VERSION >= 20424 && LDAP_VENDOR_VERSION <= 20431)
12848 if ac_fn_c_try_compile "$LINENO"; then :
12849 pgac_cv_ldap_safe=yes
12851 pgac_cv_ldap_safe=no
12853 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_ldap_safe" >&5
12856 $as_echo "$pgac_cv_ldap_safe" >&6; }
12858 if test "$pgac_cv_ldap_safe" != yes; then
12859 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
12860 *** With OpenLDAP versions 2.4.24 through 2.4.31, inclusive, each backend
12861 *** process that loads libpq (via WAL receiver, dblink, or postgres_fdw) and
12862 *** also uses LDAP will crash on exit." >&5
12863 $as_echo "$as_me: WARNING:
12864 *** With OpenLDAP versions 2.4.24 through 2.4.31, inclusive, each backend
12865 *** process that loads libpq (via WAL receiver, dblink, or postgres_fdw) and
12866 *** also uses LDAP will crash on exit." >&2;}
12869 for ac_header in winldap.h
12871 ac_fn_c_check_header_compile "$LINENO" "winldap.h" "ac_cv_header_winldap_h" "$ac_includes_default
12872 #include <windows.h>
12875 if test "x$ac_cv_header_winldap_h" = xyes; then :
12876 cat >>confdefs.h <<_ACEOF
12877 #define HAVE_WINLDAP_H 1
12881 as_fn_error $? "header file <winldap.h> is required for LDAP" "$LINENO" 5
12889 if test "$with_bonjour" = yes ; then
12890 ac_fn_c_check_header_mongrel "$LINENO" "dns_sd.h" "ac_cv_header_dns_sd_h" "$ac_includes_default"
12891 if test "x$ac_cv_header_dns_sd_h" = xyes; then :
12894 as_fn_error $? "header file <dns_sd.h> is required for Bonjour" "$LINENO" 5
12900 # for contrib/uuid-ossp
12901 if test "$with_uuid" = bsd ; then
12902 for ac_header in uuid.h
12904 ac_fn_c_check_header_mongrel "$LINENO" "uuid.h" "ac_cv_header_uuid_h" "$ac_includes_default"
12905 if test "x$ac_cv_header_uuid_h" = xyes; then :
12906 cat >>confdefs.h <<_ACEOF
12907 #define HAVE_UUID_H 1
12909 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12910 /* end confdefs.h. */
12914 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12915 $EGREP "uuid_to_string" >/dev/null 2>&1; then :
12918 as_fn_error $? "header file <uuid.h> does not match BSD UUID library" "$LINENO" 5
12923 as_fn_error $? "header file <uuid.h> is required for BSD UUID" "$LINENO" 5
12928 elif test "$with_uuid" = e2fs ; then
12929 for ac_header in uuid/uuid.h
12931 ac_fn_c_check_header_mongrel "$LINENO" "uuid/uuid.h" "ac_cv_header_uuid_uuid_h" "$ac_includes_default"
12932 if test "x$ac_cv_header_uuid_uuid_h" = xyes; then :
12933 cat >>confdefs.h <<_ACEOF
12934 #define HAVE_UUID_UUID_H 1
12936 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12937 /* end confdefs.h. */
12938 #include <uuid/uuid.h>
12941 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12942 $EGREP "uuid_generate" >/dev/null 2>&1; then :
12945 as_fn_error $? "header file <uuid/uuid.h> does not match E2FS UUID library" "$LINENO" 5
12950 for ac_header in uuid.h
12952 ac_fn_c_check_header_mongrel "$LINENO" "uuid.h" "ac_cv_header_uuid_h" "$ac_includes_default"
12953 if test "x$ac_cv_header_uuid_h" = xyes; then :
12954 cat >>confdefs.h <<_ACEOF
12955 #define HAVE_UUID_H 1
12957 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12958 /* end confdefs.h. */
12962 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12963 $EGREP "uuid_generate" >/dev/null 2>&1; then :
12966 as_fn_error $? "header file <uuid.h> does not match E2FS UUID library" "$LINENO" 5
12971 as_fn_error $? "header file <uuid/uuid.h> or <uuid.h> is required for E2FS UUID" "$LINENO" 5
12980 elif test "$with_uuid" = ossp ; then
12981 for ac_header in ossp/uuid.h
12983 ac_fn_c_check_header_mongrel "$LINENO" "ossp/uuid.h" "ac_cv_header_ossp_uuid_h" "$ac_includes_default"
12984 if test "x$ac_cv_header_ossp_uuid_h" = xyes; then :
12985 cat >>confdefs.h <<_ACEOF
12986 #define HAVE_OSSP_UUID_H 1
12988 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12989 /* end confdefs.h. */
12990 #include <ossp/uuid.h>
12993 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12994 $EGREP "uuid_export" >/dev/null 2>&1; then :
12997 as_fn_error $? "header file <ossp/uuid.h> does not match OSSP UUID library" "$LINENO" 5
13002 for ac_header in uuid.h
13004 ac_fn_c_check_header_mongrel "$LINENO" "uuid.h" "ac_cv_header_uuid_h" "$ac_includes_default"
13005 if test "x$ac_cv_header_uuid_h" = xyes; then :
13006 cat >>confdefs.h <<_ACEOF
13007 #define HAVE_UUID_H 1
13009 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13010 /* end confdefs.h. */
13014 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13015 $EGREP "uuid_export" >/dev/null 2>&1; then :
13018 as_fn_error $? "header file <uuid.h> does not match OSSP UUID library" "$LINENO" 5
13023 as_fn_error $? "header file <ossp/uuid.h> or <uuid.h> is required for OSSP UUID" "$LINENO" 5
13034 if test "$PORTNAME" = "win32" ; then
13035 for ac_header in crtdefs.h
13037 ac_fn_c_check_header_mongrel "$LINENO" "crtdefs.h" "ac_cv_header_crtdefs_h" "$ac_includes_default"
13038 if test "x$ac_cv_header_crtdefs_h" = xyes; then :
13039 cat >>confdefs.h <<_ACEOF
13040 #define HAVE_CRTDEFS_H 1
13050 ## Types, structures, compiler characteristics
13053 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
13054 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
13055 if ${ac_cv_c_bigendian+:} false; then :
13056 $as_echo_n "(cached) " >&6
13058 ac_cv_c_bigendian=unknown
13059 # See if we're dealing with a universal compiler.
13060 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13061 /* end confdefs.h. */
13062 #ifndef __APPLE_CC__
13063 not a universal capable compiler
13068 if ac_fn_c_try_compile "$LINENO"; then :
13070 # Check for potential -arch flags. It is not universal unless
13071 # there are at least two -arch flags with different values.
13074 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
13075 if test -n "$ac_prev"; then
13077 i?86 | x86_64 | ppc | ppc64)
13078 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
13081 ac_cv_c_bigendian=universal
13087 elif test "x$ac_word" = "x-arch"; then
13092 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13093 if test $ac_cv_c_bigendian = unknown; then
13094 # See if sys/param.h defines the BYTE_ORDER macro.
13095 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13096 /* end confdefs.h. */
13097 #include <sys/types.h>
13098 #include <sys/param.h>
13103 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
13104 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
13106 bogus endian macros
13113 if ac_fn_c_try_compile "$LINENO"; then :
13114 # It does; now see whether it defined to BIG_ENDIAN or not.
13115 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13116 /* end confdefs.h. */
13117 #include <sys/types.h>
13118 #include <sys/param.h>
13123 #if BYTE_ORDER != BIG_ENDIAN
13131 if ac_fn_c_try_compile "$LINENO"; then :
13132 ac_cv_c_bigendian=yes
13134 ac_cv_c_bigendian=no
13136 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13138 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13140 if test $ac_cv_c_bigendian = unknown; then
13141 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
13142 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13143 /* end confdefs.h. */
13144 #include <limits.h>
13149 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
13150 bogus endian macros
13157 if ac_fn_c_try_compile "$LINENO"; then :
13158 # It does; now see whether it defined to _BIG_ENDIAN or not.
13159 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13160 /* end confdefs.h. */
13161 #include <limits.h>
13166 #ifndef _BIG_ENDIAN
13174 if ac_fn_c_try_compile "$LINENO"; then :
13175 ac_cv_c_bigendian=yes
13177 ac_cv_c_bigendian=no
13179 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13181 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13183 if test $ac_cv_c_bigendian = unknown; then
13184 # Compile a test program.
13185 if test "$cross_compiling" = yes; then :
13186 # Try to guess by grepping values from an object file.
13187 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13188 /* end confdefs.h. */
13189 short int ascii_mm[] =
13190 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
13191 short int ascii_ii[] =
13192 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
13193 int use_ascii (int i) {
13194 return ascii_mm[i] + ascii_ii[i];
13196 short int ebcdic_ii[] =
13197 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
13198 short int ebcdic_mm[] =
13199 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
13200 int use_ebcdic (int i) {
13201 return ebcdic_mm[i] + ebcdic_ii[i];
13208 return use_ascii (foo) == use_ebcdic (foo);
13213 if ac_fn_c_try_compile "$LINENO"; then :
13214 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
13215 ac_cv_c_bigendian=yes
13217 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
13218 if test "$ac_cv_c_bigendian" = unknown; then
13219 ac_cv_c_bigendian=no
13221 # finding both strings is unlikely to happen, but who knows?
13222 ac_cv_c_bigendian=unknown
13226 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13228 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13229 /* end confdefs.h. */
13230 $ac_includes_default
13235 /* Are we little or big endian? From Harbison&Steele. */
13239 char c[sizeof (long int)];
13242 return u.c[sizeof (long int) - 1] == 1;
13248 if ac_fn_c_try_run "$LINENO"; then :
13249 ac_cv_c_bigendian=no
13251 ac_cv_c_bigendian=yes
13253 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13254 conftest.$ac_objext conftest.beam conftest.$ac_ext
13259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
13260 $as_echo "$ac_cv_c_bigendian" >&6; }
13261 case $ac_cv_c_bigendian in #(
13263 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
13269 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
13273 as_fn_error $? "unknown endianness
13274 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
13277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
13278 $as_echo_n "checking for inline... " >&6; }
13279 if ${ac_cv_c_inline+:} false; then :
13280 $as_echo_n "(cached) " >&6
13283 for ac_kw in inline __inline__ __inline; do
13284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13285 /* end confdefs.h. */
13286 #ifndef __cplusplus
13288 static $ac_kw foo_t static_foo () {return 0; }
13289 $ac_kw foo_t foo () {return 0; }
13293 if ac_fn_c_try_compile "$LINENO"; then :
13294 ac_cv_c_inline=$ac_kw
13296 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13297 test "$ac_cv_c_inline" != no && break
13301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
13302 $as_echo "$ac_cv_c_inline" >&6; }
13304 case $ac_cv_c_inline in
13307 case $ac_cv_c_inline in
13309 *) ac_val=$ac_cv_c_inline;;
13311 cat >>confdefs.h <<_ACEOF
13312 #ifndef __cplusplus
13313 #define inline $ac_val
13319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for printf format archetype" >&5
13320 $as_echo_n "checking for printf format archetype... " >&6; }
13321 if ${pgac_cv_printf_archetype+:} false; then :
13322 $as_echo_n "(cached) " >&6
13324 ac_save_c_werror_flag=$ac_c_werror_flag
13325 ac_c_werror_flag=yes
13326 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13327 /* end confdefs.h. */
13329 pgac_write(int ignore, const char *fmt,...)
13330 __attribute__((format(gnu_printf, 2, 3)));
13339 if ac_fn_c_try_compile "$LINENO"; then :
13340 pgac_cv_printf_archetype=gnu_printf
13342 pgac_cv_printf_archetype=printf
13344 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13345 ac_c_werror_flag=$ac_save_c_werror_flag
13347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_printf_archetype" >&5
13348 $as_echo "$pgac_cv_printf_archetype" >&6; }
13350 cat >>confdefs.h <<_ACEOF
13351 #define PG_PRINTF_ATTRIBUTE $pgac_cv_printf_archetype
13356 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flexible array members" >&5
13357 $as_echo_n "checking for flexible array members... " >&6; }
13358 if ${ac_cv_c_flexmember+:} false; then :
13359 $as_echo_n "(cached) " >&6
13361 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13362 /* end confdefs.h. */
13363 #include <stdlib.h>
13365 #include <stddef.h>
13366 struct s { int n; double d[]; };
13370 int m = getchar ();
13371 struct s *p = malloc (offsetof (struct s, d)
13372 + m * sizeof (double));
13374 return p->d != (double *) NULL;
13379 if ac_fn_c_try_compile "$LINENO"; then :
13380 ac_cv_c_flexmember=yes
13382 ac_cv_c_flexmember=no
13384 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_flexmember" >&5
13387 $as_echo "$ac_cv_c_flexmember" >&6; }
13388 if test $ac_cv_c_flexmember = yes; then
13390 $as_echo "#define FLEXIBLE_ARRAY_MEMBER /**/" >>confdefs.h
13393 $as_echo "#define FLEXIBLE_ARRAY_MEMBER 1" >>confdefs.h
13397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signed types" >&5
13398 $as_echo_n "checking for signed types... " >&6; }
13399 if ${pgac_cv_c_signed+:} false; then :
13400 $as_echo_n "(cached) " >&6
13402 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13403 /* end confdefs.h. */
13408 signed char c; signed short s; signed int i;
13413 if ac_fn_c_try_compile "$LINENO"; then :
13414 pgac_cv_c_signed=yes
13416 pgac_cv_c_signed=no
13418 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_c_signed" >&5
13421 $as_echo "$pgac_cv_c_signed" >&6; }
13422 if test x"$pgac_cv_c_signed" = xno ; then
13424 $as_echo "#define signed /**/" >>confdefs.h
13427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __func__" >&5
13428 $as_echo_n "checking for __func__... " >&6; }
13429 if ${pgac_cv_funcname_func_support+:} false; then :
13430 $as_echo_n "(cached) " >&6
13432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13433 /* end confdefs.h. */
13438 printf("%s\n", __func__);
13443 if ac_fn_c_try_compile "$LINENO"; then :
13444 pgac_cv_funcname_func_support=yes
13446 pgac_cv_funcname_func_support=no
13448 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_funcname_func_support" >&5
13451 $as_echo "$pgac_cv_funcname_func_support" >&6; }
13452 if test x"$pgac_cv_funcname_func_support" = xyes ; then
13454 $as_echo "#define HAVE_FUNCNAME__FUNC 1" >>confdefs.h
13457 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __FUNCTION__" >&5
13458 $as_echo_n "checking for __FUNCTION__... " >&6; }
13459 if ${pgac_cv_funcname_function_support+:} false; then :
13460 $as_echo_n "(cached) " >&6
13462 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13463 /* end confdefs.h. */
13468 printf("%s\n", __FUNCTION__);
13473 if ac_fn_c_try_compile "$LINENO"; then :
13474 pgac_cv_funcname_function_support=yes
13476 pgac_cv_funcname_function_support=no
13478 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_funcname_function_support" >&5
13481 $as_echo "$pgac_cv_funcname_function_support" >&6; }
13482 if test x"$pgac_cv_funcname_function_support" = xyes ; then
13484 $as_echo "#define HAVE_FUNCNAME__FUNCTION 1" >>confdefs.h
13488 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _Static_assert" >&5
13489 $as_echo_n "checking for _Static_assert... " >&6; }
13490 if ${pgac_cv__static_assert+:} false; then :
13491 $as_echo_n "(cached) " >&6
13493 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13494 /* end confdefs.h. */
13499 ({ _Static_assert(1, "foo"); })
13504 if ac_fn_c_try_link "$LINENO"; then :
13505 pgac_cv__static_assert=yes
13507 pgac_cv__static_assert=no
13509 rm -f core conftest.err conftest.$ac_objext \
13510 conftest$ac_exeext conftest.$ac_ext
13512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__static_assert" >&5
13513 $as_echo "$pgac_cv__static_assert" >&6; }
13514 if test x"$pgac_cv__static_assert" = xyes ; then
13516 $as_echo "#define HAVE__STATIC_ASSERT 1" >>confdefs.h
13519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for typeof" >&5
13520 $as_echo_n "checking for typeof... " >&6; }
13521 if ${pgac_cv_c_typeof+:} false; then :
13522 $as_echo_n "(cached) " >&6
13524 pgac_cv_c_typeof=no
13525 for pgac_kw in typeof __typeof__ decltype; do
13526 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13527 /* end confdefs.h. */
13540 if ac_fn_c_try_compile "$LINENO"; then :
13541 pgac_cv_c_typeof=$pgac_kw
13543 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13544 test "$pgac_cv_c_typeof" != no && break
13547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_c_typeof" >&5
13548 $as_echo "$pgac_cv_c_typeof" >&6; }
13549 if test "$pgac_cv_c_typeof" != no; then
13551 $as_echo "#define HAVE_TYPEOF 1" >>confdefs.h
13553 if test "$pgac_cv_c_typeof" != typeof; then
13555 cat >>confdefs.h <<_ACEOF
13556 #define typeof $pgac_cv_c_typeof
13561 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_types_compatible_p" >&5
13562 $as_echo_n "checking for __builtin_types_compatible_p... " >&6; }
13563 if ${pgac_cv__types_compatible+:} false; then :
13564 $as_echo_n "(cached) " >&6
13566 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13567 /* end confdefs.h. */
13572 int x; static int y[__builtin_types_compatible_p(__typeof__(x), int)];
13577 if ac_fn_c_try_compile "$LINENO"; then :
13578 pgac_cv__types_compatible=yes
13580 pgac_cv__types_compatible=no
13582 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__types_compatible" >&5
13585 $as_echo "$pgac_cv__types_compatible" >&6; }
13586 if test x"$pgac_cv__types_compatible" = xyes ; then
13588 $as_echo "#define HAVE__BUILTIN_TYPES_COMPATIBLE_P 1" >>confdefs.h
13591 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_bswap16" >&5
13592 $as_echo_n "checking for __builtin_bswap16... " >&6; }
13593 if ${pgac_cv__builtin_bswap16+:} false; then :
13594 $as_echo_n "(cached) " >&6
13596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13597 /* end confdefs.h. */
13598 static unsigned long int x = __builtin_bswap16(0xaabb);
13601 if ac_fn_c_try_compile "$LINENO"; then :
13602 pgac_cv__builtin_bswap16=yes
13604 pgac_cv__builtin_bswap16=no
13606 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_bswap16" >&5
13609 $as_echo "$pgac_cv__builtin_bswap16" >&6; }
13610 if test x"$pgac_cv__builtin_bswap16" = xyes ; then
13612 $as_echo "#define HAVE__BUILTIN_BSWAP16 1" >>confdefs.h
13615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_bswap32" >&5
13616 $as_echo_n "checking for __builtin_bswap32... " >&6; }
13617 if ${pgac_cv__builtin_bswap32+:} false; then :
13618 $as_echo_n "(cached) " >&6
13620 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13621 /* end confdefs.h. */
13622 static unsigned long int x = __builtin_bswap32(0xaabbccdd);
13625 if ac_fn_c_try_compile "$LINENO"; then :
13626 pgac_cv__builtin_bswap32=yes
13628 pgac_cv__builtin_bswap32=no
13630 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_bswap32" >&5
13633 $as_echo "$pgac_cv__builtin_bswap32" >&6; }
13634 if test x"$pgac_cv__builtin_bswap32" = xyes ; then
13636 $as_echo "#define HAVE__BUILTIN_BSWAP32 1" >>confdefs.h
13639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_bswap64" >&5
13640 $as_echo_n "checking for __builtin_bswap64... " >&6; }
13641 if ${pgac_cv__builtin_bswap64+:} false; then :
13642 $as_echo_n "(cached) " >&6
13644 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13645 /* end confdefs.h. */
13646 static unsigned long int x = __builtin_bswap64(0xaabbccddeeff0011);
13649 if ac_fn_c_try_compile "$LINENO"; then :
13650 pgac_cv__builtin_bswap64=yes
13652 pgac_cv__builtin_bswap64=no
13654 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_bswap64" >&5
13657 $as_echo "$pgac_cv__builtin_bswap64" >&6; }
13658 if test x"$pgac_cv__builtin_bswap64" = xyes ; then
13660 $as_echo "#define HAVE__BUILTIN_BSWAP64 1" >>confdefs.h
13663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_constant_p" >&5
13664 $as_echo_n "checking for __builtin_constant_p... " >&6; }
13665 if ${pgac_cv__builtin_constant_p+:} false; then :
13666 $as_echo_n "(cached) " >&6
13668 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13669 /* end confdefs.h. */
13671 static int y[__builtin_constant_p(x) ? x : 1];
13672 static int z[__builtin_constant_p("string literal") ? 1 : x];
13676 if ac_fn_c_try_compile "$LINENO"; then :
13677 pgac_cv__builtin_constant_p=yes
13679 pgac_cv__builtin_constant_p=no
13681 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_constant_p" >&5
13684 $as_echo "$pgac_cv__builtin_constant_p" >&6; }
13685 if test x"$pgac_cv__builtin_constant_p" = xyes ; then
13687 $as_echo "#define HAVE__BUILTIN_CONSTANT_P 1" >>confdefs.h
13690 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unreachable" >&5
13691 $as_echo_n "checking for __builtin_unreachable... " >&6; }
13692 if ${pgac_cv__builtin_unreachable+:} false; then :
13693 $as_echo_n "(cached) " >&6
13695 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13696 /* end confdefs.h. */
13701 __builtin_unreachable();
13706 if ac_fn_c_try_link "$LINENO"; then :
13707 pgac_cv__builtin_unreachable=yes
13709 pgac_cv__builtin_unreachable=no
13711 rm -f core conftest.err conftest.$ac_objext \
13712 conftest$ac_exeext conftest.$ac_ext
13714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_unreachable" >&5
13715 $as_echo "$pgac_cv__builtin_unreachable" >&6; }
13716 if test x"$pgac_cv__builtin_unreachable" = xyes ; then
13718 $as_echo "#define HAVE__BUILTIN_UNREACHABLE 1" >>confdefs.h
13721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for computed goto support" >&5
13722 $as_echo_n "checking for computed goto support... " >&6; }
13723 if ${pgac_cv_computed_goto+:} false; then :
13724 $as_echo_n "(cached) " >&6
13726 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13727 /* end confdefs.h. */
13732 void *labeladdrs[] = {&&my_label};
13733 goto *labeladdrs[0];
13741 if ac_fn_c_try_compile "$LINENO"; then :
13742 pgac_cv_computed_goto=yes
13744 pgac_cv_computed_goto=no
13746 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_computed_goto" >&5
13749 $as_echo "$pgac_cv_computed_goto" >&6; }
13750 if test x"$pgac_cv_computed_goto" = xyes ; then
13752 $as_echo "#define HAVE_COMPUTED_GOTO 1" >>confdefs.h
13755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __VA_ARGS__" >&5
13756 $as_echo_n "checking for __VA_ARGS__... " >&6; }
13757 if ${pgac_cv__va_args+:} false; then :
13758 $as_echo_n "(cached) " >&6
13760 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13761 /* end confdefs.h. */
13766 #define debug(...) fprintf(stderr, __VA_ARGS__)
13767 debug("%s", "blarg");
13773 if ac_fn_c_try_compile "$LINENO"; then :
13774 pgac_cv__va_args=yes
13776 pgac_cv__va_args=no
13778 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__va_args" >&5
13781 $as_echo "$pgac_cv__va_args" >&6; }
13782 if test x"$pgac_cv__va_args" = xyes ; then
13784 $as_echo "#define HAVE__VA_ARGS 1" >>confdefs.h
13787 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
13788 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
13789 if ${ac_cv_struct_tm+:} false; then :
13790 $as_echo_n "(cached) " >&6
13792 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13793 /* end confdefs.h. */
13794 #include <sys/types.h>
13801 int *p = &tm.tm_sec;
13807 if ac_fn_c_try_compile "$LINENO"; then :
13808 ac_cv_struct_tm=time.h
13810 ac_cv_struct_tm=sys/time.h
13812 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
13815 $as_echo "$ac_cv_struct_tm" >&6; }
13816 if test $ac_cv_struct_tm = sys/time.h; then
13818 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
13822 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
13823 #include <$ac_cv_struct_tm>
13826 if test "x$ac_cv_member_struct_tm_tm_zone" = xyes; then :
13828 cat >>confdefs.h <<_ACEOF
13829 #define HAVE_STRUCT_TM_TM_ZONE 1
13835 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
13837 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
13840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
13841 $as_echo_n "checking for tzname... " >&6; }
13842 if ${ac_cv_var_tzname+:} false; then :
13843 $as_echo_n "(cached) " >&6
13845 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13846 /* end confdefs.h. */
13847 #include <stdlib.h>
13849 #ifndef tzname /* For SGI. */
13850 extern char *tzname[]; /* RS6000 and others reject char **tzname. */
13861 if ac_fn_c_try_link "$LINENO"; then :
13862 ac_cv_var_tzname=yes
13864 ac_cv_var_tzname=no
13866 rm -f core conftest.err conftest.$ac_objext \
13867 conftest$ac_exeext conftest.$ac_ext
13869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
13870 $as_echo "$ac_cv_var_tzname" >&6; }
13871 if test $ac_cv_var_tzname = yes; then
13873 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
13877 ac_fn_c_check_type "$LINENO" "union semun" "ac_cv_type_union_semun" "#include <sys/types.h>
13878 #ifdef HAVE_SYS_IPC_H
13879 #include <sys/ipc.h>
13881 #ifdef HAVE_SYS_SEM_H
13882 #include <sys/sem.h>
13885 if test "x$ac_cv_type_union_semun" = xyes; then :
13887 cat >>confdefs.h <<_ACEOF
13888 #define HAVE_UNION_SEMUN 1
13894 ac_fn_c_check_type "$LINENO" "struct sockaddr_un" "ac_cv_type_struct_sockaddr_un" "#include <sys/types.h>
13895 #ifdef HAVE_SYS_UN_H
13896 #include <sys/un.h>
13900 if test "x$ac_cv_type_struct_sockaddr_un" = xyes; then :
13902 $as_echo "#define HAVE_UNIX_SOCKETS 1" >>confdefs.h
13906 ac_fn_c_check_type "$LINENO" "struct sockaddr_storage" "ac_cv_type_struct_sockaddr_storage" "#include <sys/types.h>
13907 #include <sys/socket.h>
13910 if test "x$ac_cv_type_struct_sockaddr_storage" = xyes; then :
13912 cat >>confdefs.h <<_ACEOF
13913 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
13919 ac_fn_c_check_member "$LINENO" "struct sockaddr_storage" "ss_family" "ac_cv_member_struct_sockaddr_storage_ss_family" "#include <sys/types.h>
13920 #include <sys/socket.h>
13923 if test "x$ac_cv_member_struct_sockaddr_storage_ss_family" = xyes; then :
13925 cat >>confdefs.h <<_ACEOF
13926 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
13931 ac_fn_c_check_member "$LINENO" "struct sockaddr_storage" "__ss_family" "ac_cv_member_struct_sockaddr_storage___ss_family" "#include <sys/types.h>
13932 #include <sys/socket.h>
13935 if test "x$ac_cv_member_struct_sockaddr_storage___ss_family" = xyes; then :
13937 cat >>confdefs.h <<_ACEOF
13938 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
13943 ac_fn_c_check_member "$LINENO" "struct sockaddr_storage" "ss_len" "ac_cv_member_struct_sockaddr_storage_ss_len" "#include <sys/types.h>
13944 #include <sys/socket.h>
13947 if test "x$ac_cv_member_struct_sockaddr_storage_ss_len" = xyes; then :
13949 cat >>confdefs.h <<_ACEOF
13950 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
13955 ac_fn_c_check_member "$LINENO" "struct sockaddr_storage" "__ss_len" "ac_cv_member_struct_sockaddr_storage___ss_len" "#include <sys/types.h>
13956 #include <sys/socket.h>
13959 if test "x$ac_cv_member_struct_sockaddr_storage___ss_len" = xyes; then :
13961 cat >>confdefs.h <<_ACEOF
13962 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
13967 ac_fn_c_check_member "$LINENO" "struct sockaddr" "sa_len" "ac_cv_member_struct_sockaddr_sa_len" "#include <sys/types.h>
13968 #include <sys/socket.h>
13971 if test "x$ac_cv_member_struct_sockaddr_sa_len" = xyes; then :
13973 cat >>confdefs.h <<_ACEOF
13974 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
13980 ac_fn_c_check_type "$LINENO" "struct addrinfo" "ac_cv_type_struct_addrinfo" "#include <sys/types.h>
13981 #include <sys/socket.h>
13985 if test "x$ac_cv_type_struct_addrinfo" = xyes; then :
13987 cat >>confdefs.h <<_ACEOF
13988 #define HAVE_STRUCT_ADDRINFO 1
13995 ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default"
13996 if test "x$ac_cv_type_intptr_t" = xyes; then :
13998 $as_echo "#define HAVE_INTPTR_T 1" >>confdefs.h
14001 for ac_type in 'int' 'long int' 'long long int'; do
14002 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14003 /* end confdefs.h. */
14004 $ac_includes_default
14008 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
14009 test_array [0] = 0;
14010 return test_array [0];
14016 if ac_fn_c_try_compile "$LINENO"; then :
14018 cat >>confdefs.h <<_ACEOF
14019 #define intptr_t $ac_type
14024 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14025 test -z "$ac_type" && break
14031 ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default"
14032 if test "x$ac_cv_type_uintptr_t" = xyes; then :
14034 $as_echo "#define HAVE_UINTPTR_T 1" >>confdefs.h
14037 for ac_type in 'unsigned int' 'unsigned long int' \
14038 'unsigned long long int'; do
14039 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14040 /* end confdefs.h. */
14041 $ac_includes_default
14045 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
14046 test_array [0] = 0;
14047 return test_array [0];
14053 if ac_fn_c_try_compile "$LINENO"; then :
14055 cat >>confdefs.h <<_ACEOF
14056 #define uintptr_t $ac_type
14061 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14062 test -z "$ac_type" && break
14068 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
14069 $as_echo_n "checking for unsigned long long int... " >&6; }
14070 if ${ac_cv_type_unsigned_long_long_int+:} false; then :
14071 $as_echo_n "(cached) " >&6
14073 ac_cv_type_unsigned_long_long_int=yes
14074 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
14075 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14076 /* end confdefs.h. */
14078 /* For now, do not test the preprocessor; as of 2007 there are too many
14079 implementations with broken preprocessors. Perhaps this can
14080 be revisited in 2012. In the meantime, code should not expect
14081 #if to work with literals wider than 32 bits. */
14082 /* Test literals. */
14083 long long int ll = 9223372036854775807ll;
14084 long long int nll = -9223372036854775807LL;
14085 unsigned long long int ull = 18446744073709551615ULL;
14086 /* Test constant expressions. */
14087 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
14089 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
14095 /* Test availability of runtime routines for shift and division. */
14096 long long int llmax = 9223372036854775807ll;
14097 unsigned long long int ullmax = 18446744073709551615ull;
14098 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
14099 | (llmax / ll) | (llmax % ll)
14100 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
14101 | (ullmax / ull) | (ullmax % ull));
14107 if ac_fn_c_try_link "$LINENO"; then :
14110 ac_cv_type_unsigned_long_long_int=no
14112 rm -f core conftest.err conftest.$ac_objext \
14113 conftest$ac_exeext conftest.$ac_ext
14116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
14117 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
14118 if test $ac_cv_type_unsigned_long_long_int = yes; then
14120 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
14126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
14127 $as_echo_n "checking for long long int... " >&6; }
14128 if ${ac_cv_type_long_long_int+:} false; then :
14129 $as_echo_n "(cached) " >&6
14131 ac_cv_type_long_long_int=yes
14132 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
14133 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
14134 if test $ac_cv_type_long_long_int = yes; then
14135 if test "$cross_compiling" = yes; then :
14138 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14139 /* end confdefs.h. */
14140 #include <limits.h>
14143 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
14144 # define LLONG_MAX (HALF - 1 + HALF)
14149 long long int n = 1;
14153 long long int m = n << i;
14156 if (LLONG_MAX / 2 < m)
14164 if ac_fn_c_try_run "$LINENO"; then :
14167 ac_cv_type_long_long_int=no
14169 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14170 conftest.$ac_objext conftest.beam conftest.$ac_ext
14176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
14177 $as_echo "$ac_cv_type_long_long_int" >&6; }
14178 if test $ac_cv_type_long_long_int = yes; then
14180 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
14185 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for locale_t" >&5
14186 $as_echo_n "checking for locale_t... " >&6; }
14187 if ${pgac_cv_type_locale_t+:} false; then :
14188 $as_echo_n "(cached) " >&6
14190 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14191 /* end confdefs.h. */
14192 #include <locale.h>
14202 if ac_fn_c_try_compile "$LINENO"; then :
14203 pgac_cv_type_locale_t=yes
14205 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14206 /* end confdefs.h. */
14207 #include <xlocale.h>
14217 if ac_fn_c_try_compile "$LINENO"; then :
14218 pgac_cv_type_locale_t='yes (in xlocale.h)'
14220 pgac_cv_type_locale_t=no
14222 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14224 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_type_locale_t" >&5
14227 $as_echo "$pgac_cv_type_locale_t" >&6; }
14228 if test "$pgac_cv_type_locale_t" != no; then
14230 $as_echo "#define HAVE_LOCALE_T 1" >>confdefs.h
14233 if test "$pgac_cv_type_locale_t" = 'yes (in xlocale.h)'; then
14235 $as_echo "#define LOCALE_T_IN_XLOCALE 1" >>confdefs.h
14239 # MSVC doesn't cope well with defining restrict to __restrict, the
14240 # spelling it understands, because it conflicts with
14241 # __declspec(restrict). Therefore we define pg_restrict to the
14242 # appropriate definition, which presumably won't conflict.
14244 # Allow platforms with buggy compilers to force restrict to not be
14245 # used by setting $FORCE_DISABLE_RESTRICT=yes in the relevant
14247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
14248 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
14249 if ${ac_cv_c_restrict+:} false; then :
14250 $as_echo_n "(cached) " >&6
14252 ac_cv_c_restrict=no
14253 # The order here caters to the fact that C++ does not require restrict.
14254 for ac_kw in __restrict __restrict__ _Restrict restrict; do
14255 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14256 /* end confdefs.h. */
14257 typedef int * int_ptr;
14258 int foo (int_ptr $ac_kw ip) {
14265 int * $ac_kw t = s;
14272 if ac_fn_c_try_compile "$LINENO"; then :
14273 ac_cv_c_restrict=$ac_kw
14275 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14276 test "$ac_cv_c_restrict" != no && break
14280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
14281 $as_echo "$ac_cv_c_restrict" >&6; }
14283 case $ac_cv_c_restrict in
14285 no) $as_echo "#define restrict /**/" >>confdefs.h
14287 *) cat >>confdefs.h <<_ACEOF
14288 #define restrict $ac_cv_c_restrict
14293 if test "$ac_cv_c_restrict" = "no" -o "x$FORCE_DISABLE_RESTRICT" = "xyes"; then
14296 pg_restrict="$ac_cv_c_restrict"
14299 cat >>confdefs.h <<_ACEOF
14300 #define pg_restrict $pg_restrict
14304 ac_fn_c_check_type "$LINENO" "struct cmsgcred" "ac_cv_type_struct_cmsgcred" "#include <sys/socket.h>
14305 #include <sys/param.h>
14306 #ifdef HAVE_SYS_UCRED_H
14307 #include <sys/ucred.h>
14310 if test "x$ac_cv_type_struct_cmsgcred" = xyes; then :
14312 cat >>confdefs.h <<_ACEOF
14313 #define HAVE_STRUCT_CMSGCRED 1
14320 ac_fn_c_check_type "$LINENO" "struct option" "ac_cv_type_struct_option" "#ifdef HAVE_GETOPT_H
14321 #include <getopt.h>
14324 if test "x$ac_cv_type_struct_option" = xyes; then :
14326 cat >>confdefs.h <<_ACEOF
14327 #define HAVE_STRUCT_OPTION 1
14334 if test "$with_zlib" = yes; then
14335 # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
14336 # did not). While we could work around the lack of z_streamp, it
14337 # seems unwise to encourage people to use such old zlib versions...
14338 ac_fn_c_check_type "$LINENO" "z_streamp" "ac_cv_type_z_streamp" "#include <zlib.h>
14340 if test "x$ac_cv_type_z_streamp" = xyes; then :
14343 as_fn_error $? "zlib version is too old
14344 Use --without-zlib to disable zlib support." "$LINENO" 5
14349 # On PPC, check if assembler supports LWARX instruction's mutex hint bit
14352 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether assembler supports lwarx hint bit" >&5
14353 $as_echo_n "checking whether assembler supports lwarx hint bit... " >&6; }
14354 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14355 /* end confdefs.h. */
14360 int a = 0; int *p = &a; int r;
14361 __asm__ __volatile__ (" lwarx %0,0,%1,1\n" : "=&r"(r) : "r"(p));
14366 if ac_fn_c_try_compile "$LINENO"; then :
14367 pgac_cv_have_ppc_mutex_hint=yes
14369 pgac_cv_have_ppc_mutex_hint=no
14371 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_have_ppc_mutex_hint" >&5
14373 $as_echo "$pgac_cv_have_ppc_mutex_hint" >&6; }
14374 if test x"$pgac_cv_have_ppc_mutex_hint" = xyes ; then
14376 $as_echo "#define HAVE_PPC_LWARX_MUTEX_HINT 1" >>confdefs.h
14382 # Check largefile support. You might think this is a system service not a
14383 # compiler characteristic, but you'd be wrong. We must check this before
14384 # probing existence of related functions such as fseeko, since the largefile
14385 # defines can affect what is generated for that.
14386 if test "$PORTNAME" != "win32"; then
14387 # Check whether --enable-largefile was given.
14388 if test "${enable_largefile+set}" = set; then :
14389 enableval=$enable_largefile;
14392 if test "$enable_largefile" != no; then
14394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
14395 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
14396 if ${ac_cv_sys_largefile_CC+:} false; then :
14397 $as_echo_n "(cached) " >&6
14399 ac_cv_sys_largefile_CC=no
14400 if test "$GCC" != yes; then
14403 # IRIX 6.2 and later do not support large files by default,
14404 # so use the C compiler's -n32 option if that helps.
14405 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14406 /* end confdefs.h. */
14407 #include <sys/types.h>
14408 /* Check that off_t can represent 2**63 - 1 correctly.
14409 We can't simply define LARGE_OFF_T to be 9223372036854775807,
14410 since some C++ compilers masquerading as C compilers
14411 incorrectly reject 9223372036854775807. */
14412 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
14413 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
14414 && LARGE_OFF_T % 2147483647 == 1)
14424 if ac_fn_c_try_compile "$LINENO"; then :
14427 rm -f core conftest.err conftest.$ac_objext
14429 if ac_fn_c_try_compile "$LINENO"; then :
14430 ac_cv_sys_largefile_CC=' -n32'; break
14432 rm -f core conftest.err conftest.$ac_objext
14436 rm -f conftest.$ac_ext
14439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
14440 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
14441 if test "$ac_cv_sys_largefile_CC" != no; then
14442 CC=$CC$ac_cv_sys_largefile_CC
14445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
14446 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
14447 if ${ac_cv_sys_file_offset_bits+:} false; then :
14448 $as_echo_n "(cached) " >&6
14451 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14452 /* end confdefs.h. */
14453 #include <sys/types.h>
14454 /* Check that off_t can represent 2**63 - 1 correctly.
14455 We can't simply define LARGE_OFF_T to be 9223372036854775807,
14456 since some C++ compilers masquerading as C compilers
14457 incorrectly reject 9223372036854775807. */
14458 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
14459 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
14460 && LARGE_OFF_T % 2147483647 == 1)
14470 if ac_fn_c_try_compile "$LINENO"; then :
14471 ac_cv_sys_file_offset_bits=no; break
14473 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14474 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14475 /* end confdefs.h. */
14476 #define _FILE_OFFSET_BITS 64
14477 #include <sys/types.h>
14478 /* Check that off_t can represent 2**63 - 1 correctly.
14479 We can't simply define LARGE_OFF_T to be 9223372036854775807,
14480 since some C++ compilers masquerading as C compilers
14481 incorrectly reject 9223372036854775807. */
14482 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
14483 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
14484 && LARGE_OFF_T % 2147483647 == 1)
14494 if ac_fn_c_try_compile "$LINENO"; then :
14495 ac_cv_sys_file_offset_bits=64; break
14497 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14498 ac_cv_sys_file_offset_bits=unknown
14502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
14503 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
14504 case $ac_cv_sys_file_offset_bits in #(
14507 cat >>confdefs.h <<_ACEOF
14508 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
14513 if test $ac_cv_sys_file_offset_bits = unknown; then
14514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
14515 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
14516 if ${ac_cv_sys_large_files+:} false; then :
14517 $as_echo_n "(cached) " >&6
14520 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14521 /* end confdefs.h. */
14522 #include <sys/types.h>
14523 /* Check that off_t can represent 2**63 - 1 correctly.
14524 We can't simply define LARGE_OFF_T to be 9223372036854775807,
14525 since some C++ compilers masquerading as C compilers
14526 incorrectly reject 9223372036854775807. */
14527 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
14528 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
14529 && LARGE_OFF_T % 2147483647 == 1)
14539 if ac_fn_c_try_compile "$LINENO"; then :
14540 ac_cv_sys_large_files=no; break
14542 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14543 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14544 /* end confdefs.h. */
14545 #define _LARGE_FILES 1
14546 #include <sys/types.h>
14547 /* Check that off_t can represent 2**63 - 1 correctly.
14548 We can't simply define LARGE_OFF_T to be 9223372036854775807,
14549 since some C++ compilers masquerading as C compilers
14550 incorrectly reject 9223372036854775807. */
14551 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
14552 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
14553 && LARGE_OFF_T % 2147483647 == 1)
14563 if ac_fn_c_try_compile "$LINENO"; then :
14564 ac_cv_sys_large_files=1; break
14566 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14567 ac_cv_sys_large_files=unknown
14571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
14572 $as_echo "$ac_cv_sys_large_files" >&6; }
14573 case $ac_cv_sys_large_files in #(
14576 cat >>confdefs.h <<_ACEOF
14577 #define _LARGE_FILES $ac_cv_sys_large_files
14590 # Check for largefile support (must be after AC_SYS_LARGEFILE)
14591 # The cast to long int works around a bug in the HP C Compiler
14592 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
14593 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
14594 # This bug is HP SR number 8606223364.
14595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5
14596 $as_echo_n "checking size of off_t... " >&6; }
14597 if ${ac_cv_sizeof_off_t+:} false; then :
14598 $as_echo_n "(cached) " >&6
14600 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (off_t))" "ac_cv_sizeof_off_t" "$ac_includes_default"; then :
14603 if test "$ac_cv_type_off_t" = yes; then
14604 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
14605 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
14606 as_fn_error 77 "cannot compute sizeof (off_t)
14607 See \`config.log' for more details" "$LINENO" 5; }
14609 ac_cv_sizeof_off_t=0
14614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5
14615 $as_echo "$ac_cv_sizeof_off_t" >&6; }
14619 cat >>confdefs.h <<_ACEOF
14620 #define SIZEOF_OFF_T $ac_cv_sizeof_off_t
14625 # If we don't have largefile support, can't handle segsize >= 2GB.
14626 if test "$ac_cv_sizeof_off_t" -lt 8 -a "$segsize" != "1"; then
14627 as_fn_error $? "Large file support is not enabled. Segment size cannot be larger than 1GB." "$LINENO" 5
14630 # The cast to long int works around a bug in the HP C Compiler
14631 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
14632 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
14633 # This bug is HP SR number 8606223364.
14634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of bool" >&5
14635 $as_echo_n "checking size of bool... " >&6; }
14636 if ${ac_cv_sizeof_bool+:} false; then :
14637 $as_echo_n "(cached) " >&6
14639 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (bool))" "ac_cv_sizeof_bool" "#ifdef HAVE_STDBOOL_H
14640 #include <stdbool.h>
14645 if test "$ac_cv_type_bool" = yes; then
14646 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
14647 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
14648 as_fn_error 77 "cannot compute sizeof (bool)
14649 See \`config.log' for more details" "$LINENO" 5; }
14651 ac_cv_sizeof_bool=0
14656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_bool" >&5
14657 $as_echo "$ac_cv_sizeof_bool" >&6; }
14661 cat >>confdefs.h <<_ACEOF
14662 #define SIZEOF_BOOL $ac_cv_sizeof_bool
14669 ## Functions, global variables
14672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for int timezone" >&5
14673 $as_echo_n "checking for int timezone... " >&6; }
14674 if ${pgac_cv_var_int_timezone+:} false; then :
14675 $as_echo_n "(cached) " >&6
14677 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14678 /* end confdefs.h. */
14685 res = timezone / 60;
14687 res = _timezone / 60;
14693 if ac_fn_c_try_link "$LINENO"; then :
14694 pgac_cv_var_int_timezone=yes
14696 pgac_cv_var_int_timezone=no
14698 rm -f core conftest.err conftest.$ac_objext \
14699 conftest$ac_exeext conftest.$ac_ext
14701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_var_int_timezone" >&5
14702 $as_echo "$pgac_cv_var_int_timezone" >&6; }
14703 if test x"$pgac_cv_var_int_timezone" = xyes ; then
14705 $as_echo "#define HAVE_INT_TIMEZONE 1" >>confdefs.h
14708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of arguments for accept()" >&5
14709 $as_echo_n "checking types of arguments for accept()... " >&6; }
14710 if ${ac_cv_func_accept_return+:} false; then :
14711 $as_echo_n "(cached) " >&6
14713 if ${ac_cv_func_accept_arg1+:} false; then :
14714 $as_echo_n "(cached) " >&6
14716 if ${ac_cv_func_accept_arg2+:} false; then :
14717 $as_echo_n "(cached) " >&6
14719 if ${ac_cv_func_accept_arg3+:} false; then :
14720 $as_echo_n "(cached) " >&6
14722 for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL' 'SOCKET WSAAPI'; do
14723 for ac_cv_func_accept_arg1 in 'int' 'unsigned int' 'SOCKET'; do
14724 for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
14725 for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
14726 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14727 /* end confdefs.h. */
14728 #include <sys/types.h>
14729 #include <sys/socket.h>
14730 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
14732 if ac_fn_c_try_compile "$LINENO"; then :
14733 ac_not_found=no; break 4
14737 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14742 if test "$ac_not_found" = yes; then
14743 as_fn_error $? "could not determine argument types" "$LINENO" 5
14745 if test "$ac_cv_func_accept_arg3" = "void"; then
14746 ac_cv_func_accept_arg3=int
14756 { $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
14757 $as_echo "$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6; }
14759 cat >>confdefs.h <<_ACEOF
14760 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
14764 cat >>confdefs.h <<_ACEOF
14765 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
14769 cat >>confdefs.h <<_ACEOF
14770 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
14774 cat >>confdefs.h <<_ACEOF
14775 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
14779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday takes only one argument" >&5
14780 $as_echo_n "checking whether gettimeofday takes only one argument... " >&6; }
14781 if ${pgac_cv_func_gettimeofday_1arg+:} false; then :
14782 $as_echo_n "(cached) " >&6
14784 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14785 /* end confdefs.h. */
14786 #include <sys/time.h>
14790 struct timeval *tp;
14791 struct timezone *tzp;
14792 gettimeofday(tp,tzp);
14797 if ac_fn_c_try_compile "$LINENO"; then :
14798 pgac_cv_func_gettimeofday_1arg=no
14800 pgac_cv_func_gettimeofday_1arg=yes
14802 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_func_gettimeofday_1arg" >&5
14805 $as_echo "$pgac_cv_func_gettimeofday_1arg" >&6; }
14806 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
14808 $as_echo "#define GETTIMEOFDAY_1ARG 1" >>confdefs.h
14812 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wcstombs_l declaration" >&5
14813 $as_echo_n "checking for wcstombs_l declaration... " >&6; }
14814 if ${pgac_cv_func_wcstombs_l+:} false; then :
14815 $as_echo_n "(cached) " >&6
14817 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14818 /* end confdefs.h. */
14819 #include <stdlib.h>
14820 #include <locale.h>
14831 if ac_fn_c_try_compile "$LINENO"; then :
14832 pgac_cv_func_wcstombs_l='yes'
14834 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14835 /* end confdefs.h. */
14836 #include <stdlib.h>
14837 #include <locale.h>
14838 #include <xlocale.h>
14849 if ac_fn_c_try_compile "$LINENO"; then :
14850 pgac_cv_func_wcstombs_l='yes (in xlocale.h)'
14852 pgac_cv_func_wcstombs_l='no'
14854 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14856 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_func_wcstombs_l" >&5
14859 $as_echo "$pgac_cv_func_wcstombs_l" >&6; }
14860 if test "$pgac_cv_func_wcstombs_l" = 'yes (in xlocale.h)'; then
14862 $as_echo "#define WCSTOMBS_L_IN_XLOCALE 1" >>confdefs.h
14866 # Some versions of libedit contain strlcpy(), setproctitle(), and other
14867 # symbols that that library has no business exposing to the world. Pending
14868 # acquisition of a clue by those developers, ignore libedit (including its
14869 # possible alias of libreadline) while checking for everything else.
14870 LIBS_including_readline="$LIBS"
14871 LIBS=`echo "$LIBS" | sed -e 's/-ledit//g' -e 's/-lreadline//g'`
14873 for ac_func in cbrt clock_gettime dlopen fdatasync getifaddrs getpeerucred getrlimit mbstowcs_l memmove poll posix_fallocate pstat pthread_is_threaded_np readlink setproctitle setsid shm_open symlink sync_file_range uselocale utime utimes wcstombs_l
14875 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14876 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14877 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
14878 cat >>confdefs.h <<_ACEOF
14879 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14886 ac_fn_c_check_func "$LINENO" "fseeko" "ac_cv_func_fseeko"
14887 if test "x$ac_cv_func_fseeko" = xyes; then :
14888 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
14891 case " $LIBOBJS " in
14892 *" fseeko.$ac_objext "* ) ;;
14893 *) LIBOBJS="$LIBOBJS fseeko.$ac_objext"
14901 # NetBSD uses a custom fseeko/ftello built on fsetpos/fgetpos
14902 # Mingw uses macros to access Win32 API calls
14905 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
14907 ac_cv_func_fseeko=yes;;
14909 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
14910 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
14911 if ${ac_cv_sys_largefile_source+:} false; then :
14912 $as_echo_n "(cached) " >&6
14915 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14916 /* end confdefs.h. */
14917 #include <sys/types.h> /* for off_t */
14922 int (*fp) (FILE *, off_t, int) = fseeko;
14923 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
14928 if ac_fn_c_try_link "$LINENO"; then :
14929 ac_cv_sys_largefile_source=no; break
14931 rm -f core conftest.err conftest.$ac_objext \
14932 conftest$ac_exeext conftest.$ac_ext
14933 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14934 /* end confdefs.h. */
14935 #define _LARGEFILE_SOURCE 1
14936 #include <sys/types.h> /* for off_t */
14941 int (*fp) (FILE *, off_t, int) = fseeko;
14942 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
14947 if ac_fn_c_try_link "$LINENO"; then :
14948 ac_cv_sys_largefile_source=1; break
14950 rm -f core conftest.err conftest.$ac_objext \
14951 conftest$ac_exeext conftest.$ac_ext
14952 ac_cv_sys_largefile_source=unknown
14956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
14957 $as_echo "$ac_cv_sys_largefile_source" >&6; }
14958 case $ac_cv_sys_largefile_source in #(
14961 cat >>confdefs.h <<_ACEOF
14962 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
14968 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
14969 # in glibc 2.1.3, but that breaks too many other things.
14970 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
14971 if test $ac_cv_sys_largefile_source != unknown; then
14973 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
14979 # posix_fadvise() is a no-op on Solaris, so don't incur function overhead
14980 # by calling it, 2009-04-02
14981 # http://src.opensolaris.org/source/xref/onnv/onnv-gate/usr/src/lib/libc/port/gen/posix_fadvise.c
14982 # The Clang compiler raises a warning for an undeclared identifier that matches
14983 # a compiler builtin function. All extant Clang versions are affected, as of
14984 # Clang 3.6.0. Test a builtin known to every version. This problem affects the
14985 # C and Objective C languages, but Clang does report an error under C++ and
14988 # Passing -fno-builtin to the compiler would suppress this problem. That
14989 # strategy would have the advantage of being insensitive to stray warnings, but
14990 # it would make tests less realistic.
14991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how $CC reports undeclared, standard C functions" >&5
14992 $as_echo_n "checking how $CC reports undeclared, standard C functions... " >&6; }
14993 if ${ac_cv_c_decl_report+:} false; then :
14994 $as_echo_n "(cached) " >&6
14996 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14997 /* end confdefs.h. */
15007 if ac_fn_c_try_compile "$LINENO"; then :
15008 if test -s conftest.err; then :
15009 # For AC_CHECK_DECL to react to warnings, the compiler must be silent on
15010 # valid AC_CHECK_DECL input. No library function is consistently available
15011 # on freestanding implementations, so test against a dummy declaration.
15012 # Include always-available headers on the off chance that they somehow
15014 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15015 /* end confdefs.h. */
15017 #include <limits.h>
15018 #include <stdarg.h>
15019 #include <stddef.h>
15020 extern void ac_decl (int, char *);
15025 (void) ac_decl ((int) 0, (char *) 0);
15035 if ac_fn_c_try_compile "$LINENO"; then :
15036 if test -s conftest.err; then :
15037 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15038 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15039 as_fn_error $? "cannot detect from compiler exit status or warnings
15040 See \`config.log' for more details" "$LINENO" 5; }
15042 ac_cv_c_decl_report=warning
15045 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15046 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15047 as_fn_error $? "cannot compile a simple declaration test
15048 See \`config.log' for more details" "$LINENO" 5; }
15050 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15052 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15053 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15054 as_fn_error $? "compiler does not report undeclared identifiers
15055 See \`config.log' for more details" "$LINENO" 5; }
15058 ac_cv_c_decl_report=error
15060 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_decl_report" >&5
15063 $as_echo "$ac_cv_c_decl_report" >&6; }
15065 case $ac_cv_c_decl_report in
15066 warning) ac_c_decl_warn_flag=yes ;;
15067 *) ac_c_decl_warn_flag= ;;
15070 if test "$PORTNAME" != "solaris"; then :
15072 for ac_func in posix_fadvise
15074 ac_fn_c_check_func "$LINENO" "posix_fadvise" "ac_cv_func_posix_fadvise"
15075 if test "x$ac_cv_func_posix_fadvise" = xyes; then :
15076 cat >>confdefs.h <<_ACEOF
15077 #define HAVE_POSIX_FADVISE 1
15083 ac_fn_c_check_decl "$LINENO" "posix_fadvise" "ac_cv_have_decl_posix_fadvise" "#include <fcntl.h>
15085 if test "x$ac_cv_have_decl_posix_fadvise" = xyes; then :
15091 cat >>confdefs.h <<_ACEOF
15092 #define HAVE_DECL_POSIX_FADVISE $ac_have_decl
15098 ac_fn_c_check_decl "$LINENO" "fdatasync" "ac_cv_have_decl_fdatasync" "#include <unistd.h>
15100 if test "x$ac_cv_have_decl_fdatasync" = xyes; then :
15106 cat >>confdefs.h <<_ACEOF
15107 #define HAVE_DECL_FDATASYNC $ac_have_decl
15110 ac_fn_c_check_decl "$LINENO" "strlcat" "ac_cv_have_decl_strlcat" "$ac_includes_default"
15111 if test "x$ac_cv_have_decl_strlcat" = xyes; then :
15117 cat >>confdefs.h <<_ACEOF
15118 #define HAVE_DECL_STRLCAT $ac_have_decl
15120 ac_fn_c_check_decl "$LINENO" "strlcpy" "ac_cv_have_decl_strlcpy" "$ac_includes_default"
15121 if test "x$ac_cv_have_decl_strlcpy" = xyes; then :
15127 cat >>confdefs.h <<_ACEOF
15128 #define HAVE_DECL_STRLCPY $ac_have_decl
15130 ac_fn_c_check_decl "$LINENO" "strnlen" "ac_cv_have_decl_strnlen" "$ac_includes_default"
15131 if test "x$ac_cv_have_decl_strnlen" = xyes; then :
15137 cat >>confdefs.h <<_ACEOF
15138 #define HAVE_DECL_STRNLEN $ac_have_decl
15141 # This is probably only present on macOS, but may as well check always
15142 ac_fn_c_check_decl "$LINENO" "F_FULLFSYNC" "ac_cv_have_decl_F_FULLFSYNC" "#include <fcntl.h>
15144 if test "x$ac_cv_have_decl_F_FULLFSYNC" = xyes; then :
15150 cat >>confdefs.h <<_ACEOF
15151 #define HAVE_DECL_F_FULLFSYNC $ac_have_decl
15156 ac_fn_c_check_type "$LINENO" "struct sockaddr_in6" "ac_cv_type_struct_sockaddr_in6" "$ac_includes_default
15157 #include <netinet/in.h>
15159 if test "x$ac_cv_type_struct_sockaddr_in6" = xyes; then :
15161 $as_echo "#define HAVE_IPV6 1" >>confdefs.h
15168 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PS_STRINGS" >&5
15169 $as_echo_n "checking for PS_STRINGS... " >&6; }
15170 if ${pgac_cv_var_PS_STRINGS+:} false; then :
15171 $as_echo_n "(cached) " >&6
15173 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15174 /* end confdefs.h. */
15175 #include <machine/vmparam.h>
15176 #include <sys/exec.h>
15181 PS_STRINGS->ps_nargvstr = 1;
15182 PS_STRINGS->ps_argvstr = "foo";
15187 if ac_fn_c_try_link "$LINENO"; then :
15188 pgac_cv_var_PS_STRINGS=yes
15190 pgac_cv_var_PS_STRINGS=no
15192 rm -f core conftest.err conftest.$ac_objext \
15193 conftest$ac_exeext conftest.$ac_ext
15195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_var_PS_STRINGS" >&5
15196 $as_echo "$pgac_cv_var_PS_STRINGS" >&6; }
15197 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
15199 $as_echo "#define HAVE_PS_STRINGS 1" >>confdefs.h
15204 # We use our snprintf.c emulation if either snprintf() or vsnprintf()
15205 # is missing. Yes, there are machines that have only one. We may
15206 # also decide to use snprintf.c if snprintf() is present but does not
15207 # have all the features we need --- see below.
15209 if test "$PORTNAME" = "win32"; then
15210 # Win32 gets snprintf.c built unconditionally.
15212 # To properly translate all NLS languages strings, we must support the
15213 # *printf() %$ format, which allows *printf() arguments to be selected
15214 # by position in the translated string.
15216 # libintl versions < 0.13 use the native *printf() functions, and Win32
15217 # *printf() doesn't understand %$, so we must use our /port versions,
15218 # which do understand %$. libintl versions >= 0.13 include their own
15219 # *printf versions on Win32. The libintl 0.13 release note text is:
15221 # C format strings with positions, as they arise when a translator
15222 # needs to reorder a sentence, are now supported on all platforms.
15223 # On those few platforms (NetBSD and Woe32) for which the native
15224 # printf()/fprintf()/... functions don't support such format
15225 # strings, replacements are provided through <libintl.h>.
15227 # We could use libintl >= 0.13's *printf() if we were sure that we had
15228 # a libintl >= 0.13 at runtime, but seeing that there is no clean way
15229 # to guarantee that, it is best to just use our own, so we are sure to
15230 # get %$ support. In include/port.h we disable the *printf() macros
15231 # that might have been defined by libintl.
15233 # We do this unconditionally whether NLS is used or not so we are sure
15234 # that all Win32 libraries and binaries behave the same.
15235 pgac_need_repl_snprintf=yes
15237 pgac_need_repl_snprintf=no
15238 for ac_func in snprintf
15240 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
15241 if test "x$ac_cv_func_snprintf" = xyes; then :
15242 cat >>confdefs.h <<_ACEOF
15243 #define HAVE_SNPRINTF 1
15247 pgac_need_repl_snprintf=yes
15251 for ac_func in vsnprintf
15253 ac_fn_c_check_func "$LINENO" "vsnprintf" "ac_cv_func_vsnprintf"
15254 if test "x$ac_cv_func_vsnprintf" = xyes; then :
15255 cat >>confdefs.h <<_ACEOF
15256 #define HAVE_VSNPRINTF 1
15260 pgac_need_repl_snprintf=yes
15267 # Check whether <stdio.h> declares snprintf() and vsnprintf(); if not,
15268 # include/c.h will provide declarations. Note this is a separate test
15269 # from whether the functions exist in the C library --- there are
15270 # systems that have the functions but don't bother to declare them :-(
15272 ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
15273 if test "x$ac_cv_have_decl_snprintf" = xyes; then :
15279 cat >>confdefs.h <<_ACEOF
15280 #define HAVE_DECL_SNPRINTF $ac_have_decl
15282 ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
15283 if test "x$ac_cv_have_decl_vsnprintf" = xyes; then :
15289 cat >>confdefs.h <<_ACEOF
15290 #define HAVE_DECL_VSNPRINTF $ac_have_decl
15295 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for isinf" >&5
15296 $as_echo_n "checking for isinf... " >&6; }
15297 if ${ac_cv_func_isinf+:} false; then :
15298 $as_echo_n "(cached) " >&6
15300 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15301 /* end confdefs.h. */
15304 double glob_double;
15309 return isinf(glob_double) ? 0 : 1;
15314 if ac_fn_c_try_link "$LINENO"; then :
15315 ac_cv_func_isinf=yes
15317 ac_cv_func_isinf=no
15319 rm -f core conftest.err conftest.$ac_objext \
15320 conftest$ac_exeext conftest.$ac_ext
15322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_isinf" >&5
15323 $as_echo "$ac_cv_func_isinf" >&6; }
15325 if test $ac_cv_func_isinf = yes ; then
15327 $as_echo "#define HAVE_ISINF 1" >>confdefs.h
15330 case " $LIBOBJS " in
15331 *" isinf.$ac_objext "* ) ;;
15332 *) LIBOBJS="$LIBOBJS isinf.$ac_objext"
15336 # Look for a way to implement a substitute for isinf()
15337 for ac_func in fpclass fp_class fp_class_d class
15339 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15340 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15341 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
15342 cat >>confdefs.h <<_ACEOF
15343 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15351 ac_fn_c_check_func "$LINENO" "crypt" "ac_cv_func_crypt"
15352 if test "x$ac_cv_func_crypt" = xyes; then :
15353 $as_echo "#define HAVE_CRYPT 1" >>confdefs.h
15356 case " $LIBOBJS " in
15357 *" crypt.$ac_objext "* ) ;;
15358 *) LIBOBJS="$LIBOBJS crypt.$ac_objext"
15364 ac_fn_c_check_func "$LINENO" "fls" "ac_cv_func_fls"
15365 if test "x$ac_cv_func_fls" = xyes; then :
15366 $as_echo "#define HAVE_FLS 1" >>confdefs.h
15369 case " $LIBOBJS " in
15370 *" fls.$ac_objext "* ) ;;
15371 *) LIBOBJS="$LIBOBJS fls.$ac_objext"
15377 ac_fn_c_check_func "$LINENO" "getopt" "ac_cv_func_getopt"
15378 if test "x$ac_cv_func_getopt" = xyes; then :
15379 $as_echo "#define HAVE_GETOPT 1" >>confdefs.h
15382 case " $LIBOBJS " in
15383 *" getopt.$ac_objext "* ) ;;
15384 *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
15390 ac_fn_c_check_func "$LINENO" "getrusage" "ac_cv_func_getrusage"
15391 if test "x$ac_cv_func_getrusage" = xyes; then :
15392 $as_echo "#define HAVE_GETRUSAGE 1" >>confdefs.h
15395 case " $LIBOBJS " in
15396 *" getrusage.$ac_objext "* ) ;;
15397 *) LIBOBJS="$LIBOBJS getrusage.$ac_objext"
15403 ac_fn_c_check_func "$LINENO" "inet_aton" "ac_cv_func_inet_aton"
15404 if test "x$ac_cv_func_inet_aton" = xyes; then :
15405 $as_echo "#define HAVE_INET_ATON 1" >>confdefs.h
15408 case " $LIBOBJS " in
15409 *" inet_aton.$ac_objext "* ) ;;
15410 *) LIBOBJS="$LIBOBJS inet_aton.$ac_objext"
15416 ac_fn_c_check_func "$LINENO" "mkdtemp" "ac_cv_func_mkdtemp"
15417 if test "x$ac_cv_func_mkdtemp" = xyes; then :
15418 $as_echo "#define HAVE_MKDTEMP 1" >>confdefs.h
15421 case " $LIBOBJS " in
15422 *" mkdtemp.$ac_objext "* ) ;;
15423 *) LIBOBJS="$LIBOBJS mkdtemp.$ac_objext"
15429 ac_fn_c_check_func "$LINENO" "random" "ac_cv_func_random"
15430 if test "x$ac_cv_func_random" = xyes; then :
15431 $as_echo "#define HAVE_RANDOM 1" >>confdefs.h
15434 case " $LIBOBJS " in
15435 *" random.$ac_objext "* ) ;;
15436 *) LIBOBJS="$LIBOBJS random.$ac_objext"
15442 ac_fn_c_check_func "$LINENO" "rint" "ac_cv_func_rint"
15443 if test "x$ac_cv_func_rint" = xyes; then :
15444 $as_echo "#define HAVE_RINT 1" >>confdefs.h
15447 case " $LIBOBJS " in
15448 *" rint.$ac_objext "* ) ;;
15449 *) LIBOBJS="$LIBOBJS rint.$ac_objext"
15455 ac_fn_c_check_func "$LINENO" "srandom" "ac_cv_func_srandom"
15456 if test "x$ac_cv_func_srandom" = xyes; then :
15457 $as_echo "#define HAVE_SRANDOM 1" >>confdefs.h
15460 case " $LIBOBJS " in
15461 *" srandom.$ac_objext "* ) ;;
15462 *) LIBOBJS="$LIBOBJS srandom.$ac_objext"
15468 ac_fn_c_check_func "$LINENO" "strerror" "ac_cv_func_strerror"
15469 if test "x$ac_cv_func_strerror" = xyes; then :
15470 $as_echo "#define HAVE_STRERROR 1" >>confdefs.h
15473 case " $LIBOBJS " in
15474 *" strerror.$ac_objext "* ) ;;
15475 *) LIBOBJS="$LIBOBJS strerror.$ac_objext"
15481 ac_fn_c_check_func "$LINENO" "strlcat" "ac_cv_func_strlcat"
15482 if test "x$ac_cv_func_strlcat" = xyes; then :
15483 $as_echo "#define HAVE_STRLCAT 1" >>confdefs.h
15486 case " $LIBOBJS " in
15487 *" strlcat.$ac_objext "* ) ;;
15488 *) LIBOBJS="$LIBOBJS strlcat.$ac_objext"
15494 ac_fn_c_check_func "$LINENO" "strlcpy" "ac_cv_func_strlcpy"
15495 if test "x$ac_cv_func_strlcpy" = xyes; then :
15496 $as_echo "#define HAVE_STRLCPY 1" >>confdefs.h
15499 case " $LIBOBJS " in
15500 *" strlcpy.$ac_objext "* ) ;;
15501 *) LIBOBJS="$LIBOBJS strlcpy.$ac_objext"
15507 ac_fn_c_check_func "$LINENO" "strnlen" "ac_cv_func_strnlen"
15508 if test "x$ac_cv_func_strnlen" = xyes; then :
15509 $as_echo "#define HAVE_STRNLEN 1" >>confdefs.h
15512 case " $LIBOBJS " in
15513 *" strnlen.$ac_objext "* ) ;;
15514 *) LIBOBJS="$LIBOBJS strnlen.$ac_objext"
15524 # Windows uses a specialised env handler
15525 # and doesn't need a replacement getpeereid because it doesn't use
15529 $as_echo "#define HAVE_UNSETENV 1" >>confdefs.h
15532 $as_echo "#define HAVE_GETPEEREID 1" >>confdefs.h
15534 ac_cv_func_unsetenv=yes
15535 ac_cv_func_getpeereid=yes;;
15537 ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv"
15538 if test "x$ac_cv_func_unsetenv" = xyes; then :
15539 $as_echo "#define HAVE_UNSETENV 1" >>confdefs.h
15542 case " $LIBOBJS " in
15543 *" unsetenv.$ac_objext "* ) ;;
15544 *) LIBOBJS="$LIBOBJS unsetenv.$ac_objext"
15550 ac_fn_c_check_func "$LINENO" "getpeereid" "ac_cv_func_getpeereid"
15551 if test "x$ac_cv_func_getpeereid" = xyes; then :
15552 $as_echo "#define HAVE_GETPEEREID 1" >>confdefs.h
15555 case " $LIBOBJS " in
15556 *" getpeereid.$ac_objext "* ) ;;
15557 *) LIBOBJS="$LIBOBJS getpeereid.$ac_objext"
15567 # System's version of getaddrinfo(), if any, may be used only if we found
15568 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h.
15569 # We use only our own getaddrinfo.c on Windows, but it's time to revisit that.
15570 if test x"$ac_cv_type_struct_addrinfo" = xyes && \
15571 test "$PORTNAME" != "win32"; then
15572 ac_fn_c_check_func "$LINENO" "getaddrinfo" "ac_cv_func_getaddrinfo"
15573 if test "x$ac_cv_func_getaddrinfo" = xyes; then :
15574 $as_echo "#define HAVE_GETADDRINFO 1" >>confdefs.h
15577 case " $LIBOBJS " in
15578 *" getaddrinfo.$ac_objext "* ) ;;
15579 *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext"
15587 case " $LIBOBJS " in
15588 *" getaddrinfo.$ac_objext "* ) ;;
15589 *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext"
15595 # Similarly, use system's getopt_long() only if system provides struct option.
15596 if test x"$ac_cv_type_struct_option" = xyes ; then
15597 ac_fn_c_check_func "$LINENO" "getopt_long" "ac_cv_func_getopt_long"
15598 if test "x$ac_cv_func_getopt_long" = xyes; then :
15599 $as_echo "#define HAVE_GETOPT_LONG 1" >>confdefs.h
15602 case " $LIBOBJS " in
15603 *" getopt_long.$ac_objext "* ) ;;
15604 *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
15612 case " $LIBOBJS " in
15613 *" getopt_long.$ac_objext "* ) ;;
15614 *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
15620 # On OpenBSD and Solaris, getopt() doesn't do what we want for long options
15621 # (i.e., allow '-' as a flag character), so use our version on those platforms.
15622 if test "$PORTNAME" = "openbsd" -o "$PORTNAME" = "solaris"; then
15623 case " $LIBOBJS " in
15624 *" getopt.$ac_objext "* ) ;;
15625 *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
15631 # mingw has adopted a GNU-centric interpretation of optind/optreset,
15632 # so always use our version on Windows.
15633 if test "$PORTNAME" = "win32"; then
15634 case " $LIBOBJS " in
15635 *" getopt.$ac_objext "* ) ;;
15636 *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
15640 case " $LIBOBJS " in
15641 *" getopt_long.$ac_objext "* ) ;;
15642 *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
15648 # Win32 (really MinGW) support
15649 if test "$PORTNAME" = "win32"; then
15650 for ac_func in _configthreadlocale
15652 ac_fn_c_check_func "$LINENO" "_configthreadlocale" "ac_cv_func__configthreadlocale"
15653 if test "x$ac_cv_func__configthreadlocale" = xyes; then :
15654 cat >>confdefs.h <<_ACEOF
15655 #define HAVE__CONFIGTHREADLOCALE 1
15661 ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday"
15662 if test "x$ac_cv_func_gettimeofday" = xyes; then :
15663 $as_echo "#define HAVE_GETTIMEOFDAY 1" >>confdefs.h
15666 case " $LIBOBJS " in
15667 *" gettimeofday.$ac_objext "* ) ;;
15668 *) LIBOBJS="$LIBOBJS gettimeofday.$ac_objext"
15675 case " $LIBOBJS " in
15676 *" dirmod.$ac_objext "* ) ;;
15677 *) LIBOBJS="$LIBOBJS dirmod.$ac_objext"
15681 case " $LIBOBJS " in
15682 *" kill.$ac_objext "* ) ;;
15683 *) LIBOBJS="$LIBOBJS kill.$ac_objext"
15687 case " $LIBOBJS " in
15688 *" open.$ac_objext "* ) ;;
15689 *) LIBOBJS="$LIBOBJS open.$ac_objext"
15693 case " $LIBOBJS " in
15694 *" system.$ac_objext "* ) ;;
15695 *) LIBOBJS="$LIBOBJS system.$ac_objext"
15699 case " $LIBOBJS " in
15700 *" win32env.$ac_objext "* ) ;;
15701 *) LIBOBJS="$LIBOBJS win32env.$ac_objext"
15705 case " $LIBOBJS " in
15706 *" win32error.$ac_objext "* ) ;;
15707 *) LIBOBJS="$LIBOBJS win32error.$ac_objext"
15711 case " $LIBOBJS " in
15712 *" win32security.$ac_objext "* ) ;;
15713 *) LIBOBJS="$LIBOBJS win32security.$ac_objext"
15717 case " $LIBOBJS " in
15718 *" win32setlocale.$ac_objext "* ) ;;
15719 *) LIBOBJS="$LIBOBJS win32setlocale.$ac_objext"
15724 $as_echo "#define HAVE_SYMLINK 1" >>confdefs.h
15726 ac_fn_c_check_type "$LINENO" "MINIDUMP_TYPE" "ac_cv_type_MINIDUMP_TYPE" "
15727 #define WIN32_LEAN_AND_MEAN
15728 #include <windows.h>
15729 #include <string.h>
15730 #include <dbghelp.h>
15732 if test "x$ac_cv_type_MINIDUMP_TYPE" = xyes; then :
15734 cat >>confdefs.h <<_ACEOF
15735 #define HAVE_MINIDUMP_TYPE 1
15738 pgac_minidump_type=yes
15740 pgac_minidump_type=no
15744 if test x"$pgac_minidump_type" = x"yes" ; then
15745 have_win32_dbghelp=yes
15748 have_win32_dbghelp=no
15752 # Cygwin needs only a bit of that
15753 if test "$PORTNAME" = "cygwin"; then
15754 case " $LIBOBJS " in
15755 *" dirmod.$ac_objext "* ) ;;
15756 *) LIBOBJS="$LIBOBJS dirmod.$ac_objext"
15762 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "#include <signal.h>
15763 /* NetBSD declares sys_siglist in unistd.h. */
15764 #ifdef HAVE_UNISTD_H
15765 # include <unistd.h>
15769 if test "x$ac_cv_have_decl_sys_siglist" = xyes; then :
15775 cat >>confdefs.h <<_ACEOF
15776 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
15780 ac_fn_c_check_func "$LINENO" "syslog" "ac_cv_func_syslog"
15781 if test "x$ac_cv_func_syslog" = xyes; then :
15782 ac_fn_c_check_header_mongrel "$LINENO" "syslog.h" "ac_cv_header_syslog_h" "$ac_includes_default"
15783 if test "x$ac_cv_header_syslog_h" = xyes; then :
15785 $as_echo "#define HAVE_SYSLOG 1" >>confdefs.h
15793 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for opterr" >&5
15794 $as_echo_n "checking for opterr... " >&6; }
15795 if ${pgac_cv_var_int_opterr+:} false; then :
15796 $as_echo_n "(cached) " >&6
15798 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15799 /* end confdefs.h. */
15800 #include <unistd.h>
15804 extern int opterr; opterr = 1;
15809 if ac_fn_c_try_link "$LINENO"; then :
15810 pgac_cv_var_int_opterr=yes
15812 pgac_cv_var_int_opterr=no
15814 rm -f core conftest.err conftest.$ac_objext \
15815 conftest$ac_exeext conftest.$ac_ext
15817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_var_int_opterr" >&5
15818 $as_echo "$pgac_cv_var_int_opterr" >&6; }
15819 if test x"$pgac_cv_var_int_opterr" = x"yes"; then
15821 $as_echo "#define HAVE_INT_OPTERR 1" >>confdefs.h
15825 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for optreset" >&5
15826 $as_echo_n "checking for optreset... " >&6; }
15827 if ${pgac_cv_var_int_optreset+:} false; then :
15828 $as_echo_n "(cached) " >&6
15830 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15831 /* end confdefs.h. */
15832 #include <unistd.h>
15836 extern int optreset; optreset = 1;
15841 if ac_fn_c_try_link "$LINENO"; then :
15842 pgac_cv_var_int_optreset=yes
15844 pgac_cv_var_int_optreset=no
15846 rm -f core conftest.err conftest.$ac_objext \
15847 conftest$ac_exeext conftest.$ac_ext
15849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_var_int_optreset" >&5
15850 $as_echo "$pgac_cv_var_int_optreset" >&6; }
15851 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
15853 $as_echo "#define HAVE_INT_OPTRESET 1" >>confdefs.h
15857 for ac_func in strtoll __strtoll strtoq
15859 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15860 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15861 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
15862 cat >>confdefs.h <<_ACEOF
15863 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15869 for ac_func in strtoull __strtoull strtouq
15871 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15872 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15873 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
15874 cat >>confdefs.h <<_ACEOF
15875 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15881 # strto[u]ll may exist but not be declared
15882 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
15883 if test "x$ac_cv_have_decl_strtoll" = xyes; then :
15889 cat >>confdefs.h <<_ACEOF
15890 #define HAVE_DECL_STRTOLL $ac_have_decl
15892 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
15893 if test "x$ac_cv_have_decl_strtoull" = xyes; then :
15899 cat >>confdefs.h <<_ACEOF
15900 #define HAVE_DECL_STRTOULL $ac_have_decl
15904 if test "$with_icu" = yes; then
15905 ac_save_CPPFLAGS=$CPPFLAGS
15906 CPPFLAGS="$ICU_CFLAGS $CPPFLAGS"
15908 # Verify we have ICU's header files
15909 ac_fn_c_check_header_mongrel "$LINENO" "unicode/ucol.h" "ac_cv_header_unicode_ucol_h" "$ac_includes_default"
15910 if test "x$ac_cv_header_unicode_ucol_h" = xyes; then :
15913 as_fn_error $? "header file <unicode/ucol.h> is required for ICU" "$LINENO" 5
15918 CPPFLAGS=$ac_save_CPPFLAGS
15921 if test "$with_llvm" = yes; then
15923 # Check which functionality is present
15924 SAVE_CPPFLAGS="$CPPFLAGS"
15925 CPPFLAGS="$CPPFLAGS $LLVM_CPPFLAGS"
15926 ac_fn_c_check_decl "$LINENO" "LLVMOrcGetSymbolAddressIn" "ac_cv_have_decl_LLVMOrcGetSymbolAddressIn" "#include <llvm-c/OrcBindings.h>
15928 if test "x$ac_cv_have_decl_LLVMOrcGetSymbolAddressIn" = xyes; then :
15934 cat >>confdefs.h <<_ACEOF
15935 #define HAVE_DECL_LLVMORCGETSYMBOLADDRESSIN $ac_have_decl
15938 ac_fn_c_check_decl "$LINENO" "LLVMGetHostCPUName" "ac_cv_have_decl_LLVMGetHostCPUName" "#include <llvm-c/TargetMachine.h>
15940 if test "x$ac_cv_have_decl_LLVMGetHostCPUName" = xyes; then :
15946 cat >>confdefs.h <<_ACEOF
15947 #define HAVE_DECL_LLVMGETHOSTCPUNAME $ac_have_decl
15949 ac_fn_c_check_decl "$LINENO" "LLVMGetHostCPUFeatures" "ac_cv_have_decl_LLVMGetHostCPUFeatures" "#include <llvm-c/TargetMachine.h>
15951 if test "x$ac_cv_have_decl_LLVMGetHostCPUFeatures" = xyes; then :
15957 cat >>confdefs.h <<_ACEOF
15958 #define HAVE_DECL_LLVMGETHOSTCPUFEATURES $ac_have_decl
15961 ac_fn_c_check_decl "$LINENO" "LLVMCreateGDBRegistrationListener" "ac_cv_have_decl_LLVMCreateGDBRegistrationListener" "#include <llvm-c/ExecutionEngine.h>
15963 if test "x$ac_cv_have_decl_LLVMCreateGDBRegistrationListener" = xyes; then :
15969 cat >>confdefs.h <<_ACEOF
15970 #define HAVE_DECL_LLVMCREATEGDBREGISTRATIONLISTENER $ac_have_decl
15972 ac_fn_c_check_decl "$LINENO" "LLVMCreatePerfJITEventListener" "ac_cv_have_decl_LLVMCreatePerfJITEventListener" "#include <llvm-c/ExecutionEngine.h>
15974 if test "x$ac_cv_have_decl_LLVMCreatePerfJITEventListener" = xyes; then :
15980 cat >>confdefs.h <<_ACEOF
15981 #define HAVE_DECL_LLVMCREATEPERFJITEVENTLISTENER $ac_have_decl
15984 CPPFLAGS="$SAVE_CPPFLAGS"
15988 # Lastly, restore full LIBS list and check for readline/libedit symbols
15989 LIBS="$LIBS_including_readline"
15991 if test "$with_readline" = yes; then
15992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_completion_append_character" >&5
15993 $as_echo_n "checking for rl_completion_append_character... " >&6; }
15994 if ${pgac_cv_var_rl_completion_append_character+:} false; then :
15995 $as_echo_n "(cached) " >&6
15997 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15998 /* end confdefs.h. */
16000 #ifdef HAVE_READLINE_READLINE_H
16001 # include <readline/readline.h>
16002 #elif defined(HAVE_READLINE_H)
16003 # include <readline.h>
16009 rl_completion_append_character = 'x';
16014 if ac_fn_c_try_link "$LINENO"; then :
16015 pgac_cv_var_rl_completion_append_character=yes
16017 pgac_cv_var_rl_completion_append_character=no
16019 rm -f core conftest.err conftest.$ac_objext \
16020 conftest$ac_exeext conftest.$ac_ext
16022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_var_rl_completion_append_character" >&5
16023 $as_echo "$pgac_cv_var_rl_completion_append_character" >&6; }
16024 if test x"$pgac_cv_var_rl_completion_append_character" = x"yes"; then
16026 $as_echo "#define HAVE_RL_COMPLETION_APPEND_CHARACTER 1" >>confdefs.h
16029 for ac_func in rl_completion_matches rl_filename_completion_function rl_reset_screen_size
16031 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16032 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16033 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
16034 cat >>confdefs.h <<_ACEOF
16035 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16041 for ac_func in append_history history_truncate_file
16043 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16044 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16045 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
16046 cat >>confdefs.h <<_ACEOF
16047 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16056 # This test makes sure that run tests work at all. Sometimes a shared
16057 # library is found by the linker, but the runtime linker can't find it.
16058 # This check should come after all modifications of compiler or linker
16059 # variables, and before any other run tests.
16060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking test program" >&5
16061 $as_echo_n "checking test program... " >&6; }
16062 if test "$cross_compiling" = yes; then :
16063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: cross-compiling" >&5
16064 $as_echo "cross-compiling" >&6; }
16066 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16067 /* end confdefs.h. */
16068 int main() { return 0; }
16070 if ac_fn_c_try_run "$LINENO"; then :
16071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
16072 $as_echo "ok" >&6; }
16074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
16075 $as_echo "failed" >&6; }
16077 Could not execute a simple test program. This may be a problem
16078 related to locating shared libraries. Check the file 'config.log'
16079 for the exact reason." "$LINENO" 5
16081 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16082 conftest.$ac_objext conftest.beam conftest.$ac_ext
16086 # --------------------
16087 # Run tests below here
16088 # --------------------
16090 # Force use of our snprintf if system's doesn't do arg control
16091 # See comment above at snprintf test for details.
16092 if test "$enable_nls" = yes -a "$pgac_need_repl_snprintf" = no; then
16093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf supports argument control" >&5
16094 $as_echo_n "checking whether snprintf supports argument control... " >&6; }
16095 if ${pgac_cv_snprintf_arg_control+:} false; then :
16096 $as_echo_n "(cached) " >&6
16098 if test "$cross_compiling" = yes; then :
16099 pgac_cv_snprintf_arg_control=cross
16101 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16102 /* end confdefs.h. */
16104 #include <string.h>
16110 /* can it swap arguments? */
16111 snprintf(buf, 100, "%2\$d %1\$d", 3, 4);
16112 if (strcmp(buf, "4 3") != 0)
16117 if ac_fn_c_try_run "$LINENO"; then :
16118 pgac_cv_snprintf_arg_control=yes
16120 pgac_cv_snprintf_arg_control=no
16122 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16123 conftest.$ac_objext conftest.beam conftest.$ac_ext
16128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_snprintf_arg_control" >&5
16129 $as_echo "$pgac_cv_snprintf_arg_control" >&6; }
16131 if test $pgac_cv_snprintf_arg_control != yes ; then
16132 pgac_need_repl_snprintf=yes
16138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether long int is 64 bits" >&5
16139 $as_echo_n "checking whether long int is 64 bits... " >&6; }
16140 if ${pgac_cv_type_long_int_64+:} false; then :
16141 $as_echo_n "(cached) " >&6
16143 if test "$cross_compiling" = yes; then :
16144 # If cross-compiling, check the size reported by the compiler and
16145 # trust that the arithmetic works.
16146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16147 /* end confdefs.h. */
16152 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
16153 test_array [0] = 0;
16154 return test_array [0];
16160 if ac_fn_c_try_compile "$LINENO"; then :
16161 pgac_cv_type_long_int_64=yes
16163 pgac_cv_type_long_int_64=no
16165 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16167 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16168 /* end confdefs.h. */
16169 typedef long int ac_int64;
16172 * These are globals to discourage the compiler from folding all the
16173 * arithmetic tests down to compile-time constants.
16175 ac_int64 a = 20000001;
16176 ac_int64 b = 40000005;
16178 int does_int64_work()
16182 if (sizeof(ac_int64) != 8)
16183 return 0; /* definitely not the right size */
16185 /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
16195 return (! does_int64_work());
16198 if ac_fn_c_try_run "$LINENO"; then :
16199 pgac_cv_type_long_int_64=yes
16201 pgac_cv_type_long_int_64=no
16203 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16204 conftest.$ac_objext conftest.beam conftest.$ac_ext
16208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_type_long_int_64" >&5
16209 $as_echo "$pgac_cv_type_long_int_64" >&6; }
16211 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
16212 if test x"$pgac_cv_type_long_int_64" = xyes ; then
16214 $as_echo "#define HAVE_LONG_INT_64 1" >>confdefs.h
16219 if test x"$HAVE_LONG_INT_64" = x"yes" ; then
16220 pg_int64_type="long int"
16222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether long long int is 64 bits" >&5
16223 $as_echo_n "checking whether long long int is 64 bits... " >&6; }
16224 if ${pgac_cv_type_long_long_int_64+:} false; then :
16225 $as_echo_n "(cached) " >&6
16227 if test "$cross_compiling" = yes; then :
16228 # If cross-compiling, check the size reported by the compiler and
16229 # trust that the arithmetic works.
16230 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16231 /* end confdefs.h. */
16236 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
16237 test_array [0] = 0;
16238 return test_array [0];
16244 if ac_fn_c_try_compile "$LINENO"; then :
16245 pgac_cv_type_long_long_int_64=yes
16247 pgac_cv_type_long_long_int_64=no
16249 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16251 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16252 /* end confdefs.h. */
16253 typedef long long int ac_int64;
16256 * These are globals to discourage the compiler from folding all the
16257 * arithmetic tests down to compile-time constants.
16259 ac_int64 a = 20000001;
16260 ac_int64 b = 40000005;
16262 int does_int64_work()
16266 if (sizeof(ac_int64) != 8)
16267 return 0; /* definitely not the right size */
16269 /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
16279 return (! does_int64_work());
16282 if ac_fn_c_try_run "$LINENO"; then :
16283 pgac_cv_type_long_long_int_64=yes
16285 pgac_cv_type_long_long_int_64=no
16287 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16288 conftest.$ac_objext conftest.beam conftest.$ac_ext
16292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_type_long_long_int_64" >&5
16293 $as_echo "$pgac_cv_type_long_long_int_64" >&6; }
16295 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
16296 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
16298 $as_echo "#define HAVE_LONG_LONG_INT_64 1" >>confdefs.h
16302 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
16303 pg_int64_type="long long int"
16305 as_fn_error $? "Cannot find a working 64-bit integer type." "$LINENO" 5
16310 cat >>confdefs.h <<_ACEOF
16311 #define PG_INT64_TYPE $pg_int64_type
16315 # Select the printf length modifier that goes with that, too.
16316 # (This used to be bound up with replacement-snprintf selection, but now
16317 # we assume that the native *printf functions use standard length modifiers.)
16318 if test x"$pg_int64_type" = x"long long int" ; then
16319 INT64_MODIFIER='"ll"'
16321 INT64_MODIFIER='"l"'
16325 cat >>confdefs.h <<_ACEOF
16326 #define INT64_MODIFIER $INT64_MODIFIER
16330 # Force use of our snprintf if the system's doesn't support the %z flag.
16331 # (Note this test uses PG_INT64_TYPE and INT64_MODIFIER.)
16332 if test "$pgac_need_repl_snprintf" = no; then
16333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf supports the %z modifier" >&5
16334 $as_echo_n "checking whether snprintf supports the %z modifier... " >&6; }
16335 if ${pgac_cv_snprintf_size_t_support+:} false; then :
16336 $as_echo_n "(cached) " >&6
16338 if test "$cross_compiling" = yes; then :
16339 pgac_cv_snprintf_size_t_support=cross
16341 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16342 /* end confdefs.h. */
16344 #include <string.h>
16352 * Print the largest unsigned number fitting in a size_t using both %zu
16353 * and the previously-determined format for 64-bit integers. Note that
16354 * we don't run this code unless we know snprintf handles 64-bit ints.
16356 bufz[0] = '\0'; /* in case snprintf fails to emit anything */
16357 snprintf(bufz, sizeof(bufz), "%zu", ~((size_t) 0));
16358 snprintf(buf64, sizeof(buf64), "%" INT64_MODIFIER "u",
16359 (unsigned PG_INT64_TYPE) ~((size_t) 0));
16360 if (strcmp(bufz, buf64) != 0)
16365 if ac_fn_c_try_run "$LINENO"; then :
16366 pgac_cv_snprintf_size_t_support=yes
16368 pgac_cv_snprintf_size_t_support=no
16370 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16371 conftest.$ac_objext conftest.beam conftest.$ac_ext
16376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_snprintf_size_t_support" >&5
16377 $as_echo "$pgac_cv_snprintf_size_t_support" >&6; }
16379 if test "$pgac_cv_snprintf_size_t_support" != yes; then
16380 pgac_need_repl_snprintf=yes
16384 # Now we have checked all the reasons to replace snprintf
16385 if test $pgac_need_repl_snprintf = yes; then
16387 $as_echo "#define USE_REPL_SNPRINTF 1" >>confdefs.h
16389 case " $LIBOBJS " in
16390 *" snprintf.$ac_objext "* ) ;;
16391 *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
16397 # has to be down here, rather than with the other builtins, because
16398 # the test uses PG_INT64_TYPE.
16399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_mul_overflow" >&5
16400 $as_echo_n "checking for __builtin_mul_overflow... " >&6; }
16401 if ${pgac_cv__builtin_op_overflow+:} false; then :
16402 $as_echo_n "(cached) " >&6
16404 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16405 /* end confdefs.h. */
16407 PG_INT64_TYPE a = 1;
16408 PG_INT64_TYPE b = 1;
16409 PG_INT64_TYPE result;
16415 oflo = __builtin_mul_overflow(a, b, &result);
16420 if ac_fn_c_try_link "$LINENO"; then :
16421 pgac_cv__builtin_op_overflow=yes
16423 pgac_cv__builtin_op_overflow=no
16425 rm -f core conftest.err conftest.$ac_objext \
16426 conftest$ac_exeext conftest.$ac_ext
16428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_op_overflow" >&5
16429 $as_echo "$pgac_cv__builtin_op_overflow" >&6; }
16430 if test x"$pgac_cv__builtin_op_overflow" = xyes ; then
16432 $as_echo "#define HAVE__BUILTIN_OP_OVERFLOW 1" >>confdefs.h
16436 # Check size of void *, size_t (enables tweaks for > 32bit address space)
16437 # The cast to long int works around a bug in the HP C Compiler
16438 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
16439 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
16440 # This bug is HP SR number 8606223364.
16441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5
16442 $as_echo_n "checking size of void *... " >&6; }
16443 if ${ac_cv_sizeof_void_p+:} false; then :
16444 $as_echo_n "(cached) " >&6
16446 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"; then :
16449 if test "$ac_cv_type_void_p" = yes; then
16450 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16451 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16452 as_fn_error 77 "cannot compute sizeof (void *)
16453 See \`config.log' for more details" "$LINENO" 5; }
16455 ac_cv_sizeof_void_p=0
16460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5
16461 $as_echo "$ac_cv_sizeof_void_p" >&6; }
16465 cat >>confdefs.h <<_ACEOF
16466 #define SIZEOF_VOID_P $ac_cv_sizeof_void_p
16470 # The cast to long int works around a bug in the HP C Compiler
16471 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
16472 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
16473 # This bug is HP SR number 8606223364.
16474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5
16475 $as_echo_n "checking size of size_t... " >&6; }
16476 if ${ac_cv_sizeof_size_t+:} false; then :
16477 $as_echo_n "(cached) " >&6
16479 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (size_t))" "ac_cv_sizeof_size_t" "$ac_includes_default"; then :
16482 if test "$ac_cv_type_size_t" = yes; then
16483 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16484 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16485 as_fn_error 77 "cannot compute sizeof (size_t)
16486 See \`config.log' for more details" "$LINENO" 5; }
16488 ac_cv_sizeof_size_t=0
16493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5
16494 $as_echo "$ac_cv_sizeof_size_t" >&6; }
16498 cat >>confdefs.h <<_ACEOF
16499 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
16503 # The cast to long int works around a bug in the HP C Compiler
16504 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
16505 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
16506 # This bug is HP SR number 8606223364.
16507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
16508 $as_echo_n "checking size of long... " >&6; }
16509 if ${ac_cv_sizeof_long+:} false; then :
16510 $as_echo_n "(cached) " >&6
16512 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then :
16515 if test "$ac_cv_type_long" = yes; then
16516 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16517 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16518 as_fn_error 77 "cannot compute sizeof (long)
16519 See \`config.log' for more details" "$LINENO" 5; }
16521 ac_cv_sizeof_long=0
16526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
16527 $as_echo "$ac_cv_sizeof_long" >&6; }
16531 cat >>confdefs.h <<_ACEOF
16532 #define SIZEOF_LONG $ac_cv_sizeof_long
16537 # Decide whether float4 is passed by value: user-selectable, enabled by default
16538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with float4 passed by value" >&5
16539 $as_echo_n "checking whether to build with float4 passed by value... " >&6; }
16542 # Check whether --enable-float4-byval was given.
16543 if test "${enable_float4_byval+set}" = set; then :
16544 enableval=$enable_float4_byval;
16548 $as_echo "#define USE_FLOAT4_BYVAL 1" >>confdefs.h
16550 float4passbyval=true
16553 float4passbyval=false
16556 as_fn_error $? "no argument expected for --enable-float4-byval option" "$LINENO" 5
16561 enable_float4_byval=yes
16563 $as_echo "#define USE_FLOAT4_BYVAL 1" >>confdefs.h
16565 float4passbyval=true
16569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_float4_byval" >&5
16570 $as_echo "$enable_float4_byval" >&6; }
16572 cat >>confdefs.h <<_ACEOF
16573 #define FLOAT4PASSBYVAL $float4passbyval
16577 # Decide whether float8 is passed by value.
16578 # Note: this setting also controls int8 and related types such as timestamp.
16579 # If sizeof(Datum) >= 8, this is user-selectable, enabled by default.
16580 # If not, trying to select it is an error.
16581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with float8 passed by value" >&5
16582 $as_echo_n "checking whether to build with float8 passed by value... " >&6; }
16583 if test $ac_cv_sizeof_void_p -ge 8 ; then
16586 # Check whether --enable-float8-byval was given.
16587 if test "${enable_float8_byval+set}" = set; then :
16588 enableval=$enable_float8_byval;
16597 as_fn_error $? "no argument expected for --enable-float8-byval option" "$LINENO" 5
16602 enable_float8_byval=yes
16610 # Check whether --enable-float8-byval was given.
16611 if test "${enable_float8_byval+set}" = set; then :
16612 enableval=$enable_float8_byval;
16621 as_fn_error $? "no argument expected for --enable-float8-byval option" "$LINENO" 5
16626 enable_float8_byval=no
16631 if test "$enable_float8_byval" = yes ; then
16632 as_fn_error $? "--enable-float8-byval is not supported on 32-bit platforms." "$LINENO" 5
16635 if test "$enable_float8_byval" = yes ; then
16637 $as_echo "#define USE_FLOAT8_BYVAL 1" >>confdefs.h
16639 float8passbyval=true
16641 float8passbyval=false
16643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_float8_byval" >&5
16644 $as_echo "$enable_float8_byval" >&6; }
16646 cat >>confdefs.h <<_ACEOF
16647 #define FLOAT8PASSBYVAL $float8passbyval
16651 # Determine memory alignment requirements for the basic C data types.
16653 # The cast to long int works around a bug in the HP C Compiler,
16654 # see AC_CHECK_SIZEOF for more information.
16655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of short" >&5
16656 $as_echo_n "checking alignment of short... " >&6; }
16657 if ${ac_cv_alignof_short+:} false; then :
16658 $as_echo_n "(cached) " >&6
16660 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_short" "$ac_includes_default
16662 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
16664 typedef struct { char x; short y; } ac__type_alignof_;"; then :
16667 if test "$ac_cv_type_short" = yes; then
16668 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16669 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16670 as_fn_error 77 "cannot compute alignment of short
16671 See \`config.log' for more details" "$LINENO" 5; }
16673 ac_cv_alignof_short=0
16678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_short" >&5
16679 $as_echo "$ac_cv_alignof_short" >&6; }
16683 cat >>confdefs.h <<_ACEOF
16684 #define ALIGNOF_SHORT $ac_cv_alignof_short
16688 # The cast to long int works around a bug in the HP C Compiler,
16689 # see AC_CHECK_SIZEOF for more information.
16690 { $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of int" >&5
16691 $as_echo_n "checking alignment of int... " >&6; }
16692 if ${ac_cv_alignof_int+:} false; then :
16693 $as_echo_n "(cached) " >&6
16695 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_int" "$ac_includes_default
16697 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
16699 typedef struct { char x; int y; } ac__type_alignof_;"; then :
16702 if test "$ac_cv_type_int" = yes; then
16703 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16704 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16705 as_fn_error 77 "cannot compute alignment of int
16706 See \`config.log' for more details" "$LINENO" 5; }
16708 ac_cv_alignof_int=0
16713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_int" >&5
16714 $as_echo "$ac_cv_alignof_int" >&6; }
16718 cat >>confdefs.h <<_ACEOF
16719 #define ALIGNOF_INT $ac_cv_alignof_int
16723 # The cast to long int works around a bug in the HP C Compiler,
16724 # see AC_CHECK_SIZEOF for more information.
16725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of long" >&5
16726 $as_echo_n "checking alignment of long... " >&6; }
16727 if ${ac_cv_alignof_long+:} false; then :
16728 $as_echo_n "(cached) " >&6
16730 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_long" "$ac_includes_default
16732 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
16734 typedef struct { char x; long y; } ac__type_alignof_;"; then :
16737 if test "$ac_cv_type_long" = yes; then
16738 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16739 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16740 as_fn_error 77 "cannot compute alignment of long
16741 See \`config.log' for more details" "$LINENO" 5; }
16743 ac_cv_alignof_long=0
16748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_long" >&5
16749 $as_echo "$ac_cv_alignof_long" >&6; }
16753 cat >>confdefs.h <<_ACEOF
16754 #define ALIGNOF_LONG $ac_cv_alignof_long
16758 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
16759 # The cast to long int works around a bug in the HP C Compiler,
16760 # see AC_CHECK_SIZEOF for more information.
16761 { $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of long long int" >&5
16762 $as_echo_n "checking alignment of long long int... " >&6; }
16763 if ${ac_cv_alignof_long_long_int+:} false; then :
16764 $as_echo_n "(cached) " >&6
16766 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_long_long_int" "$ac_includes_default
16768 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
16770 typedef struct { char x; long long int y; } ac__type_alignof_;"; then :
16773 if test "$ac_cv_type_long_long_int" = yes; then
16774 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16775 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16776 as_fn_error 77 "cannot compute alignment of long long int
16777 See \`config.log' for more details" "$LINENO" 5; }
16779 ac_cv_alignof_long_long_int=0
16784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_long_long_int" >&5
16785 $as_echo "$ac_cv_alignof_long_long_int" >&6; }
16789 cat >>confdefs.h <<_ACEOF
16790 #define ALIGNOF_LONG_LONG_INT $ac_cv_alignof_long_long_int
16795 # The cast to long int works around a bug in the HP C Compiler,
16796 # see AC_CHECK_SIZEOF for more information.
16797 { $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of double" >&5
16798 $as_echo_n "checking alignment of double... " >&6; }
16799 if ${ac_cv_alignof_double+:} false; then :
16800 $as_echo_n "(cached) " >&6
16802 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_double" "$ac_includes_default
16804 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
16806 typedef struct { char x; double y; } ac__type_alignof_;"; then :
16809 if test "$ac_cv_type_double" = yes; then
16810 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16811 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16812 as_fn_error 77 "cannot compute alignment of double
16813 See \`config.log' for more details" "$LINENO" 5; }
16815 ac_cv_alignof_double=0
16820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_double" >&5
16821 $as_echo "$ac_cv_alignof_double" >&6; }
16825 cat >>confdefs.h <<_ACEOF
16826 #define ALIGNOF_DOUBLE $ac_cv_alignof_double
16831 # Compute maximum alignment of any basic type.
16832 # We assume long's alignment is at least as strong as char, short, or int;
16833 # but we must check long long (if it is being used for int64) and double.
16834 # Note that we intentionally do not consider any types wider than 64 bits,
16835 # as allowing MAXIMUM_ALIGNOF to exceed 8 would be too much of a penalty
16836 # for disk and memory space.
16838 MAX_ALIGNOF=$ac_cv_alignof_long
16839 if test $MAX_ALIGNOF -lt $ac_cv_alignof_double ; then
16840 MAX_ALIGNOF=$ac_cv_alignof_double
16842 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $ac_cv_alignof_long_long_int ; then
16843 MAX_ALIGNOF="$ac_cv_alignof_long_long_int"
16846 cat >>confdefs.h <<_ACEOF
16847 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
16852 # Some platforms predefine the types int8, int16, etc. Only check
16853 # a (hopefully) representative subset.
16854 ac_fn_c_check_type "$LINENO" "int8" "ac_cv_type_int8" "#include <stdio.h>
16856 if test "x$ac_cv_type_int8" = xyes; then :
16858 cat >>confdefs.h <<_ACEOF
16859 #define HAVE_INT8 1
16864 ac_fn_c_check_type "$LINENO" "uint8" "ac_cv_type_uint8" "#include <stdio.h>
16866 if test "x$ac_cv_type_uint8" = xyes; then :
16868 cat >>confdefs.h <<_ACEOF
16869 #define HAVE_UINT8 1
16874 ac_fn_c_check_type "$LINENO" "int64" "ac_cv_type_int64" "#include <stdio.h>
16876 if test "x$ac_cv_type_int64" = xyes; then :
16878 cat >>confdefs.h <<_ACEOF
16879 #define HAVE_INT64 1
16884 ac_fn_c_check_type "$LINENO" "uint64" "ac_cv_type_uint64" "#include <stdio.h>
16886 if test "x$ac_cv_type_uint64" = xyes; then :
16888 cat >>confdefs.h <<_ACEOF
16889 #define HAVE_UINT64 1
16896 # Some compilers offer a 128-bit integer scalar type.
16897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __int128" >&5
16898 $as_echo_n "checking for __int128... " >&6; }
16899 if ${pgac_cv__128bit_int+:} false; then :
16900 $as_echo_n "(cached) " >&6
16902 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16903 /* end confdefs.h. */
16906 * We don't actually run this test, just link it to verify that any support
16907 * functions needed for __int128 are present.
16909 * These are globals to discourage the compiler from folding all the
16910 * arithmetic tests down to compile-time constants. We do not have
16911 * convenient support for 128bit literals at this point...
16913 __int128 a = 48828125;
16914 __int128 b = 97656250;
16921 a = (a << 12) + 1; /* 200000000001 */
16922 b = (b << 12) + 5; /* 400000000005 */
16923 /* try the most relevant arithmetic ops */
16926 /* must use the results, else compiler may optimize arithmetic away */
16934 if ac_fn_c_try_link "$LINENO"; then :
16935 pgac_cv__128bit_int=yes
16937 pgac_cv__128bit_int=no
16939 rm -f core conftest.err conftest.$ac_objext \
16940 conftest$ac_exeext conftest.$ac_ext
16942 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__128bit_int" >&5
16943 $as_echo "$pgac_cv__128bit_int" >&6; }
16944 if test x"$pgac_cv__128bit_int" = xyes ; then
16945 # Use of non-default alignment with __int128 tickles bugs in some compilers.
16946 # If not cross-compiling, we can test for bugs and disable use of __int128
16947 # with buggy compilers. If cross-compiling, hope for the best.
16948 # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83925
16949 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __int128 alignment bug" >&5
16950 $as_echo_n "checking for __int128 alignment bug... " >&6; }
16951 if ${pgac_cv__128bit_int_bug+:} false; then :
16952 $as_echo_n "(cached) " >&6
16954 if test "$cross_compiling" = yes; then :
16955 pgac_cv__128bit_int_bug="assuming ok"
16957 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16958 /* end confdefs.h. */
16960 /* This must match the corresponding code in c.h: */
16961 #if defined(__GNUC__) || defined(__SUNPRO_C) || defined(__IBMC__)
16962 #define pg_attribute_aligned(a) __attribute__((aligned(a)))
16964 typedef __int128 int128a
16965 #if defined(pg_attribute_aligned)
16966 pg_attribute_aligned(8)
16970 void pass_by_val(void *buffer, int128a par) { holder = par; }
16976 long int i64 = 97656225L << 12;
16978 pass_by_val(main, (int128a) i64);
16987 if ac_fn_c_try_run "$LINENO"; then :
16988 pgac_cv__128bit_int_bug=ok
16990 pgac_cv__128bit_int_bug=broken
16992 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16993 conftest.$ac_objext conftest.beam conftest.$ac_ext
16997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__128bit_int_bug" >&5
16998 $as_echo "$pgac_cv__128bit_int_bug" >&6; }
16999 if test x"$pgac_cv__128bit_int_bug" != xbroken ; then
17001 $as_echo "#define PG_INT128_TYPE __int128" >>confdefs.h
17003 # The cast to long int works around a bug in the HP C Compiler,
17004 # see AC_CHECK_SIZEOF for more information.
17005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of PG_INT128_TYPE" >&5
17006 $as_echo_n "checking alignment of PG_INT128_TYPE... " >&6; }
17007 if ${ac_cv_alignof_PG_INT128_TYPE+:} false; then :
17008 $as_echo_n "(cached) " >&6
17010 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_PG_INT128_TYPE" "$ac_includes_default
17012 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
17014 typedef struct { char x; PG_INT128_TYPE y; } ac__type_alignof_;"; then :
17017 if test "$ac_cv_type_PG_INT128_TYPE" = yes; then
17018 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17019 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17020 as_fn_error 77 "cannot compute alignment of PG_INT128_TYPE
17021 See \`config.log' for more details" "$LINENO" 5; }
17023 ac_cv_alignof_PG_INT128_TYPE=0
17028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_PG_INT128_TYPE" >&5
17029 $as_echo "$ac_cv_alignof_PG_INT128_TYPE" >&6; }
17033 cat >>confdefs.h <<_ACEOF
17034 #define ALIGNOF_PG_INT128_TYPE $ac_cv_alignof_PG_INT128_TYPE
17041 # Check for various atomic operations now that we have checked how to declare
17043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __sync char locking functions" >&5
17044 $as_echo_n "checking for builtin __sync char locking functions... " >&6; }
17045 if ${pgac_cv_gcc_sync_char_tas+:} false; then :
17046 $as_echo_n "(cached) " >&6
17048 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17049 /* end confdefs.h. */
17055 __sync_lock_test_and_set(&lock, 1);
17056 __sync_lock_release(&lock);
17061 if ac_fn_c_try_link "$LINENO"; then :
17062 pgac_cv_gcc_sync_char_tas="yes"
17064 pgac_cv_gcc_sync_char_tas="no"
17066 rm -f core conftest.err conftest.$ac_objext \
17067 conftest$ac_exeext conftest.$ac_ext
17069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_gcc_sync_char_tas" >&5
17070 $as_echo "$pgac_cv_gcc_sync_char_tas" >&6; }
17071 if test x"$pgac_cv_gcc_sync_char_tas" = x"yes"; then
17073 $as_echo "#define HAVE_GCC__SYNC_CHAR_TAS 1" >>confdefs.h
17076 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __sync int32 locking functions" >&5
17077 $as_echo_n "checking for builtin __sync int32 locking functions... " >&6; }
17078 if ${pgac_cv_gcc_sync_int32_tas+:} false; then :
17079 $as_echo_n "(cached) " >&6
17081 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17082 /* end confdefs.h. */
17088 __sync_lock_test_and_set(&lock, 1);
17089 __sync_lock_release(&lock);
17094 if ac_fn_c_try_link "$LINENO"; then :
17095 pgac_cv_gcc_sync_int32_tas="yes"
17097 pgac_cv_gcc_sync_int32_tas="no"
17099 rm -f core conftest.err conftest.$ac_objext \
17100 conftest$ac_exeext conftest.$ac_ext
17102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_gcc_sync_int32_tas" >&5
17103 $as_echo "$pgac_cv_gcc_sync_int32_tas" >&6; }
17104 if test x"$pgac_cv_gcc_sync_int32_tas" = x"yes"; then
17106 $as_echo "#define HAVE_GCC__SYNC_INT32_TAS 1" >>confdefs.h
17109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __sync int32 atomic operations" >&5
17110 $as_echo_n "checking for builtin __sync int32 atomic operations... " >&6; }
17111 if ${pgac_cv_gcc_sync_int32_cas+:} false; then :
17112 $as_echo_n "(cached) " >&6
17114 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17115 /* end confdefs.h. */
17121 __sync_val_compare_and_swap(&val, 0, 37);
17126 if ac_fn_c_try_link "$LINENO"; then :
17127 pgac_cv_gcc_sync_int32_cas="yes"
17129 pgac_cv_gcc_sync_int32_cas="no"
17131 rm -f core conftest.err conftest.$ac_objext \
17132 conftest$ac_exeext conftest.$ac_ext
17134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_gcc_sync_int32_cas" >&5
17135 $as_echo "$pgac_cv_gcc_sync_int32_cas" >&6; }
17136 if test x"$pgac_cv_gcc_sync_int32_cas" = x"yes"; then
17138 $as_echo "#define HAVE_GCC__SYNC_INT32_CAS 1" >>confdefs.h
17141 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __sync int64 atomic operations" >&5
17142 $as_echo_n "checking for builtin __sync int64 atomic operations... " >&6; }
17143 if ${pgac_cv_gcc_sync_int64_cas+:} false; then :
17144 $as_echo_n "(cached) " >&6
17146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17147 /* end confdefs.h. */
17152 PG_INT64_TYPE lock = 0;
17153 __sync_val_compare_and_swap(&lock, 0, (PG_INT64_TYPE) 37);
17158 if ac_fn_c_try_link "$LINENO"; then :
17159 pgac_cv_gcc_sync_int64_cas="yes"
17161 pgac_cv_gcc_sync_int64_cas="no"
17163 rm -f core conftest.err conftest.$ac_objext \
17164 conftest$ac_exeext conftest.$ac_ext
17166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_gcc_sync_int64_cas" >&5
17167 $as_echo "$pgac_cv_gcc_sync_int64_cas" >&6; }
17168 if test x"$pgac_cv_gcc_sync_int64_cas" = x"yes"; then
17170 $as_echo "#define HAVE_GCC__SYNC_INT64_CAS 1" >>confdefs.h
17173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __atomic int32 atomic operations" >&5
17174 $as_echo_n "checking for builtin __atomic int32 atomic operations... " >&6; }
17175 if ${pgac_cv_gcc_atomic_int32_cas+:} false; then :
17176 $as_echo_n "(cached) " >&6
17178 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17179 /* end confdefs.h. */
17186 __atomic_compare_exchange_n(&val, &expect, 37, 0, __ATOMIC_SEQ_CST, __ATOMIC_RELAXED);
17191 if ac_fn_c_try_link "$LINENO"; then :
17192 pgac_cv_gcc_atomic_int32_cas="yes"
17194 pgac_cv_gcc_atomic_int32_cas="no"
17196 rm -f core conftest.err conftest.$ac_objext \
17197 conftest$ac_exeext conftest.$ac_ext
17199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_gcc_atomic_int32_cas" >&5
17200 $as_echo "$pgac_cv_gcc_atomic_int32_cas" >&6; }
17201 if test x"$pgac_cv_gcc_atomic_int32_cas" = x"yes"; then
17203 $as_echo "#define HAVE_GCC__ATOMIC_INT32_CAS 1" >>confdefs.h
17206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __atomic int64 atomic operations" >&5
17207 $as_echo_n "checking for builtin __atomic int64 atomic operations... " >&6; }
17208 if ${pgac_cv_gcc_atomic_int64_cas+:} false; then :
17209 $as_echo_n "(cached) " >&6
17211 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17212 /* end confdefs.h. */
17217 PG_INT64_TYPE val = 0;
17218 PG_INT64_TYPE expect = 0;
17219 __atomic_compare_exchange_n(&val, &expect, 37, 0, __ATOMIC_SEQ_CST, __ATOMIC_RELAXED);
17224 if ac_fn_c_try_link "$LINENO"; then :
17225 pgac_cv_gcc_atomic_int64_cas="yes"
17227 pgac_cv_gcc_atomic_int64_cas="no"
17229 rm -f core conftest.err conftest.$ac_objext \
17230 conftest$ac_exeext conftest.$ac_ext
17232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_gcc_atomic_int64_cas" >&5
17233 $as_echo "$pgac_cv_gcc_atomic_int64_cas" >&6; }
17234 if test x"$pgac_cv_gcc_atomic_int64_cas" = x"yes"; then
17236 $as_echo "#define HAVE_GCC__ATOMIC_INT64_CAS 1" >>confdefs.h
17241 # Check for x86 cpuid instruction
17242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __get_cpuid" >&5
17243 $as_echo_n "checking for __get_cpuid... " >&6; }
17244 if ${pgac_cv__get_cpuid+:} false; then :
17245 $as_echo_n "(cached) " >&6
17247 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17248 /* end confdefs.h. */
17253 unsigned int exx[4] = {0, 0, 0, 0};
17254 __get_cpuid(1, &exx[0], &exx[1], &exx[2], &exx[3]);
17260 if ac_fn_c_try_link "$LINENO"; then :
17261 pgac_cv__get_cpuid="yes"
17263 pgac_cv__get_cpuid="no"
17265 rm -f core conftest.err conftest.$ac_objext \
17266 conftest$ac_exeext conftest.$ac_ext
17268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__get_cpuid" >&5
17269 $as_echo "$pgac_cv__get_cpuid" >&6; }
17270 if test x"$pgac_cv__get_cpuid" = x"yes"; then
17272 $as_echo "#define HAVE__GET_CPUID 1" >>confdefs.h
17276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __cpuid" >&5
17277 $as_echo_n "checking for __cpuid... " >&6; }
17278 if ${pgac_cv__cpuid+:} false; then :
17279 $as_echo_n "(cached) " >&6
17281 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17282 /* end confdefs.h. */
17283 #include <intrin.h>
17287 unsigned int exx[4] = {0, 0, 0, 0};
17288 __get_cpuid(exx[0], 1);
17294 if ac_fn_c_try_link "$LINENO"; then :
17295 pgac_cv__cpuid="yes"
17297 pgac_cv__cpuid="no"
17299 rm -f core conftest.err conftest.$ac_objext \
17300 conftest$ac_exeext conftest.$ac_ext
17302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__cpuid" >&5
17303 $as_echo "$pgac_cv__cpuid" >&6; }
17304 if test x"$pgac_cv__cpuid" = x"yes"; then
17306 $as_echo "#define HAVE__CPUID 1" >>confdefs.h
17310 # Check for Intel SSE 4.2 intrinsics to do CRC calculations.
17312 # First check if the _mm_crc32_u8 and _mm_crc32_u64 intrinsics can be used
17313 # with the default compiler flags. If not, check if adding the -msse4.2
17314 # flag helps. CFLAGS_SSE42 is set to -msse4.2 if that's required.
17315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _mm_crc32_u8 and _mm_crc32_u32 with CFLAGS=" >&5
17316 $as_echo_n "checking for _mm_crc32_u8 and _mm_crc32_u32 with CFLAGS=... " >&6; }
17317 if ${pgac_cv_sse42_crc32_intrinsics_+:} false; then :
17318 $as_echo_n "(cached) " >&6
17320 pgac_save_CFLAGS=$CFLAGS
17321 CFLAGS="$pgac_save_CFLAGS "
17322 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17323 /* end confdefs.h. */
17324 #include <nmmintrin.h>
17328 unsigned int crc = 0;
17329 crc = _mm_crc32_u8(crc, 0);
17330 crc = _mm_crc32_u32(crc, 0);
17331 /* return computed value, to prevent the above being optimized away */
17337 if ac_fn_c_try_link "$LINENO"; then :
17338 pgac_cv_sse42_crc32_intrinsics_=yes
17340 pgac_cv_sse42_crc32_intrinsics_=no
17342 rm -f core conftest.err conftest.$ac_objext \
17343 conftest$ac_exeext conftest.$ac_ext
17344 CFLAGS="$pgac_save_CFLAGS"
17346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_sse42_crc32_intrinsics_" >&5
17347 $as_echo "$pgac_cv_sse42_crc32_intrinsics_" >&6; }
17348 if test x"$pgac_cv_sse42_crc32_intrinsics_" = x"yes"; then
17350 pgac_sse42_crc32_intrinsics=yes
17353 if test x"$pgac_sse42_crc32_intrinsics" != x"yes"; then
17354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _mm_crc32_u8 and _mm_crc32_u32 with CFLAGS=-msse4.2" >&5
17355 $as_echo_n "checking for _mm_crc32_u8 and _mm_crc32_u32 with CFLAGS=-msse4.2... " >&6; }
17356 if ${pgac_cv_sse42_crc32_intrinsics__msse4_2+:} false; then :
17357 $as_echo_n "(cached) " >&6
17359 pgac_save_CFLAGS=$CFLAGS
17360 CFLAGS="$pgac_save_CFLAGS -msse4.2"
17361 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17362 /* end confdefs.h. */
17363 #include <nmmintrin.h>
17367 unsigned int crc = 0;
17368 crc = _mm_crc32_u8(crc, 0);
17369 crc = _mm_crc32_u32(crc, 0);
17370 /* return computed value, to prevent the above being optimized away */
17376 if ac_fn_c_try_link "$LINENO"; then :
17377 pgac_cv_sse42_crc32_intrinsics__msse4_2=yes
17379 pgac_cv_sse42_crc32_intrinsics__msse4_2=no
17381 rm -f core conftest.err conftest.$ac_objext \
17382 conftest$ac_exeext conftest.$ac_ext
17383 CFLAGS="$pgac_save_CFLAGS"
17385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_sse42_crc32_intrinsics__msse4_2" >&5
17386 $as_echo "$pgac_cv_sse42_crc32_intrinsics__msse4_2" >&6; }
17387 if test x"$pgac_cv_sse42_crc32_intrinsics__msse4_2" = x"yes"; then
17388 CFLAGS_SSE42="-msse4.2"
17389 pgac_sse42_crc32_intrinsics=yes
17395 # Are we targeting a processor that supports SSE 4.2? gcc, clang and icc all
17396 # define __SSE4_2__ in that case.
17397 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17398 /* end confdefs.h. */
17405 #error __SSE4_2__ not defined
17412 if ac_fn_c_try_compile "$LINENO"; then :
17415 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17417 # Check for ARMv8 CRC Extension intrinsics to do CRC calculations.
17419 # First check if __crc32c* intrinsics can be used with the default compiler
17420 # flags. If not, check if adding -march=armv8-a+crc flag helps.
17421 # CFLAGS_ARMV8_CRC32C is set if the extra flag is required.
17422 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __crc32cb, __crc32ch, __crc32cw, and __crc32cd with CFLAGS=" >&5
17423 $as_echo_n "checking for __crc32cb, __crc32ch, __crc32cw, and __crc32cd with CFLAGS=... " >&6; }
17424 if ${pgac_cv_armv8_crc32c_intrinsics_+:} false; then :
17425 $as_echo_n "(cached) " >&6
17427 pgac_save_CFLAGS=$CFLAGS
17428 CFLAGS="$pgac_save_CFLAGS "
17429 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17430 /* end confdefs.h. */
17431 #include <arm_acle.h>
17435 unsigned int crc = 0;
17436 crc = __crc32cb(crc, 0);
17437 crc = __crc32ch(crc, 0);
17438 crc = __crc32cw(crc, 0);
17439 crc = __crc32cd(crc, 0);
17440 /* return computed value, to prevent the above being optimized away */
17446 if ac_fn_c_try_link "$LINENO"; then :
17447 pgac_cv_armv8_crc32c_intrinsics_=yes
17449 pgac_cv_armv8_crc32c_intrinsics_=no
17451 rm -f core conftest.err conftest.$ac_objext \
17452 conftest$ac_exeext conftest.$ac_ext
17453 CFLAGS="$pgac_save_CFLAGS"
17455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_armv8_crc32c_intrinsics_" >&5
17456 $as_echo "$pgac_cv_armv8_crc32c_intrinsics_" >&6; }
17457 if test x"$pgac_cv_armv8_crc32c_intrinsics_" = x"yes"; then
17458 CFLAGS_ARMV8_CRC32C=""
17459 pgac_armv8_crc32c_intrinsics=yes
17462 if test x"$pgac_armv8_crc32c_intrinsics" != x"yes"; then
17463 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __crc32cb, __crc32ch, __crc32cw, and __crc32cd with CFLAGS=-march=armv8-a+crc" >&5
17464 $as_echo_n "checking for __crc32cb, __crc32ch, __crc32cw, and __crc32cd with CFLAGS=-march=armv8-a+crc... " >&6; }
17465 if ${pgac_cv_armv8_crc32c_intrinsics__march_armv8_apcrc+:} false; then :
17466 $as_echo_n "(cached) " >&6
17468 pgac_save_CFLAGS=$CFLAGS
17469 CFLAGS="$pgac_save_CFLAGS -march=armv8-a+crc"
17470 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17471 /* end confdefs.h. */
17472 #include <arm_acle.h>
17476 unsigned int crc = 0;
17477 crc = __crc32cb(crc, 0);
17478 crc = __crc32ch(crc, 0);
17479 crc = __crc32cw(crc, 0);
17480 crc = __crc32cd(crc, 0);
17481 /* return computed value, to prevent the above being optimized away */
17487 if ac_fn_c_try_link "$LINENO"; then :
17488 pgac_cv_armv8_crc32c_intrinsics__march_armv8_apcrc=yes
17490 pgac_cv_armv8_crc32c_intrinsics__march_armv8_apcrc=no
17492 rm -f core conftest.err conftest.$ac_objext \
17493 conftest$ac_exeext conftest.$ac_ext
17494 CFLAGS="$pgac_save_CFLAGS"
17496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_armv8_crc32c_intrinsics__march_armv8_apcrc" >&5
17497 $as_echo "$pgac_cv_armv8_crc32c_intrinsics__march_armv8_apcrc" >&6; }
17498 if test x"$pgac_cv_armv8_crc32c_intrinsics__march_armv8_apcrc" = x"yes"; then
17499 CFLAGS_ARMV8_CRC32C="-march=armv8-a+crc"
17500 pgac_armv8_crc32c_intrinsics=yes
17506 # Select CRC-32C implementation.
17508 # If we are targeting a processor that has Intel SSE 4.2 instructions, we can
17509 # use the special CRC instructions for calculating CRC-32C. If we're not
17510 # targeting such a processor, but we can nevertheless produce code that uses
17511 # the SSE intrinsics, perhaps with some extra CFLAGS, compile both
17512 # implementations and select which one to use at runtime, depending on whether
17513 # SSE 4.2 is supported by the processor we're running on.
17515 # Similarly, if we are targeting an ARM processor that has the CRC
17516 # instructions that are part of the ARMv8 CRC Extension, use them. And if
17517 # we're not targeting such a processor, but can nevertheless produce code that
17518 # uses the CRC instructions, compile both, and select at runtime.
17520 # You can override this logic by setting the appropriate USE_*_CRC32 flag to 1
17521 # in the template or configure command line.
17522 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
17523 # Use Intel SSE 4.2 if available.
17524 if test x"$pgac_sse42_crc32_intrinsics" = x"yes" && test x"$SSE4_2_TARGETED" = x"1" ; then
17527 # Intel SSE 4.2, with runtime check? The CPUID instruction is needed for
17528 # the runtime check.
17529 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
17530 USE_SSE42_CRC32C_WITH_RUNTIME_CHECK=1
17532 # Use ARM CRC Extension if available.
17533 if test x"$pgac_armv8_crc32c_intrinsics" = x"yes" && test x"$CFLAGS_ARMV8_CRC32C" = x""; then
17536 # ARM CRC Extension, with runtime check?
17537 if test x"$pgac_armv8_crc32c_intrinsics" = x"yes"; then
17538 USE_ARMV8_CRC32C_WITH_RUNTIME_CHECK=1
17540 # fall back to slicing-by-8 algorithm, which doesn't require any
17541 # special CPU support.
17542 USE_SLICING_BY_8_CRC32C=1
17549 # Set PG_CRC32C_OBJS appropriately depending on the selected implementation.
17550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which CRC-32C implementation to use" >&5
17551 $as_echo_n "checking which CRC-32C implementation to use... " >&6; }
17552 if test x"$USE_SSE42_CRC32C" = x"1"; then
17554 $as_echo "#define USE_SSE42_CRC32C 1" >>confdefs.h
17556 PG_CRC32C_OBJS="pg_crc32c_sse42.o"
17557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: SSE 4.2" >&5
17558 $as_echo "SSE 4.2" >&6; }
17560 if test x"$USE_SSE42_CRC32C_WITH_RUNTIME_CHECK" = x"1"; then
17562 $as_echo "#define USE_SSE42_CRC32C_WITH_RUNTIME_CHECK 1" >>confdefs.h
17564 PG_CRC32C_OBJS="pg_crc32c_sse42.o pg_crc32c_sb8.o pg_crc32c_sse42_choose.o"
17565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: SSE 4.2 with runtime check" >&5
17566 $as_echo "SSE 4.2 with runtime check" >&6; }
17568 if test x"$USE_ARMV8_CRC32C" = x"1"; then
17570 $as_echo "#define USE_ARMV8_CRC32C 1" >>confdefs.h
17572 PG_CRC32C_OBJS="pg_crc32c_armv8.o"
17573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ARMv8 CRC instructions" >&5
17574 $as_echo "ARMv8 CRC instructions" >&6; }
17576 if test x"$USE_ARMV8_CRC32C_WITH_RUNTIME_CHECK" = x"1"; then
17578 $as_echo "#define USE_ARMV8_CRC32C_WITH_RUNTIME_CHECK 1" >>confdefs.h
17580 PG_CRC32C_OBJS="pg_crc32c_armv8.o pg_crc32c_sb8.o pg_crc32c_armv8_choose.o"
17581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ARMv8 CRC instructions with runtime check" >&5
17582 $as_echo "ARMv8 CRC instructions with runtime check" >&6; }
17585 $as_echo "#define USE_SLICING_BY_8_CRC32C 1" >>confdefs.h
17587 PG_CRC32C_OBJS="pg_crc32c_sb8.o"
17588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: slicing-by-8" >&5
17589 $as_echo "slicing-by-8" >&6; }
17597 # Select semaphore implementation type.
17598 if test "$PORTNAME" != "win32"; then
17599 if test x"$PREFERRED_SEMAPHORES" = x"NAMED_POSIX" ; then
17600 # Need sem_open for this
17601 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sem_open" >&5
17602 $as_echo_n "checking for library containing sem_open... " >&6; }
17603 if ${ac_cv_search_sem_open+:} false; then :
17604 $as_echo_n "(cached) " >&6
17606 ac_func_search_save_LIBS=$LIBS
17607 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17608 /* end confdefs.h. */
17610 /* Override any GCC internal prototype to avoid an error.
17611 Use char because int might match the return type of a GCC
17612 builtin and then its argument prototype would still apply. */
17620 return sem_open ();
17625 for ac_lib in '' rt pthread; do
17626 if test -z "$ac_lib"; then
17627 ac_res="none required"
17630 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
17632 if ac_fn_c_try_link "$LINENO"; then :
17633 ac_cv_search_sem_open=$ac_res
17635 rm -f core conftest.err conftest.$ac_objext \
17637 if ${ac_cv_search_sem_open+:} false; then :
17641 if ${ac_cv_search_sem_open+:} false; then :
17644 ac_cv_search_sem_open=no
17646 rm conftest.$ac_ext
17647 LIBS=$ac_func_search_save_LIBS
17649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sem_open" >&5
17650 $as_echo "$ac_cv_search_sem_open" >&6; }
17651 ac_res=$ac_cv_search_sem_open
17652 if test "$ac_res" != no; then :
17653 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17654 USE_NAMED_POSIX_SEMAPHORES=1
17658 if test x"$PREFERRED_SEMAPHORES" = x"UNNAMED_POSIX" ; then
17659 # Need sem_init for this
17660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sem_init" >&5
17661 $as_echo_n "checking for library containing sem_init... " >&6; }
17662 if ${ac_cv_search_sem_init+:} false; then :
17663 $as_echo_n "(cached) " >&6
17665 ac_func_search_save_LIBS=$LIBS
17666 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17667 /* end confdefs.h. */
17669 /* Override any GCC internal prototype to avoid an error.
17670 Use char because int might match the return type of a GCC
17671 builtin and then its argument prototype would still apply. */
17679 return sem_init ();
17684 for ac_lib in '' rt pthread; do
17685 if test -z "$ac_lib"; then
17686 ac_res="none required"
17689 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
17691 if ac_fn_c_try_link "$LINENO"; then :
17692 ac_cv_search_sem_init=$ac_res
17694 rm -f core conftest.err conftest.$ac_objext \
17696 if ${ac_cv_search_sem_init+:} false; then :
17700 if ${ac_cv_search_sem_init+:} false; then :
17703 ac_cv_search_sem_init=no
17705 rm conftest.$ac_ext
17706 LIBS=$ac_func_search_save_LIBS
17708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sem_init" >&5
17709 $as_echo "$ac_cv_search_sem_init" >&6; }
17710 ac_res=$ac_cv_search_sem_init
17711 if test "$ac_res" != no; then :
17712 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17713 USE_UNNAMED_POSIX_SEMAPHORES=1
17717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which semaphore API to use" >&5
17718 $as_echo_n "checking which semaphore API to use... " >&6; }
17719 if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
17721 $as_echo "#define USE_NAMED_POSIX_SEMAPHORES 1" >>confdefs.h
17723 SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
17724 sematype="named POSIX"
17726 if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
17728 $as_echo "#define USE_UNNAMED_POSIX_SEMAPHORES 1" >>confdefs.h
17730 SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
17731 sematype="unnamed POSIX"
17734 $as_echo "#define USE_SYSV_SEMAPHORES 1" >>confdefs.h
17736 SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
17737 sematype="System V"
17740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $sematype" >&5
17741 $as_echo "$sematype" >&6; }
17744 $as_echo "#define USE_WIN32_SEMAPHORES 1" >>confdefs.h
17746 SEMA_IMPLEMENTATION="src/backend/port/win32_sema.c"
17750 # Select shared-memory implementation type.
17751 if test "$PORTNAME" != "win32"; then
17753 $as_echo "#define USE_SYSV_SHARED_MEMORY 1" >>confdefs.h
17755 SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
17758 $as_echo "#define USE_WIN32_SHARED_MEMORY 1" >>confdefs.h
17760 SHMEM_IMPLEMENTATION="src/backend/port/win32_shmem.c"
17763 # Select random number source
17765 # You can override this logic by setting the appropriate USE_*RANDOM flag to 1
17766 # in the template or configure command line.
17768 # If not selected manually, try to select a source automatically.
17769 if test "$enable_strong_random" = "yes" && test x"$USE_OPENSSL_RANDOM" = x"" && test x"$USE_WIN32_RANDOM" = x"" && test x"$USE_DEV_URANDOM" = x"" ; then
17770 if test x"$with_openssl" = x"yes" ; then
17771 USE_OPENSSL_RANDOM=1
17772 elif test "$PORTNAME" = "win32" ; then
17775 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/urandom" >&5
17776 $as_echo_n "checking for /dev/urandom... " >&6; }
17777 if ${ac_cv_file__dev_urandom+:} false; then :
17778 $as_echo_n "(cached) " >&6
17780 test "$cross_compiling" = yes &&
17781 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
17782 if test -r "/dev/urandom"; then
17783 ac_cv_file__dev_urandom=yes
17785 ac_cv_file__dev_urandom=no
17788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__dev_urandom" >&5
17789 $as_echo "$ac_cv_file__dev_urandom" >&6; }
17790 if test "x$ac_cv_file__dev_urandom" = xyes; then :
17795 if test x"$ac_cv_file__dev_urandom" = x"yes" ; then
17801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which random number source to use" >&5
17802 $as_echo_n "checking which random number source to use... " >&6; }
17803 if test "$enable_strong_random" = yes ; then
17804 if test x"$USE_OPENSSL_RANDOM" = x"1" ; then
17806 $as_echo "#define USE_OPENSSL_RANDOM 1" >>confdefs.h
17808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: OpenSSL" >&5
17809 $as_echo "OpenSSL" >&6; }
17810 elif test x"$USE_WIN32_RANDOM" = x"1" ; then
17812 $as_echo "#define USE_WIN32_RANDOM 1" >>confdefs.h
17814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Windows native" >&5
17815 $as_echo "Windows native" >&6; }
17816 elif test x"$USE_DEV_URANDOM" = x"1" ; then
17818 $as_echo "#define USE_DEV_URANDOM 1" >>confdefs.h
17820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: /dev/urandom" >&5
17821 $as_echo "/dev/urandom" >&6; }
17824 no source of strong random numbers was found
17825 PostgreSQL can use OpenSSL or /dev/urandom as a source of random numbers,
17826 for authentication protocols. You can use --disable-strong-random to use a
17827 built-in pseudo random number generator, but that may be insecure." "$LINENO" 5
17830 $as_echo "#define HAVE_STRONG_RANDOM 1" >>confdefs.h
17833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: weak builtin PRNG" >&5
17834 $as_echo "weak builtin PRNG" >&6; }
17835 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
17836 *** Not using a strong random number source may be insecure." >&5
17837 $as_echo "$as_me: WARNING:
17838 *** Not using a strong random number source may be insecure." >&2;}
17841 # If not set in template file, set bytes to use libc memset()
17842 if test x"$MEMSET_LOOP_LIMIT" = x"" ; then
17843 MEMSET_LOOP_LIMIT=1024
17846 cat >>confdefs.h <<_ACEOF
17847 #define MEMSET_LOOP_LIMIT ${MEMSET_LOOP_LIMIT}
17852 if test "$enable_nls" = yes ; then
17854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing bind_textdomain_codeset" >&5
17855 $as_echo_n "checking for library containing bind_textdomain_codeset... " >&6; }
17856 if ${ac_cv_search_bind_textdomain_codeset+:} false; then :
17857 $as_echo_n "(cached) " >&6
17859 ac_func_search_save_LIBS=$LIBS
17860 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17861 /* end confdefs.h. */
17863 /* Override any GCC internal prototype to avoid an error.
17864 Use char because int might match the return type of a GCC
17865 builtin and then its argument prototype would still apply. */
17869 char bind_textdomain_codeset ();
17873 return bind_textdomain_codeset ();
17878 for ac_lib in '' intl; do
17879 if test -z "$ac_lib"; then
17880 ac_res="none required"
17883 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
17885 if ac_fn_c_try_link "$LINENO"; then :
17886 ac_cv_search_bind_textdomain_codeset=$ac_res
17888 rm -f core conftest.err conftest.$ac_objext \
17890 if ${ac_cv_search_bind_textdomain_codeset+:} false; then :
17894 if ${ac_cv_search_bind_textdomain_codeset+:} false; then :
17897 ac_cv_search_bind_textdomain_codeset=no
17899 rm conftest.$ac_ext
17900 LIBS=$ac_func_search_save_LIBS
17902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_bind_textdomain_codeset" >&5
17903 $as_echo "$ac_cv_search_bind_textdomain_codeset" >&6; }
17904 ac_res=$ac_cv_search_bind_textdomain_codeset
17905 if test "$ac_res" != no; then :
17906 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17909 as_fn_error $? "a gettext implementation is required for NLS" "$LINENO" 5
17912 ac_fn_c_check_header_mongrel "$LINENO" "libintl.h" "ac_cv_header_libintl_h" "$ac_includes_default"
17913 if test "x$ac_cv_header_libintl_h" = xyes; then :
17916 as_fn_error $? "header file <libintl.h> is required for NLS" "$LINENO" 5
17920 if test -z "$MSGFMT"; then
17921 for ac_prog in msgfmt
17923 # Extract the first word of "$ac_prog", so it can be a program name with args.
17924 set dummy $ac_prog; ac_word=$2
17925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17926 $as_echo_n "checking for $ac_word... " >&6; }
17927 if ${ac_cv_path_MSGFMT+:} false; then :
17928 $as_echo_n "(cached) " >&6
17932 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
17935 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17936 for as_dir in $PATH
17939 test -z "$as_dir" && as_dir=.
17940 for ac_exec_ext in '' $ac_executable_extensions; do
17941 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17942 ac_cv_path_MSGFMT="$as_dir/$ac_word$ac_exec_ext"
17943 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17953 MSGFMT=$ac_cv_path_MSGFMT
17954 if test -n "$MSGFMT"; then
17955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
17956 $as_echo "$MSGFMT" >&6; }
17958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17959 $as_echo "no" >&6; }
17963 test -n "$MSGFMT" && break
17967 # Report the value of MSGFMT in configure's output in all cases.
17968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MSGFMT" >&5
17969 $as_echo_n "checking for MSGFMT... " >&6; }
17970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
17971 $as_echo "$MSGFMT" >&6; }
17974 if test -z "$MSGFMT"; then
17975 as_fn_error $? "msgfmt is required for NLS" "$LINENO" 5
17977 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msgfmt flags" >&5
17978 $as_echo_n "checking for msgfmt flags... " >&6; }
17979 if ${pgac_cv_msgfmt_flags+:} false; then :
17980 $as_echo_n "(cached) " >&6
17982 if test x"$MSGFMT" != x"" && "$MSGFMT" --version 2>&1 | grep "GNU" >/dev/null; then
17983 pgac_cv_msgfmt_flags=-c
17986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_msgfmt_flags" >&5
17987 $as_echo "$pgac_cv_msgfmt_flags" >&6; }
17988 MSGFMT_FLAGS=$pgac_cv_msgfmt_flags
17990 if test -z "$MSGMERGE"; then
17991 for ac_prog in msgmerge
17993 # Extract the first word of "$ac_prog", so it can be a program name with args.
17994 set dummy $ac_prog; ac_word=$2
17995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17996 $as_echo_n "checking for $ac_word... " >&6; }
17997 if ${ac_cv_path_MSGMERGE+:} false; then :
17998 $as_echo_n "(cached) " >&6
18002 ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
18005 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18006 for as_dir in $PATH
18009 test -z "$as_dir" && as_dir=.
18010 for ac_exec_ext in '' $ac_executable_extensions; do
18011 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18012 ac_cv_path_MSGMERGE="$as_dir/$ac_word$ac_exec_ext"
18013 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18023 MSGMERGE=$ac_cv_path_MSGMERGE
18024 if test -n "$MSGMERGE"; then
18025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
18026 $as_echo "$MSGMERGE" >&6; }
18028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18029 $as_echo "no" >&6; }
18033 test -n "$MSGMERGE" && break
18037 # Report the value of MSGMERGE in configure's output in all cases.
18038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MSGMERGE" >&5
18039 $as_echo_n "checking for MSGMERGE... " >&6; }
18040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
18041 $as_echo "$MSGMERGE" >&6; }
18044 if test -z "$XGETTEXT"; then
18045 for ac_prog in xgettext
18047 # Extract the first word of "$ac_prog", so it can be a program name with args.
18048 set dummy $ac_prog; ac_word=$2
18049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18050 $as_echo_n "checking for $ac_word... " >&6; }
18051 if ${ac_cv_path_XGETTEXT+:} false; then :
18052 $as_echo_n "(cached) " >&6
18056 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
18059 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18060 for as_dir in $PATH
18063 test -z "$as_dir" && as_dir=.
18064 for ac_exec_ext in '' $ac_executable_extensions; do
18065 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18066 ac_cv_path_XGETTEXT="$as_dir/$ac_word$ac_exec_ext"
18067 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18077 XGETTEXT=$ac_cv_path_XGETTEXT
18078 if test -n "$XGETTEXT"; then
18079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
18080 $as_echo "$XGETTEXT" >&6; }
18082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18083 $as_echo "no" >&6; }
18087 test -n "$XGETTEXT" && break
18091 # Report the value of XGETTEXT in configure's output in all cases.
18092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XGETTEXT" >&5
18093 $as_echo_n "checking for XGETTEXT... " >&6; }
18094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
18095 $as_echo "$XGETTEXT" >&6; }
18101 # Check for Tcl configuration script tclConfig.sh
18102 if test "$with_tcl" = yes; then
18103 if test -z "$TCLSH"; then
18104 for ac_prog in tclsh tcl tclsh8.6 tclsh86 tclsh8.5 tclsh85 tclsh8.4 tclsh84
18106 # Extract the first word of "$ac_prog", so it can be a program name with args.
18107 set dummy $ac_prog; ac_word=$2
18108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18109 $as_echo_n "checking for $ac_word... " >&6; }
18110 if ${ac_cv_path_TCLSH+:} false; then :
18111 $as_echo_n "(cached) " >&6
18115 ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
18118 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18119 for as_dir in $PATH
18122 test -z "$as_dir" && as_dir=.
18123 for ac_exec_ext in '' $ac_executable_extensions; do
18124 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18125 ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
18126 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18136 TCLSH=$ac_cv_path_TCLSH
18137 if test -n "$TCLSH"; then
18138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TCLSH" >&5
18139 $as_echo "$TCLSH" >&6; }
18141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18142 $as_echo "no" >&6; }
18146 test -n "$TCLSH" && break
18150 # Report the value of TCLSH in configure's output in all cases.
18151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TCLSH" >&5
18152 $as_echo_n "checking for TCLSH... " >&6; }
18153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TCLSH" >&5
18154 $as_echo "$TCLSH" >&6; }
18157 if test x"$TCLSH" = x""; then
18158 as_fn_error $? "Tcl shell not found" "$LINENO" 5
18161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tclConfig.sh" >&5
18162 $as_echo_n "checking for tclConfig.sh... " >&6; }
18163 # Let user override test
18164 if test -z "$TCL_CONFIG_SH"; then
18165 pgac_test_dirs="$with_tclconfig"
18167 set X $pgac_test_dirs; shift
18168 if test $# -eq 0; then
18169 test -z "$TCLSH" && as_fn_error $? "unable to locate tclConfig.sh because no Tcl shell was found" "$LINENO" 5
18170 pgac_test_dirs=`echo 'puts $auto_path' | $TCLSH`
18171 # On newer macOS, $auto_path frequently doesn't include the place
18172 # where tclConfig.sh actually lives. Append that to the end, so as not
18173 # to break cases where a non-default Tcl installation is being used.
18174 if test -d "$PG_SYSROOT/System/Library/Frameworks/Tcl.framework" ; then
18175 pgac_test_dirs="$pgac_test_dirs $PG_SYSROOT/System/Library/Frameworks/Tcl.framework"
18177 set X $pgac_test_dirs; shift
18181 if test -r "$pgac_dir/tclConfig.sh"; then
18182 TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
18188 if test -z "$TCL_CONFIG_SH"; then
18189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18190 $as_echo "no" >&6; }
18191 as_fn_error $? "file 'tclConfig.sh' is required for Tcl" "$LINENO" 5
18193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TCL_CONFIG_SH" >&5
18194 $as_echo "$TCL_CONFIG_SH" >&6; }
18200 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
18201 eval TCL_LIBS=\"$TCL_LIBS\"
18202 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
18203 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
18205 if test "$TCL_SHARED_BUILD" != 1; then
18206 as_fn_error $? "cannot build PL/Tcl because Tcl is not a shared library
18207 Use --without-tcl to disable building PL/Tcl." "$LINENO" 5
18209 # now that we have TCL_INCLUDE_SPEC, we can check for <tcl.h>
18210 ac_save_CPPFLAGS=$CPPFLAGS
18211 CPPFLAGS="$TCL_INCLUDE_SPEC $CPPFLAGS"
18212 ac_fn_c_check_header_mongrel "$LINENO" "tcl.h" "ac_cv_header_tcl_h" "$ac_includes_default"
18213 if test "x$ac_cv_header_tcl_h" = xyes; then :
18216 as_fn_error $? "header file <tcl.h> is required for Tcl" "$LINENO" 5
18220 CPPFLAGS=$ac_save_CPPFLAGS
18223 # check for <perl.h>
18224 if test "$with_perl" = yes; then
18225 ac_save_CPPFLAGS=$CPPFLAGS
18226 CPPFLAGS="$CPPFLAGS $perl_includespec"
18227 ac_fn_c_check_header_compile "$LINENO" "perl.h" "ac_cv_header_perl_h" "#include <EXTERN.h>
18229 if test "x$ac_cv_header_perl_h" = xyes; then :
18232 as_fn_error $? "header file <perl.h> is required for Perl" "$LINENO" 5
18236 # While we're at it, check that we can link to libperl.
18237 # On most platforms, if perl.h is there then libperl.so will be too, but at
18238 # this writing Debian packages them separately. There is no known reason to
18239 # waste cycles on separate probes for the Tcl or Python libraries, though.
18240 pgac_save_LIBS=$LIBS
18241 LIBS="$perl_embed_ldflags"
18242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libperl" >&5
18243 $as_echo_n "checking for libperl... " >&6; }
18244 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18245 /* end confdefs.h. */
18247 #include <EXTERN.h>
18258 if ac_fn_c_try_link "$LINENO"; then :
18259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18260 $as_echo "yes" >&6; }
18262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18263 $as_echo "no" >&6; }
18264 as_fn_error $? "libperl library is required for Perl" "$LINENO" 5
18266 rm -f core conftest.err conftest.$ac_objext \
18267 conftest$ac_exeext conftest.$ac_ext
18268 LIBS=$pgac_save_LIBS
18269 CPPFLAGS=$ac_save_CPPFLAGS
18272 # check for <Python.h>
18273 if test "$with_python" = yes; then
18274 ac_save_CPPFLAGS=$CPPFLAGS
18275 CPPFLAGS="$python_includespec $CPPFLAGS"
18276 ac_fn_c_check_header_mongrel "$LINENO" "Python.h" "ac_cv_header_Python_h" "$ac_includes_default"
18277 if test "x$ac_cv_header_Python_h" = xyes; then :
18280 as_fn_error $? "header file <Python.h> is required for Python" "$LINENO" 5
18284 CPPFLAGS=$ac_save_CPPFLAGS
18288 # Check for DocBook and tools
18290 if test -z "$XMLLINT"; then
18291 for ac_prog in xmllint
18293 # Extract the first word of "$ac_prog", so it can be a program name with args.
18294 set dummy $ac_prog; ac_word=$2
18295 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18296 $as_echo_n "checking for $ac_word... " >&6; }
18297 if ${ac_cv_path_XMLLINT+:} false; then :
18298 $as_echo_n "(cached) " >&6
18302 ac_cv_path_XMLLINT="$XMLLINT" # Let the user override the test with a path.
18305 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18306 for as_dir in $PATH
18309 test -z "$as_dir" && as_dir=.
18310 for ac_exec_ext in '' $ac_executable_extensions; do
18311 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18312 ac_cv_path_XMLLINT="$as_dir/$ac_word$ac_exec_ext"
18313 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18323 XMLLINT=$ac_cv_path_XMLLINT
18324 if test -n "$XMLLINT"; then
18325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XMLLINT" >&5
18326 $as_echo "$XMLLINT" >&6; }
18328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18329 $as_echo "no" >&6; }
18333 test -n "$XMLLINT" && break
18337 # Report the value of XMLLINT in configure's output in all cases.
18338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XMLLINT" >&5
18339 $as_echo_n "checking for XMLLINT... " >&6; }
18340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XMLLINT" >&5
18341 $as_echo "$XMLLINT" >&6; }
18345 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DocBook XML V4.2" >&5
18346 $as_echo_n "checking for DocBook XML V4.2... " >&6; }
18347 if ${pgac_cv_check_docbook+:} false; then :
18348 $as_echo_n "(cached) " >&6
18350 cat >conftest.xml <<EOF
18351 <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
18353 <title>test</title>
18355 <title>random</title>
18357 <title>testsect</title>
18364 pgac_cv_check_docbook=no
18366 if test -n "$XMLLINT"; then
18367 $XMLLINT --noout --valid conftest.xml 1>&5 2>&1
18368 if test $? -eq 0; then
18369 pgac_cv_check_docbook=yes
18374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_check_docbook" >&5
18375 $as_echo "$pgac_cv_check_docbook" >&6; }
18377 have_docbook=$pgac_cv_check_docbook
18380 if test -z "$DBTOEPUB"; then
18381 for ac_prog in dbtoepub
18383 # Extract the first word of "$ac_prog", so it can be a program name with args.
18384 set dummy $ac_prog; ac_word=$2
18385 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18386 $as_echo_n "checking for $ac_word... " >&6; }
18387 if ${ac_cv_path_DBTOEPUB+:} false; then :
18388 $as_echo_n "(cached) " >&6
18392 ac_cv_path_DBTOEPUB="$DBTOEPUB" # Let the user override the test with a path.
18395 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18396 for as_dir in $PATH
18399 test -z "$as_dir" && as_dir=.
18400 for ac_exec_ext in '' $ac_executable_extensions; do
18401 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18402 ac_cv_path_DBTOEPUB="$as_dir/$ac_word$ac_exec_ext"
18403 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18413 DBTOEPUB=$ac_cv_path_DBTOEPUB
18414 if test -n "$DBTOEPUB"; then
18415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBTOEPUB" >&5
18416 $as_echo "$DBTOEPUB" >&6; }
18418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18419 $as_echo "no" >&6; }
18423 test -n "$DBTOEPUB" && break
18427 # Report the value of DBTOEPUB in configure's output in all cases.
18428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DBTOEPUB" >&5
18429 $as_echo_n "checking for DBTOEPUB... " >&6; }
18430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBTOEPUB" >&5
18431 $as_echo "$DBTOEPUB" >&6; }
18434 if test -z "$XSLTPROC"; then
18435 for ac_prog in xsltproc
18437 # Extract the first word of "$ac_prog", so it can be a program name with args.
18438 set dummy $ac_prog; ac_word=$2
18439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18440 $as_echo_n "checking for $ac_word... " >&6; }
18441 if ${ac_cv_path_XSLTPROC+:} false; then :
18442 $as_echo_n "(cached) " >&6
18446 ac_cv_path_XSLTPROC="$XSLTPROC" # Let the user override the test with a path.
18449 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18450 for as_dir in $PATH
18453 test -z "$as_dir" && as_dir=.
18454 for ac_exec_ext in '' $ac_executable_extensions; do
18455 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18456 ac_cv_path_XSLTPROC="$as_dir/$ac_word$ac_exec_ext"
18457 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18467 XSLTPROC=$ac_cv_path_XSLTPROC
18468 if test -n "$XSLTPROC"; then
18469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XSLTPROC" >&5
18470 $as_echo "$XSLTPROC" >&6; }
18472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18473 $as_echo "no" >&6; }
18477 test -n "$XSLTPROC" && break
18481 # Report the value of XSLTPROC in configure's output in all cases.
18482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XSLTPROC" >&5
18483 $as_echo_n "checking for XSLTPROC... " >&6; }
18484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XSLTPROC" >&5
18485 $as_echo "$XSLTPROC" >&6; }
18488 if test -z "$FOP"; then
18491 # Extract the first word of "$ac_prog", so it can be a program name with args.
18492 set dummy $ac_prog; ac_word=$2
18493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18494 $as_echo_n "checking for $ac_word... " >&6; }
18495 if ${ac_cv_path_FOP+:} false; then :
18496 $as_echo_n "(cached) " >&6
18500 ac_cv_path_FOP="$FOP" # Let the user override the test with a path.
18503 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18504 for as_dir in $PATH
18507 test -z "$as_dir" && as_dir=.
18508 for ac_exec_ext in '' $ac_executable_extensions; do
18509 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18510 ac_cv_path_FOP="$as_dir/$ac_word$ac_exec_ext"
18511 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18521 FOP=$ac_cv_path_FOP
18522 if test -n "$FOP"; then
18523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FOP" >&5
18524 $as_echo "$FOP" >&6; }
18526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18527 $as_echo "no" >&6; }
18531 test -n "$FOP" && break
18535 # Report the value of FOP in configure's output in all cases.
18536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FOP" >&5
18537 $as_echo_n "checking for FOP... " >&6; }
18538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FOP" >&5
18539 $as_echo "$FOP" >&6; }
18544 # Check for test tools
18546 if test "$enable_tap_tests" = yes; then
18547 # Check for necessary modules, unless user has specified the "prove" to use;
18548 # in that case it's her responsibility to have a working configuration.
18549 # (prove might be part of a different Perl installation than perl, eg on
18550 # MSys, so the result of AX_PROG_PERL_MODULES could be irrelevant anyway.)
18551 if test -z "$PROVE"; then
18552 # Test::More and Time::HiRes are supposed to be part of core Perl,
18553 # but some distros omit them in a minimal installation.
18564 # Make sure we have perl
18565 if test -z "$PERL"; then
18566 # Extract the first word of "perl", so it can be a program name with args.
18567 set dummy perl; ac_word=$2
18568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18569 $as_echo_n "checking for $ac_word... " >&6; }
18570 if ${ac_cv_prog_PERL+:} false; then :
18571 $as_echo_n "(cached) " >&6
18573 if test -n "$PERL"; then
18574 ac_cv_prog_PERL="$PERL" # Let the user override the test.
18576 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18577 for as_dir in $PATH
18580 test -z "$as_dir" && as_dir=.
18581 for ac_exec_ext in '' $ac_executable_extensions; do
18582 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18583 ac_cv_prog_PERL="perl"
18584 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18593 PERL=$ac_cv_prog_PERL
18594 if test -n "$PERL"; then
18595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5
18596 $as_echo "$PERL" >&6; }
18598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18599 $as_echo "no" >&6; }
18605 if test "x$PERL" != x; then
18606 ax_perl_modules_failed=0
18607 for ax_perl_module in 'IPC::Run' 'Test::More 0.87' 'Time::HiRes' ; do
18608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perl module $ax_perl_module" >&5
18609 $as_echo_n "checking for perl module $ax_perl_module... " >&6; }
18611 # Would be nice to log result here, but can't rely on autoconf internals
18612 $PERL -e "use $ax_perl_module; exit" > /dev/null 2>&1
18613 if test $? -ne 0; then
18614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18615 $as_echo "no" >&6; };
18616 ax_perl_modules_failed=1
18618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
18619 $as_echo "ok" >&6; };
18623 # Run optional shell commands
18624 if test "$ax_perl_modules_failed" = 0; then
18629 as_fn_error $? "Additional Perl modules are required to run TAP tests" "$LINENO" 5
18632 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: could not find perl" >&5
18633 $as_echo "$as_me: WARNING: could not find perl" >&2;}
18636 # Now make sure we know where prove is
18637 if test -z "$PROVE"; then
18638 for ac_prog in prove
18640 # Extract the first word of "$ac_prog", so it can be a program name with args.
18641 set dummy $ac_prog; ac_word=$2
18642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18643 $as_echo_n "checking for $ac_word... " >&6; }
18644 if ${ac_cv_path_PROVE+:} false; then :
18645 $as_echo_n "(cached) " >&6
18649 ac_cv_path_PROVE="$PROVE" # Let the user override the test with a path.
18652 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18653 for as_dir in $PATH
18656 test -z "$as_dir" && as_dir=.
18657 for ac_exec_ext in '' $ac_executable_extensions; do
18658 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18659 ac_cv_path_PROVE="$as_dir/$ac_word$ac_exec_ext"
18660 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18670 PROVE=$ac_cv_path_PROVE
18671 if test -n "$PROVE"; then
18672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROVE" >&5
18673 $as_echo "$PROVE" >&6; }
18675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18676 $as_echo "no" >&6; }
18680 test -n "$PROVE" && break
18684 # Report the value of PROVE in configure's output in all cases.
18685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PROVE" >&5
18686 $as_echo_n "checking for PROVE... " >&6; }
18687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROVE" >&5
18688 $as_echo "$PROVE" >&6; }
18691 if test -z "$PROVE"; then
18692 as_fn_error $? "prove not found" "$LINENO" 5
18698 # We have to run the thread test near the end so we have all our symbols
18699 # defined. Cross compiling throws a warning.
18701 if test "$enable_thread_safety" = yes; then
18702 if test "$PORTNAME" != "win32"
18704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking thread safety of required library functions" >&5
18705 $as_echo_n "checking thread safety of required library functions... " >&6; }
18709 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
18710 LIBS="$LIBS $PTHREAD_LIBS"
18711 if test "$cross_compiling" = yes; then :
18712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: maybe" >&5
18713 $as_echo "maybe" >&6; }
18714 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
18715 *** Skipping thread test program because of cross-compile build.
18716 *** Run the program in src/test/thread on the target machine.
18718 $as_echo "$as_me: WARNING:
18719 *** Skipping thread test program because of cross-compile build.
18720 *** Run the program in src/test/thread on the target machine.
18723 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18724 /* end confdefs.h. */
18725 #include "$srcdir/src/test/thread/thread_test.c"
18727 if ac_fn_c_try_run "$LINENO"; then :
18728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18729 $as_echo "yes" >&6; }
18731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18732 $as_echo "no" >&6; }
18733 as_fn_error $? "thread test program failed
18734 This platform is not thread-safe. Check the file 'config.log' or compile
18735 and run src/test/thread/thread_test for the exact reason.
18736 Use --disable-thread-safety to disable thread safety." "$LINENO" 5
18738 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18739 conftest.$ac_objext conftest.beam conftest.$ac_ext
18745 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** skipping thread test on Win32" >&5
18746 $as_echo "$as_me: WARNING: *** skipping thread test on Win32" >&2;}
18750 # If compiler will take -Wl,--as-needed (or various platform-specific
18751 # spellings thereof) then add that to LDFLAGS. This is much easier than
18752 # trying to filter LIBS to the minimum for each executable.
18753 # On (at least) some Red-Hat-derived systems, this switch breaks linking to
18754 # libreadline; therefore we postpone testing it until we know what library
18755 # dependencies readline has. The test code will try to link with $LIBS.
18756 if test "$with_readline" = yes; then
18757 link_test_func=readline
18759 link_test_func=exit
18762 if test "$PORTNAME" = "darwin"; then
18763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wl,-dead_strip_dylibs" >&5
18764 $as_echo_n "checking whether $CC supports -Wl,-dead_strip_dylibs... " >&6; }
18765 if ${pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs+:} false; then :
18766 $as_echo_n "(cached) " >&6
18768 pgac_save_LDFLAGS=$LDFLAGS
18769 LDFLAGS="$pgac_save_LDFLAGS -Wl,-dead_strip_dylibs"
18770 if test "$cross_compiling" = yes; then :
18771 pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs="assuming no"
18773 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18774 /* end confdefs.h. */
18775 extern void $link_test_func (); void (*fptr) () = $link_test_func;
18784 if ac_fn_c_try_run "$LINENO"; then :
18785 pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs=yes
18787 pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs=no
18789 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18790 conftest.$ac_objext conftest.beam conftest.$ac_ext
18793 LDFLAGS="$pgac_save_LDFLAGS"
18795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" >&5
18796 $as_echo "$pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" >&6; }
18797 if test x"$pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" = x"yes"; then
18798 LDFLAGS="$LDFLAGS -Wl,-dead_strip_dylibs"
18801 elif test "$PORTNAME" = "openbsd"; then
18802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wl,-Bdynamic" >&5
18803 $as_echo_n "checking whether $CC supports -Wl,-Bdynamic... " >&6; }
18804 if ${pgac_cv_prog_cc_ldflags__Wl__Bdynamic+:} false; then :
18805 $as_echo_n "(cached) " >&6
18807 pgac_save_LDFLAGS=$LDFLAGS
18808 LDFLAGS="$pgac_save_LDFLAGS -Wl,-Bdynamic"
18809 if test "$cross_compiling" = yes; then :
18810 pgac_cv_prog_cc_ldflags__Wl__Bdynamic="assuming no"
18812 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18813 /* end confdefs.h. */
18814 extern void $link_test_func (); void (*fptr) () = $link_test_func;
18823 if ac_fn_c_try_run "$LINENO"; then :
18824 pgac_cv_prog_cc_ldflags__Wl__Bdynamic=yes
18826 pgac_cv_prog_cc_ldflags__Wl__Bdynamic=no
18828 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18829 conftest.$ac_objext conftest.beam conftest.$ac_ext
18832 LDFLAGS="$pgac_save_LDFLAGS"
18834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_cc_ldflags__Wl__Bdynamic" >&5
18835 $as_echo "$pgac_cv_prog_cc_ldflags__Wl__Bdynamic" >&6; }
18836 if test x"$pgac_cv_prog_cc_ldflags__Wl__Bdynamic" = x"yes"; then
18837 LDFLAGS="$LDFLAGS -Wl,-Bdynamic"
18841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wl,--as-needed" >&5
18842 $as_echo_n "checking whether $CC supports -Wl,--as-needed... " >&6; }
18843 if ${pgac_cv_prog_cc_ldflags__Wl___as_needed+:} false; then :
18844 $as_echo_n "(cached) " >&6
18846 pgac_save_LDFLAGS=$LDFLAGS
18847 LDFLAGS="$pgac_save_LDFLAGS -Wl,--as-needed"
18848 if test "$cross_compiling" = yes; then :
18849 pgac_cv_prog_cc_ldflags__Wl___as_needed="assuming no"
18851 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18852 /* end confdefs.h. */
18853 extern void $link_test_func (); void (*fptr) () = $link_test_func;
18862 if ac_fn_c_try_run "$LINENO"; then :
18863 pgac_cv_prog_cc_ldflags__Wl___as_needed=yes
18865 pgac_cv_prog_cc_ldflags__Wl___as_needed=no
18867 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18868 conftest.$ac_objext conftest.beam conftest.$ac_ext
18871 LDFLAGS="$pgac_save_LDFLAGS"
18873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_cc_ldflags__Wl___as_needed" >&5
18874 $as_echo "$pgac_cv_prog_cc_ldflags__Wl___as_needed" >&6; }
18875 if test x"$pgac_cv_prog_cc_ldflags__Wl___as_needed" = x"yes"; then
18876 LDFLAGS="$LDFLAGS -Wl,--as-needed"
18881 # Create compiler version string
18882 if test x"$GCC" = x"yes" ; then
18883 cc_string=`${CC} --version | sed q`
18884 case $cc_string in [A-Za-z]*) ;; *) cc_string="GCC $cc_string";; esac
18885 elif test x"$SUN_STUDIO_CC" = x"yes" ; then
18886 cc_string=`${CC} -V 2>&1 | sed q`
18892 cat >>confdefs.h <<_ACEOF
18893 #define PG_VERSION_STR "PostgreSQL $PG_VERSION on $host, compiled by $cc_string, `expr $ac_cv_sizeof_void_p \* 8`-bit"
18897 # Supply a numeric version string for use by 3rd party add-ons
18898 # awk -F is a regex on some platforms, and not on others, so make "." a tab
18899 PG_VERSION_NUM="`echo "$PACKAGE_VERSION" | sed 's/[A-Za-z].*$//' |
18901 $AWK '{printf "%d%04d", $1, $2}'`"
18903 cat >>confdefs.h <<_ACEOF
18904 #define PG_VERSION_NUM $PG_VERSION_NUM
18909 # If we are inserting PG_SYSROOT into CPPFLAGS, do so symbolically not
18910 # literally, so that it's possible to override it at build time using
18911 # a command like "make ... PG_SYSROOT=path". This has to be done after
18912 # we've finished all configure checks that depend on CPPFLAGS.
18913 if test x"$PG_SYSROOT" != x; then
18914 CPPFLAGS=`echo "$CPPFLAGS" | sed -e "s| $PG_SYSROOT | \\\$(PG_SYSROOT) |"`
18919 # Begin output steps
18921 { $as_echo "$as_me:${as_lineno-$LINENO}: using compiler=$cc_string" >&5
18922 $as_echo "$as_me: using compiler=$cc_string" >&6;}
18923 { $as_echo "$as_me:${as_lineno-$LINENO}: using CFLAGS=$CFLAGS" >&5
18924 $as_echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
18925 { $as_echo "$as_me:${as_lineno-$LINENO}: using CPPFLAGS=$CPPFLAGS" >&5
18926 $as_echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
18927 { $as_echo "$as_me:${as_lineno-$LINENO}: using LDFLAGS=$LDFLAGS" >&5
18928 $as_echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
18929 # Currently only used when LLVM is used
18930 if test "$with_llvm" = yes ; then
18931 { $as_echo "$as_me:${as_lineno-$LINENO}: using CXX=$CXX" >&5
18932 $as_echo "$as_me: using CXX=$CXX" >&6;}
18933 { $as_echo "$as_me:${as_lineno-$LINENO}: using CXXFLAGS=$CXXFLAGS" >&5
18934 $as_echo "$as_me: using CXXFLAGS=$CXXFLAGS" >&6;}
18935 { $as_echo "$as_me:${as_lineno-$LINENO}: using CLANG=$CLANG" >&5
18936 $as_echo "$as_me: using CLANG=$CLANG" >&6;}
18937 { $as_echo "$as_me:${as_lineno-$LINENO}: using BITCODE_CFLAGS=$BITCODE_CFLAGS" >&5
18938 $as_echo "$as_me: using BITCODE_CFLAGS=$BITCODE_CFLAGS" >&6;}
18939 { $as_echo "$as_me:${as_lineno-$LINENO}: using BITCODE_CXXFLAGS=$BITCODE_CXXFLAGS" >&5
18940 $as_echo "$as_me: using BITCODE_CXXFLAGS=$BITCODE_CXXFLAGS" >&6;}
18943 # prepare build tree if outside source tree
18944 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
18945 # Note 2: /bin/pwd might be better than shell's built-in at getting
18946 # a symlink-free name.
18947 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
18951 if test "$no_create" != yes; then
18952 $as_echo_n "preparing build tree... " >&6
18953 pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
18954 $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
18955 || as_fn_error $? "failed" "$LINENO" 5
18956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
18957 $as_echo "done" >&6; }
18963 ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
18966 ac_config_links="$ac_config_links src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION} src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION} src/include/dynloader.h:src/backend/port/dynloader/${template}.h src/include/pg_config_os.h:src/include/port/${template}.h src/Makefile.port:src/makefiles/Makefile.${template}"
18969 if test "$PORTNAME" = "win32"; then
18970 ac_config_commands="$ac_config_commands check_win32_symlinks"
18974 ac_config_headers="$ac_config_headers src/include/pg_config.h"
18977 ac_config_headers="$ac_config_headers src/include/pg_config_ext.h"
18980 ac_config_headers="$ac_config_headers src/interfaces/ecpg/include/ecpg_config.h"
18983 cat >confcache <<\_ACEOF
18984 # This file is a shell script that caches the results of configure
18985 # tests run on this system so they can be shared between configure
18986 # scripts and configure runs, see configure's option --config-cache.
18987 # It is not useful on other systems. If it contains results you don't
18988 # want to keep, you may remove or edit it.
18990 # config.status only pays attention to the cache file if you give it
18991 # the --recheck option to rerun configure.
18993 # `ac_cv_env_foo' variables (set or unset) will be overridden when
18994 # loading this file, other *unset* `ac_cv_foo' will be assigned the
18995 # following values.
18999 # The following way of writing the cache mishandles newlines in values,
19000 # but we know of no workaround that is simple, portable, and efficient.
19001 # So, we kill variables containing newlines.
19002 # Ultrix sh set writes to stderr and can't be redirected directly,
19003 # and sets the high bit in the cache file unless we assign to the vars.
19005 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
19006 eval ac_val=\$$ac_var
19010 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
19011 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
19014 _ | IFS | as_nl) ;; #(
19015 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
19016 *) { eval $ac_var=; unset $ac_var;} ;;
19022 case $as_nl`(ac_space=' '; set) 2>&1` in #(
19023 *${as_nl}ac_space=\ *)
19024 # `set' does not quote correctly, so add quotes: double-quote
19025 # substitution turns \\\\ into \\, and sed turns \\ into \.
19028 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
19031 # `set' quotes correctly as required by POSIX, so do not add quotes.
19032 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
19041 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
19043 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
19045 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
19046 if test -w "$cache_file"; then
19047 if test "x$cache_file" != "x/dev/null"; then
19048 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
19049 $as_echo "$as_me: updating cache $cache_file" >&6;}
19050 if test ! -f "$cache_file" || test -h "$cache_file"; then
19051 cat confcache >"$cache_file"
19053 case $cache_file in #(
19055 mv -f confcache "$cache_file"$$ &&
19056 mv -f "$cache_file"$$ "$cache_file" ;; #(
19058 mv -f confcache "$cache_file" ;;
19063 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
19064 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
19069 test "x$prefix" = xNONE && prefix=$ac_default_prefix
19070 # Let make expand exec_prefix.
19071 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
19073 DEFS=-DHAVE_CONFIG_H
19078 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
19079 # 1. Remove the extension, and $U if already installed.
19080 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
19081 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
19082 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
19083 # will be set to the directory where LIBOBJS objects are built.
19084 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
19085 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
19087 LIBOBJS=$ac_libobjs
19089 LTLIBOBJS=$ac_ltlibobjs
19094 : "${CONFIG_STATUS=./config.status}"
19096 ac_clean_files_save=$ac_clean_files
19097 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
19098 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
19099 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
19101 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
19103 # Generated by $as_me.
19104 # Run this file to recreate the current configuration.
19105 # Compiler output produced by configure, useful for debugging
19106 # configure, is in config.log if it exists.
19109 ac_cs_recheck=false
19112 SHELL=\${CONFIG_SHELL-$SHELL}
19115 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
19116 ## -------------------- ##
19117 ## M4sh Initialization. ##
19118 ## -------------------- ##
19120 # Be more Bourne compatible
19121 DUALCASE=1; export DUALCASE # for MKS sh
19122 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
19125 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
19126 # is contrary to our usage. Disable this feature.
19127 alias -g '${1+"$@"}'='"$@"'
19128 setopt NO_GLOB_SUBST
19130 case `(set -o) 2>/dev/null` in #(
19142 # Printing a long string crashes Solaris 7 /usr/bin/printf.
19143 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
19144 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
19145 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
19146 # Prefer a ksh shell builtin over an external printf program on Solaris,
19147 # but without wasting forks for bash or zsh.
19148 if test -z "$BASH_VERSION$ZSH_VERSION" \
19149 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
19150 as_echo='print -r --'
19151 as_echo_n='print -rn --'
19152 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
19153 as_echo='printf %s\n'
19154 as_echo_n='printf %s'
19156 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
19157 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
19158 as_echo_n='/usr/ucb/echo -n'
19160 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
19161 as_echo_n_body='eval
19165 expr "X$arg" : "X\\(.*\\)$as_nl";
19166 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
19168 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
19170 export as_echo_n_body
19171 as_echo_n='sh -c $as_echo_n_body as_echo'
19173 export as_echo_body
19174 as_echo='sh -c $as_echo_body as_echo'
19177 # The user is always right.
19178 if test "${PATH_SEPARATOR+set}" != set; then
19180 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
19181 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
19188 # We need space, tab and new line, in precisely that order. Quoting is
19189 # there to prevent editors from complaining about space-tab.
19190 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
19191 # splitting by setting IFS to empty value.)
19194 # Find who we are. Look in the path if we contain no directory separator.
19197 *[\\/]* ) as_myself=$0 ;;
19198 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19199 for as_dir in $PATH
19202 test -z "$as_dir" && as_dir=.
19203 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
19209 # We did not find ourselves, most probably we were run as `sh COMMAND'
19210 # in which case we are not to be found in the path.
19211 if test "x$as_myself" = x; then
19214 if test ! -f "$as_myself"; then
19215 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
19219 # Unset variables that we do not need and which cause bugs (e.g. in
19220 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
19221 # suppresses any "Segmentation fault" message there. '((' could
19222 # trigger a bug in pdksh 5.2.14.
19223 for as_var in BASH_ENV ENV MAIL MAILPATH
19224 do eval test x\${$as_var+set} = xset \
19225 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
19238 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
19241 # as_fn_error STATUS ERROR [LINENO LOG_FD]
19242 # ----------------------------------------
19243 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
19244 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
19245 # script with STATUS, using 1 if that was 0.
19248 as_status=$1; test $as_status -eq 0 && as_status=1
19250 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
19251 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
19253 $as_echo "$as_me: error: $2" >&2
19254 as_fn_exit $as_status
19258 # as_fn_set_status STATUS
19259 # -----------------------
19260 # Set $? to STATUS, without forking.
19261 as_fn_set_status ()
19264 } # as_fn_set_status
19266 # as_fn_exit STATUS
19267 # -----------------
19268 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
19272 as_fn_set_status $1
19278 # Portably unset VAR.
19281 { eval $1=; unset $1;}
19283 as_unset=as_fn_unset
19284 # as_fn_append VAR VALUE
19285 # ----------------------
19286 # Append the text in VALUE to the end of the definition contained in VAR. Take
19287 # advantage of any shell optimizations that allow amortized linear growth over
19288 # repeated appends, instead of the typical quadratic growth present in naive
19290 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
19291 eval 'as_fn_append ()
19302 # as_fn_arith ARG...
19303 # ------------------
19304 # Perform arithmetic evaluation on the ARGs, and store the result in the
19305 # global $as_val. Take advantage of shells that can avoid forks. The arguments
19306 # must be portable across $(()) and expr.
19307 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
19308 eval 'as_fn_arith ()
19315 as_val=`expr "$@" || test $? -eq 1`
19320 if expr a : '\(a\)' >/dev/null 2>&1 &&
19321 test "X`expr 00001 : '.*\(...\)'`" = X001; then
19327 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
19328 as_basename=basename
19333 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
19339 as_me=`$as_basename -- "$0" ||
19340 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
19341 X"$0" : 'X\(//\)$' \| \
19342 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
19344 sed '/^.*\/\([^/][^/]*\)\/*$/{
19358 # Avoid depending upon Character Ranges.
19359 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
19360 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
19361 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
19362 as_cr_digits='0123456789'
19363 as_cr_alnum=$as_cr_Letters$as_cr_digits
19365 ECHO_C= ECHO_N= ECHO_T=
19366 case `echo -n x` in #(((((
19368 case `echo 'xy\c'` in
19369 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
19371 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
19378 rm -f conf$$ conf$$.exe conf$$.file
19379 if test -d conf$$.dir; then
19380 rm -f conf$$.dir/conf$$.file
19383 mkdir conf$$.dir 2>/dev/null
19385 if (echo >conf$$.file) 2>/dev/null; then
19386 if ln -s conf$$.file conf$$ 2>/dev/null; then
19388 # ... but there are two gotchas:
19389 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
19390 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
19391 # In both cases, we have to default to `cp -pR'.
19392 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
19394 elif ln conf$$.file conf$$ 2>/dev/null; then
19402 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
19403 rmdir conf$$.dir 2>/dev/null
19408 # Create "$as_dir" as a directory, including parents if necessary.
19413 -*) as_dir=./$as_dir;;
19415 test -d "$as_dir" || eval $as_mkdir_p || {
19419 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
19420 *) as_qdir=$as_dir;;
19422 as_dirs="'$as_qdir' $as_dirs"
19423 as_dir=`$as_dirname -- "$as_dir" ||
19424 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19425 X"$as_dir" : 'X\(//\)[^/]' \| \
19426 X"$as_dir" : 'X\(//\)$' \| \
19427 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
19428 $as_echo X"$as_dir" |
19429 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
19433 /^X\(\/\/\)[^/].*/{
19446 test -d "$as_dir" && break
19448 test -z "$as_dirs" || eval "mkdir $as_dirs"
19449 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
19453 if mkdir -p . 2>/dev/null; then
19454 as_mkdir_p='mkdir -p "$as_dir"'
19456 test -d ./-p && rmdir ./-p
19461 # as_fn_executable_p FILE
19462 # -----------------------
19463 # Test if FILE is an executable regular file.
19464 as_fn_executable_p ()
19466 test -f "$1" && test -x "$1"
19467 } # as_fn_executable_p
19468 as_test_x='test -x'
19469 as_executable_p=as_fn_executable_p
19471 # Sed expression to map a string onto a valid CPP name.
19472 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
19474 # Sed expression to map a string onto a valid variable name.
19475 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
19479 ## ----------------------------------- ##
19480 ## Main body of $CONFIG_STATUS script. ##
19481 ## ----------------------------------- ##
19483 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
19485 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19486 # Save the log message, to keep $0 and so on meaningful, and to
19487 # report actual input values of CONFIG_FILES etc. instead of their
19488 # values after options handling.
19490 This file was extended by PostgreSQL $as_me 11.5, which was
19491 generated by GNU Autoconf 2.69. Invocation command line was
19493 CONFIG_FILES = $CONFIG_FILES
19494 CONFIG_HEADERS = $CONFIG_HEADERS
19495 CONFIG_LINKS = $CONFIG_LINKS
19496 CONFIG_COMMANDS = $CONFIG_COMMANDS
19499 on `(hostname || uname -n) 2>/dev/null | sed 1q`
19504 case $ac_config_files in *"
19505 "*) set x $ac_config_files; shift; ac_config_files=$*;;
19508 case $ac_config_headers in *"
19509 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
19513 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19514 # Files that config.status was made for.
19515 config_files="$ac_config_files"
19516 config_headers="$ac_config_headers"
19517 config_links="$ac_config_links"
19518 config_commands="$ac_config_commands"
19522 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19524 \`$as_me' instantiates files and other configuration actions
19525 from templates according to the current configuration. Unless the files
19526 and actions are specified as TAGs, all are instantiated by default.
19528 Usage: $0 [OPTION]... [TAG]...
19530 -h, --help print this help, then exit
19531 -V, --version print version number and configuration settings, then exit
19532 --config print configuration, then exit
19533 -q, --quiet, --silent
19534 do not print progress messages
19535 -d, --debug don't remove temporary files
19536 --recheck update $as_me by reconfiguring in the same conditions
19537 --file=FILE[:TEMPLATE]
19538 instantiate the configuration file FILE
19539 --header=FILE[:TEMPLATE]
19540 instantiate the configuration header FILE
19542 Configuration files:
19545 Configuration headers:
19548 Configuration links:
19551 Configuration commands:
19554 Report bugs to <pgsql-bugs@postgresql.org>."
19557 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19558 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
19560 PostgreSQL config.status 11.5
19561 configured by $0, generated by GNU Autoconf 2.69,
19562 with options \\"\$ac_cs_config\\"
19564 Copyright (C) 2012 Free Software Foundation, Inc.
19565 This config.status script is free software; the Free Software Foundation
19566 gives unlimited permission to copy, distribute and modify it."
19573 test -n "\$AWK" || AWK=awk
19576 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19577 # The default lists apply if the user does not specify any file.
19583 ac_option=`expr "X$1" : 'X\([^=]*\)='`
19584 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
19588 ac_option=`expr "X$1" : 'X\([^=]*\)='`
19600 # Handling of the options.
19601 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
19603 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
19604 $as_echo "$ac_cs_version"; exit ;;
19605 --config | --confi | --conf | --con | --co | --c )
19606 $as_echo "$ac_cs_config"; exit ;;
19607 --debug | --debu | --deb | --de | --d | -d )
19609 --file | --fil | --fi | --f )
19612 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
19613 '') as_fn_error $? "missing file argument" ;;
19615 as_fn_append CONFIG_FILES " '$ac_optarg'"
19616 ac_need_defaults=false;;
19617 --header | --heade | --head | --hea )
19620 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
19622 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
19623 ac_need_defaults=false;;
19625 # Conflict between --help and --header
19626 as_fn_error $? "ambiguous option: \`$1'
19627 Try \`$0 --help' for more information.";;
19628 --help | --hel | -h )
19629 $as_echo "$ac_cs_usage"; exit ;;
19630 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
19631 | -silent | --silent | --silen | --sile | --sil | --si | --s)
19634 # This is an error.
19635 -*) as_fn_error $? "unrecognized option: \`$1'
19636 Try \`$0 --help' for more information." ;;
19638 *) as_fn_append ac_config_targets " $1"
19639 ac_need_defaults=false ;;
19645 ac_configure_extra_args=
19647 if $ac_cs_silent; then
19649 ac_configure_extra_args="$ac_configure_extra_args --silent"
19653 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19654 if \$ac_cs_recheck; then
19655 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
19657 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
19658 CONFIG_SHELL='$SHELL'
19659 export CONFIG_SHELL
19664 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19668 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
19669 ## Running $as_me. ##
19675 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19678 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19680 # Handling of arguments.
19681 for ac_config_target in $ac_config_targets
19683 case $ac_config_target in
19684 "src/backend/port/tas.s") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
19685 "GNUmakefile") CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
19686 "src/Makefile.global") CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
19687 "src/backend/port/dynloader.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;;
19688 "src/backend/port/pg_sema.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
19689 "src/backend/port/pg_shmem.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
19690 "src/include/dynloader.h") CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;;
19691 "src/include/pg_config_os.h") CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
19692 "src/Makefile.port") CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
19693 "check_win32_symlinks") CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
19694 "src/include/pg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
19695 "src/include/pg_config_ext.h") CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config_ext.h" ;;
19696 "src/interfaces/ecpg/include/ecpg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/interfaces/ecpg/include/ecpg_config.h" ;;
19698 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
19703 # If the user did not use the arguments to specify the items to instantiate,
19704 # then the envvar interface is used. Set only those that are not.
19705 # We use the long form for the default assignment because of an extremely
19706 # bizarre bug on SunOS 4.1.3.
19707 if $ac_need_defaults; then
19708 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
19709 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
19710 test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
19711 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
19714 # Have a temporary directory for convenience. Make it in the build tree
19715 # simply because there is no reason against having it here, and in addition,
19716 # creating and moving files from /tmp can sometimes cause problems.
19717 # Hook for its removal unless debugging.
19718 # Note that there is a small window in which the directory will not be cleaned:
19719 # after its creation but before its name has been assigned to `$tmp'.
19723 trap 'exit_status=$?
19724 : "${ac_tmp:=$tmp}"
19725 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
19727 trap 'as_fn_exit 1' 1 2 13 15
19729 # Create a (secure) tmp directory for tmp files.
19732 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
19736 tmp=./conf$$-$RANDOM
19737 (umask 077 && mkdir "$tmp")
19738 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
19741 # Set up the scripts for CONFIG_FILES section.
19742 # No need to generate them if there are no CONFIG_FILES.
19743 # This happens for instance with `./config.status config.h'.
19744 if test -n "$CONFIG_FILES"; then
19747 ac_cr=`echo X | tr X '\015'`
19748 # On cygwin, bash can eat \r inside `` if the user requested igncr.
19749 # But we know of no other shell where ac_cr would be empty at this
19750 # point, so we can use a bashism as a fallback.
19751 if test "x$ac_cr" = x; then
19752 eval ac_cr=\$\'\\r\'
19754 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
19755 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
19758 ac_cs_awk_cr=$ac_cr
19761 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
19766 echo "cat >conf$$subs.awk <<_ACEOF" &&
19767 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
19769 } >conf$$subs.sh ||
19770 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
19771 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
19773 for ac_last_try in false false false false false :; do
19774 . ./conf$$subs.sh ||
19775 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
19777 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
19778 if test $ac_delim_n = $ac_delim_num; then
19780 elif $ac_last_try; then
19781 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
19783 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
19786 rm -f conf$$subs.sh
19788 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19789 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
19793 s/^/S["/; s/!.*/"]=/
19803 s/\(.\{148\}\)..*/\1/
19805 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
19810 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
19817 s/\(.\{148\}\)..*/\1/
19819 s/["\\]/\\&/g; s/^/"/; s/$/"/
19823 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
19828 ' <conf$$subs.awk | sed '
19833 ' >>$CONFIG_STATUS || ac_write_fail=1
19834 rm -f conf$$subs.awk
19835 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19837 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
19838 for (key in S) S_is_set[key] = 1
19844 nfields = split(line, field, "@")
19846 len = length(field[1])
19847 for (i = 2; i < nfields; i++) {
19849 keylen = length(key)
19850 if (S_is_set[key]) {
19852 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
19853 len += length(value) + length(field[++i])
19864 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19865 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
19866 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
19869 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
19870 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
19873 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
19874 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
19875 # trailing colons and then remove the whole line if VPATH becomes empty
19876 # (actually we leave an empty line to preserve line numbers).
19877 if test "x$srcdir" = x.; then
19878 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
19896 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19897 fi # test -n "$CONFIG_FILES"
19899 # Set up the scripts for CONFIG_HEADERS section.
19900 # No need to generate them if there are no CONFIG_HEADERS.
19901 # This happens for instance with `./config.status Makefile'.
19902 if test -n "$CONFIG_HEADERS"; then
19903 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
19907 # Transform confdefs.h into an awk script `defines.awk', embedded as
19908 # here-document in config.status, that substitutes the proper values into
19909 # config.h.in to produce config.h.
19911 # Create a delimiter string that does not exist in confdefs.h, to ease
19912 # handling of long lines.
19914 for ac_last_try in false false :; do
19915 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
19916 if test -z "$ac_tt"; then
19918 elif $ac_last_try; then
19919 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
19921 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
19925 # For the awk script, D is an array of macro values keyed by name,
19926 # likewise P contains macro parameters if any. Preserve backslash
19927 # newline sequences.
19929 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
19931 s/.\{148\}/&'"$ac_delim"'/g
19934 s/^[ ]*#[ ]*define[ ][ ]*/ /
19941 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
19943 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
19947 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
19948 D["\1"]=" \3\\\\\\n"\\/p
19950 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
19955 s/.\{148\}/&'"$ac_delim"'/g
19960 s/["\\]/\\&/g; s/^/"/; s/$/"/p
19963 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
19965 ' <confdefs.h | sed '
19966 s/'"$ac_delim"'/"\\\
19967 "/g' >>$CONFIG_STATUS || ac_write_fail=1
19969 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19970 for (key in D) D_is_set[key] = 1
19973 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
19975 split(line, arg, " ")
19976 if (arg[1] == "#") {
19980 defundef = substr(arg[1], 2)
19983 split(mac1, mac2, "(") #)
19985 prefix = substr(line, 1, index(line, defundef) - 1)
19986 if (D_is_set[macro]) {
19987 # Preserve the white space surrounding the "#".
19988 print prefix "define", macro P[macro] D[macro]
19991 # Replace #undef with comments. This is necessary, for example,
19992 # in the case of _POSIX_SOURCE, which is predefined and required
19993 # on some systems where configure will not decide to define it.
19994 if (defundef == "undef") {
19995 print "/*", prefix defundef, macro, "*/"
20003 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20004 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
20005 fi # test -n "$CONFIG_HEADERS"
20008 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :L $CONFIG_LINKS :C $CONFIG_COMMANDS"
20013 :[FHLC]) ac_mode=$ac_tag; continue;;
20015 case $ac_mode$ac_tag in
20017 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
20018 :[FH]-) ac_tag=-:-;;
20019 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
20036 -) ac_f="$ac_tmp/stdin";;
20037 *) # Look for the file first in the build tree, then in the source tree
20038 # (if the path is not absolute). The absolute path cannot be DOS-style,
20039 # because $ac_f cannot contain `:'.
20043 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
20045 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
20047 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
20048 as_fn_append ac_file_inputs " '$ac_f'"
20051 # Let's still pretend it is `configure' which instantiates (i.e., don't
20052 # use $as_me), people would be surprised to read:
20053 # /* config.h. Generated by config.status. */
20054 configure_input='Generated from '`
20055 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
20057 if test x"$ac_file" != x-; then
20058 configure_input="$ac_file. $configure_input"
20059 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
20060 $as_echo "$as_me: creating $ac_file" >&6;}
20062 # Neutralize special characters interpreted by sed in replacement strings.
20063 case $configure_input in #(
20064 *\&* | *\|* | *\\* )
20065 ac_sed_conf_input=`$as_echo "$configure_input" |
20066 sed 's/[\\\\&|]/\\\\&/g'`;; #(
20067 *) ac_sed_conf_input=$configure_input;;
20071 *:-:* | *:-) cat >"$ac_tmp/stdin" \
20072 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
20077 ac_dir=`$as_dirname -- "$ac_file" ||
20078 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20079 X"$ac_file" : 'X\(//\)[^/]' \| \
20080 X"$ac_file" : 'X\(//\)$' \| \
20081 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
20082 $as_echo X"$ac_file" |
20083 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
20087 /^X\(\/\/\)[^/].*/{
20100 as_dir="$ac_dir"; as_fn_mkdir_p
20104 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
20106 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
20107 # A ".." for each directory in $ac_dir_suffix.
20108 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
20109 case $ac_top_builddir_sub in
20110 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
20111 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
20114 ac_abs_top_builddir=$ac_pwd
20115 ac_abs_builddir=$ac_pwd$ac_dir_suffix
20116 # for backward compatibility:
20117 ac_top_builddir=$ac_top_build_prefix
20120 .) # We are building in place.
20122 ac_top_srcdir=$ac_top_builddir_sub
20123 ac_abs_top_srcdir=$ac_pwd ;;
20124 [\\/]* | ?:[\\/]* ) # Absolute name.
20125 ac_srcdir=$srcdir$ac_dir_suffix;
20126 ac_top_srcdir=$srcdir
20127 ac_abs_top_srcdir=$srcdir ;;
20128 *) # Relative name.
20129 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
20130 ac_top_srcdir=$ac_top_build_prefix$srcdir
20131 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
20133 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
20143 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
20144 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
20146 ac_MKDIR_P=$MKDIR_P
20148 [\\/$]* | ?:[\\/]* ) ;;
20149 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
20153 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20154 # If the template does not know about datarootdir, expand it.
20155 # FIXME: This hack should be removed a few years after 2.60.
20156 ac_datarootdir_hack=; ac_datarootdir_seen=
20167 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
20168 *datarootdir*) ac_datarootdir_seen=yes;;
20169 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
20170 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
20171 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
20173 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20174 ac_datarootdir_hack='
20175 s&@datadir@&$datadir&g
20176 s&@docdir@&$docdir&g
20177 s&@infodir@&$infodir&g
20178 s&@localedir@&$localedir&g
20179 s&@mandir@&$mandir&g
20180 s&\\\${datarootdir}&$datarootdir&g' ;;
20184 # Neutralize VPATH when `$srcdir' = `.'.
20185 # Shell code in configure.ac might set extrasub.
20186 # FIXME: do we really want to maintain this feature?
20187 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20188 ac_sed_extra="$ac_vpsub
20191 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20193 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
20194 s|@configure_input@|$ac_sed_conf_input|;t t
20195 s&@top_builddir@&$ac_top_builddir_sub&;t t
20196 s&@top_build_prefix@&$ac_top_build_prefix&;t t
20197 s&@srcdir@&$ac_srcdir&;t t
20198 s&@abs_srcdir@&$ac_abs_srcdir&;t t
20199 s&@top_srcdir@&$ac_top_srcdir&;t t
20200 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
20201 s&@builddir@&$ac_builddir&;t t
20202 s&@abs_builddir@&$ac_abs_builddir&;t t
20203 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
20204 s&@INSTALL@&$ac_INSTALL&;t t
20205 s&@MKDIR_P@&$ac_MKDIR_P&;t t
20206 $ac_datarootdir_hack
20208 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
20209 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
20211 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
20212 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
20213 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
20214 "$ac_tmp/out"`; test -z "$ac_out"; } &&
20215 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
20216 which seems to be undefined. Please make sure it is defined" >&5
20217 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
20218 which seems to be undefined. Please make sure it is defined" >&2;}
20220 rm -f "$ac_tmp/stdin"
20222 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
20223 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
20225 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
20231 if test x"$ac_file" != x-; then
20233 $as_echo "/* $configure_input */" \
20234 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
20235 } >"$ac_tmp/config.h" \
20236 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
20237 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
20238 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
20239 $as_echo "$as_me: $ac_file is unchanged" >&6;}
20242 mv "$ac_tmp/config.h" "$ac_file" \
20243 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
20246 $as_echo "/* $configure_input */" \
20247 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
20248 || as_fn_error $? "could not create -" "$LINENO" 5
20256 if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
20259 # Prefer the file from the source tree if names are identical.
20260 if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
20261 ac_source=$srcdir/$ac_source
20264 { $as_echo "$as_me:${as_lineno-$LINENO}: linking $ac_source to $ac_file" >&5
20265 $as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
20267 if test ! -r "$ac_source"; then
20268 as_fn_error $? "$ac_source: file not found" "$LINENO" 5
20272 # Try a relative symlink, then a hard link, then a copy.
20274 [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
20275 *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
20277 ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
20278 ln "$ac_source" "$ac_file" 2>/dev/null ||
20279 cp -p "$ac_source" "$ac_file" ||
20280 as_fn_error $? "cannot link or copy $ac_source to $ac_file" "$LINENO" 5
20283 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
20284 $as_echo "$as_me: executing $ac_file commands" >&6;}
20289 case $ac_file$ac_mode in
20290 "check_win32_symlinks":C)
20291 # Links sometimes fail undetected on Mingw -
20292 # so here we detect it and warn the user
20293 for FILE in $CONFIG_LINKS
20295 # test -e works for symlinks in the MinGW console
20296 test -e `expr "$FILE" : '\([^:]*\)'` || { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** link for $FILE -- please fix by hand" >&5
20297 $as_echo "$as_me: WARNING: *** link for $FILE -- please fix by hand" >&2;}
20300 "src/include/pg_config.h":H)
20301 # Update timestamp for pg_config.h (see Makefile.global)
20302 echo >src/include/stamp-h
20304 "src/include/pg_config_ext.h":H)
20305 # Update timestamp for pg_config_ext.h (see Makefile.global)
20306 echo >src/include/stamp-ext-h
20308 "src/interfaces/ecpg/include/ecpg_config.h":H) echo >src/interfaces/ecpg/include/stamp-h ;;
20316 ac_clean_files=$ac_clean_files_save
20318 test $ac_write_fail = 0 ||
20319 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
20322 # configure is writing to config.log, and then calls config.status.
20323 # config.status does its own redirection, appending to config.log.
20324 # Unfortunately, on DOS this fails, as config.log is still kept open
20325 # by configure, so config.status won't be able to write to it; its
20326 # output is simply discarded. So we exec the FD to /dev/null,
20327 # effectively closing config.log, so it can be properly (re)opened and
20328 # appended to by config.status. When coming back to configure, we
20329 # need to make the FD available again.
20330 if test "$no_create" != yes; then
20332 ac_config_status_args=
20333 test "$silent" = yes &&
20334 ac_config_status_args="$ac_config_status_args --quiet"
20336 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
20338 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
20339 # would make configure fail if this is the last instruction.
20340 $ac_cs_success || as_fn_exit 1
20342 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
20343 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
20344 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}