mirror of
https://github.com/matrix-construct/construct
synced 2024-11-29 02:02:38 +01:00
configure: Use PKG_CHECK_MODULES; fix jemalloc related.
construct: Add missing MALLOC_LDFLAGS.
This commit is contained in:
parent
1c11e6b2c1
commit
dc713f711a
2 changed files with 11 additions and 5 deletions
15
configure.ac
15
configure.ac
|
@ -1941,20 +1941,25 @@ dnl
|
|||
dnl
|
||||
|
||||
RB_CHK_SYSHEADER(jemalloc/jemalloc.h, [JEMALLOC_H])
|
||||
AC_CHECK_LIB(jemalloc, malloc,
|
||||
PKG_CHECK_MODULES(JEMALLOC, [jemalloc],
|
||||
[
|
||||
have_jemalloc="yes"
|
||||
], [
|
||||
have_jemalloc="no"
|
||||
AC_CHECK_LIB(jemalloc, malloc,
|
||||
[
|
||||
have_jemalloc="yes"
|
||||
], [
|
||||
have_jemalloc="no"
|
||||
])
|
||||
])
|
||||
|
||||
AC_MSG_CHECKING(whether to enable use of any found jemalloc)
|
||||
AC_MSG_CHECKING(whether to disable use of any found jemalloc)
|
||||
AC_ARG_ENABLE(jemalloc, AC_HELP_STRING([--disable-jemalloc], [Disable jemalloc as third-party dynamic memory manager.]),
|
||||
[
|
||||
AC_MSG_RESULT([no])
|
||||
AC_MSG_RESULT([yes])
|
||||
enable_jemalloc="no"
|
||||
], [
|
||||
AC_MSG_RESULT([yes])
|
||||
AC_MSG_RESULT([no])
|
||||
enable_jemalloc="yes"
|
||||
])
|
||||
|
||||
|
|
|
@ -38,6 +38,7 @@ construct_LDFLAGS = \
|
|||
@BOOST_LDFLAGS@ \
|
||||
@SSL_LDFLAGS@ \
|
||||
@CRYPTO_LDFLAGS@ \
|
||||
@MALLOC_LDFLAGS@ \
|
||||
###
|
||||
|
||||
construct_LDADD = \
|
||||
|
|
Loading…
Reference in a new issue