Whamcloud - gitweb
LU-10611 autoconf: check zlib library and zlib.h header file 86/31186/2
authorJian Yu <jian.yu@intel.com>
Tue, 6 Feb 2018 20:37:23 +0000 (12:37 -0800)
committerOleg Drokin <oleg.drokin@intel.com>
Wed, 14 Feb 2018 00:52:57 +0000 (00:52 +0000)
After landing commit f1daa8fc6575e5b9e4a2f1f2ae4ceaefb889a694,
zlib library and zlib.h header file are required to compile lfs.c.
This patch adds the check in configure script.

Change-Id: Id3a8acfc780fb4fcdec0bb99b79b550c5c9e957a
Test-Parameters: trivial testlist=sanity-flr
Signed-off-by: Jian Yu <jian.yu@intel.com>
Reviewed-on: https://review.whamcloud.com/31186
Tested-by: Jenkins
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bobi Jam <bobijam@hotmail.com>
Reviewed-by: Quentin Bouget <quentin.bouget@cea.fr>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/autoconf/lustre-core.m4

index 6ac4fd4..0fe194b 100644 (file)
@@ -3119,6 +3119,15 @@ AC_CHECK_HEADERS([blkid/blkid.h])
 # lustre/utils/llverfs.c
 AC_CHECK_HEADERS([ext2fs/ext2fs.h])
 
+# lustre/utils/lfs.c
+AC_CHECK_LIB([z], [crc32], [
+            AC_CHECK_HEADER([zlib.h], [], [
+                            AC_MSG_ERROR([zlib.h not found.])])
+            ], [
+            AC_MSG_ERROR([
+zlib library not found. Please install zlib development package.])
+])
+
 SELINUX=""
 AC_CHECK_LIB([selinux], [is_selinux_enabled],
        [AC_CHECK_HEADERS([selinux/selinux.h],