From 994c4de26637204ff14fe4be7f5cc051a04573fe Mon Sep 17 00:00:00 2001 From: David Oberhollenzer Date: Sat, 23 Apr 2022 17:46:10 +0200 Subject: configure: Abort/fail if there is not compressor library Implement a check that verifies that we have at least a single SquashFS block compressor available and aborst the build if none was found. Signed-off-by: David Oberhollenzer --- configure.ac | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/configure.ac b/configure.ac index 94a5eee..16a288f 100644 --- a/configure.ac +++ b/configure.ac @@ -274,6 +274,18 @@ PKG_CHECK_MODULES(READLINE, [readline], [have_readline="yes"], [have_readline="no"]) AM_CONDITIONAL([WITH_READLINE], [test "x$have_readline" = "xyes"]) +#### make sure we actually have a compressor #### +have_compressor="no" + +AS_IF([test "x$with_gzip" != "xno"], [have_compressor="yes"]) +AS_IF([test "x$with_xz" != "xno"], [have_compressor="yes"]) +AS_IF([test "x$with_lzo" != "xno"], [have_compressor="yes"]) +AS_IF([test "x$with_lz4" != "xno"], [have_compressor="yes"]) +AS_IF([test "x$with_zstd" != "xno"], [have_compressor="yes"]) + +AS_IF([test "x$have_compressor" != "xyes"], + [AC_MSG_FAILURE([no block compression libraries found!])]) + ##### additional checks ##### AC_CHECK_HEADERS([sys/xattr.h], [], []) AC_CHECK_HEADERS([sys/sysinfo.h], [], []) -- cgit v1.2.3