summaryrefslogtreecommitdiff
path: root/lib/make/configure.in
diff options
context:
space:
mode:
authoreschnett <eschnett@17b73243-c579-4c4c-a9d2-2d5706c11dac>2013-05-20 14:44:43 +0000
committereschnett <eschnett@17b73243-c579-4c4c-a9d2-2d5706c11dac>2013-05-20 14:44:43 +0000
commit72ced1dca342ab7d6ecab897e6f041f42f39a21b (patch)
treeb5391d2507e1945c5a8dc4dfe47065ba5e29ae46 /lib/make/configure.in
parent6d26c28d3b9562087a41514499cb585df3dd52f0 (diff)
Auto-configure static_assert
Check whether static_assert is supported by C++. Define a work-around if it is not supported. git-svn-id: http://svn.cactuscode.org/flesh/trunk@5014 17b73243-c579-4c4c-a9d2-2d5706c11dac
Diffstat (limited to 'lib/make/configure.in')
-rw-r--r--lib/make/configure.in27
1 files changed, 15 insertions, 12 deletions
diff --git a/lib/make/configure.in b/lib/make/configure.in
index a1eab0e6..8206f044 100644
--- a/lib/make/configure.in
+++ b/lib/make/configure.in
@@ -876,58 +876,61 @@ CCTK_C__PRAGMA
# Ranger. Don't know whether this is a problem with the compiler or
# with how the function annotations are used here.
#
-## Find out whether the C compiler supports __attribute__((const))
+## Find out whether the compiler supports __attribute__((const))
#CCTK_C_ATTRIBUTE_CONST
#CCTK_CXX_ATTRIBUTE_CONST
#CCTK_CXX_MEMBER_ATTRIBUTE_CONST
#
-## Find out whether the C compiler supports __attribute__((pure))
+## Find out whether the compiler supports __attribute__((pure))
#CCTK_C_ATTRIBUTE_PURE
#CCTK_CXX_ATTRIBUTE_PURE
#CCTK_CXX_MEMBER_ATTRIBUTE_PURE
-# Find out whether the C compiler supports __attribute__((noinline))
+# Find out whether the compiler supports __attribute__((noinline))
CCTK_C_ATTRIBUTE_NOINLINE
CCTK_CXX_ATTRIBUTE_NOINLINE
CCTK_CXX_MEMBER_ATTRIBUTE_NOINLINE
-# Find out whether the C compiler supports __attribute__((always_inline))
+# Find out whether the compiler supports __attribute__((always_inline))
CCTK_C_ATTRIBUTE_ALWAYS_INLINE
CCTK_CXX_ATTRIBUTE_ALWAYS_INLINE
CCTK_CXX_MEMBER_ATTRIBUTE_ALWAYS_INLINE
-# Find out whether the C compiler supports __attribute__((unused))
+# Find out whether the compiler supports __attribute__((unused))
CCTK_C_ATTRIBUTE_UNUSED
CCTK_CXX_ATTRIBUTE_UNUSED
-# Find out whether the C compiler supports __attribute__((aligned(...)))
+# Find out whether the compiler supports __attribute__((aligned(...)))
CCTK_C_ATTRIBUTE_ALIGNED
CCTK_CXX_ATTRIBUTE_ALIGNED
-# Find out whether the C compiler supports __attribute__((cold))
+# Find out whether the compiler supports __attribute__((cold))
CCTK_C_ATTRIBUTE_COLD
CCTK_CXX_ATTRIBUTE_COLD
-# Find out whether the C compiler supports __attribute__((hot))
+# Find out whether the compiler supports __attribute__((hot))
CCTK_C_ATTRIBUTE_HOT
CCTK_CXX_ATTRIBUTE_HOT
-# Find out whether the C compiler supports __attribute__((format(...)))
+# Find out whether the compiler supports __attribute__((format(...)))
CCTK_C_ATTRIBUTE_FORMAT
CCTK_CXX_ATTRIBUTE_FORMAT
-# Find out whether the C compiler supports __attribute__((noreturn))
+# Find out whether the compiler supports __attribute__((noreturn))
CCTK_C_ATTRIBUTE_NORETURN
CCTK_CXX_ATTRIBUTE_NORETURN
-# Find out whether the C compiler supports __builtin_expect
+# Find out whether the compiler supports __builtin_expect
CCTK_C_BUILTIN_EXPECT
CCTK_CXX_BUILTIN_EXPECT
-# Find out whether the C compiler supports __builtin_unreachable
+# Find out whether the compiler supports __builtin_unreachable
CCTK_C_BUILTIN_UNREACHABLE
CCTK_CXX_BUILTIN_UNREACHABLE
+# Find out whether the compiler supports static_assert
+CCTK_CXX_STATIC_ASSERT
+
if test "x$REAL16_KIND" = 'x'; then
REAL16_KIND=16
fi