summaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
authorRene Engelhard <rene@openoffice.org>2010-06-22 18:10:51 +0200
committerRene Engelhard <rene@openoffice.org>2010-06-22 18:10:51 +0200
commit826a90d68a4dc458585c6d2e647bec17971e9193 (patch)
tree3a63e63b8737df42aed59e2fe00fb3538af1ff43 /configure.in
parenta80e89c5529e2cb5b38b0c6b046ef4d3585437e1 (diff)
configure25: #i111045# jemalloc
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in10
1 files changed, 9 insertions, 1 deletions
diff --git a/configure.in b/configure.in
index e8854c685222..089742eca99e 100644
--- a/configure.in
+++ b/configure.in
@@ -807,7 +807,7 @@ AC_ARG_WITH(build-version,
],with_build_version=$withval)
AC_ARG_WITH(alloc,
[ --with-alloc Define which allocator to build with
- (choices are oo, system, tcmalloc)
+ (choices are oo, system, tcmalloc, jemalloc)
],,)
AC_ARG_ENABLE(verbose,
[ --enable-verbose Increase build verbosity.
@@ -2677,6 +2677,14 @@ if test "$with_alloc" = "tcmalloc"; then
[AC_MSG_ERROR(tcmalloc not found or functional. Install the Google Profiling Tools)], [])
ALLOC="TCMALLOC";
fi
+if test "$with_alloc" = "jemalloc"; then
+ save_CFLAGS=$CFLAGS
+ CFLAGS="$CFLAGS -pthread"
+ AC_CHECK_LIB(jemalloc, malloc, [],
+ [AC_MSG_ERROR(jemalloc not found or functional. Install the jemalloc allocator.)], [])
+ ALLOC="JEMALLOC";
+ CFLAGS=$save_CFLAGS
+fi
if test "$with_alloc" = "internal" -o -z "$with_alloc"; then
AC_MSG_RESULT([internal])
fi