Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitfefd3d2

Browse files
committed
bpo-41916: allow cross-compiled python to have -pthread set for CXX
When cross-compiling, the compile/run test for -pthread always fails so -pthreadwill never be automatically set without an override from the cache. ac_cv_pthreadcan already be overridden, so do the same thing for ac_cv_cxx_thread.
1 parentb863b9c commitfefd3d2

File tree

3 files changed

+19
-8
lines changed

3 files changed

+19
-8
lines changed
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Allow override of ac_cv_cxx_thread so that cross compiled python can set
2+
-pthread for CXX.

‎configure

Lines changed: 10 additions & 3 deletions
Some generated files are not rendered by default. Learn more aboutcustomizing how changed files appear on GitHub.

‎configure.ac

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2664,11 +2664,10 @@ fi
26642664

26652665
# If we have set a CC compiler flag for thread support then
26662666
# check if it works for CXX, too.
2667-
ac_cv_cxx_thread=no
26682667
if test ! -z "$CXX"
26692668
then
2670-
AC_MSG_CHECKING(whether$CXXalsoacceptsflagsforthreadsupport)
2671-
ac_save_cxx="$CXX"
2669+
AC_CACHE_CHECK([whether $CXX also accepts flags for thread support],[ac_cv_cxx_thread],
2670+
[ac_save_cxx="$CXX"
26722671
26732672
if test "$ac_cv_kpthread" = "yes"
26742673
then
@@ -2682,6 +2681,8 @@ elif test "$ac_cv_pthread" = "yes"
26822681
then
26832682
CXX="$CXX -pthread"
26842683
ac_cv_cxx_thread=yes
2684+
else
2685+
ac_cv_cxx_thread=no
26852686
fi
26862687
26872688
if test $ac_cv_cxx_thread = yes
@@ -2697,9 +2698,10 @@ then
26972698
fi
26982699
rm -fr conftest*
26992700
fi
2700-
AC_MSG_RESULT($ac_cv_cxx_thread)
2701+
CXX="$ac_save_cxx"])
2702+
else
2703+
ac_cv_cxx_thread=no
27012704
fi
2702-
CXX="$ac_save_cxx"
27032705

27042706
dnl # check for ANSI or K&R ("traditional") preprocessor
27052707
dnl AC_MSG_CHECKING(for C preprocessor type)

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp