summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meta-oe/recipes-support/snapper/snapper/0001-Include-linux-types.h-for-__u16-__u32-__u64-type.patch30
-rw-r--r--meta-oe/recipes-support/snapper/snapper/0002-Use-statvfs-instead-of-statvfs64.patch37
-rw-r--r--meta-oe/recipes-support/snapper/snapper_0.12.2.bb (renamed from meta-oe/recipes-support/snapper/snapper_0.11.2.bb)20
3 files changed, 9 insertions, 78 deletions
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 @@
1From d103eaeae169708ca567f092182a89b79e5ab9db Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Sun, 20 Oct 2024 07:52:33 -0700
4Subject: [PATCH 1/2] Include linux/types.h for __u16/__u32/__u64 type
5
6This header is included indirectly with glibc but when using musl
7it ends up with compilation failure
8
9BcachefsUtils.cc:85:20: error: use of undeclared identifier '__u32'
10 85 | args.dirfd = (__u32) fddst;
11 | ^
12
13Upstream-Status: Submitted [https://github.com/openSUSE/snapper/pull/945]
14Signed-off-by: Khem Raj <raj.khem@gmail.com>
15---
16 snapper/BcachefsUtils.cc | 1 +
17 1 file changed, 1 insertion(+)
18
19diff --git a/snapper/BcachefsUtils.cc b/snapper/BcachefsUtils.cc
20index e9163ffb..1d328a78 100644
21--- a/snapper/BcachefsUtils.cc
22+++ b/snapper/BcachefsUtils.cc
23@@ -24,6 +24,7 @@
24
25 #include <cstring>
26 #include <cerrno>
27+#include <linux/types.h>
28 #include <sys/stat.h>
29 #include <sys/ioctl.h>
30
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 @@
1From 0b39f4484553c796cb300fb4933ea314e91d913b Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Sun, 20 Oct 2024 07:55:23 -0700
4Subject: [PATCH 2/2] Use statvfs instead of statvfs64
5
6when using LFS64 these functions are same and also
7on 64bit systems they are same. musl is using 64bit off_t
8by default and does not define LFS64 variants of these functions
9and it ends up in build errors
10
11Taken from Alpine Linux: [https://gitlab.alpinelinux.org/alpine/aports/-/blob/master/testing/snapper/statvfs64.patch]
12
13Upstream-Status: Submitted [https://github.com/openSUSE/snapper/pull/945]
14
15Signed-off-by: Markus Volk <f_l_k@t-online.de>
16Signed-off-by: Khem Raj <raj.khem@gmail.com>
17---
18 snapper/FileUtils.cc | 6 +++---
19 1 file changed, 3 insertions(+), 3 deletions(-)
20
21diff --git a/snapper/FileUtils.cc b/snapper/FileUtils.cc
22index d4034279..4c8578a1 100644
23--- a/snapper/FileUtils.cc
24+++ b/snapper/FileUtils.cc
25@@ -387,9 +387,9 @@ namespace snapper
26 std::pair<unsigned long long, unsigned long long>
27 SDir::statvfs() const
28 {
29- struct statvfs64 fsbuf;
30- if (fstatvfs64(dirfd, &fsbuf) != 0)
31- SN_THROW(IOErrorException(sformat("statvfs64 failed path:%s errno:%d (%s)", base_path.c_str(),
32+ struct statvfs fsbuf;
33+ if (fstatvfs(dirfd, &fsbuf) != 0)
34+ SN_THROW(IOErrorException(sformat("statvfs failed path:%s errno:%d (%s)", base_path.c_str(),
35 errno, stringerror(errno).c_str())));
36
37 // 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.12.2.bb
index 887615ef45..cdbe155d59 100644
--- a/meta-oe/recipes-support/snapper/snapper_0.11.2.bb
+++ b/meta-oe/recipes-support/snapper/snapper_0.12.2.bb
@@ -8,13 +8,8 @@ DEPENDS = "acl boost btrfs-tools dbus e2fsprogs json-c libxml2 lvm2 ncurses zlib
8# Build separation is slightly broken 8# Build separation is slightly broken
9inherit autotools-brokensep pkgconfig gettext 9inherit autotools-brokensep pkgconfig gettext
10 10
11SRC_URI = " \ 11SRC_URI = "git://github.com/openSUSE/snapper.git;protocol=https;branch=master"
12 git://github.com/openSUSE/snapper.git;protocol=https;branch=master \ 12SRCREV = "4f3d2b2fc58aefa976668cd25b8eac02ba0f85e7"
13 file://0001-Include-linux-types.h-for-__u16-__u32-__u64-type.patch \
14 file://0002-Use-statvfs-instead-of-statvfs64.patch \
15"
16SRCREV = "6c603565f36e9996d85045c8012cd04aba5f3708"
17
18 13
19EXTRA_OECONF += "--disable-zypp" 14EXTRA_OECONF += "--disable-zypp"
20 15
@@ -24,10 +19,13 @@ PACKAGECONFIG[systemd] = "--enable-systemd,--disable-systemd"
24PACKAGECONFIG[api-documentation] = "--enable-doc,--disable-doc,libxslt-native docbook-xsl-stylesheets-native" 19PACKAGECONFIG[api-documentation] = "--enable-doc,--disable-doc,libxslt-native docbook-xsl-stylesheets-native"
25 20
26# Avoid HOSTTOOLS path in binaries 21# Avoid HOSTTOOLS path in binaries
27export DIFFBIN = "${bindir}/diff" 22export DIFF_BIN = "${bindir}/diff"
28export RMBIN = "${bindir}/rm" 23export RM_BIN = "${bindir}/rm"
29export TOUCHBIN = "${bindir}/touch" 24export RMDIR_BIN = "${bindir}/rmdir"
30export CPBIN = "${bindir}/cp" 25export MKDIR_BIN = "${bindir}/mkdir"
26export TOUCH_BIN = "${bindir}/touch"
27export CP_BIN = "${bindir}/cp"
28export REALPATH_BIN = "${bindir}/realpath"
31 29
32do_install:append() { 30do_install:append() {
33 install -d ${D}${sysconfdir}/sysconfig 31 install -d ${D}${sysconfdir}/sysconfig