diff options
author | Faidon Liambotis <paravoid@debian.org> | 2017-08-07 18:51:09 (GMT) |
---|---|---|
committer | Qi Wang <interwq@gmail.com> | 2017-08-11 23:35:44 (GMT) |
commit | 8da69b69e6c4cd951832138780ac632e57987b7c (patch) | |
tree | 6bfdb8ac6fbc887f8a8049a1bb926b1da8d560b8 /configure.ac | |
parent | 3ec279ba1c702286b2a7d4ce7aaf48d7905f1c5b (diff) | |
download | jemalloc-8da69b69e6c4cd951832138780ac632e57987b7c.zip jemalloc-8da69b69e6c4cd951832138780ac632e57987b7c.tar.gz jemalloc-8da69b69e6c4cd951832138780ac632e57987b7c.tar.bz2 |
Fix support for GNU/kFreeBSD
The configure.ac seciton right now is the same for Linux and kFreeBSD,
which results into an incorrect configuration of e.g. defining
JEMALLOC_PROC_SYS_VM_OVERCOMMIT_MEMORY instead of FreeBSD's
JEMALLOC_SYSCTL_VM_OVERCOMMIT.
GNU/kFreeBSD is really a glibc + FreeBSD kernel system, so it needs its
own entry which has a mixture of configuration options from Linux and
FreeBSD.
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac index e1a7343..49b2df1 100644 --- a/configure.ac +++ b/configure.ac @@ -567,7 +567,7 @@ case "${host}" in default_retain="1" fi ;; - *-*-linux* | *-*-kfreebsd*) + *-*-linux*) dnl syscall(2) and secure_getenv(3) are exposed by _GNU_SOURCE. JE_APPEND_VS(CPPFLAGS, -D_GNU_SOURCE) abi="elf" @@ -580,6 +580,15 @@ case "${host}" in default_retain="1" fi ;; + *-*-kfreebsd*) + dnl syscall(2) and secure_getenv(3) are exposed by _GNU_SOURCE. + JE_APPEND_VS(CPPFLAGS, -D_GNU_SOURCE) + abi="elf" + AC_DEFINE([JEMALLOC_HAS_ALLOCA_H]) + AC_DEFINE([JEMALLOC_SYSCTL_VM_OVERCOMMIT], [ ]) + AC_DEFINE([JEMALLOC_THREADED_INIT], [ ]) + AC_DEFINE([JEMALLOC_USE_CXX_THROW], [ ]) + ;; *-*-netbsd*) AC_MSG_CHECKING([ABI]) AC_COMPILE_IFELSE([AC_LANG_PROGRAM( |