summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac15
1 files changed, 15 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 31c0d553..5dd27ca2 100644
--- a/configure.ac
+++ b/configure.ac
@@ -994,6 +994,21 @@ fi
#
+# Check whether the compiler supports the GCC style may_alias attribute
+#
+AC_CACHE_CHECK([whether the GCC style may_alias attribute is supported],
+ [gcry_cv_gcc_attribute_may_alias],
+ [gcry_cv_gcc_attribute_may_alias=no
+ AC_COMPILE_IFELSE([AC_LANG_SOURCE(
+ [[struct { int a; } foo __attribute__ ((may_alias));]])],
+ [gcry_cv_gcc_attribute_may_alias=yes])])
+if test "$gcry_cv_gcc_attribute_may_alias" = "yes" ; then
+ AC_DEFINE(HAVE_GCC_ATTRIBUTE_MAY_ALIAS,1,
+ [Defined if a GCC style "__attribute__ ((may_alias))" is supported])
+fi
+
+
+#
# Check whether the compiler supports 'asm' or '__asm__' keyword for
# assembler blocks.
#