ostree: Use systemd_system_unitdir for systemd units
PATCH 1/4 ostree: Use systemd_system_unitdir for systemd units
Signed-off-by Alex Kiernan <[email protected]>
---
meta-oe/recipes-extended/ostree/ostree_2022.7.bb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
meta-oe/recipes-extended/ostree/ostree_2022.7.bb +3 -3
@@ -84,7 +84,7 @@ PACKAGECONFIG[selinux] = "--with-selinux, --without-selinux, libselinux, bubblew PACKAGECONFIG[smack] = "--with-smack, --without-smack, smack" PACKAGECONFIG[soup] = "--with-soup, --without-soup --disable-glibtest, libsoup-2.4" PACKAGECONFIG[static] = "" -PACKAGECONFIG[systemd] = "--with-libsystemd --with-systemdsystemunitdir=${systemd_unitdir}/system, --without-libsystemd, systemd" +PACKAGECONFIG[systemd] = "--with-libsystemd --with-systemdsystemunitdir=${systemd_system_unitdir}, --without-libsystemd, systemd" PACKAGECONFIG[trivial-httpd-cmdline] = "--enable-trivial-httpd-cmdline, --disable-trivial-httpd-cmdline" EXTRA_OECONF = " \
@@ -139,7 +139,7 @@ PACKAGE_BEFORE_PN = " \ FILES:${PN} += " \ ${nonarch_libdir}/${BPN} \ ${nonarch_libdir}/tmpfiles.d \ - ${systemd_unitdir}/system \ + ${systemd_system_unitdir} \ ${systemd_unitdir}/system-generators \ " FILES:${PN}-dracut = " \
@@ -156,7 +156,7 @@ FILES:${PN}-mkinitcpio = " \ " FILES:${PN}-switchroot = " \ ${nonarch_libdir}/${BPN}/ostree-prepare-root \ - ${systemd_unitdir}/system/ostree-prepare-root.service \ + ${systemd_system_unitdir}/ostree-prepare-root.service \ " FILES:${PN}-trivial-httpd = " \ ${libexecdir}/libostree/ostree-trivial-httpd \
Signature · 1 line
2.39.0
PATCH 2/4 ostree: Switch to fuse3 which is supported in ostree now
Signed-off-by Alex Kiernan <[email protected]>
---
meta-oe/recipes-extended/ostree/ostree_2022.7.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
meta-oe/recipes-extended/ostree/ostree_2022.7.bb +1 -1
@@ -79,7 +79,7 @@ PACKAGECONFIG[manpages] = "--enable-man, --disable-man, libxslt-native docbook-x PACKAGECONFIG[mkinitcpio] = "--with-mkinitcpio, --without-mkinitcpio" PACKAGECONFIG[no-http2] = "--disable-http2, --enable-http2" PACKAGECONFIG[openssl] = "--with-crypto=openssl, , openssl, , , glib gnutls" -PACKAGECONFIG[rofiles-fuse] = "--enable-rofiles-fuse, --disable-rofiles-fuse, fuse" +PACKAGECONFIG[rofiles-fuse] = "--enable-rofiles-fuse, --disable-rofiles-fuse, fuse3" PACKAGECONFIG[selinux] = "--with-selinux, --without-selinux, libselinux, bubblewrap" PACKAGECONFIG[smack] = "--with-smack, --without-smack, smack" PACKAGECONFIG[soup] = "--with-soup, --without-soup --disable-glibtest, libsoup-2.4"
Signature · 1 line
2.39.0
PATCH 3/4 ostree: Fix comments for configuration/ptest
In reply to Alex KiernanThe comments and recipe had diverged, bring them back into line. Update the instructions on how to get ptest to pass.
Signed-off-by Alex Kiernan <[email protected]>
---
.../recipes-extended/ostree/ostree_2022.7.bb | 25 +++++++++++++------ 1 file changed, 17 insertions(+), 8 deletions(-)
meta-oe/recipes-extended/ostree/ostree_2022.7.bb +17 -8
@@ -39,7 +39,9 @@ BUILD_OPTIMIZATION:remove = "-Og" BUILD_OPTIMIZATION:append = " -O2" # Package configuration - match ostree defaults, but without rofiles-fuse -# otherwise we introduce a dependendency on meta-filesystems +# otherwise we introduce a dependendency on meta-filesystems and swap +# soup for curl to avoid bringing in deprecated libsoup2 (though +# to run ptest requires that you have soup). PACKAGECONFIG ??= " \ ${@bb.utils.filter('DISTRO_FEATURES', 'selinux smack', d)} \ ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd libmount', '', d)} \
@@ -48,7 +50,7 @@ PACKAGECONFIG ??= " \ curl \ " -# We include soup because ostree can't (currently) be built without +# We include curl because ostree can't (currently) be built without # soup or curl - https://github.com/ostreedev/ostree/issues/1897 PACKAGECONFIG:class-native ??= " \ ${@bb.utils.filter('DISTRO_FEATURES', 'selinux smack', d)} \
@@ -175,13 +177,20 @@ RDEPENDS:${PN}:class-target = " \ # # Note that to get ptest to pass you also need: # -# xattr in DISTRO_FEATURES -# static ostree-prepare-root (PACKAGECONFIG:append:pn-ostree = " static") -# meta-python in your layers -# overlayfs in your kernel (KERNEL_EXTRA_FEATURES += "features/overlayfs/overlayfs.scc") +# xattr in DISTRO_FEATURES (default) +# static ostree-prepare-root +# ostree-trivial-httpd (requires soup - note soup and curl can coexist) +# overlayfs in your kernel # busybox built statically -# /var/tmp as a real filesystem (not a tmpfs) -# Sufficient disk space (IMAGE_ROOTFS_SIZE = "524288") and RAM (QB_MEM = "-m 1024") +# C.UTF-8 locale available +# Sufficient disk space/RAM (e.g. core-image-sato-sdk) +# +# Something like this in your local.conf: +# +# PACKAGECONFIG:append:pn-ostree = " static soup" +# KERNEL_EXTRA_FEATURES:append = " features/overlayfs/overlayfs.scc" +# TARGET_CFLAGS:append:pn-busybox = " -static" +# IMAGE_LINGUAS:append:libc-glibc = " c" # RDEPENDS:${PN}-ptest += " \ attr \
Signature · 1 line
2.39.0
PATCH 4/4 ostree: Handle musl's ERANGE mapping
In reply to Alex KiernanSigned-off-by Alex Kiernan <[email protected]>
---
...1-tests-Handle-musl-s-ERANGE-mapping.patch | 29 +++++++++++++++++++ .../recipes-extended/ostree/ostree_2022.7.bb | 1 + 2 files changed, 30 insertions(+) create mode 100644 meta-oe/recipes-extended/ostree/ostree/0001-tests-Handle-musl-s-ERANGE-mapping.patch
meta-oe/recipes-extended/ostree/ostree/0001-tests-Handle-musl-s-ERANGE-mapping.patch new file +29 -0
@@ -0,0 +1,29 @@ +From bd182584a1e2f820493d9db689598a20c5700ba5 Mon Sep 17 00:00:00 2001 +From: Alex Kiernan <[email protected]> +Date: Mon, 2 Jan 2023 10:37:49 +0000 +Subject: [PATCH] tests: Handle musl's ERANGE mapping + +musl uses "Result not representable" for ERANGE, support this in +addition to glibc's "Numerical result out of range". + +Upstream-Status: Backport [https://github.com/ostreedev/ostree/commit/2d4ee168d7eae0afcce356a3f8135294e6d7fe6f] +Signed-off-by: Alex Kiernan <[email protected]> +--- + tests/test-commit-timestamp.sh | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/tests/test-commit-timestamp.sh b/tests/test-commit-timestamp.sh +index 0688c63a4bdb..de105b768a9c 100755 +--- a/tests/test-commit-timestamp.sh ++++ b/tests/test-commit-timestamp.sh +@@ -40,6 +40,6 @@ fi + ${CMD_PREFIX} ostree --repo=./testrepo show env > show-env.txt + rm -rf testrepo testrepo-files + assert_file_has_content_literal commit-invalid.txt 'Failed to convert SOURCE_DATE_EPOCH' +-assert_file_has_content_literal commit-overflowing.txt 'Parsing SOURCE_DATE_EPOCH: Numerical result out of range' ++assert_file_has_content commit-overflowing.txt 'Parsing SOURCE_DATE_EPOCH: \(Numerical result out of range\|Result not representable\)' + assert_file_has_content_literal show-env.txt 'Date: 2009-02-13 23:31:30 +0000' + echo "ok commit with env timestamp" +-- +2.39.0 +
meta-oe/recipes-extended/ostree/ostree_2022.7.bb +1 -0
@@ -20,6 +20,7 @@ DEPENDS = " \ SRC_URI = " \ https://github.com/ostreedev/ostree/releases/download/v${PV}/libostree-${PV}.tar.xz \ file://0001-lib-repo-checkout-Add-ALLPERMS-for-musl.patch \ + file://0001-tests-Handle-musl-s-ERANGE-mapping.patch \ file://run-ptest \ " SRC_URI[sha256sum] = "8be2a9261c94e8b9ec4113380ffc480f8598245fb321a009bad4fae4b822411f"
Signature · 1 line
2.39.0