@@ -28885,6 +28885,154 @@ fi
2888528885 CPPFLAGS=$ac_save_CPPFLAGS
2888628886fi
2888728887
28888+ # check for <Python.h>
28889+ if test "$with_python" = yes; then
28890+ ac_save_CPPFLAGS=$CPPFLAGS
28891+ CPPFLAGS="$python_includespec $CPPFLAGS"
28892+ if test "${ac_cv_header_Python_h+set}" = set; then
28893+ { $as_echo "$as_me:$LINENO: checking for Python.h" >&5
28894+ $as_echo_n "checking for Python.h... " >&6; }
28895+ if test "${ac_cv_header_Python_h+set}" = set; then
28896+ $as_echo_n "(cached) " >&6
28897+ fi
28898+ { $as_echo "$as_me:$LINENO: result: $ac_cv_header_Python_h" >&5
28899+ $as_echo "$ac_cv_header_Python_h" >&6; }
28900+ else
28901+ # Is the header compilable?
28902+ { $as_echo "$as_me:$LINENO: checking Python.h usability" >&5
28903+ $as_echo_n "checking Python.h usability... " >&6; }
28904+ cat >conftest.$ac_ext <<_ACEOF
28905+ /* confdefs.h. */
28906+ _ACEOF
28907+ cat confdefs.h >>conftest.$ac_ext
28908+ cat >>conftest.$ac_ext <<_ACEOF
28909+ /* end confdefs.h. */
28910+ $ac_includes_default
28911+ #include <Python.h>
28912+ _ACEOF
28913+ rm -f conftest.$ac_objext
28914+ if { (ac_try="$ac_compile"
28915+ case "(($ac_try" in
28916+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28917+ *) ac_try_echo=$ac_try;;
28918+ esac
28919+ eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28920+ $as_echo "$ac_try_echo") >&5
28921+ (eval "$ac_compile") 2>conftest.er1
28922+ ac_status=$?
28923+ grep -v '^ *+' conftest.er1 >conftest.err
28924+ rm -f conftest.er1
28925+ cat conftest.err >&5
28926+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28927+ (exit $ac_status); } && {
28928+ test -z "$ac_c_werror_flag" ||
28929+ test ! -s conftest.err
28930+ } && test -s conftest.$ac_objext; then
28931+ ac_header_compiler=yes
28932+ else
28933+ $as_echo "$as_me: failed program was:" >&5
28934+ sed 's/^/| /' conftest.$ac_ext >&5
28935+
28936+ ac_header_compiler=no
28937+ fi
28938+
28939+ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28940+ { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
28941+ $as_echo "$ac_header_compiler" >&6; }
28942+
28943+ # Is the header present?
28944+ { $as_echo "$as_me:$LINENO: checking Python.h presence" >&5
28945+ $as_echo_n "checking Python.h presence... " >&6; }
28946+ cat >conftest.$ac_ext <<_ACEOF
28947+ /* confdefs.h. */
28948+ _ACEOF
28949+ cat confdefs.h >>conftest.$ac_ext
28950+ cat >>conftest.$ac_ext <<_ACEOF
28951+ /* end confdefs.h. */
28952+ #include <Python.h>
28953+ _ACEOF
28954+ if { (ac_try="$ac_cpp conftest.$ac_ext"
28955+ case "(($ac_try" in
28956+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28957+ *) ac_try_echo=$ac_try;;
28958+ esac
28959+ eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28960+ $as_echo "$ac_try_echo") >&5
28961+ (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
28962+ ac_status=$?
28963+ grep -v '^ *+' conftest.er1 >conftest.err
28964+ rm -f conftest.er1
28965+ cat conftest.err >&5
28966+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28967+ (exit $ac_status); } >/dev/null && {
28968+ test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
28969+ test ! -s conftest.err
28970+ }; then
28971+ ac_header_preproc=yes
28972+ else
28973+ $as_echo "$as_me: failed program was:" >&5
28974+ sed 's/^/| /' conftest.$ac_ext >&5
28975+
28976+ ac_header_preproc=no
28977+ fi
28978+
28979+ rm -f conftest.err conftest.$ac_ext
28980+ { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
28981+ $as_echo "$ac_header_preproc" >&6; }
28982+
28983+ # So? What about this header?
28984+ case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
28985+ yes:no: )
28986+ { $as_echo "$as_me:$LINENO: WARNING: Python.h: accepted by the compiler, rejected by the preprocessor!" >&5
28987+ $as_echo "$as_me: WARNING: Python.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
28988+ { $as_echo "$as_me:$LINENO: WARNING: Python.h: proceeding with the compiler's result" >&5
28989+ $as_echo "$as_me: WARNING: Python.h: proceeding with the compiler's result" >&2;}
28990+ ac_header_preproc=yes
28991+ ;;
28992+ no:yes:* )
28993+ { $as_echo "$as_me:$LINENO: WARNING: Python.h: present but cannot be compiled" >&5
28994+ $as_echo "$as_me: WARNING: Python.h: present but cannot be compiled" >&2;}
28995+ { $as_echo "$as_me:$LINENO: WARNING: Python.h: check for missing prerequisite headers?" >&5
28996+ $as_echo "$as_me: WARNING: Python.h: check for missing prerequisite headers?" >&2;}
28997+ { $as_echo "$as_me:$LINENO: WARNING: Python.h: see the Autoconf documentation" >&5
28998+ $as_echo "$as_me: WARNING: Python.h: see the Autoconf documentation" >&2;}
28999+ { $as_echo "$as_me:$LINENO: WARNING: Python.h: section \"Present But Cannot Be Compiled\"" >&5
29000+ $as_echo "$as_me: WARNING: Python.h: section \"Present But Cannot Be Compiled\"" >&2;}
29001+ { $as_echo "$as_me:$LINENO: WARNING: Python.h: proceeding with the preprocessor's result" >&5
29002+ $as_echo "$as_me: WARNING: Python.h: proceeding with the preprocessor's result" >&2;}
29003+ { $as_echo "$as_me:$LINENO: WARNING: Python.h: in the future, the compiler will take precedence" >&5
29004+ $as_echo "$as_me: WARNING: Python.h: in the future, the compiler will take precedence" >&2;}
29005+ ( cat <<\_ASBOX
29006+ ## ---------------------------------------- ##
29007+ ## Report this to pgsql-bugs@postgresql.org ##
29008+ ## ---------------------------------------- ##
29009+ _ASBOX
29010+ ) | sed "s/^/$as_me: WARNING: /" >&2
29011+ ;;
29012+ esac
29013+ { $as_echo "$as_me:$LINENO: checking for Python.h" >&5
29014+ $as_echo_n "checking for Python.h... " >&6; }
29015+ if test "${ac_cv_header_Python_h+set}" = set; then
29016+ $as_echo_n "(cached) " >&6
29017+ else
29018+ ac_cv_header_Python_h=$ac_header_preproc
29019+ fi
29020+ { $as_echo "$as_me:$LINENO: result: $ac_cv_header_Python_h" >&5
29021+ $as_echo "$ac_cv_header_Python_h" >&6; }
29022+
29023+ fi
29024+ if test "x$ac_cv_header_Python_h" = x""yes; then
29025+ :
29026+ else
29027+ { { $as_echo "$as_me:$LINENO: error: header file <Python.h> is required for Python" >&5
29028+ $as_echo "$as_me: error: header file <Python.h> is required for Python" >&2;}
29029+ { (exit 1); exit 1; }; }
29030+ fi
29031+
29032+
29033+ CPPFLAGS=$ac_save_CPPFLAGS
29034+ fi
29035+
2888829036#
2888929037# Check for DocBook and tools
2889029038#