From: Jeremy Sowden Date: Sun, 9 Jan 2022 11:57:53 +0000 (+0000) Subject: build: if `--enable-sqlite3` is `yes`, abort if libsqlite3 is not found X-Git-Tag: ulogd-2.0.8~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5f9628c9273815b6e560603427fe86118e7cb5bb;p=thirdparty%2Fulogd2.git build: if `--enable-sqlite3` is `yes`, abort if libsqlite3 is not found If SQLITE3 support has been explicitly requested, abort if it is not available. Signed-off-by: Jeremy Sowden Signed-off-by: Pablo Neira Ayuso --- diff --git a/configure.ac b/configure.ac index 62c43d6..5e90bb6 100644 --- a/configure.ac +++ b/configure.ac @@ -176,8 +176,13 @@ AM_CONDITIONAL([HAVE_MYSQL], [test "x$libmysqlclient_LIBS" != "x"]) AC_ARG_ENABLE([sqlite3], [AS_HELP_STRING([--enable-sqlite3], [Enable SQLITE3 output plugin [default=test]])]) -AS_IF([test "x$enable_sqlite3" != "xno"], - [PKG_CHECK_MODULES([libsqlite3], [sqlite3], [], [:])]) +AS_IF([test "x$enable_sqlite3" != "xno"], [ + PKG_CHECK_MODULES([libsqlite3], [sqlite3], [], [ + AS_IF([test "x$enable_sqlite3" = "xyes"], [ + AC_MSG_ERROR([$libsqlite3_PKG_ERRORS]) + ]) + ]) +]) AS_IF([test "x$libsqlite3_LIBS" != "x"], [enable_sqlite3=yes], [enable_sqlite3=no]) AM_CONDITIONAL([HAVE_SQLITE3], [test "x$libsqlite3_LIBS" != "x"])