]> jfr.im git - solanum.git/blobdiff - configure.ac
Merge pull request #319 from edk0/invite-notify
[solanum.git] / configure.ac
index 242959e3eeb5a5dd2ba703d041e875226ad73811..e03c71575ab8fd5ab7adc4e5f913daf5040749bb 100644 (file)
@@ -4,7 +4,7 @@ dnl said functions need to be just about as complex as they already are.
 
 AC_PREREQ(2.60)
 
-AC_INIT([charybdis], [4.1.2])
+AC_INIT([charybdis], [4.1.3-dev])
 
 AC_LANG(C)
 AC_USE_SYSTEM_EXTENSIONS
@@ -320,6 +320,28 @@ dnl End OpenSSL detection
 dnl Specialized functions and libraries
 dnl ===================================
 
+AC_ARG_ENABLE(hyperscan,
+AC_HELP_STRING([--disable-hyperscan],[Disable hyperscan support]),
+[hyperscan=$enableval],[hyperscan=yes])
+
+AS_IF([test "$hyperscan" = yes], [
+       save_CPPFLAGS="$CPPFLAGS"
+       save_LIBS="$LIBS"
+       PKG_CHECK_MODULES([HS], [libhs >= 4], [], [hyperscan=no])
+       CPPFLAGS="$CPPFLAGS $HS_CFLAGS"
+       LIBS="$LIBS $HS_LIBS"
+       AC_CHECK_HEADER([hs_common.h], [], [hyperscan=no])
+       AC_CHECK_FUNC([hs_scan], [], [hyperscan=no])
+])
+
+AS_IF([test "$hyperscan" = no], [
+       CPPFLAGS="$save_CPPFLAGS"
+       LIBS="$save_LIBS"
+])
+
+AM_CONDITIONAL([HAVE_HYPERSCAN], [test "$hyperscan" = "yes"])
+
+
 AC_ARG_WITH(zlib-path,
 AC_HELP_STRING([--with-zlib-path=DIR],[Path to libz.so for ziplinks support.]),
 [LIBS="$LIBS -L$withval"],)
@@ -595,6 +617,14 @@ AC_HELP_STRING([--with-topiclen=NUMBER],[Set the max topic length to NUMBER (def
 AC_DEFINE_UNQUOTED(TOPICLEN, ${TOPICLEN}, [Maximum topic length (<=390)])
 AC_DEFINE_UNQUOTED(NICKLEN, (${NICKLEN}+1), [Nickname length])
 
+
+AC_ARG_WITH(asan,
+AC_HELP_STRING([--with-asan],[Build with Address Sanitizer]),
+[
+    CFLAGS="$CFLAGS -fsanitize=address"
+    LDFLAGS="$LDFLAGS -fsanitize=address"
+])
+
 # rpath, for finding librb.so at run time
 hold_ldflags=$LDFLAGS
 AC_MSG_CHECKING(for the ld -rpath flag)