summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorRonald Oussoren <ronaldoussoren@mac.com>2020-11-22 01:13:11 (GMT)
committerGitHub <noreply@github.com>2020-11-22 01:13:11 (GMT)
commit0f20bd9042c9b7fce20c3b9511cd0820b30094c3 (patch)
tree8c931cb6a71fb4416a0e502d718a44c5742b0d61 /configure.ac
parent68f68fa423739802fce37589ee77683c42ddb933 (diff)
downloadcpython-0f20bd9042c9b7fce20c3b9511cd0820b30094c3.zip
cpython-0f20bd9042c9b7fce20c3b9511cd0820b30094c3.tar.gz
cpython-0f20bd9042c9b7fce20c3b9511cd0820b30094c3.tar.bz2
bpo-38443: Check that the specified universal architectures work (GH-22910)
As [bpo-38443]() says the error message from configure when specifying --enable-universalsdk with a set of architectures that is not supported by the compiler is not very helpful. This PR explicitly checks if the compiler works and bails out if it doesn't.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac7
1 files changed, 7 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 668715c..7f7dfa5 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1978,6 +1978,13 @@ yes)
EXPORT_MACOSX_DEPLOYMENT_TARGET=''
AC_MSG_RESULT($MACOSX_DEPLOYMENT_TARGET)
+ AC_MSG_CHECKING(if specified universal architectures work)
+ AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <stdio.h>]], [[printf("%d", 42);]])],
+ [AC_MSG_RESULT(yes)],
+ [AC_MSG_RESULT(no)
+ AC_MSG_ERROR(check config.log and use the '--with-universal-archs' option)
+ ])
+
# end of Darwin* tests
;;
esac