Commit 35e21c5f by Geoff Simmons

Workaround: build for Varnish >=5.2.0, when _Static_assert is defined.

See Varnish issue #2449
parent 79d01e88
Pipeline #302 skipped
......@@ -130,6 +130,24 @@ if test "x$enable_debugging" != "xno"; then
AC_LANG_POP()
fi
# Varnish since 5.2.0 depends on AC_DEFINE(STATIC_ASSERT)
save_LIBS="${LIBS}"
LIBS=""
AC_CACHE_CHECK([for _Static_assert],
[ac_cv_static_assert],
[AC_RUN_IFELSE(
[AC_LANG_PROGRAM([[
_Static_assert(1 == sizeof(char), "didn't work");
]],[[
]])],
[ac_cv_static_assert=yes],
[ac_cv_static_assert=no])
])
if test "$ac_cv_static_assert" = yes; then
AC_DEFINE([STATIC_ASSERT], [1], [Define if _Static_assert is availabel])
fi
LIBS="${save_LIBS}"
AC_CONFIG_FILES([
Makefile
src/Makefile
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment