diff mbox series

[meta-oe,PATCHv2] snapper: add recipe

Message ID 20241018135346.21402-1-f_l_k@t-online.de
State Accepted
Headers show
Series [meta-oe,PATCHv2] snapper: add recipe | expand

Commit Message

Markus Volk Oct. 18, 2024, 1:53 p.m. UTC
Snapper is a tool for Linux file system snapshot management. Apart from
the obvious creation and deletion of snapshots it can compare snapshots
and revert differences between them. In simple terms, this allows root
and non-root users to view older versions of files and revert changes.

Signed-off-by: Markus Volk <f_l_k@t-online.de>
---
 .../recipes-support/snapper/snapper_0.11.2.bb | 37 +++++++++++++++++++
 1 file changed, 37 insertions(+)
 create mode 100644 meta-oe/recipes-support/snapper/snapper_0.11.2.bb
diff mbox series

Patch

diff --git a/meta-oe/recipes-support/snapper/snapper_0.11.2.bb b/meta-oe/recipes-support/snapper/snapper_0.11.2.bb
new file mode 100644
index 000000000..5bc0d36f8
--- /dev/null
+++ b/meta-oe/recipes-support/snapper/snapper_0.11.2.bb
@@ -0,0 +1,37 @@ 
+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 json-c libxml2 lvm2 zlib"
+
+# Build separation is slightly broken
+inherit autotools-brokensep pkgconfig gettext
+
+SRC_URI = "git://github.com/openSUSE/snapper.git;protocol=https;branch=master"
+SRCREV = "6c603565f36e9996d85045c8012cd04aba5f3708"
+
+S = "${WORKDIR}/git"
+
+EXTRA_OECONF += "--disable-zypp"
+
+PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'api-documentation systemd pam', d)}"
+PACKAGECONFIG[pam] = "--enable-pam,--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} += "${libdir}/pam_snapper ${libdir}/systemd ${libdir}/security ${datadir}"
+# bash is needed for the testsuite
+RDEPENDS:${PN} = "bash diffutils util-linux"