mirror of
git://git.code.sf.net/p/dhcpd-pools/code
synced 2025-12-16 15:57:00 +00:00
build-sys: omit mustach compilation when it cannot work
For example mac does not have open_memstream(3), and strndupa(3) can also be missing. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
This commit is contained in:
parent
b96f8cd8ad
commit
39b2811aa7
6 changed files with 31 additions and 4 deletions
10
configure.ac
10
configure.ac
|
|
@ -69,8 +69,18 @@ AC_TYPE_UINT32_T
|
|||
AC_FUNC_ERROR_AT_LINE
|
||||
AC_CHECK_FUNCS([\
|
||||
__fpending \
|
||||
open_memstream \
|
||||
posix_fadvise \
|
||||
])
|
||||
AC_CHECK_DECL([strndupa])
|
||||
|
||||
AS_IF([test "x$ac_cv_func_open_memstream" = "xyes" && test "x$ac_cv_have_decl_strndupa" == "xyes"], [
|
||||
build_mustach=yes
|
||||
AC_DEFINE([BUILD_MUSTACH], [1], [build mustach support])
|
||||
], [
|
||||
build_mustach=no
|
||||
])
|
||||
AM_CONDITIONAL([ENABLE_MUSTACH], [test "x$build_mustach" = xyes])
|
||||
|
||||
AC_MSG_CHECKING([if the compiler supports __builtin_expect])
|
||||
AC_LINK_IFELSE([AC_LANG_PROGRAM([[]], [[
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue