https://github.com/python/cpython/commit/4ddee55c5c81237f98306b0c740035c42f80e5c8 commit: 4ddee55c5c81237f98306b0c740035c42f80e5c8 branch: 3.12 author: Miss Islington (bot) <[email protected]> committer: erlend-aasland <[email protected]> date: 2024-12-30T17:42:49Z summary:
[3.12] gh-128321: Set LIBS instead of LDFLAGS when checking sqlite3 requirements (GH-128322) (#128355) (cherry picked from commit 81376fef76a53fb79893bfa9c9db18d97c228fbe) Co-authored-by: Zanie Blue <[email protected]> Co-authored-by: Erlend E. Aasland <[email protected]> files: A Misc/NEWS.d/next/Build/2024-12-28-21-05-19.gh-issue-128321.0UvbXw.rst M configure M configure.ac diff --git a/Misc/NEWS.d/next/Build/2024-12-28-21-05-19.gh-issue-128321.0UvbXw.rst b/Misc/NEWS.d/next/Build/2024-12-28-21-05-19.gh-issue-128321.0UvbXw.rst new file mode 100644 index 00000000000000..ed72cc8ab1449a --- /dev/null +++ b/Misc/NEWS.d/next/Build/2024-12-28-21-05-19.gh-issue-128321.0UvbXw.rst @@ -0,0 +1,3 @@ +Set ``LIBS`` instead of ``LDFLAGS`` when checking if :mod:`sqlite3` library +functions are available. This fixes the ordering of linked libraries during +checks, which was incorrect when using a statically linked ``libsqlite3``. diff --git a/configure b/configure index 635e2372e905ff..c14d27ede2b173 100755 --- a/configure +++ b/configure @@ -15019,7 +15019,7 @@ save_LIBS=$LIBS CPPFLAGS="$CPPFLAGS $LIBSQLITE3_CFLAGS" - LDFLAGS="$LIBSQLITE3_LIBS $LDFLAGS" + LIBS="$LIBSQLITE3_LIBS $LIBS" ac_fn_c_check_header_compile "$LINENO" "sqlite3.h" "ac_cv_header_sqlite3_h" "$ac_includes_default" if test "x$ac_cv_header_sqlite3_h" = xyes diff --git a/configure.ac b/configure.ac index de9d7f56ffb571..bc8c357e99667e 100644 --- a/configure.ac +++ b/configure.ac @@ -4056,7 +4056,7 @@ WITH_SAVE_ENV([ dnl bpo-45774/GH-29507: The CPP check in AC_CHECK_HEADER can fail on FreeBSD, dnl hence CPPFLAGS instead of CFLAGS. CPPFLAGS="$CPPFLAGS $LIBSQLITE3_CFLAGS" - LDFLAGS="$LIBSQLITE3_LIBS $LDFLAGS" + LIBS="$LIBSQLITE3_LIBS $LIBS" AC_CHECK_HEADER([sqlite3.h], [ have_sqlite3=yes _______________________________________________ Python-checkins mailing list -- [email protected] To unsubscribe send an email to [email protected] https://mail.python.org/mailman3/lists/python-checkins.python.org/ Member address: [email protected]
