summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorMike Hommey <mh@glandium.org>2012-12-06 21:16:26 (GMT)
committerJason Evans <jasone@canonware.com>2012-12-23 19:47:10 (GMT)
commit5135e34062584f67ae2d12b1f3940a9fad32ca9f (patch)
tree6c198c10466440c2443ae5500c529a8ca3eec379 /configure.ac
parentd0357f7a09a6fcbf1df461b07851f61a7f0bdc2d (diff)
downloadjemalloc-5135e34062584f67ae2d12b1f3940a9fad32ca9f.zip
jemalloc-5135e34062584f67ae2d12b1f3940a9fad32ca9f.tar.gz
jemalloc-5135e34062584f67ae2d12b1f3940a9fad32ca9f.tar.bz2
Allow to enable ivsalloc independently
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac19
1 files changed, 17 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac
index 249a66c..9d062a9 100644
--- a/configure.ac
+++ b/configure.ac
@@ -551,7 +551,7 @@ fi
dnl Do not compile with debugging by default.
AC_ARG_ENABLE([debug],
- [AS_HELP_STRING([--enable-debug], [Build debugging code])],
+ [AS_HELP_STRING([--enable-debug], [Build debugging code (implies --enable-ivsalloc)])],
[if test "x$enable_debug" = "xno" ; then
enable_debug="0"
else
@@ -562,10 +562,25 @@ fi
)
if test "x$enable_debug" = "x1" ; then
AC_DEFINE([JEMALLOC_DEBUG], [ ])
- AC_DEFINE([JEMALLOC_IVSALLOC], [ ])
+ enable_ivsalloc="1"
fi
AC_SUBST([enable_debug])
+dnl Do not validate pointers by default.
+AC_ARG_ENABLE([ivsalloc],
+ [AS_HELP_STRING([--enable-ivsalloc], [Validate pointers passed through the public API])],
+[if test "x$enable_ivsalloc" = "xno" ; then
+ enable_ivsalloc="0"
+else
+ enable_ivsalloc="1"
+fi
+],
+[enable_ivsalloc="0"]
+)
+if test "x$enable_ivsalloc" = "x1" ; then
+ AC_DEFINE([JEMALLOC_IVSALLOC], [ ])
+fi
+
dnl Only optimize if not debugging.
if test "x$enable_debug" = "x0" -a "x$no_CFLAGS" = "xyes" ; then
dnl Make sure that an optimization flag was not specified in EXTRA_CFLAGS.