From 24ca62b3c1fd404b67d549b29aeeacf913e6dc86 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Mon, 20 Apr 2020 17:19:11 +0100 Subject: oeqa/selftest: Add test for conflicting sysroot provider sysroot-test depends on virtual/sysroot-test which we build for one machine, switch machine, switch provider of virtual/sysroot-test and check that the sysroot is correctly cleaned up. The files in the two providers overlap so can cause errors if the sysroot code doesn't function correctly. Yes, sysroot-test should be machine specific really to avoid this, however the sysroot cleanup should also work. This adds a test for bug: [YOCTO #13702] Signed-off-by: Richard Purdie --- .../recipes-test/sysroot-test/sysroot-test-arch1_1.0.bb | 14 ++++++++++++++ .../recipes-test/sysroot-test/sysroot-test-arch2_1.0.bb | 14 ++++++++++++++ .../recipes-test/sysroot-test/sysroot-test_1.0.bb | 6 ++++++ 3 files changed, 34 insertions(+) create mode 100644 meta-selftest/recipes-test/sysroot-test/sysroot-test-arch1_1.0.bb create mode 100644 meta-selftest/recipes-test/sysroot-test/sysroot-test-arch2_1.0.bb create mode 100644 meta-selftest/recipes-test/sysroot-test/sysroot-test_1.0.bb (limited to 'meta-selftest') diff --git a/meta-selftest/recipes-test/sysroot-test/sysroot-test-arch1_1.0.bb b/meta-selftest/recipes-test/sysroot-test/sysroot-test-arch1_1.0.bb new file mode 100644 index 0000000000..36a682c53d --- /dev/null +++ b/meta-selftest/recipes-test/sysroot-test/sysroot-test-arch1_1.0.bb @@ -0,0 +1,14 @@ +LICENSE = "CLOSED" + +PROVIDES = "virtual/sysroot-test" +INHIBIT_DEFAULT_DEPS = "1" +PACKAGE_ARCH = "${MACHINE_ARCH}" + +TESTSTRING ?= "1" + +do_install() { + install -d ${D}${includedir} + echo "# test ${TESTSTRING}" > ${D}${includedir}/sysroot-test.h +} + +EXCLUDE_FROM_WORLD = "1" diff --git a/meta-selftest/recipes-test/sysroot-test/sysroot-test-arch2_1.0.bb b/meta-selftest/recipes-test/sysroot-test/sysroot-test-arch2_1.0.bb new file mode 100644 index 0000000000..67172f3cab --- /dev/null +++ b/meta-selftest/recipes-test/sysroot-test/sysroot-test-arch2_1.0.bb @@ -0,0 +1,14 @@ +LICENSE = "CLOSED" + +PROVIDES = "virtual/sysroot-test" +INHIBIT_DEFAULT_DEPS = "1" +PACKAGE_ARCH = "${MACHINE_ARCH}" + +TESTSTRING ?= "2" + +do_install() { + install -d ${D}${includedir} + echo "# test ${TESTSTRING}" > ${D}${includedir}/sysroot-test.h +} + +EXCLUDE_FROM_WORLD = "1" diff --git a/meta-selftest/recipes-test/sysroot-test/sysroot-test_1.0.bb b/meta-selftest/recipes-test/sysroot-test/sysroot-test_1.0.bb new file mode 100644 index 0000000000..560487c159 --- /dev/null +++ b/meta-selftest/recipes-test/sysroot-test/sysroot-test_1.0.bb @@ -0,0 +1,6 @@ +SUMMARY = "Virtual provider sysroot test" +LICENSE = "CLOSED" +INHIBIT_DEFAULT_DEPS = "1" +DEPENDS = "virtual/sysroot-test" + +EXCLUDE_FROM_WORLD = "1" -- cgit 1.2.3-korg