btrfs-progs: autoconf: check btrfs-convert dependencies

Use the standard pkg-config checks.

Signed-off-by: David Sterba <dsterba@suse.cz>
This commit is contained in:
David Sterba 2015-02-03 17:12:28 +01:00
parent 8fa3fed3a4
commit 99c53e440e
2 changed files with 6 additions and 1 deletions

View File

@ -82,7 +82,7 @@ endif
# external libs required by various binaries; for btrfs-foo,
# specify btrfs_foo_libs = <list of libs>; see $($(subst...)) rules below
btrfs_convert_libs = -lext2fs -lcom_err
btrfs_convert_libs = @EXT2FS_LIBS@ @COM_ERR_LIBS@
btrfs_fragments_libs = -lgd -lpng -ljpeg -lfreetype
SUBDIRS =

View File

@ -99,6 +99,11 @@ AC_ARG_ENABLE([convert],
AS_IF([test "x$enable_btrfsconvert" = xyes], [DISABLE_BTRFSCONVERT=0], [DISABLE_BTRFSCONVERT=1])
AC_SUBST([DISABLE_BTRFSCONVERT])
if test "x$enable_btrfsconvert" = xyes; then
PKG_CHECK_MODULES(EXT2FS, [ext2fs])
PKG_CHECK_MODULES(COM_ERR, [com_err])
fi
dnl Define <NAME>_LIBS= and <NAME>_CFLAGS= by pkg-config
dnl