diff options
4 files changed, 140 insertions, 0 deletions
diff --git a/meta-oe/recipes-extended/ostree/ostree/0001-Avoid-race-condition-when-building-outside-of-source.patch b/meta-oe/recipes-extended/ostree/ostree/0001-Avoid-race-condition-when-building-outside-of-source.patch new file mode 100644 index 0000000000..c926965de5 --- /dev/null +++ b/meta-oe/recipes-extended/ostree/ostree/0001-Avoid-race-condition-when-building-outside-of-source.patch | |||
| @@ -0,0 +1,33 @@ | |||
| 1 | From 77b27c07df2bdff86945766a4728b6012062535c Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Stefan Agner <stefan@agner.ch> | ||
| 3 | Date: Tue, 26 Nov 2019 09:20:30 +0100 | ||
| 4 | Subject: [PATCH] Avoid race condition when building outside of source tree | ||
| 5 | |||
| 6 | When building outside of source tree it can happen that src/ostree/ | ||
| 7 | does not exist (yet) when bison is called. This leads to an build | ||
| 8 | error like so: | ||
| 9 | bison: src/ostree/parse-datetime.c: cannot open: No such file or directory | ||
| 10 | |||
| 11 | Make sure that src/ostree/ exists when parse-datetime.c is built. | ||
| 12 | |||
| 13 | Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com> | ||
| 14 | Upstream-Status: Backport | ||
| 15 | --- | ||
| 16 | Makefile-ostree.am | 1 + | ||
| 17 | 1 file changed, 1 insertion(+) | ||
| 18 | |||
| 19 | diff --git a/Makefile-ostree.am b/Makefile-ostree.am | ||
| 20 | index 76f39cad4b74..f861afe42168 100644 | ||
| 21 | --- a/Makefile-ostree.am | ||
| 22 | +++ b/Makefile-ostree.am | ||
| 23 | @@ -123,6 +123,7 @@ ostree_SOURCES += src/ostree/ot-remote-builtin-add-cookie.c \ | ||
| 24 | endif | ||
| 25 | |||
| 26 | src/ostree/parse-datetime.c: src/ostree/parse-datetime.y Makefile | ||
| 27 | + mkdir -p src/ostree/ | ||
| 28 | $(AM_V_GEN) $(YACC) $< -o $@ | ||
| 29 | |||
| 30 | EXTRA_DIST += src/ostree/parse-datetime.y | ||
| 31 | -- | ||
| 32 | 2.17.1 | ||
| 33 | |||
diff --git a/meta-oe/recipes-extended/ostree/ostree/0001-Makefile-declare-ostree_boot_SCRIPTS-and-append-valu.patch b/meta-oe/recipes-extended/ostree/ostree/0001-Makefile-declare-ostree_boot_SCRIPTS-and-append-valu.patch new file mode 100644 index 0000000000..4b1c02a62e --- /dev/null +++ b/meta-oe/recipes-extended/ostree/ostree/0001-Makefile-declare-ostree_boot_SCRIPTS-and-append-valu.patch | |||
| @@ -0,0 +1,60 @@ | |||
| 1 | From de8e0765a4a54f0367999f682ce4cc53bfaa60b0 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Ricardo Salveti <ricardo@foundries.io> | ||
| 3 | Date: Tue, 5 Nov 2019 21:16:07 -0300 | ||
| 4 | Subject: [PATCH] Makefile: declare ostree_boot_SCRIPTS and append values | ||
| 5 | |||
| 6 | ostree_boot_SCRIPTS was being set on both Makefile-boot.am and | ||
| 7 | Makefile-switchroot.am, causing the first one to be replaced by the | ||
| 8 | other at the final Makefile, so declare as empty and append on both | ||
| 9 | places instead. | ||
| 10 | |||
| 11 | Signed-off-by: Ricardo Salveti <ricardo@foundries.io> | ||
| 12 | Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com> | ||
| 13 | Upstream-Status: Backport | ||
| 14 | --- | ||
| 15 | Makefile-boot.am | 2 +- | ||
| 16 | Makefile-decls.am | 1 + | ||
| 17 | Makefile-switchroot.am | 2 +- | ||
| 18 | 3 files changed, 3 insertions(+), 2 deletions(-) | ||
| 19 | |||
| 20 | diff --git a/Makefile-boot.am b/Makefile-boot.am | ||
| 21 | index b4d4a1af670e..b51928f08d7c 100644 | ||
| 22 | --- a/Makefile-boot.am | ||
| 23 | +++ b/Makefile-boot.am | ||
| 24 | @@ -60,7 +60,7 @@ grub2configdir = $(sysconfdir)/grub.d | ||
| 25 | INSTALL_DATA_HOOKS += install-grub2-config-hook | ||
| 26 | else | ||
| 27 | # We're using our internal generator | ||
| 28 | -ostree_boot_SCRIPTS = src/boot/grub2/ostree-grub-generator | ||
| 29 | +ostree_boot_SCRIPTS += src/boot/grub2/ostree-grub-generator | ||
| 30 | endif | ||
| 31 | |||
| 32 | EXTRA_DIST += src/boot/dracut/module-setup.sh \ | ||
| 33 | diff --git a/Makefile-decls.am b/Makefile-decls.am | ||
| 34 | index 115c19fb663f..086ee1384a0b 100644 | ||
| 35 | --- a/Makefile-decls.am | ||
| 36 | +++ b/Makefile-decls.am | ||
| 37 | @@ -47,6 +47,7 @@ typelibdir = $(libdir)/girepository-1.0 | ||
| 38 | typelib_DATA = | ||
| 39 | gsettings_SCHEMAS = | ||
| 40 | ostree_bootdir = $(prefix)/lib/ostree | ||
| 41 | +ostree_boot_SCRIPTS = | ||
| 42 | ostree_boot_PROGRAMS = | ||
| 43 | |||
| 44 | # This initializes some more variables | ||
| 45 | diff --git a/Makefile-switchroot.am b/Makefile-switchroot.am | ||
| 46 | index ff44d4bc3981..b81b843febbc 100644 | ||
| 47 | --- a/Makefile-switchroot.am | ||
| 48 | +++ b/Makefile-switchroot.am | ||
| 49 | @@ -42,7 +42,7 @@ if BUILDOPT_USE_STATIC_COMPILER | ||
| 50 | # to get autotools to install this as an executable but without generating rules | ||
| 51 | # to make it itself which we have specified manually. See | ||
| 52 | # https://lists.gnu.org/archive/html/help-gnu-utils/2007-01/msg00007.html | ||
| 53 | -ostree_boot_SCRIPTS = ostree-prepare-root | ||
| 54 | +ostree_boot_SCRIPTS += ostree-prepare-root | ||
| 55 | |||
| 56 | ostree-prepare-root : $(ostree_prepare_root_SOURCES) | ||
| 57 | $(STATIC_COMPILER) -o $@ -static $(top_srcdir)/src/switchroot/ostree-prepare-root.c $(ostree_prepare_root_CPPFLAGS) $(AM_CFLAGS) $(DEFAULT_INCLUDES) -DOSTREE_PREPARE_ROOT_STATIC=1 | ||
| 58 | -- | ||
| 59 | 2.17.1 | ||
| 60 | |||
diff --git a/meta-oe/recipes-extended/ostree/ostree/0001-tests-repo-finder-Run-realpath-on-tmp.patch b/meta-oe/recipes-extended/ostree/ostree/0001-tests-repo-finder-Run-realpath-on-tmp.patch new file mode 100644 index 0000000000..ba116a9efe --- /dev/null +++ b/meta-oe/recipes-extended/ostree/ostree/0001-tests-repo-finder-Run-realpath-on-tmp.patch | |||
| @@ -0,0 +1,44 @@ | |||
| 1 | From 16bb294384bb4ae4ba83af51fbb64fdd14d02838 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Colin Walters <walters@verbum.org> | ||
| 3 | Date: Thu, 21 Nov 2019 18:37:48 +0000 | ||
| 4 | Subject: [PATCH] tests/repo-finder: Run realpath() on /tmp | ||
| 5 | |||
| 6 | This fixes running this test case inside | ||
| 7 | https://github.com/cgwalters/coretoolbox | ||
| 8 | |||
| 9 | Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com> | ||
| 10 | Upstream-Status: Backport | ||
| 11 | --- | ||
| 12 | tests/test-repo-finder-mount.c | 9 +++++---- | ||
| 13 | 1 file changed, 5 insertions(+), 4 deletions(-) | ||
| 14 | |||
| 15 | diff --git a/tests/test-repo-finder-mount.c b/tests/test-repo-finder-mount.c | ||
| 16 | index 847f4becd1c6..af2f5e085f68 100644 | ||
| 17 | --- a/tests/test-repo-finder-mount.c | ||
| 18 | +++ b/tests/test-repo-finder-mount.c | ||
| 19 | @@ -62,7 +62,9 @@ setup (Fixture *fixture, | ||
| 20 | g_clear_error (&error); | ||
| 21 | g_assert_no_error (error); | ||
| 22 | |||
| 23 | - fixture->working_dir = g_file_new_for_path (fixture->tmpdir.path); | ||
| 24 | + /* Realpath since at least coretoolbox makes /tmp a symlink to /host/tmp */ | ||
| 25 | + g_autofree char *tmpdir_real_path = realpath (fixture->tmpdir.path, NULL); | ||
| 26 | + fixture->working_dir = g_file_new_for_path (tmpdir_real_path); | ||
| 27 | |||
| 28 | fixture->parent_repo = ot_test_setup_repo (NULL, &error); | ||
| 29 | g_assert_no_error (error); | ||
| 30 | @@ -443,9 +445,8 @@ test_repo_finder_mount_mixed_mounts (Fixture *fixture, | ||
| 31 | } | ||
| 32 | else | ||
| 33 | { | ||
| 34 | - g_test_message ("Unknown result ‘%s’ with keyring ‘%s’.", | ||
| 35 | - result->remote->name, result->remote->keyring); | ||
| 36 | - g_assert_not_reached (); | ||
| 37 | + g_error ("Unknown result ‘%s’ with keyring ‘%s’", | ||
| 38 | + result->remote->name, result->remote->keyring); | ||
| 39 | } | ||
| 40 | } | ||
| 41 | |||
| 42 | -- | ||
| 43 | 2.17.1 | ||
| 44 | |||
diff --git a/meta-oe/recipes-extended/ostree/ostree_2019.5.bb b/meta-oe/recipes-extended/ostree/ostree_2019.5.bb index 7c1ed9c6b7..4f437f3480 100644 --- a/meta-oe/recipes-extended/ostree/ostree_2019.5.bb +++ b/meta-oe/recipes-extended/ostree/ostree_2019.5.bb | |||
| @@ -31,6 +31,9 @@ SRC_URI = " \ | |||
| 31 | file://0002-tests-core-Assume-C.UTF-8-if-locale-isn-t-found.patch \ | 31 | file://0002-tests-core-Assume-C.UTF-8-if-locale-isn-t-found.patch \ |
| 32 | file://0003-tests-Avoid-musl-failure-with-cp-a.patch \ | 32 | file://0003-tests-Avoid-musl-failure-with-cp-a.patch \ |
| 33 | file://0001-build-create-tests-directory-for-split-builds.patch \ | 33 | file://0001-build-create-tests-directory-for-split-builds.patch \ |
| 34 | file://0001-Makefile-declare-ostree_boot_SCRIPTS-and-append-valu.patch \ | ||
| 35 | file://0001-Avoid-race-condition-when-building-outside-of-source.patch \ | ||
| 36 | file://0001-tests-repo-finder-Run-realpath-on-tmp.patch \ | ||
| 34 | " | 37 | " |
| 35 | SRCREV = "980ca07b03b3aa7e0012729dd6c84b0878775d93" | 38 | SRCREV = "980ca07b03b3aa7e0012729dd6c84b0878775d93" |
| 36 | 39 | ||
