diff options
Diffstat (limited to 'recipes-kernel/kselftests/kselftests_4.4.bb')
-rw-r--r-- | recipes-kernel/kselftests/kselftests_4.4.bb | 88 |
1 files changed, 88 insertions, 0 deletions
diff --git a/recipes-kernel/kselftests/kselftests_4.4.bb b/recipes-kernel/kselftests/kselftests_4.4.bb new file mode 100644 index 00000000..3cdf4f10 --- /dev/null +++ b/recipes-kernel/kselftests/kselftests_4.4.bb | |||
@@ -0,0 +1,88 @@ | |||
1 | SUMMARY = "Linux Kernel Selftests" | ||
2 | LICENSE = "GPLv2" | ||
3 | LIC_FILES_CHKSUM = "file://COPYING;md5=d7810fab7487fb0aad327b76f1be7cd7" | ||
4 | |||
5 | SRC_URI = "https://www.kernel.org/pub/linux/kernel/v4.x/linux-${PV}.tar.xz" | ||
6 | |||
7 | SRC_URI[md5sum] = "9a78fa2eb6c68ca5a40ed5af08142599" | ||
8 | SRC_URI[sha256sum] = "401d7c8fef594999a460d10c72c5a94e9c2e1022f16795ec51746b0d165418b2" | ||
9 | |||
10 | S = "${WORKDIR}/linux-${PV}" | ||
11 | |||
12 | PACKAGE_ARCH = "${MACHINE_ARCH}" | ||
13 | |||
14 | DEPENDS = "popt" | ||
15 | |||
16 | inherit kernel-arch | ||
17 | |||
18 | TARGETS = "cpu-hotplug efivarfs exec firmware ftrace kcmp memfd memory-hotplug \ | ||
19 | mount mqueue net ptrace size sysctl timers user vm" | ||
20 | |||
21 | # Arch specific tests | ||
22 | TARGETS_append_x86 = " breakpoints ipc x86" | ||
23 | TARGETS_append_x86-64 = " breakpoints ipc x86" | ||
24 | TARGETS_append_powerpc = " powerpc" | ||
25 | TARGETS_append_powerpc64 = " powerpc" | ||
26 | |||
27 | EXTRA_OEMAKE += "-C tools/testing/selftests TARGETS="${TARGETS}" INSTALL_PATH=${D}${bindir}/kselftests CC="${CC}"" | ||
28 | |||
29 | # Their Makefiles are so sloppy, let's clean up a bit | ||
30 | do_configure () { | ||
31 | sed "s|^CC := .*||g" -i ${S}/tools/testing/selftests/lib.mk | ||
32 | sed "s|^CC = .*||g" -i ${S}/tools/testing/selftests/timers/Makefile | ||
33 | sed "s|^CC = .*||g" -i ${S}/tools/testing/selftests/memfd/Makefile | ||
34 | sed "s|^CC := .*||g" -i ${S}/tools/testing/selftests/powerpc/switch_endian/Makefile | ||
35 | sed "s|gcc|\$(CC)|g" -i ${S}/tools/testing/selftests/breakpoints/Makefile | ||
36 | sed "s|^LDFLAGS += -lrt -lpthread|LDLIBS += -lrt -lpthread|g" -i ${S}/tools/testing/selftests/timers/Makefile | ||
37 | } | ||
38 | |||
39 | do_compile () { | ||
40 | oe_runmake | ||
41 | } | ||
42 | |||
43 | do_install () { | ||
44 | oe_runmake install | ||
45 | } | ||
46 | |||
47 | PACKAGE_BEFORE_PN = "${PN}-breakpoints ${PN}-cpu-hotplug ${PN}-efivarfs ${PN}-exec ${PN}-firmware ${PN}-ftrace \ | ||
48 | ${PN}-ipc ${PN}-kcmp ${PN}-memfd ${PN}-memory-hotplug ${PN}-mount ${PN}-mqueue ${PN}-net ${PN}-powerpc \ | ||
49 | ${PN}-ptrace ${PN}-size ${PN}-sysctl ${PN}-timers ${PN}-user ${PN}-vm ${PN}-x86" | ||
50 | |||
51 | FILES_${PN}-breakpoints = "${bindir}/kselftests/breakpoints" | ||
52 | FILES_${PN}-cpu-hotplug = "${bindir}/kselftests/cpu-hotplug" | ||
53 | FILES_${PN}-efivarfs = "${bindir}/kselftests/efivarfs" | ||
54 | FILES_${PN}-exec = "${bindir}/kselftests/exec" | ||
55 | FILES_${PN}-firmware = "${bindir}/kselftests/firmware" | ||
56 | FILES_${PN}-ftrace = "${bindir}/kselftests/ftrace" | ||
57 | FILES_${PN}-ipc = "${bindir}/kselftests/ipc" | ||
58 | FILES_${PN}-kcmp = "${bindir}/kselftests/kcmp" | ||
59 | FILES_${PN}-memfd = "${bindir}/kselftests/memfd" | ||
60 | FILES_${PN}-memory-hotplug = "${bindir}/kselftests/memory-hotplug" | ||
61 | FILES_${PN}-mount = "${bindir}/kselftests/mount" | ||
62 | FILES_${PN}-mqueue = "${bindir}/kselftests/mqueue" | ||
63 | FILES_${PN}-net = "${bindir}/kselftests/net" | ||
64 | FILES_${PN}-powerpc = "${bindir}/kselftests/powerpc" | ||
65 | FILES_${PN}-ptrace = "${bindir}/kselftests/ptrace" | ||
66 | FILES_${PN}-size = "${bindir}/kselftests/size" | ||
67 | FILES_${PN}-sysctl = "${bindir}/kselftests/sysctl" | ||
68 | FILES_${PN}-timers = "${bindir}/kselftests/timers" | ||
69 | FILES_${PN}-user = "${bindir}/kselftests/user" | ||
70 | FILES_${PN}-vm = "${bindir}/kselftests/vm" | ||
71 | FILES_${PN}-x86 = "${bindir}/kselftests/x86" | ||
72 | FILES_${PN}-dbg += "${bindir}/kselftests/*/.debug" | ||
73 | |||
74 | RDEPENDS_${PN}-cpu-hotplug += "bash" | ||
75 | RDEPENDS_${PN}-efivarfs += "bash" | ||
76 | RDEPENDS_${PN}-memory-hotplug += "bash" | ||
77 | RDEPENDS_${PN}-net += "bash" | ||
78 | RDEPENDS_${PN}-vm += "bash" | ||
79 | RDEPENDS_${PN} += "bash ${PN}-cpu-hotplug ${PN}-efivarfs ${PN}-exec ${PN}-firmware ${PN}-ftrace \ | ||
80 | ${PN}-kcmp ${PN}-memfd ${PN}-memory-hotplug ${PN}-mount ${PN}-mqueue ${PN}-net ${PN}-ptrace \ | ||
81 | ${PN}-size ${PN}-sysctl ${PN}-timers ${PN}-user ${PN}-vm" | ||
82 | |||
83 | RDEPENDS_${PN}_append_x86 = " ${PN}-breakpoints ${PN}-ipc ${PN}-x86" | ||
84 | RDEPENDS_${PN}_append_x86-64 = " ${PN}-breakpoints ${PN}-ipc ${PN}-x86" | ||
85 | RDEPENDS_${PN}_append_powerpc = " ${PN}-powerpc" | ||
86 | RDEPENDS_${PN}_append_powerpc64 = " ${PN}-powerpc" | ||
87 | |||
88 | INSANE_SKIP_${PN} = "already-stripped" | ||