Skip to content

Commit 44998dc

Browse files
committed
Add -mfpu=auto test for GCC 11
1 parent 7ceb762 commit 44998dc

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

configure.ac

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1549,14 +1549,25 @@ if test "$IS_ARM32" != "0" && test "$IS_ANDROID_OS" = "0"; then
15491549
[AC_MSG_RESULT([no])]
15501550
)
15511551

1552-
CXXFLAGS="-march=armv7-a -mfpu=neon"
1552+
# Auto is a GCC 11 option
1553+
CXXFLAGS="-march=armv7-a -mfpu=auto"
15531554
AC_MSG_CHECKING([if $CXXNAME supports $CXXFLAGS])
15541555
XXX_COMPILE_IFELSE(
15551556
[AC_LANG_SOURCE([`cat TestPrograms/test_arm_neon.cpp`])],
15561557
[AC_MSG_RESULT([yes])],
15571558
[AC_MSG_RESULT([no])]
15581559
)
15591560

1561+
if test "$retval" != "0"; then
1562+
CXXFLAGS="-march=armv7-a -mfpu=neon"
1563+
AC_MSG_CHECKING([if $CXXNAME supports $CXXFLAGS])
1564+
XXX_COMPILE_IFELSE(
1565+
[AC_LANG_SOURCE([`cat TestPrograms/test_arm_neon.cpp`])],
1566+
[AC_MSG_RESULT([yes])],
1567+
[AC_MSG_RESULT([no])]
1568+
)
1569+
fi
1570+
15601571
if test "$retval" = "0"; then
15611572
AC_SUBST([CRYPTOPP_AES_FLAG], [$CXXFLAGS])
15621573
AC_SUBST([CRYPTOPP_ARIA_FLAG], [$CXXFLAGS])

0 commit comments

Comments
 (0)