diff options
author | Victor Stinner <vstinner@python.org> | 2023-09-10 16:21:13 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-09-10 16:21:13 (GMT) |
commit | 71b6e2602c0b5b06d51855f179cdb30094a67968 (patch) | |
tree | 948c3c65d46a290a87f86cc9ed5d0638f51f7d51 | |
parent | 429749969621b149c1a7c3c004bd44f52bec8f44 (diff) | |
download | cpython-71b6e2602c0b5b06d51855f179cdb30094a67968.zip cpython-71b6e2602c0b5b06d51855f179cdb30094a67968.tar.gz cpython-71b6e2602c0b5b06d51855f179cdb30094a67968.tar.bz2 |
gh-109054: Don't use libatomic on cross-compilation (#109211)
configure no longer uses libatomic by default when Python is
cross-compiled. The LIBATOMIC variable can be set manually in this
case:
./configure LIBATOMIC="-latomic" (...)
-rwxr-xr-x | configure | 7 | ||||
-rw-r--r-- | configure.ac | 7 |
2 files changed, 6 insertions, 8 deletions
@@ -27774,7 +27774,7 @@ then : else $as_nop if test "$cross_compiling" = yes then : - ac_cv_libatomic_needed=yes + ac_cv_libatomic_needed=no else $as_nop cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -27811,17 +27811,14 @@ int main() _ACEOF if ac_fn_c_try_run "$LINENO" then : - ac_cv_libatomic_needed=no - else $as_nop - ac_cv_libatomic_needed=yes + ac_cv_libatomic_needed=yes fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libatomic_needed" >&5 printf "%s\n" "$ac_cv_libatomic_needed" >&6; } diff --git a/configure.ac b/configure.ac index f833755..843f2b2 100644 --- a/configure.ac +++ b/configure.ac @@ -7007,9 +7007,10 @@ int main() } return 0; // all good } -]])],[ - ac_cv_libatomic_needed=no -],[ac_cv_libatomic_needed=yes],[ac_cv_libatomic_needed=yes]) +]])], + [ac_cv_libatomic_needed=no], dnl build succeeded + [ac_cv_libatomic_needed=yes], dnl build failed + [ac_cv_libatomic_needed=no]) dnl cross compilation ]) AS_VAR_IF([ac_cv_libatomic_needed], [yes], |