From fd8989db25c674ca65389a2d41bf5b447e8794be Mon Sep 17 00:00:00 2001 From: wangmy Date: Mon, 19 Jul 2021 16:59:28 +0800 Subject: btrfs-tools: upgrade 5.12.1 -> 5.13 Add patch to fix bug for undeclared macro on musl. btrfs-progs-5.13 (2021-07-13) * restore: remove loop checks for extent count and directory scan * inspect dump-tree: new options to print node (--csum-headers) and data checksums (--csum-items) * fi usage: * print stripe count for striped profiles * print zoned information: size, total unusable * mkfs: print note about sha256 accelerated module loading issue * check: ability to reset dev_item::bytes_used * fixes * detect zoned kernel support at run time too * exclusive op running check return value * fi resize: support cancel (kernel 5.14) * device remove: support cancel (kernel 5.14) * documentation about general topics * compression * zoned mode * storage model * hardware considerations * other * libbtrfsutil API overview * help text fixes and updates * hash speedtest measure time, cycles using perf and print throughput Signed-off-by: Wang Mingyu Signed-off-by: Alexandre Belloni Signed-off-by: Richard Purdie --- ...01-fix-error-for-undeclared-macro-on-musl.patch | 28 +++++++++ .../btrfs-tools/btrfs-tools_5.12.1.bb | 72 --------------------- .../btrfs-tools/btrfs-tools_5.13.bb | 73 ++++++++++++++++++++++ 3 files changed, 101 insertions(+), 72 deletions(-) create mode 100644 meta/recipes-devtools/btrfs-tools/btrfs-tools/0001-fix-error-for-undeclared-macro-on-musl.patch delete mode 100644 meta/recipes-devtools/btrfs-tools/btrfs-tools_5.12.1.bb create mode 100644 meta/recipes-devtools/btrfs-tools/btrfs-tools_5.13.bb diff --git a/meta/recipes-devtools/btrfs-tools/btrfs-tools/0001-fix-error-for-undeclared-macro-on-musl.patch b/meta/recipes-devtools/btrfs-tools/btrfs-tools/0001-fix-error-for-undeclared-macro-on-musl.patch new file mode 100644 index 0000000000..251f5d2b0e --- /dev/null +++ b/meta/recipes-devtools/btrfs-tools/btrfs-tools/0001-fix-error-for-undeclared-macro-on-musl.patch @@ -0,0 +1,28 @@ +From a9802902d37b83c2c992cfe34179312f7209a962 Mon Sep 17 00:00:00 2001 +From: Wang Mingyu +Date: Mon, 19 Jul 2021 10:12:12 +0900 +Subject: [PATCH] fix error for undeclared macro on musl + +Fixes the following compilation errors with musl that does not have +NAME_MAX declared: +'NAME_MAX' undeclared (first use in this function) + +Upstream-Status: Pending + +Signed-off-by: Wang Mingyu +--- + cmds/filesystem-usage.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/cmds/filesystem-usage.c b/cmds/filesystem-usage.c +index 50d8995e..856e9d7b 100644 +--- a/cmds/filesystem-usage.c ++++ b/cmds/filesystem-usage.c +@@ -24,6 +24,7 @@ + #include + #include + #include ++#include + + #include "common/utils.h" + #include "kerncompat.h" diff --git a/meta/recipes-devtools/btrfs-tools/btrfs-tools_5.12.1.bb b/meta/recipes-devtools/btrfs-tools/btrfs-tools_5.12.1.bb deleted file mode 100644 index d0c9cf2a99..0000000000 --- a/meta/recipes-devtools/btrfs-tools/btrfs-tools_5.12.1.bb +++ /dev/null @@ -1,72 +0,0 @@ -SUMMARY = "Checksumming Copy on Write Filesystem utilities" -DESCRIPTION = "Btrfs is a new copy on write filesystem for Linux aimed at \ -implementing advanced features while focusing on fault tolerance, repair and \ -easy administration. \ -This package contains utilities (mkfs, fsck, btrfsctl) used to work with \ -btrfs and an utility (btrfs-convert) to make a btrfs filesystem from an ext3." - -HOMEPAGE = "https://btrfs.wiki.kernel.org" - -LICENSE = "GPLv2 & LGPLv2.1+" -LIC_FILES_CHKSUM = " \ - file://COPYING;md5=fcb02dc552a041dee27e4b85c7396067 \ - file://libbtrfsutil/COPYING;md5=4fbd65380cdd255951079008b364516c \ -" -SECTION = "base" -DEPENDS = "lzo util-linux zlib" -DEPENDS_append_class-target = " udev" - -SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/kdave/btrfs-progs.git \ - file://0001-Add-a-possibility-to-specify-where-python-modules-ar.patch \ - file://0001-btrfs-tools-include-linux-const.h-to-fix-build-with-.patch \ - " -SRCREV = "96d77fcefdd3b9fd297b5aabbce6dc43e2315ee2" -S = "${WORKDIR}/git" - -PACKAGECONFIG ??= " \ - programs \ - convert \ - python \ - crypto-builtin \ -" -PACKAGECONFIG[manpages] = "--enable-documentation, --disable-documentation, asciidoc-native xmlto-native" -PACKAGECONFIG[programs] = "--enable-programs,--disable-programs" -PACKAGECONFIG[convert] = "--enable-convert --with-convert=ext2,--disable-convert --without-convert,e2fsprogs" -PACKAGECONFIG[zoned] = "--enable-zoned,--disable-zoned" -PACKAGECONFIG[python] = "--enable-python,--disable-python,python3-setuptools-native" -PACKAGECONFIG[zstd] = "--enable-zstd,--disable-zstd,zstd" - -# Pick only one crypto provider -PACKAGECONFIG[crypto-builtin] = "--with-crypto=builtin" -PACKAGECONFIG[crypto-libgcrypt] = "--with-crypto=libgcrypt,,libgcrypt" -PACKAGECONFIG[crypto-libsodium] = "--with-crypto=libsodium,,libsodium" -PACKAGECONFIG[crypto-libkcapi] = "--with-crypto=libkcapi,,libkcapi" - -inherit autotools-brokensep pkgconfig manpages -inherit ${@bb.utils.contains('PACKAGECONFIG', 'python', 'distutils3-base', '', d)} - -CLEANBROKEN = "1" - -EXTRA_OECONF = "--enable-largefile" -EXTRA_OECONF_append_libc-musl = " --disable-backtrace " -EXTRA_PYTHON_CFLAGS = "${DEBUG_PREFIX_MAP}" -EXTRA_PYTHON_CFLAGS_class-native = "" -EXTRA_PYTHON_LDFLAGS = "${LDFLAGS}" -EXTRA_OEMAKE = "V=1 'EXTRA_PYTHON_CFLAGS=${EXTRA_PYTHON_CFLAGS}' 'EXTRA_PYTHON_LDFLAGS=${EXTRA_PYTHON_LDFLAGS}'" - -do_configure_prepend() { - # Upstream doesn't ship this and autoreconf won't install it as automake isn't used. - mkdir -p ${S}/config - cp -f $(automake --print-libdir)/install-sh ${S}/config/ -} - - -do_install_append() { - if [ "${@bb.utils.filter('PACKAGECONFIG', 'python', d)}" ]; then - oe_runmake 'DESTDIR=${D}' 'PYTHON_SITEPACKAGES_DIR=${PYTHON_SITEPACKAGES_DIR}' install_python - fi -} - -RDEPENDS_${PN} = "libgcc" - -BBCLASSEXTEND = "native nativesdk" diff --git a/meta/recipes-devtools/btrfs-tools/btrfs-tools_5.13.bb b/meta/recipes-devtools/btrfs-tools/btrfs-tools_5.13.bb new file mode 100644 index 0000000000..fa33cad7b9 --- /dev/null +++ b/meta/recipes-devtools/btrfs-tools/btrfs-tools_5.13.bb @@ -0,0 +1,73 @@ +SUMMARY = "Checksumming Copy on Write Filesystem utilities" +DESCRIPTION = "Btrfs is a new copy on write filesystem for Linux aimed at \ +implementing advanced features while focusing on fault tolerance, repair and \ +easy administration. \ +This package contains utilities (mkfs, fsck, btrfsctl) used to work with \ +btrfs and an utility (btrfs-convert) to make a btrfs filesystem from an ext3." + +HOMEPAGE = "https://btrfs.wiki.kernel.org" + +LICENSE = "GPLv2 & LGPLv2.1+" +LIC_FILES_CHKSUM = " \ + file://COPYING;md5=fcb02dc552a041dee27e4b85c7396067 \ + file://libbtrfsutil/COPYING;md5=4fbd65380cdd255951079008b364516c \ +" +SECTION = "base" +DEPENDS = "lzo util-linux zlib" +DEPENDS_append_class-target = " udev" + +SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/kdave/btrfs-progs.git \ + file://0001-Add-a-possibility-to-specify-where-python-modules-ar.patch \ + file://0001-btrfs-tools-include-linux-const.h-to-fix-build-with-.patch \ + file://0001-fix-error-for-undeclared-macro-on-musl.patch \ + " +SRCREV = "de4914dbfd7e419d1c534b3d2ec8728e702114bf" +S = "${WORKDIR}/git" + +PACKAGECONFIG ??= " \ + programs \ + convert \ + python \ + crypto-builtin \ +" +PACKAGECONFIG[manpages] = "--enable-documentation, --disable-documentation, asciidoc-native xmlto-native" +PACKAGECONFIG[programs] = "--enable-programs,--disable-programs" +PACKAGECONFIG[convert] = "--enable-convert --with-convert=ext2,--disable-convert --without-convert,e2fsprogs" +PACKAGECONFIG[zoned] = "--enable-zoned,--disable-zoned" +PACKAGECONFIG[python] = "--enable-python,--disable-python,python3-setuptools-native" +PACKAGECONFIG[zstd] = "--enable-zstd,--disable-zstd,zstd" + +# Pick only one crypto provider +PACKAGECONFIG[crypto-builtin] = "--with-crypto=builtin" +PACKAGECONFIG[crypto-libgcrypt] = "--with-crypto=libgcrypt,,libgcrypt" +PACKAGECONFIG[crypto-libsodium] = "--with-crypto=libsodium,,libsodium" +PACKAGECONFIG[crypto-libkcapi] = "--with-crypto=libkcapi,,libkcapi" + +inherit autotools-brokensep pkgconfig manpages +inherit ${@bb.utils.contains('PACKAGECONFIG', 'python', 'distutils3-base', '', d)} + +CLEANBROKEN = "1" + +EXTRA_OECONF = "--enable-largefile" +EXTRA_OECONF_append_libc-musl = " --disable-backtrace " +EXTRA_PYTHON_CFLAGS = "${DEBUG_PREFIX_MAP}" +EXTRA_PYTHON_CFLAGS_class-native = "" +EXTRA_PYTHON_LDFLAGS = "${LDFLAGS}" +EXTRA_OEMAKE = "V=1 'EXTRA_PYTHON_CFLAGS=${EXTRA_PYTHON_CFLAGS}' 'EXTRA_PYTHON_LDFLAGS=${EXTRA_PYTHON_LDFLAGS}'" + +do_configure_prepend() { + # Upstream doesn't ship this and autoreconf won't install it as automake isn't used. + mkdir -p ${S}/config + cp -f $(automake --print-libdir)/install-sh ${S}/config/ +} + + +do_install_append() { + if [ "${@bb.utils.filter('PACKAGECONFIG', 'python', d)}" ]; then + oe_runmake 'DESTDIR=${D}' 'PYTHON_SITEPACKAGES_DIR=${PYTHON_SITEPACKAGES_DIR}' install_python + fi +} + +RDEPENDS_${PN} = "libgcc" + +BBCLASSEXTEND = "native nativesdk" -- cgit 1.2.3-korg