blob: 688e0c836d7b208bc4d8b858275219ebe998091f [file] [log] [blame]
Jason Evansb7924f52009-06-23 19:01:18 -07001dnl Process this file with autoconf to produce a configure script.
2AC_INIT([Makefile.in])
3
Jason Evansf3340ca2009-06-30 16:17:05 -07004dnl ============================================================================
5dnl Custom macro definitions.
6
7dnl JE_CFLAGS_APPEND(cflag)
8AC_DEFUN([JE_CFLAGS_APPEND],
9[
10AC_MSG_CHECKING([whether compiler supports $1])
11TCFLAGS="${CFLAGS}"
12if test "x${CFLAGS}" = "x" ; then
13 CFLAGS="$1"
14else
15 CFLAGS="${CFLAGS} $1"
16fi
17AC_RUN_IFELSE([AC_LANG_PROGRAM(
18[[
19]], [[
20 return 0;
21]])],
22 AC_MSG_RESULT([yes]),
23 AC_MSG_RESULT([no])
24 [CFLAGS="${TCFLAGS}"]
25)
26])
27
28dnl JE_COMPILABLE(label, hcode, mcode, rvar)
29AC_DEFUN([JE_COMPILABLE],
30[
31AC_MSG_CHECKING([whether $1 is compilable])
Jason Evans9f949f92011-03-22 20:44:40 -070032AC_RUN_IFELSE([AC_LANG_PROGRAM(
Jason Evansf3340ca2009-06-30 16:17:05 -070033[$2], [$3])],
34 AC_MSG_RESULT([yes])
35 [$4="yes"],
36 AC_MSG_RESULT([no])
37 [$4="no"]
38)
39])
40
41dnl ============================================================================
42
Jason Evansb7924f52009-06-23 19:01:18 -070043srcroot=$srcdir
44if test "x${srcroot}" = "x." ; then
45 srcroot=""
46else
47 srcroot="${srcroot}/"
48fi
49AC_SUBST([srcroot])
50abs_srcroot="`cd \"${srcdir}\"; pwd`/"
51AC_SUBST([abs_srcroot])
52
53objroot=""
54AC_SUBST([objroot])
55abs_objroot="`pwd`/"
56AC_SUBST([abs_objroot])
57
58dnl Munge install path variables.
59if test "x$prefix" = "xNONE" ; then
60 prefix="/usr/local"
61fi
62if test "x$exec_prefix" = "xNONE" ; then
63 exec_prefix=$prefix
64fi
65PREFIX=$prefix
66AC_SUBST([PREFIX])
67BINDIR=`eval echo $bindir`
68BINDIR=`eval echo $BINDIR`
69AC_SUBST([BINDIR])
70INCLUDEDIR=`eval echo $includedir`
71INCLUDEDIR=`eval echo $INCLUDEDIR`
72AC_SUBST([INCLUDEDIR])
73LIBDIR=`eval echo $libdir`
74LIBDIR=`eval echo $LIBDIR`
75AC_SUBST([LIBDIR])
76DATADIR=`eval echo $datadir`
77DATADIR=`eval echo $DATADIR`
78AC_SUBST([DATADIR])
79MANDIR=`eval echo $mandir`
80MANDIR=`eval echo $MANDIR`
81AC_SUBST([MANDIR])
82
Jason Evansaee7fd22010-11-24 22:00:02 -080083dnl Support for building documentation.
84AC_PATH_PROG([XSLTPROC], [xsltproc], , [$PATH])
85AC_ARG_WITH([xslroot],
86 [AS_HELP_STRING([--with-xslroot=<path>], [XSL stylesheet root path])],
87if test "x$with_xslroot" = "xno" ; then
88 XSLROOT="/usr/share/xml/docbook/stylesheet/docbook-xsl"
89else
90 XSLROOT="${with_xslroot}"
91fi,
92 XSLROOT="/usr/share/xml/docbook/stylesheet/docbook-xsl"
93)
94AC_SUBST([XSLROOT])
95
Jason Evansf3340ca2009-06-30 16:17:05 -070096dnl If CFLAGS isn't defined, set CFLAGS to something reasonable. Otherwise,
97dnl just prevent autoconf from molesting CFLAGS.
Jason Evansb7924f52009-06-23 19:01:18 -070098CFLAGS=$CFLAGS
99AC_PROG_CC
100if test "x$CFLAGS" = "x" ; then
101 no_CFLAGS="yes"
Jason Evanscfeccd32010-03-03 15:48:20 -0800102 if test "x$GCC" = "xyes" ; then
103 JE_CFLAGS_APPEND([-std=gnu99])
104 JE_CFLAGS_APPEND([-Wall])
105 JE_CFLAGS_APPEND([-pipe])
106 JE_CFLAGS_APPEND([-g3])
107 fi
Jason Evansb7924f52009-06-23 19:01:18 -0700108fi
109dnl Append EXTRA_CFLAGS to CFLAGS, if defined.
110if test "x$EXTRA_CFLAGS" != "x" ; then
Jason Evansf3340ca2009-06-30 16:17:05 -0700111 JE_CFLAGS_APPEND([$EXTRA_CFLAGS])
Jason Evansb7924f52009-06-23 19:01:18 -0700112fi
113AC_PROG_CPP
114
Jason Evansb7924f52009-06-23 19:01:18 -0700115AC_CHECK_SIZEOF([void *])
116if test "x${ac_cv_sizeof_void_p}" = "x8" ; then
Jason Evans94ad2b52009-12-29 00:09:15 -0800117 LG_SIZEOF_PTR=3
Jason Evansb7924f52009-06-23 19:01:18 -0700118elif test "x${ac_cv_sizeof_void_p}" = "x4" ; then
Jason Evans94ad2b52009-12-29 00:09:15 -0800119 LG_SIZEOF_PTR=2
Jason Evansb7924f52009-06-23 19:01:18 -0700120else
121 AC_MSG_ERROR([Unsupported pointer size: ${ac_cv_sizeof_void_p}])
122fi
Jason Evans94ad2b52009-12-29 00:09:15 -0800123AC_DEFINE_UNQUOTED([LG_SIZEOF_PTR], [$LG_SIZEOF_PTR])
124
125AC_CHECK_SIZEOF([int])
126if test "x${ac_cv_sizeof_int}" = "x8" ; then
127 LG_SIZEOF_INT=3
128elif test "x${ac_cv_sizeof_int}" = "x4" ; then
129 LG_SIZEOF_INT=2
130else
131 AC_MSG_ERROR([Unsupported int size: ${ac_cv_sizeof_int}])
132fi
133AC_DEFINE_UNQUOTED([LG_SIZEOF_INT], [$LG_SIZEOF_INT])
Jason Evansb7924f52009-06-23 19:01:18 -0700134
Jason Evans84c8eef2011-03-16 10:30:13 -0700135AC_CHECK_SIZEOF([long])
136if test "x${ac_cv_sizeof_long}" = "x8" ; then
137 LG_SIZEOF_LONG=3
138elif test "x${ac_cv_sizeof_long}" = "x4" ; then
139 LG_SIZEOF_LONG=2
140else
141 AC_MSG_ERROR([Unsupported long size: ${ac_cv_sizeof_long}])
142fi
143AC_DEFINE_UNQUOTED([LG_SIZEOF_LONG], [$LG_SIZEOF_LONG])
144
Jason Evansb7924f52009-06-23 19:01:18 -0700145AC_CANONICAL_HOST
146dnl CPU-specific settings.
147CPU_SPINWAIT=""
148case "${host_cpu}" in
149 i[[345]]86)
150 ;;
151 i686)
Jason Evansf3340ca2009-06-30 16:17:05 -0700152 JE_COMPILABLE([__asm__], [], [[__asm__ volatile("pause"); return 0;]],
153 [asm])
154 if test "x${asm}" = "xyes" ; then
155 CPU_SPINWAIT='__asm__ volatile("pause")'
156 fi
Jason Evansb7924f52009-06-23 19:01:18 -0700157 ;;
158 x86_64)
Jason Evansf3340ca2009-06-30 16:17:05 -0700159 JE_COMPILABLE([__asm__ syntax], [],
160 [[__asm__ volatile("pause"); return 0;]], [asm])
161 if test "x${asm}" = "xyes" ; then
162 CPU_SPINWAIT='__asm__ volatile("pause")'
163 fi
Jason Evansb7924f52009-06-23 19:01:18 -0700164 ;;
165 *)
166 ;;
167esac
168AC_DEFINE_UNQUOTED([CPU_SPINWAIT], [$CPU_SPINWAIT])
169
Antony Dovgal2bd3cbc2011-10-13 09:33:33 +0400170LD_PRELOAD_VAR="LD_PRELOAD"
171SHLIB_SUFFIX_NAME="so"
172
Jason Evansb7924f52009-06-23 19:01:18 -0700173dnl Platform-specific settings. abi and RPATH can probably be determined
174dnl programmatically, but doing so is error-prone, which makes it generally
175dnl not worth the trouble.
176dnl
177dnl Define cpp macros in CPPFLAGS, rather than doing AC_DEFINE(macro), since the
178dnl definitions need to be seen before any headers are included, which is a pain
179dnl to make happen otherwise.
180case "${host}" in
181 *-*-darwin*)
182 CFLAGS="$CFLAGS -fno-common -no-cpp-precomp"
183 abi="macho"
Jason Evansce930552010-10-24 13:03:07 -0700184 AC_DEFINE([JEMALLOC_PURGE_MADVISE_FREE])
Jason Evansb7924f52009-06-23 19:01:18 -0700185 RPATH=""
Antony Dovgal2bd3cbc2011-10-13 09:33:33 +0400186 LD_PRELOAD_VAR="DYLD_INSERT_LIBRARIES"
187 SHLIB_SUFFIX_NAME="dylib"
Jason Evansb7924f52009-06-23 19:01:18 -0700188 ;;
189 *-*-freebsd*)
190 CFLAGS="$CFLAGS"
191 abi="elf"
Jason Evans2dbecf12010-09-05 10:35:13 -0700192 AC_DEFINE([JEMALLOC_PURGE_MADVISE_FREE])
Jason Evansb7924f52009-06-23 19:01:18 -0700193 RPATH="-Wl,-rpath,"
194 ;;
195 *-*-linux*)
196 CFLAGS="$CFLAGS"
197 CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
198 abi="elf"
Jason Evans2dbecf12010-09-05 10:35:13 -0700199 AC_DEFINE([JEMALLOC_PURGE_MADVISE_DONTNEED])
Jason Evansb7924f52009-06-23 19:01:18 -0700200 RPATH="-Wl,-rpath,"
201 ;;
202 *-*-netbsd*)
203 AC_MSG_CHECKING([ABI])
204 AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
205[[#ifdef __ELF__
206/* ELF */
207#else
208#error aout
209#endif
210]])],
211 [CFLAGS="$CFLAGS"; abi="elf"],
212 [abi="aout"])
213 AC_MSG_RESULT([$abi])
Jason Evans2dbecf12010-09-05 10:35:13 -0700214 AC_DEFINE([JEMALLOC_PURGE_MADVISE_FREE])
Jason Evansb7924f52009-06-23 19:01:18 -0700215 RPATH="-Wl,-rpath,"
216 ;;
217 *-*-solaris2*)
218 CFLAGS="$CFLAGS"
219 abi="elf"
220 RPATH="-Wl,-R,"
221 dnl Solaris needs this for sigwait().
222 CPPFLAGS="$CPPFLAGS -D_POSIX_PTHREAD_SEMANTICS"
223 LIBS="$LIBS -lposix4 -lsocket -lnsl"
224 ;;
Antony Dovgal2bd3cbc2011-10-13 09:33:33 +0400225 *-ibm-aix*)
226 if "$LG_SIZEOF_PTR" = "8"; then
227 dnl 64bit AIX
228 LD_PRELOAD_VAR="LDR_PRELOAD64"
229 else
230 dnl 32bit AIX
231 LD_PRELOAD_VAR="LDR_PRELOAD"
232 fi
233 abi="xcoff"
234 RPATH="-Wl,-rpath,"
235 ;;
Jason Evansb7924f52009-06-23 19:01:18 -0700236 *)
237 AC_MSG_RESULT([Unsupported operating system: ${host}])
238 abi="elf"
239 RPATH="-Wl,-rpath,"
240 ;;
241esac
242AC_SUBST([abi])
243AC_SUBST([RPATH])
Antony Dovgal2bd3cbc2011-10-13 09:33:33 +0400244AC_SUBST([LD_PRELOAD_VAR])
245AC_SUBST([SHLIB_SUFFIX_NAME])
Jason Evansb7924f52009-06-23 19:01:18 -0700246
Jason Evansfa5d2452011-03-15 10:25:59 -0700247JE_COMPILABLE([__attribute__ syntax],
248 [static __attribute__((unused)) void foo(void){}],
249 [],
250 [attribute])
251if test "x${attribute}" = "xyes" ; then
252 AC_DEFINE([JEMALLOC_HAVE_ATTR], [ ])
253 if test "x${GCC}" = "xyes" -a "x${abi}" = "xelf"; then
254 JE_CFLAGS_APPEND([-fvisibility=hidden])
255 fi
256fi
257
Jason Evanscfdc8cf2010-11-30 16:50:58 -0800258JE_COMPILABLE([mremap(...MREMAP_FIXED...)], [
259#define _GNU_SOURCE
260#include <sys/mman.h>
261], [
262void *p = mremap((void *)0, 0, 0, MREMAP_MAYMOVE|MREMAP_FIXED, (void *)0);
263], [mremap_fixed])
264if test "x${mremap_fixed}" = "xyes" ; then
265 AC_DEFINE([JEMALLOC_MREMAP_FIXED])
266fi
267
Jason Evansb7924f52009-06-23 19:01:18 -0700268dnl Support optional additions to rpath.
269AC_ARG_WITH([rpath],
Jason Evans90895cf2009-12-29 00:09:15 -0800270 [AS_HELP_STRING([--with-rpath=<rpath>], [Colon-separated rpath (ELF systems only)])],
Jason Evansb7924f52009-06-23 19:01:18 -0700271if test "x$with_rpath" = "xno" ; then
272 RPATH_EXTRA=
273else
274 RPATH_EXTRA="`echo $with_rpath | tr \":\" \" \"`"
275fi,
276 RPATH_EXTRA=
277)
278AC_SUBST([RPATH_EXTRA])
279
280dnl Disable rules that do automatic regeneration of configure output by default.
281AC_ARG_ENABLE([autogen],
Jason Evans78d815c2010-01-17 14:06:20 -0800282 [AS_HELP_STRING([--enable-autogen], [Automatically regenerate configure output])],
Jason Evansb7924f52009-06-23 19:01:18 -0700283if test "x$enable_autogen" = "xno" ; then
284 enable_autogen="0"
285else
286 enable_autogen="1"
287fi
288,
289enable_autogen="0"
290)
291AC_SUBST([enable_autogen])
292
293AC_PROG_INSTALL
294AC_PROG_RANLIB
295AC_PATH_PROG([AR], [ar], , [$PATH])
296AC_PATH_PROG([LD], [ld], , [$PATH])
297AC_PATH_PROG([AUTOCONF], [autoconf], , [$PATH])
298
Jason Evans90895cf2009-12-29 00:09:15 -0800299dnl Do not prefix public APIs by default.
300AC_ARG_WITH([jemalloc_prefix],
301 [AS_HELP_STRING([--with-jemalloc-prefix=<prefix>], [Prefix to prepend to all public APIs])],
Jason Evansb0fd5012010-01-17 01:49:20 -0800302 [JEMALLOC_PREFIX="$with_jemalloc_prefix"],
Jason Evans2dbecf12010-09-05 10:35:13 -0700303 [if test "x$abi" != "xmacho" ; then
304 JEMALLOC_PREFIX=""
305else
306 JEMALLOC_PREFIX="je_"
307fi]
Jason Evans90895cf2009-12-29 00:09:15 -0800308)
309if test "x$JEMALLOC_PREFIX" != "x" ; then
Jason Evanse7339702010-10-23 18:37:06 -0700310 JEMALLOC_CPREFIX=`echo ${JEMALLOC_PREFIX} | tr "a-z" "A-Z"`
311 AC_DEFINE_UNQUOTED([JEMALLOC_PREFIX], ["$JEMALLOC_PREFIX"])
312 AC_DEFINE_UNQUOTED([JEMALLOC_CPREFIX], ["$JEMALLOC_CPREFIX"])
Jason Evanse476f8a2010-01-16 09:53:50 -0800313 AC_DEFINE_UNQUOTED([JEMALLOC_P(string_that_no_one_should_want_to_use_as_a_jemalloc_API_prefix)], [${JEMALLOC_PREFIX}##string_that_no_one_should_want_to_use_as_a_jemalloc_API_prefix])
Jason Evans90895cf2009-12-29 00:09:15 -0800314fi
315
Jason Evans746e77a2011-07-30 16:40:52 -0700316dnl Do not mangle library-private APIs by default.
317AC_ARG_WITH([private_namespace],
318 [AS_HELP_STRING([--with-private-namespace=<prefix>], [Prefix to prepend to all library-private APIs])],
319 [JEMALLOC_PRIVATE_NAMESPACE="$with_private_namespace"],
320 [JEMALLOC_PRIVATE_NAMESPACE=""]
321)
322AC_DEFINE_UNQUOTED([JEMALLOC_PRIVATE_NAMESPACE], ["$JEMALLOC_PRIVATE_NAMESPACE"])
323if test "x$JEMALLOC_PRIVATE_NAMESPACE" != "x" ; then
324 AC_DEFINE_UNQUOTED([JEMALLOC_N(string_that_no_one_should_want_to_use_as_a_jemalloc_private_namespace_prefix)], [${JEMALLOC_PRIVATE_NAMESPACE}##string_that_no_one_should_want_to_use_as_a_jemalloc_private_namespace_prefix])
325else
326 AC_DEFINE_UNQUOTED([JEMALLOC_N(string_that_no_one_should_want_to_use_as_a_jemalloc_private_namespace_prefix)], [string_that_no_one_should_want_to_use_as_a_jemalloc_private_namespace_prefix])
327fi
328
Jason Evansb0fd5012010-01-17 01:49:20 -0800329dnl Do not add suffix to installed files by default.
330AC_ARG_WITH([install_suffix],
331 [AS_HELP_STRING([--with-install-suffix=<suffix>], [Suffix to append to all installed files])],
332 [INSTALL_SUFFIX="$with_install_suffix"],
333 [INSTALL_SUFFIX=]
334)
335install_suffix="$INSTALL_SUFFIX"
336AC_SUBST([install_suffix])
337
Jason Evansaee7fd22010-11-24 22:00:02 -0800338cfgoutputs_in="${srcroot}Makefile.in"
339cfgoutputs_in="${cfgoutputs_in} ${srcroot}doc/html.xsl.in"
340cfgoutputs_in="${cfgoutputs_in} ${srcroot}doc/manpages.xsl.in"
341cfgoutputs_in="${cfgoutputs_in} ${srcroot}doc/jemalloc.xml.in"
Jason Evans0656ec02010-04-07 23:37:35 -0700342cfgoutputs_in="${cfgoutputs_in} ${srcroot}include/jemalloc/jemalloc.h.in"
343cfgoutputs_in="${cfgoutputs_in} ${srcroot}include/jemalloc/internal/jemalloc_internal.h.in"
Jason Evans9f3b0a72010-10-07 09:53:26 -0700344cfgoutputs_in="${cfgoutputs_in} ${srcroot}test/jemalloc_test.h.in"
Jason Evansb0fd5012010-01-17 01:49:20 -0800345
Jason Evansaee7fd22010-11-24 22:00:02 -0800346cfgoutputs_out="Makefile"
347cfgoutputs_out="${cfgoutputs_out} doc/html.xsl"
348cfgoutputs_out="${cfgoutputs_out} doc/manpages.xsl"
349cfgoutputs_out="${cfgoutputs_out} doc/jemalloc${install_suffix}.xml"
Jason Evans376b1522010-02-11 14:45:59 -0800350cfgoutputs_out="${cfgoutputs_out} include/jemalloc/jemalloc${install_suffix}.h"
351cfgoutputs_out="${cfgoutputs_out} include/jemalloc/internal/jemalloc_internal.h"
Jason Evans9f3b0a72010-10-07 09:53:26 -0700352cfgoutputs_out="${cfgoutputs_out} test/jemalloc_test.h"
Jason Evansb0fd5012010-01-17 01:49:20 -0800353
Jason Evansaee7fd22010-11-24 22:00:02 -0800354cfgoutputs_tup="Makefile"
355cfgoutputs_tup="${cfgoutputs_tup} doc/html.xsl:doc/html.xsl.in"
356cfgoutputs_tup="${cfgoutputs_tup} doc/manpages.xsl:doc/manpages.xsl.in"
357cfgoutputs_tup="${cfgoutputs_tup} doc/jemalloc${install_suffix}.xml:doc/jemalloc.xml.in"
Jason Evans376b1522010-02-11 14:45:59 -0800358cfgoutputs_tup="${cfgoutputs_tup} include/jemalloc/jemalloc${install_suffix}.h:include/jemalloc/jemalloc.h.in"
359cfgoutputs_tup="${cfgoutputs_tup} include/jemalloc/internal/jemalloc_internal.h"
Jason Evans9f3b0a72010-10-07 09:53:26 -0700360cfgoutputs_tup="${cfgoutputs_tup} test/jemalloc_test.h:test/jemalloc_test.h.in"
Jason Evansb0fd5012010-01-17 01:49:20 -0800361
Jason Evans0656ec02010-04-07 23:37:35 -0700362cfghdrs_in="${srcroot}include/jemalloc/jemalloc_defs.h.in"
Jason Evansb0fd5012010-01-17 01:49:20 -0800363
Jason Evans376b1522010-02-11 14:45:59 -0800364cfghdrs_out="include/jemalloc/jemalloc_defs${install_suffix}.h"
Jason Evansb0fd5012010-01-17 01:49:20 -0800365
Jason Evans376b1522010-02-11 14:45:59 -0800366cfghdrs_tup="include/jemalloc/jemalloc_defs${install_suffix}.h:include/jemalloc/jemalloc_defs.h.in"
Jason Evansb0fd5012010-01-17 01:49:20 -0800367
Jason Evans355b4382010-09-20 19:20:48 -0700368dnl Do not silence irrelevant compiler warnings by default, since enabling this
369dnl option incurs a performance penalty.
370AC_ARG_ENABLE([cc-silence],
371 [AS_HELP_STRING([--enable-cc-silence],
372 [Silence irrelevant compiler warnings])],
373[if test "x$enable_cc_silence" = "xno" ; then
374 enable_cc_silence="0"
375else
376 enable_cc_silence="1"
377fi
378],
379[enable_cc_silence="0"]
380)
381if test "x$enable_cc_silence" = "x1" ; then
382 AC_DEFINE([JEMALLOC_CC_SILENCE])
383fi
384
Jason Evansb7924f52009-06-23 19:01:18 -0700385dnl Do not compile with debugging by default.
386AC_ARG_ENABLE([debug],
387 [AS_HELP_STRING([--enable-debug], [Build debugging code])],
388[if test "x$enable_debug" = "xno" ; then
389 enable_debug="0"
390else
391 enable_debug="1"
392fi
393],
394[enable_debug="0"]
395)
396if test "x$enable_debug" = "x1" ; then
397 AC_DEFINE([JEMALLOC_DEBUG], [ ])
Jason Evans2dbecf12010-09-05 10:35:13 -0700398 AC_DEFINE([JEMALLOC_IVSALLOC], [ ])
Jason Evansb7924f52009-06-23 19:01:18 -0700399fi
400AC_SUBST([enable_debug])
401
402dnl Only optimize if not debugging.
403if test "x$enable_debug" = "x0" -a "x$no_CFLAGS" = "xyes" ; then
404 dnl Make sure that an optimization flag was not specified in EXTRA_CFLAGS.
Jason Evansf3340ca2009-06-30 16:17:05 -0700405 optimize="no"
406 echo "$EXTRA_CFLAGS" | grep "\-O" >/dev/null || optimize="yes"
407 if test "x${optimize}" = "xyes" ; then
408 if test "x$GCC" = "xyes" ; then
409 JE_CFLAGS_APPEND([-O3])
410 JE_CFLAGS_APPEND([-funroll-loops])
Jason Evansf3340ca2009-06-30 16:17:05 -0700411 else
412 JE_CFLAGS_APPEND([-O])
413 fi
Jason Evansb7924f52009-06-23 19:01:18 -0700414 fi
415fi
416
417dnl Do not enable statistics calculation by default.
418AC_ARG_ENABLE([stats],
419 [AS_HELP_STRING([--enable-stats], [Enable statistics calculation/reporting])],
420[if test "x$enable_stats" = "xno" ; then
421 enable_stats="0"
422else
423 enable_stats="1"
424fi
425],
426[enable_stats="0"]
427)
428if test "x$enable_stats" = "x1" ; then
429 AC_DEFINE([JEMALLOC_STATS], [ ])
430fi
431AC_SUBST([enable_stats])
432
Jason Evans6109fe02010-02-10 10:37:56 -0800433dnl Do not enable profiling by default.
434AC_ARG_ENABLE([prof],
435 [AS_HELP_STRING([--enable-prof], [Enable allocation profiling])],
436[if test "x$enable_prof" = "xno" ; then
437 enable_prof="0"
438else
439 enable_prof="1"
440fi
441],
442[enable_prof="0"]
443)
Jason Evans77f350b2011-03-15 22:23:12 -0700444if test "x$enable_prof" = "x1" ; then
445 backtrace_method=""
Jason Evansb27805b2010-02-10 18:15:53 -0800446else
Jason Evans77f350b2011-03-15 22:23:12 -0700447 backtrace_method="N/A"
Jason Evansb27805b2010-02-10 18:15:53 -0800448fi
Jason Evans77f350b2011-03-15 22:23:12 -0700449
Jason Evans6109fe02010-02-10 10:37:56 -0800450AC_ARG_ENABLE([prof-libunwind],
451 [AS_HELP_STRING([--enable-prof-libunwind], [Use libunwind for backtracing])],
452[if test "x$enable_prof_libunwind" = "xno" ; then
453 enable_prof_libunwind="0"
454else
455 enable_prof_libunwind="1"
456fi
457],
458[enable_prof_libunwind="0"]
459)
Jason Evansca6bd4f2010-03-02 14:12:58 -0800460AC_ARG_WITH([static_libunwind],
461 [AS_HELP_STRING([--with-static-libunwind=<libunwind.a>],
462 [Path to static libunwind library; use rather than dynamically linking])],
463if test "x$with_static_libunwind" = "xno" ; then
464 LUNWIND="-lunwind"
465else
466 if test ! -f "$with_static_libunwind" ; then
467 AC_MSG_ERROR([Static libunwind not found: $with_static_libunwind])
468 fi
469 LUNWIND="$with_static_libunwind"
470fi,
471 LUNWIND="-lunwind"
472)
Jason Evans77f350b2011-03-15 22:23:12 -0700473if test "x$backtrace_method" = "x" -a "x$enable_prof_libunwind" = "x1" ; then
474 AC_CHECK_HEADERS([libunwind.h], , [enable_prof_libunwind="0"])
475 if test "x$LUNWIND" = "x-lunwind" ; then
476 AC_CHECK_LIB([unwind], [backtrace], [LIBS="$LIBS $LUNWIND"],
477 [enable_prof_libunwind="0"])
478 else
479 LIBS="$LIBS $LUNWIND"
480 fi
481 if test "x${enable_prof_libunwind}" = "x1" ; then
482 backtrace_method="libunwind"
483 AC_DEFINE([JEMALLOC_PROF_LIBUNWIND], [ ])
484 fi
485fi
486
487AC_ARG_ENABLE([prof-libgcc],
488 [AS_HELP_STRING([--disable-prof-libgcc],
489 [Do not use libgcc for backtracing])],
490[if test "x$enable_prof_libgcc" = "xno" ; then
491 enable_prof_libgcc="0"
492else
493 enable_prof_libgcc="1"
494fi
495],
496[enable_prof_libgcc="1"]
497)
498if test "x$backtrace_method" = "x" -a "x$enable_prof_libgcc" = "x1" \
499 -a "x$GCC" = "xyes" ; then
500 AC_CHECK_HEADERS([unwind.h], , [enable_prof_libgcc="0"])
501 AC_CHECK_LIB([gcc], [_Unwind_Backtrace], [LIBS="$LIBS -lgcc"], [enable_prof_libgcc="0"])
502 dnl The following is conservative, in that it only has entries for CPUs on
503 dnl which jemalloc has been tested.
504 AC_MSG_CHECKING([libgcc-based backtracing reliability on ${host_cpu}])
505 case "${host_cpu}" in
506 i[[3456]]86)
507 AC_MSG_RESULT([unreliable])
508 enable_prof_libgcc="0";
509 ;;
510 x86_64)
511 AC_MSG_RESULT([reliable])
512 ;;
513 *)
514 AC_MSG_RESULT([unreliable])
515 enable_prof_libgcc="0";
516 ;;
517 esac
518 if test "x${enable_prof_libgcc}" = "x1" ; then
519 backtrace_method="libgcc"
520 AC_DEFINE([JEMALLOC_PROF_LIBGCC], [ ])
521 fi
522else
523 enable_prof_libgcc="0"
524fi
525
526AC_ARG_ENABLE([prof-gcc],
527 [AS_HELP_STRING([--disable-prof-gcc],
528 [Do not use gcc intrinsics for backtracing])],
529[if test "x$enable_prof_gcc" = "xno" ; then
530 enable_prof_gcc="0"
531else
532 enable_prof_gcc="1"
533fi
534],
535[enable_prof_gcc="1"]
536)
537if test "x$backtrace_method" = "x" -a "x$enable_prof_gcc" = "x1" \
538 -a "x$GCC" = "xyes" ; then
539 backtrace_method="gcc intrinsics"
540 AC_DEFINE([JEMALLOC_PROF_GCC], [ ])
541else
542 enable_prof_gcc="0"
543fi
544
545if test "x$backtrace_method" = "x" ; then
546 backtrace_method="none (disabling profiling)"
547 enable_prof="0"
548fi
549AC_MSG_CHECKING([configured backtracing method])
550AC_MSG_RESULT([$backtrace_method])
Jason Evans2dbecf12010-09-05 10:35:13 -0700551if test "x$enable_prof" = "x1" ; then
552 LIBS="$LIBS -lm"
553 AC_DEFINE([JEMALLOC_PROF], [ ])
Jason Evans2dbecf12010-09-05 10:35:13 -0700554fi
555AC_SUBST([enable_prof])
Jason Evans2dbecf12010-09-05 10:35:13 -0700556
Jason Evansb7924f52009-06-23 19:01:18 -0700557dnl Enable tiny allocations by default.
558AC_ARG_ENABLE([tiny],
559 [AS_HELP_STRING([--disable-tiny], [Disable tiny (sub-quantum) allocations])],
560[if test "x$enable_tiny" = "xno" ; then
561 enable_tiny="0"
562else
563 enable_tiny="1"
564fi
565],
566[enable_tiny="1"]
567)
568if test "x$enable_tiny" = "x1" ; then
569 AC_DEFINE([JEMALLOC_TINY], [ ])
570fi
571AC_SUBST([enable_tiny])
572
Jason Evans84cbbcb2009-12-29 00:09:15 -0800573dnl Enable thread-specific caching by default.
574AC_ARG_ENABLE([tcache],
575 [AS_HELP_STRING([--disable-tcache], [Disable per thread caches])],
576[if test "x$enable_tcache" = "xno" ; then
577 enable_tcache="0"
Jason Evansb7924f52009-06-23 19:01:18 -0700578else
Jason Evans84cbbcb2009-12-29 00:09:15 -0800579 enable_tcache="1"
Jason Evansb7924f52009-06-23 19:01:18 -0700580fi
581],
Jason Evans84cbbcb2009-12-29 00:09:15 -0800582[enable_tcache="1"]
Jason Evansb7924f52009-06-23 19:01:18 -0700583)
Jason Evans2dbecf12010-09-05 10:35:13 -0700584if test "x$enable_tcache" = "x1" ; then
585 AC_DEFINE([JEMALLOC_TCACHE], [ ])
586fi
587AC_SUBST([enable_tcache])
Jason Evansb7924f52009-06-23 19:01:18 -0700588
Jason Evans4201af02010-01-24 02:53:40 -0800589dnl Do not enable mmap()ped swap files by default.
590AC_ARG_ENABLE([swap],
591 [AS_HELP_STRING([--enable-swap], [Enable mmap()ped swap files])],
592[if test "x$enable_swap" = "xno" ; then
593 enable_swap="0"
594else
595 enable_swap="1"
596fi
597],
598[enable_swap="0"]
599)
600if test "x$enable_swap" = "x1" ; then
601 AC_DEFINE([JEMALLOC_SWAP], [ ])
602fi
603AC_SUBST([enable_swap])
Jason Evans4201af02010-01-24 02:53:40 -0800604
Jason Evansb7924f52009-06-23 19:01:18 -0700605dnl Do not enable allocation from DSS by default.
606AC_ARG_ENABLE([dss],
607 [AS_HELP_STRING([--enable-dss], [Enable allocation from DSS])],
608[if test "x$enable_dss" = "xno" ; then
609 enable_dss="0"
610else
611 enable_dss="1"
612fi
613],
614[enable_dss="0"]
615)
616if test "x$enable_dss" = "x1" ; then
617 AC_DEFINE([JEMALLOC_DSS], [ ])
618fi
619AC_SUBST([enable_dss])
620
621dnl Do not support the junk/zero filling option by default.
622AC_ARG_ENABLE([fill],
623 [AS_HELP_STRING([--enable-fill], [Support junk/zero filling option])],
624[if test "x$enable_fill" = "xno" ; then
625 enable_fill="0"
626else
627 enable_fill="1"
628fi
629],
630[enable_fill="0"]
631)
632if test "x$enable_fill" = "x1" ; then
633 AC_DEFINE([JEMALLOC_FILL], [ ])
634fi
635AC_SUBST([enable_fill])
636
637dnl Do not support the xmalloc option by default.
638AC_ARG_ENABLE([xmalloc],
639 [AS_HELP_STRING([--enable-xmalloc], [Support xmalloc option])],
640[if test "x$enable_xmalloc" = "xno" ; then
641 enable_xmalloc="0"
642else
643 enable_xmalloc="1"
644fi
645],
646[enable_xmalloc="0"]
647)
648if test "x$enable_xmalloc" = "x1" ; then
649 AC_DEFINE([JEMALLOC_XMALLOC], [ ])
650fi
651AC_SUBST([enable_xmalloc])
652
653dnl Do not support the SYSV option by default.
654AC_ARG_ENABLE([sysv],
655 [AS_HELP_STRING([--enable-sysv], [Support SYSV semantics option])],
656[if test "x$enable_sysv" = "xno" ; then
657 enable_sysv="0"
658else
659 enable_sysv="1"
660fi
661],
662[enable_sysv="0"]
663)
664if test "x$enable_sysv" = "x1" ; then
665 AC_DEFINE([JEMALLOC_SYSV], [ ])
666fi
667AC_SUBST([enable_sysv])
668
669dnl Do not determine page shift at run time by default.
670AC_ARG_ENABLE([dynamic_page_shift],
671 [AS_HELP_STRING([--enable-dynamic-page-shift],
672 [Determine page size at run time (don't trust configure result)])],
673[if test "x$enable_dynamic_page_shift" = "xno" ; then
674 enable_dynamic_page_shift="0"
675else
676 enable_dynamic_page_shift="1"
677fi
678],
679[enable_dynamic_page_shift="0"]
680)
681if test "x$enable_dynamic_page_shift" = "x1" ; then
682 AC_DEFINE([DYNAMIC_PAGE_SHIFT], [ ])
683fi
684AC_SUBST([enable_dynamic_page_shift])
685
686AC_MSG_CHECKING([STATIC_PAGE_SHIFT])
687AC_RUN_IFELSE([AC_LANG_PROGRAM(
688[[#include <stdio.h>
689#include <unistd.h>
690#include <strings.h>
691]], [[
692 long result;
693 FILE *f;
694
695 result = sysconf(_SC_PAGESIZE);
696 if (result == -1) {
697 return 1;
698 }
699 f = fopen("conftest.out", "w");
700 if (f == NULL) {
701 return 1;
702 }
703 fprintf(f, "%u\n", ffs((int)result) - 1);
704 close(f);
705
706 return 0;
707]])],
708 [STATIC_PAGE_SHIFT=`cat conftest.out`]
709 AC_MSG_RESULT([$STATIC_PAGE_SHIFT])
710 AC_DEFINE_UNQUOTED([STATIC_PAGE_SHIFT], [$STATIC_PAGE_SHIFT]),
711 AC_MSG_RESULT([error]))
712
713dnl ============================================================================
714dnl jemalloc configuration.
715dnl
Jason Evansa40bc7a2010-03-02 13:01:16 -0800716
717dnl Set VERSION if source directory has an embedded git repository.
Jason Evans955851f2011-03-31 22:38:51 -0700718if test -d "${srcroot}.git" ; then
Jason Evans79d660d2010-09-17 17:38:24 -0700719 git describe --long --abbrev=40 > ${srcroot}VERSION
Jason Evansa40bc7a2010-03-02 13:01:16 -0800720fi
Jason Evansb7924f52009-06-23 19:01:18 -0700721jemalloc_version=`cat ${srcroot}VERSION`
Jason Evansa40bc7a2010-03-02 13:01:16 -0800722jemalloc_version_major=`echo ${jemalloc_version} | tr ".g-" " " | awk '{print [$]1}'`
723jemalloc_version_minor=`echo ${jemalloc_version} | tr ".g-" " " | awk '{print [$]2}'`
724jemalloc_version_bugfix=`echo ${jemalloc_version} | tr ".g-" " " | awk '{print [$]3}'`
725jemalloc_version_nrev=`echo ${jemalloc_version} | tr ".g-" " " | awk '{print [$]4}'`
726jemalloc_version_gid=`echo ${jemalloc_version} | tr ".g-" " " | awk '{print [$]5}'`
Jason Evansb7924f52009-06-23 19:01:18 -0700727AC_SUBST([jemalloc_version])
Jason Evansa40bc7a2010-03-02 13:01:16 -0800728AC_SUBST([jemalloc_version_major])
729AC_SUBST([jemalloc_version_minor])
730AC_SUBST([jemalloc_version_bugfix])
731AC_SUBST([jemalloc_version_nrev])
732AC_SUBST([jemalloc_version_gid])
Jason Evansb7924f52009-06-23 19:01:18 -0700733
734dnl ============================================================================
735dnl Configure pthreads.
736
737AC_CHECK_HEADERS([pthread.h], , [AC_MSG_ERROR([pthread.h is missing])])
738AC_CHECK_LIB([pthread], [pthread_create], [LIBS="$LIBS -lpthread"],
739 [AC_MSG_ERROR([libpthread is missing])])
740
741CPPFLAGS="$CPPFLAGS -D_REENTRANT"
742
Jason Evanscc00a152009-06-25 18:06:48 -0700743dnl Enable lazy locking by default.
Jason Evansb7924f52009-06-23 19:01:18 -0700744AC_ARG_ENABLE([lazy_lock],
Jason Evansa1624022009-11-09 14:58:12 -0800745 [AS_HELP_STRING([--disable-lazy-lock],
Jason Evanscc00a152009-06-25 18:06:48 -0700746 [Disable lazy locking (always lock, even when single-threaded)])],
Jason Evansb7924f52009-06-23 19:01:18 -0700747[if test "x$enable_lazy_lock" = "xno" ; then
748 enable_lazy_lock="0"
749else
750 enable_lazy_lock="1"
751fi
752],
Jason Evanscc00a152009-06-25 18:06:48 -0700753[enable_lazy_lock="1"]
Jason Evansb7924f52009-06-23 19:01:18 -0700754)
755if test "x$enable_lazy_lock" = "x1" ; then
756 AC_CHECK_HEADERS([dlfcn.h], , [AC_MSG_ERROR([dlfcn.h is missing])])
757 AC_CHECK_LIB([dl], [dlopen], [LIBS="$LIBS -ldl"],
758 [AC_MSG_ERROR([libdl is missing])])
759 AC_DEFINE([JEMALLOC_LAZY_LOCK], [ ])
760fi
761AC_SUBST([enable_lazy_lock])
762
Jason Evans78d815c2010-01-17 14:06:20 -0800763AC_ARG_ENABLE([tls],
764 [AS_HELP_STRING([--disable-tls], [Disable thread-local storage (__thread keyword)])],
765if test "x$enable_tls" = "xno" ; then
766 enable_tls="0"
767else
768 enable_tls="1"
769fi
770,
771enable_tls="1"
772)
773if test "x${enable_tls}" = "x1" ; then
774AC_MSG_CHECKING([for TLS])
775AC_RUN_IFELSE([AC_LANG_PROGRAM(
776[[
777 __thread int x;
778]], [[
779 x = 42;
780
781 return 0;
782]])],
783 AC_MSG_RESULT([yes]),
784 AC_MSG_RESULT([no])
785 enable_tls="0")
786fi
Jason Evansb267d0f2010-08-13 15:42:29 -0700787AC_SUBST([enable_tls])
Jason Evans78d815c2010-01-17 14:06:20 -0800788if test "x${enable_tls}" = "x0" ; then
789 AC_DEFINE_UNQUOTED([NO_TLS], [ ])
790fi
791
Jason Evans2dbecf12010-09-05 10:35:13 -0700792dnl ============================================================================
Jason Evans84c8eef2011-03-16 10:30:13 -0700793dnl Check for ffsl(3), and fail if not found. This function exists on all
794dnl platforms that jemalloc currently has a chance of functioning on without
795dnl modification.
796
797AC_CHECK_FUNC([ffsl], [],
798 [AC_MSG_ERROR([Cannot build without ffsl(3)])])
799
800dnl ============================================================================
Jason Evans763baa62011-03-18 19:10:31 -0700801dnl Check for atomic(3) operations as provided on Darwin.
802
803JE_COMPILABLE([Darwin OSAtomic*()], [
804#include <libkern/OSAtomic.h>
805#include <inttypes.h>
806], [
807 {
808 int32_t x32 = 0;
809 volatile int32_t *x32p = &x32;
810 OSAtomicAdd32(1, x32p);
811 }
812 {
813 int64_t x64 = 0;
814 volatile int64_t *x64p = &x64;
815 OSAtomicAdd64(1, x64p);
816 }
817], [osatomic])
818if test "x${osatomic}" = "xyes" ; then
819 AC_DEFINE([JEMALLOC_OSATOMIC])
820fi
821
822dnl ============================================================================
Jason Evans893a0ed2011-03-18 19:30:18 -0700823dnl Check for spinlock(3) operations as provided on Darwin.
824
825JE_COMPILABLE([Darwin OSSpin*()], [
826#include <libkern/OSAtomic.h>
827#include <inttypes.h>
828], [
829 OSSpinLock lock = 0;
830 OSSpinLockLock(&lock);
831 OSSpinLockUnlock(&lock);
832], [osspin])
833if test "x${osspin}" = "xyes" ; then
834 AC_DEFINE([JEMALLOC_OSSPIN])
835fi
836
837dnl ============================================================================
Jason Evans6a0d2912010-09-20 16:44:23 -0700838dnl Check for allocator-related functions that should be wrapped.
839
840AC_CHECK_FUNC([memalign],
841 [AC_DEFINE([JEMALLOC_OVERRIDE_MEMALIGN])])
842AC_CHECK_FUNC([valloc],
843 [AC_DEFINE([JEMALLOC_OVERRIDE_VALLOC])])
844
845dnl ============================================================================
Jason Evans2dbecf12010-09-05 10:35:13 -0700846dnl Darwin-related configuration.
Jason Evans78d815c2010-01-17 14:06:20 -0800847
Jason Evans2dbecf12010-09-05 10:35:13 -0700848if test "x${abi}" = "xmacho" ; then
849 AC_DEFINE([JEMALLOC_IVSALLOC])
850 AC_DEFINE([JEMALLOC_ZONE])
Jason Evans6109fe02010-02-10 10:37:56 -0800851
Jason Evans2dbecf12010-09-05 10:35:13 -0700852 dnl The szone version jumped from 3 to 6 between the OS X 10.5.x and 10.6
853 dnl releases. malloc_zone_t and malloc_introspection_t have new fields in
854 dnl 10.6, which is the only source-level indication of the change.
855 AC_MSG_CHECKING([malloc zone version])
856 AC_TRY_COMPILE([#include <stdlib.h>
857#include <malloc/malloc.h>], [
858 static malloc_zone_t zone;
859 static struct malloc_introspection_t zone_introspect;
860
861 zone.size = NULL;
862 zone.malloc = NULL;
863 zone.calloc = NULL;
864 zone.valloc = NULL;
865 zone.free = NULL;
866 zone.realloc = NULL;
867 zone.destroy = NULL;
868 zone.zone_name = "jemalloc_zone";
869 zone.batch_malloc = NULL;
870 zone.batch_free = NULL;
871 zone.introspect = &zone_introspect;
872 zone.version = 6;
873 zone.memalign = NULL;
874 zone.free_definite_size = NULL;
875
876 zone_introspect.enumerator = NULL;
877 zone_introspect.good_size = NULL;
878 zone_introspect.check = NULL;
879 zone_introspect.print = NULL;
880 zone_introspect.log = NULL;
881 zone_introspect.force_lock = NULL;
882 zone_introspect.force_unlock = NULL;
883 zone_introspect.statistics = NULL;
884 zone_introspect.zone_locked = NULL;
885], [AC_DEFINE_UNQUOTED([JEMALLOC_ZONE_VERSION], [6])
886 AC_MSG_RESULT([6])],
887 [AC_DEFINE_UNQUOTED([JEMALLOC_ZONE_VERSION], [3])
888 AC_MSG_RESULT([3])])
Jason Evansb27805b2010-02-10 18:15:53 -0800889fi
890
Jason Evansb7924f52009-06-23 19:01:18 -0700891dnl ============================================================================
892dnl Check for typedefs, structures, and compiler characteristics.
893AC_HEADER_STDBOOL
894
895dnl Process .in files.
Jason Evansb0fd5012010-01-17 01:49:20 -0800896AC_SUBST([cfghdrs_in])
897AC_SUBST([cfghdrs_out])
Jason Evans0656ec02010-04-07 23:37:35 -0700898AC_CONFIG_HEADERS([$cfghdrs_tup])
Jason Evansb7924f52009-06-23 19:01:18 -0700899
900dnl ============================================================================
901dnl Generate outputs.
Antony Dovgal2bd3cbc2011-10-13 09:33:33 +0400902AC_CONFIG_FILES([$cfgoutputs_tup config.stamp bin/jemalloc.sh])
Jason Evansb0fd5012010-01-17 01:49:20 -0800903AC_SUBST([cfgoutputs_in])
904AC_SUBST([cfgoutputs_out])
Jason Evansb7924f52009-06-23 19:01:18 -0700905AC_OUTPUT
906
907dnl ============================================================================
908dnl Print out the results of configuration.
909AC_MSG_RESULT([===============================================================================])
910AC_MSG_RESULT([jemalloc version : $jemalloc_version])
911AC_MSG_RESULT([])
912AC_MSG_RESULT([CC : ${CC}])
913AC_MSG_RESULT([CPPFLAGS : ${CPPFLAGS}])
914AC_MSG_RESULT([CFLAGS : ${CFLAGS}])
915AC_MSG_RESULT([LDFLAGS : ${LDFLAGS}])
916AC_MSG_RESULT([LIBS : ${LIBS}])
917AC_MSG_RESULT([RPATH_EXTRA : ${RPATH_EXTRA}])
918AC_MSG_RESULT([])
Jason Evansaee7fd22010-11-24 22:00:02 -0800919AC_MSG_RESULT([XSLTPROC : ${XSLTPROC}])
920AC_MSG_RESULT([XSLROOT : ${XSLROOT}])
921AC_MSG_RESULT([])
Jason Evansb7924f52009-06-23 19:01:18 -0700922AC_MSG_RESULT([PREFIX : ${PREFIX}])
923AC_MSG_RESULT([BINDIR : ${BINDIR}])
Jason Evans662a0172009-07-01 19:24:31 -0700924AC_MSG_RESULT([INCLUDEDIR : ${INCLUDEDIR}])
925AC_MSG_RESULT([LIBDIR : ${LIBDIR}])
Jason Evansb7924f52009-06-23 19:01:18 -0700926AC_MSG_RESULT([DATADIR : ${DATADIR}])
927AC_MSG_RESULT([MANDIR : ${MANDIR}])
928AC_MSG_RESULT([])
929AC_MSG_RESULT([srcroot : ${srcroot}])
930AC_MSG_RESULT([abs_srcroot : ${abs_srcroot}])
931AC_MSG_RESULT([objroot : ${objroot}])
932AC_MSG_RESULT([abs_objroot : ${abs_objroot}])
933AC_MSG_RESULT([])
Jason Evans90895cf2009-12-29 00:09:15 -0800934AC_MSG_RESULT([JEMALLOC_PREFIX : ${JEMALLOC_PREFIX}])
Jason Evans746e77a2011-07-30 16:40:52 -0700935AC_MSG_RESULT([JEMALLOC_PRIVATE_NAMESPACE])
936AC_MSG_RESULT([ : ${JEMALLOC_PRIVATE_NAMESPACE}])
Jason Evansb0fd5012010-01-17 01:49:20 -0800937AC_MSG_RESULT([install_suffix : ${install_suffix}])
Jason Evansb7924f52009-06-23 19:01:18 -0700938AC_MSG_RESULT([autogen : ${enable_autogen}])
Jason Evans355b4382010-09-20 19:20:48 -0700939AC_MSG_RESULT([cc-silence : ${enable_cc_silence}])
Jason Evansb7924f52009-06-23 19:01:18 -0700940AC_MSG_RESULT([debug : ${enable_debug}])
941AC_MSG_RESULT([stats : ${enable_stats}])
Jason Evans6109fe02010-02-10 10:37:56 -0800942AC_MSG_RESULT([prof : ${enable_prof}])
943AC_MSG_RESULT([prof-libunwind : ${enable_prof_libunwind}])
Jason Evans77f350b2011-03-15 22:23:12 -0700944AC_MSG_RESULT([prof-libgcc : ${enable_prof_libgcc}])
945AC_MSG_RESULT([prof-gcc : ${enable_prof_gcc}])
Jason Evansb7924f52009-06-23 19:01:18 -0700946AC_MSG_RESULT([tiny : ${enable_tiny}])
Jason Evans84cbbcb2009-12-29 00:09:15 -0800947AC_MSG_RESULT([tcache : ${enable_tcache}])
Jason Evansb7924f52009-06-23 19:01:18 -0700948AC_MSG_RESULT([fill : ${enable_fill}])
949AC_MSG_RESULT([xmalloc : ${enable_xmalloc}])
950AC_MSG_RESULT([sysv : ${enable_sysv}])
Jason Evans4201af02010-01-24 02:53:40 -0800951AC_MSG_RESULT([swap : ${enable_swap}])
Jason Evansb7924f52009-06-23 19:01:18 -0700952AC_MSG_RESULT([dss : ${enable_dss}])
953AC_MSG_RESULT([dynamic_page_shift : ${enable_dynamic_page_shift}])
954AC_MSG_RESULT([lazy_lock : ${enable_lazy_lock}])
Jason Evans2dbecf12010-09-05 10:35:13 -0700955AC_MSG_RESULT([tls : ${enable_tls}])
Jason Evansb7924f52009-06-23 19:01:18 -0700956AC_MSG_RESULT([===============================================================================])