我正在尝试编译一个复杂的数值模拟软件。运行autoconf
然后./configure ...
(使用其他一些标志)后,我在输出中看到以下内容:
checking for malloc in -ltcmalloc... no
configure: WARNING: No tcmalloc support available.
进去后configure.in
发现:
%zsh> grep 'tcmalloc' configure.in
AC_CHECK_LIB(tcmalloc,malloc,,AC_MSG_WARN([No tcmalloc support available.]))
我安装了gperftools,我认为它应该提供 tcmalloc。我确实有一些类似的库:
%zsh> ldconfig -p|grep 'tcmalloc'
libtcmalloc_minimal_debug.so.4 (libc6,x86-64) => /usr/lib/libtcmalloc_minimal_debug.so.4
libtcmalloc_minimal_debug.so (libc6,x86-64) => /usr/lib/libtcmalloc_minimal_debug.so
libtcmalloc_minimal.so.4 (libc6,x86-64) => /usr/lib/libtcmalloc_minimal.so.4
libtcmalloc_minimal.so (libc6,x86-64) => /usr/lib/libtcmalloc_minimal.so
libtcmalloc_debug.so.4 (libc6,x86-64) => /usr/lib/libtcmalloc_debug.so.4
libtcmalloc_debug.so (libc6,x86-64) => /usr/lib/libtcmalloc_debug.so
libtcmalloc_and_profiler.so.4 (libc6,x86-64) => /usr/lib/libtcmalloc_and_profiler.so.4
libtcmalloc_and_profiler.so (libc6,x86-64) => /usr/lib/libtcmalloc_and_profiler.so
libtcmalloc.so.4 (libc6,x86-64) => /usr/lib/libtcmalloc.so.4
libtcmalloc.so (libc6,x86-64) => /usr/lib/libtcmalloc.so
我尝试添加libtcmalloc
到列表中,configure.in
但我得到:
checking for tcmalloc in -llibtcmalloc... ./configure: line 11516: WARNING:: command not found
no
有没有办法让 autoconfAC_CHECK_LIB
检测我的 tcmalloc 库?