blob: 7969af6c37da9069f125f67da6e9311f24728df7 [file] [log] [blame]
Brad Bishop19323692019-04-05 15:28:33 -04001SUMMARY = "A collection of cpuburn programs tuned for different ARM hardware"
2LICENSE = "MIT"
3LIC_FILES_CHKSUM = "file://cpuburn-a53.S;beginline=1;endline=22;md5=3b7ccd70144c16d3fe14ac491c2d4a87"
4
Patrick Williams213cb262021-08-07 19:21:33 -05005RPROVIDES:${PN} = "cpuburn-neon"
Brad Bishop19323692019-04-05 15:28:33 -04006PROVIDES += "cpuburn-neon"
7
8SRCREV = "ad7e646700d14b81413297bda02fb7fe96613c3f"
9
10PV = "1.0+git${SRCPV}"
11
Andrew Geissler595f6302022-01-24 19:11:47 +000012SRC_URI = "git://github.com/ssvb/cpuburn-arm.git;branch=master;protocol=https \
Brad Bishop19323692019-04-05 15:28:33 -040013 file://0001-cpuburn-a8.S-Remove-.func-.endfunc.patch \
14 file://0002-burn.S-Add.patch \
15 file://0003-burn.S-Remove-.func-.endfunc.patch \
16 "
17
18S = "${WORKDIR}/git"
19
20do_compile() {
Brad Bishopc8f47122019-06-24 09:36:18 -040021
22 # If the arch is set to ARM 64-bit - we only produce and ship burn-a53 version.
23 # In case of ARM 32-bit - we would build all variants, since burn-a53 supports both
24 # 32 and 64-bit builds
25 if ${@bb.utils.contains('TUNE_FEATURES', 'aarch64', 'true', 'false', d)}; then
26 ${CC} ${CFLAGS} ${LDFLAGS} cpuburn-a53.S -o burn-a53
27 else
28 ${CC} ${CFLAGS} ${LDFLAGS} burn.S -o burn
29 ${CC} ${CFLAGS} ${LDFLAGS} cpuburn-a7.S -o burn-a7
30 ${CC} ${CFLAGS} ${LDFLAGS} cpuburn-a8.S -o burn-a8
31 ${CC} ${CFLAGS} ${LDFLAGS} cpuburn-a9.S -o burn-a9
32 ${CC} ${CFLAGS} ${LDFLAGS} cpuburn-a53.S -o burn-a53
33 ${CC} ${CFLAGS} ${LDFLAGS} cpuburn-krait.S -o burn-krait
34 fi
Brad Bishop19323692019-04-05 15:28:33 -040035}
36
37do_install() {
38 install -d ${D}${bindir}
Brad Bishopc8f47122019-06-24 09:36:18 -040039
40 if ${@bb.utils.contains('TUNE_FEATURES', 'aarch64', 'true', 'false', d)}; then
41 install -m 0755 burn-a53 ${D}${bindir}
42 else
43 for f in burn burn-a7 burn-a8 burn-a9 burn-a53 burn-krait; do
44 install -m 0755 $f ${D}${bindir}/$f
45 done
46 fi
Brad Bishop19323692019-04-05 15:28:33 -040047}
48
49COMPATIBLE_MACHINE ?= "(^$)"
Patrick Williams213cb262021-08-07 19:21:33 -050050COMPATIBLE_MACHINE:armv7a = "(.*)"
51COMPATIBLE_MACHINE:armv7ve = "(.*)"
52COMPATIBLE_MACHINE:aarch64 = "(.*)"