blob: e9456cb9f7a1d48abde26282ff8c747691719d75 [file] [log] [blame]
Eddie Jamesacd9d072022-01-24 15:42:34 -06001SUMMARY = "Enable Linux trace events"
2DESCRIPTION = "Enable Linux trace events based on a configuration file"
3LICENSE = "Apache-2.0"
4LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10"
5
Eddie Jamesacd9d072022-01-24 15:42:34 -06006SRC_URI += " file://trace-enable"
7
Ed Tanous9936f862022-09-19 09:13:20 -07008S = "${WORKDIR}"
9SYSTEMD_SERVICE:${PN} = "trace-enable.service"
Eddie Jamesacd9d072022-01-24 15:42:34 -060010
Ed Tanous9936f862022-09-19 09:13:20 -070011inherit obmc-phosphor-systemd
Eddie Jamesacd9d072022-01-24 15:42:34 -060012
13do_install:append() {
14 install -d ${D}${sysconfdir}
15 for event in ${TRACE_EVENTS}
16 do
17 echo ${event} >> ${D}${sysconfdir}/trace-events.conf
18 done
19 echo >> ${D}${sysconfdir}/trace-events.conf
20 chmod 0644 ${D}${sysconfdir}/trace-events.conf
Eddie Jamesacd9d072022-01-24 15:42:34 -060021 install -d ${D}${libexecdir}
22 install -m 0755 ${WORKDIR}/trace-enable ${D}${libexecdir}
23}
24
Ed Tanous9936f862022-09-19 09:13:20 -070025RDEPENDS:${PN} = " \
26 ${@d.getVar('PREFERRED_PROVIDER_u-boot-fw-utils', True) or 'u-boot-fw-utils'} \
27 bash \
28"
Eddie Jamesacd9d072022-01-24 15:42:34 -060029
Ed Tanous9936f862022-09-19 09:13:20 -070030FILES:${PN} += "${sysconfdir}/trace-events.conf"
31FILES:${PN} += "${libexecdir}/trace-enable"
32
33TRACE_EVENTS = ""