This is an automated email from the ASF dual-hosted git repository.
zwoop pushed a commit to branch 9.1.x
in repository https://gitbox.apache.org/repos/asf/trafficserver.git
The following commit(s) were added to refs/heads/9.1.x by this push:
new 67efe50 Fix use of -mcx16 flag - only use if it compiles cleanly.
(#7684)
67efe50 is described below
commit 67efe508da08c1ecd64af878bd10652094c7aa08
Author: Alan M. Carroll <[email protected]>
AuthorDate: Wed Apr 7 08:26:08 2021 -0500
Fix use of -mcx16 flag - only use if it compiles cleanly. (#7684)
(cherry picked from commit b05c5bea4f0669fd7e6d994b8b854ef920fc09fb)
---
configure.ac | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/configure.ac b/configure.ac
index c3f6b00..0beba77 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1569,6 +1569,8 @@ __saved_CXXFLAGS="${CXXFLAGS}"
__saved_CFLAGS="${CFLAGS}"
has_128bit_cas=0
+# Don't add the -mcx16 flag unless needed and it compiles cleanly.
+needs_mcx16_for_cas=0
TS_TRY_COMPILE_NO_WARNING([],[
__int128_t x = 0;
@@ -1587,6 +1589,7 @@ TS_TRY_COMPILE_NO_WARNING([],[
], [
AC_MSG_RESULT(yes)
has_128bit_cas=1
+ needs_mcx16_for_cas=1
], [
AC_MSG_RESULT(no)
])
@@ -1597,11 +1600,9 @@ CFLAGS="${__saved_CFLAGS}"
AC_LANG_POP
AC_SUBST(has_128bit_cas)
-AS_IF([test "x$has_128bit_cas" = "x1"], [
- AS_IF([test "x$ax_cv_c_compiler_vendor" != "xintel"], [
+AS_IF([test "x$needs_mcx16_for_cas" = "x1"], [
TS_ADDTO(AM_CFLAGS, [-mcx16])
TS_ADDTO(AM_CXXFLAGS, [-mcx16])
- ])
])
# Check for POSIX capabilities library.