build: Check for readline only if client utility has been enabled

This commit is contained in:
Marcel Holtmann 2018-02-10 11:10:26 +01:00
parent e0b5680543
commit 90aafba6d4
1 changed files with 3 additions and 1 deletions

View File

@ -86,8 +86,10 @@ AC_DEFINE_UNQUOTED(CONFIGDIR, "/etc/iwd", [Configuration directory])
AC_CHECK_HEADERS(linux/types.h linux/if_alg.h)
AC_CHECK_HEADERS(readline/readline.h, enable_readline=yes,
if (test "${enable_client}" != "no"); then
AC_CHECK_HEADERS(readline/readline.h, enable_readline=yes,
AC_MSG_ERROR(readline header files are required))
fi
AC_ARG_ENABLE([client], AC_HELP_STRING([--disable-client],
[don't install iwctl client utility]),