bool "btrfs-progs"
depends on BR2_USE_MMU # util-linux
depends on BR2_TOOLCHAIN_HAS_THREADS
- select BR2_PACKAGE_E2FSPROGS
select BR2_PACKAGE_LZO
select BR2_PACKAGE_UTIL_LINUX
select BR2_PACKAGE_UTIL_LINUX_LIBBLKID
BTRFS_PROGS_VERSION = 4.16.1
BTRFS_PROGS_SITE = $(BR2_KERNEL_MIRROR)/linux/kernel/people/kdave/btrfs-progs
BTRFS_PROGS_SOURCE = btrfs-progs-v$(BTRFS_PROGS_VERSION).tar.xz
-BTRFS_PROGS_DEPENDENCIES = host-pkgconf e2fsprogs lzo util-linux zlib
+BTRFS_PROGS_DEPENDENCIES = host-pkgconf lzo util-linux zlib
BTRFS_PROGS_CONF_OPTS = --disable-backtrace --disable-zstd --disable-python
BTRFS_PROGS_LICENSE = GPL-2.0, LGPL-3.0+ (libbtrfsutil)
BTRFS_PROGS_LICENSE_FILES = COPYING libbtrfsutil/COPYING \
BTRFS_PROGS_INSTALL_STAGING_OPTS = DESTDIR=$(STAGING_DIR) install-static
endif
+# convert also supports conversion from reiserfs, which needs some
+# reiserfs libraries, but we have no package for them in Buildroot, so
+# we keep things simple and only handle ext2.
+ifeq ($(BR2_PACKAGE_E2FSPROGS),y)
+BTRFS_PROGS_CONF_OPTS += --enable-convert --with-convert=ext2
+BTRFS_PROGS_DEPENDENCIES += e2fsprogs
+else
+BTRFS_PROGS_CONF_OPTS += --disable-convert
+endif
+
HOST_BTRFS_PROGS_DEPENDENCIES = host-util-linux host-lzo host-zlib
HOST_BTRFS_PROGS_CONF_OPTS = \
--disable-backtrace \