diff options
author | Ross Burton <ross@burtonini.com> | 2021-03-08 18:01:52 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2021-03-10 10:29:44 +0000 |
commit | b3e3eba796b843021b264f0e98dc30f983775d58 (patch) | |
tree | 8210bd5090dea9bc365edd188934198eb2a409b7 /meta-selftest | |
parent | d039d6fbfc9076f081173f6e5cc63c56fe3a5adb (diff) | |
download | openembedded-core-b3e3eba796b843021b264f0e98dc30f983775d58.tar.gz |
oeqa/selftest: add test to verify that poisoned sysroots are detected
Add a recipe that explicitly searches /usr/include, and use that in
oe-selftest to verify that host include paths are correctly causing
build failures.
Signed-off-by: Ross Burton <ross.burton@arm.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta-selftest')
-rw-r--r-- | meta-selftest/recipes-test/poison/poison.bb | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/meta-selftest/recipes-test/poison/poison.bb b/meta-selftest/recipes-test/poison/poison.bb new file mode 100644 index 0000000000..7ace901cc3 --- /dev/null +++ b/meta-selftest/recipes-test/poison/poison.bb @@ -0,0 +1,16 @@ +SUMMARY = "Sysroot poisoning test" +LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302" + +LICENSE = "MIT" + +inherit nopackages + +# This test confirms that compiling code that searches /usr/include for headers +# will result in compiler errors. This recipe should will fail to build and +# oe-selftest has a test that verifies that. +do_compile() { + touch empty.c + ${CPP} ${CFLAGS} -I/usr/include empty.c +} + +EXCLUDE_FROM_WORLD = "1" |