diff --git a/configure b/configure index 43e1d669d..0092511b8 100755 --- a/configure +++ b/configure @@ -18872,79 +18872,12 @@ AX_BS="\\\\" AX_DQ="\"" -printf "// Dummy settings for cross-compile. Configure manually. -#define pqxx_have_concepts false -#define pqxx_have_multidim false -#define pqxx_have_source_location false -#define pqxx_have_span false -#define pqxx_have_ssize false -#define pqxx_have_unreachable false -" > "include/pqxx/cxx_features.hxx" +printf "" > "include/pqxx/cxx_features.hxx" else $as_nop cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include - -int main() -{ - std::ofstream("include/pqxx/cxx_features.hxx") << - - // Feature test macros for libpqxx. - // Generated by generate_checks.py. - -"#define pqxx_have_concepts " -#if defined(__cpp_concepts) && __cpp_concepts - "true" -#else - "false" -#endif -"\n" - -"#define pqxx_have_multidim " -#if defined(__cpp_multidimensional_subscript) && __cpp_multidimensional_subscript - "true" -#else - "false" -#endif -"\n" - -"#define pqxx_have_source_location " -#if defined(__cpp_lib_source_location) && __cpp_lib_source_location - "true" -#else - "false" -#endif -"\n" - -"#define pqxx_have_span " -#if defined(__cpp_lib_span) && __cpp_lib_span - "true" -#else - "false" -#endif -"\n" - -"#define pqxx_have_ssize " -#if defined(__cpp_lib_ssize) && __cpp_lib_ssize - "true" -#else - "false" -#endif -"\n" - -"#define pqxx_have_unreachable " -#if defined(__cpp_lib_unreachable) && __cpp_lib_unreachable - "true" -#else - "false" -#endif -"\n" - - << std::endl; -} - _ACEOF diff --git a/configure.ac b/configure.ac index 9a3e62767..2905491c9 100644 --- a/configure.ac +++ b/configure.ac @@ -718,8 +718,7 @@ AC_RUN_IFELSE( [AC_MSG_RESULT([Generated cxx_features.hxx.])], [AC_MSG_FAILURE(["C++ features check failed."])], # We're cross-compiling. Generate a dummy. - AX_PRINT_TO_FILE( - [include/pqxx/cxx_features.hxx], + AX_PRINT_TO_FILE([include/pqxx/cxx_features.hxx], esyscmd( "tools/generate_checks.py" \ "cxx_features.txt" \ diff --git a/tools/generate_checks.py b/tools/generate_checks.py index 98fe91779..79c5295c1 100755 --- a/tools/generate_checks.py +++ b/tools/generate_checks.py @@ -23,7 +23,7 @@ if sys.version_info >= (3, 11): from datetime import UTC else: - from pytz impot UTC + from pytz import UTC endif HELP_EPILOGUE = dedent("""\