summaryrefslogtreecommitdiffstats
path: root/meta-oe/recipes-kernel/kernel-selftest
diff options
context:
space:
mode:
Diffstat (limited to 'meta-oe/recipes-kernel/kernel-selftest')
-rw-r--r--meta-oe/recipes-kernel/kernel-selftest/kernel-selftest.bb22
1 files changed, 2 insertions, 20 deletions
diff --git a/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest.bb b/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest.bb
index dce33c16c..ff9720f8d 100644
--- a/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest.bb
+++ b/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest.bb
@@ -39,6 +39,7 @@ EXTRA_OEMAKE = '\
39 CROSS_COMPILE=${TARGET_PREFIX} \ 39 CROSS_COMPILE=${TARGET_PREFIX} \
40 ARCH=${ARCH} \ 40 ARCH=${ARCH} \
41 CC="${CC}" \ 41 CC="${CC}" \
42 CLANG="clang -fno-stack-protector" \
42 AR="${AR}" \ 43 AR="${AR}" \
43 LD="${LD}" \ 44 LD="${LD}" \
44 DESTDIR="${D}" \ 45 DESTDIR="${D}" \
@@ -52,16 +53,6 @@ KERNEL_SELFTEST_SRC ?= "Makefile \
52 LICENSES \ 53 LICENSES \
53" 54"
54 55
55python __anonymous () {
56 import re
57
58 var = d.getVar('TARGET_CC_ARCH')
59 pattern = '_FORTIFY_SOURCE=[^0]'
60
61 if re.search(pattern, var):
62 d.appendVar('TARGET_CC_ARCH', " -O")
63}
64
65do_compile() { 56do_compile() {
66 if [ ${@bb.utils.contains('DEPENDS', 'clang-native', 'True', 'False', d)} = 'False' ]; then 57 if [ ${@bb.utils.contains('DEPENDS', 'clang-native', 'True', 'False', d)} = 'False' ]; then
67 bbwarn "clang >= 6.0 with bpf support is needed with kernel 4.18+ so 58 bbwarn "clang >= 6.0 with bpf support is needed with kernel 4.18+ so
@@ -123,13 +114,4 @@ RDEPENDS_${PN} += "python3"
123# tools/testing/selftests/vm/Makefile doesn't respect LDFLAGS and tools/testing/selftests/Makefile explicitly overrides to empty 114# tools/testing/selftests/vm/Makefile doesn't respect LDFLAGS and tools/testing/selftests/Makefile explicitly overrides to empty
124INSANE_SKIP_${PN} += "ldflags" 115INSANE_SKIP_${PN} += "ldflags"
125 116
126# userfaultfd.c:126:2: error: format not a string literal and no format arguments [-Werror=format-security] 117SECURITY_CFLAGS = ""
127# fprintf(stderr, examples);
128# ^~~~~~~
129SECURITY_STRINGFORMAT = ""
130
131# https://errors.yoctoproject.org/Errors/Details/261657/
132# kernel-selftest/1.0-r0/recipe-sysroot/usr/include/bits/fcntl2.h:50:4: error: call to '__open_missing_mode' declared with attribute error: open with O_CREAT or O_TMPFILE in second argument needs 3 arguments
133# __open_missing_mode ();
134# ^~~~~~~~~~~~~~~~~~~~~~
135lcl_maybe_fortify = ""