From 0deaa31db330c84273b1945b6261fdd442527958 Mon Sep 17 00:00:00 2001 From: Markus Volk Date: Fri, 29 Aug 2025 03:25:54 +0200 Subject: snapper: update 0.11.2 -> 0.12.2 - remove patches that were added upstream - fix reproducibility issues Signed-off-by: Markus Volk Signed-off-by: Khem Raj --- ...-linux-types.h-for-__u16-__u32-__u64-type.patch | 30 ---------------- .../0002-Use-statvfs-instead-of-statvfs64.patch | 37 -------------------- meta-oe/recipes-support/snapper/snapper_0.11.2.bb | 40 ---------------------- meta-oe/recipes-support/snapper/snapper_0.12.2.bb | 38 ++++++++++++++++++++ 4 files changed, 38 insertions(+), 107 deletions(-) delete mode 100644 meta-oe/recipes-support/snapper/snapper/0001-Include-linux-types.h-for-__u16-__u32-__u64-type.patch delete mode 100644 meta-oe/recipes-support/snapper/snapper/0002-Use-statvfs-instead-of-statvfs64.patch delete mode 100644 meta-oe/recipes-support/snapper/snapper_0.11.2.bb create mode 100644 meta-oe/recipes-support/snapper/snapper_0.12.2.bb diff --git a/meta-oe/recipes-support/snapper/snapper/0001-Include-linux-types.h-for-__u16-__u32-__u64-type.patch b/meta-oe/recipes-support/snapper/snapper/0001-Include-linux-types.h-for-__u16-__u32-__u64-type.patch deleted file mode 100644 index ec8594629e..0000000000 --- a/meta-oe/recipes-support/snapper/snapper/0001-Include-linux-types.h-for-__u16-__u32-__u64-type.patch +++ /dev/null @@ -1,30 +0,0 @@ -From d103eaeae169708ca567f092182a89b79e5ab9db Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Sun, 20 Oct 2024 07:52:33 -0700 -Subject: [PATCH 1/2] Include linux/types.h for __u16/__u32/__u64 type - -This header is included indirectly with glibc but when using musl -it ends up with compilation failure - -BcachefsUtils.cc:85:20: error: use of undeclared identifier '__u32' - 85 | args.dirfd = (__u32) fddst; - | ^ - -Upstream-Status: Submitted [https://github.com/openSUSE/snapper/pull/945] -Signed-off-by: Khem Raj ---- - snapper/BcachefsUtils.cc | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/snapper/BcachefsUtils.cc b/snapper/BcachefsUtils.cc -index e9163ffb..1d328a78 100644 ---- a/snapper/BcachefsUtils.cc -+++ b/snapper/BcachefsUtils.cc -@@ -24,6 +24,7 @@ - - #include - #include -+#include - #include - #include - diff --git a/meta-oe/recipes-support/snapper/snapper/0002-Use-statvfs-instead-of-statvfs64.patch b/meta-oe/recipes-support/snapper/snapper/0002-Use-statvfs-instead-of-statvfs64.patch deleted file mode 100644 index b915fda257..0000000000 --- a/meta-oe/recipes-support/snapper/snapper/0002-Use-statvfs-instead-of-statvfs64.patch +++ /dev/null @@ -1,37 +0,0 @@ -From 0b39f4484553c796cb300fb4933ea314e91d913b Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Sun, 20 Oct 2024 07:55:23 -0700 -Subject: [PATCH 2/2] Use statvfs instead of statvfs64 - -when using LFS64 these functions are same and also -on 64bit systems they are same. musl is using 64bit off_t -by default and does not define LFS64 variants of these functions -and it ends up in build errors - -Taken from Alpine Linux: [https://gitlab.alpinelinux.org/alpine/aports/-/blob/master/testing/snapper/statvfs64.patch] - -Upstream-Status: Submitted [https://github.com/openSUSE/snapper/pull/945] - -Signed-off-by: Markus Volk -Signed-off-by: Khem Raj ---- - snapper/FileUtils.cc | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) - -diff --git a/snapper/FileUtils.cc b/snapper/FileUtils.cc -index d4034279..4c8578a1 100644 ---- a/snapper/FileUtils.cc -+++ b/snapper/FileUtils.cc -@@ -387,9 +387,9 @@ namespace snapper - std::pair - SDir::statvfs() const - { -- struct statvfs64 fsbuf; -- if (fstatvfs64(dirfd, &fsbuf) != 0) -- SN_THROW(IOErrorException(sformat("statvfs64 failed path:%s errno:%d (%s)", base_path.c_str(), -+ struct statvfs fsbuf; -+ if (fstatvfs(dirfd, &fsbuf) != 0) -+ SN_THROW(IOErrorException(sformat("statvfs failed path:%s errno:%d (%s)", base_path.c_str(), - errno, stringerror(errno).c_str()))); - - // f_bavail is used (not f_bfree) since df seems to do the diff --git a/meta-oe/recipes-support/snapper/snapper_0.11.2.bb b/meta-oe/recipes-support/snapper/snapper_0.11.2.bb deleted file mode 100644 index 887615ef45..0000000000 --- a/meta-oe/recipes-support/snapper/snapper_0.11.2.bb +++ /dev/null @@ -1,40 +0,0 @@ -SUMMARY = "Snapper is a tool for Linux file system snapshot management" -HOMEPAGE = "https://github.com/openSUSE/snapper" -LICENSE = "GPL-2.0-only" -LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe" - -DEPENDS = "acl boost btrfs-tools dbus e2fsprogs json-c libxml2 lvm2 ncurses zlib" - -# Build separation is slightly broken -inherit autotools-brokensep pkgconfig gettext - -SRC_URI = " \ - git://github.com/openSUSE/snapper.git;protocol=https;branch=master \ - file://0001-Include-linux-types.h-for-__u16-__u32-__u64-type.patch \ - file://0002-Use-statvfs-instead-of-statvfs64.patch \ -" -SRCREV = "6c603565f36e9996d85045c8012cd04aba5f3708" - - -EXTRA_OECONF += "--disable-zypp" - -PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'api-documentation systemd pam', d)}" -PACKAGECONFIG[pam] = "--enable-pam --with-pam-security=${base_libdir}/security, --disable-pam,libpam" -PACKAGECONFIG[systemd] = "--enable-systemd,--disable-systemd" -PACKAGECONFIG[api-documentation] = "--enable-doc,--disable-doc,libxslt-native docbook-xsl-stylesheets-native" - -# Avoid HOSTTOOLS path in binaries -export DIFFBIN = "${bindir}/diff" -export RMBIN = "${bindir}/rm" -export TOUCHBIN = "${bindir}/touch" -export CPBIN = "${bindir}/cp" - -do_install:append() { - install -d ${D}${sysconfdir}/sysconfig - install -m0644 ${S}/data/default-config ${D}${sysconfdir}/sysconfig/snapper -} - -FILES:${PN} += "${base_libdir}/security ${nonarch_libdir} ${systemd_system_unitdir} ${datadir}" - -# bash is needed for the testsuite -RDEPENDS:${PN} = "bash diffutils util-linux util-linux-mount" diff --git a/meta-oe/recipes-support/snapper/snapper_0.12.2.bb b/meta-oe/recipes-support/snapper/snapper_0.12.2.bb new file mode 100644 index 0000000000..cdbe155d59 --- /dev/null +++ b/meta-oe/recipes-support/snapper/snapper_0.12.2.bb @@ -0,0 +1,38 @@ +SUMMARY = "Snapper is a tool for Linux file system snapshot management" +HOMEPAGE = "https://github.com/openSUSE/snapper" +LICENSE = "GPL-2.0-only" +LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe" + +DEPENDS = "acl boost btrfs-tools dbus e2fsprogs json-c libxml2 lvm2 ncurses zlib" + +# Build separation is slightly broken +inherit autotools-brokensep pkgconfig gettext + +SRC_URI = "git://github.com/openSUSE/snapper.git;protocol=https;branch=master" +SRCREV = "4f3d2b2fc58aefa976668cd25b8eac02ba0f85e7" + +EXTRA_OECONF += "--disable-zypp" + +PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'api-documentation systemd pam', d)}" +PACKAGECONFIG[pam] = "--enable-pam --with-pam-security=${base_libdir}/security, --disable-pam,libpam" +PACKAGECONFIG[systemd] = "--enable-systemd,--disable-systemd" +PACKAGECONFIG[api-documentation] = "--enable-doc,--disable-doc,libxslt-native docbook-xsl-stylesheets-native" + +# Avoid HOSTTOOLS path in binaries +export DIFF_BIN = "${bindir}/diff" +export RM_BIN = "${bindir}/rm" +export RMDIR_BIN = "${bindir}/rmdir" +export MKDIR_BIN = "${bindir}/mkdir" +export TOUCH_BIN = "${bindir}/touch" +export CP_BIN = "${bindir}/cp" +export REALPATH_BIN = "${bindir}/realpath" + +do_install:append() { + install -d ${D}${sysconfdir}/sysconfig + install -m0644 ${S}/data/default-config ${D}${sysconfdir}/sysconfig/snapper +} + +FILES:${PN} += "${base_libdir}/security ${nonarch_libdir} ${systemd_system_unitdir} ${datadir}" + +# bash is needed for the testsuite +RDEPENDS:${PN} = "bash diffutils util-linux util-linux-mount" -- cgit v1.2.3-54-g00ecf