summaryrefslogtreecommitdiffstats
path: root/meta/recipes-kernel/oprofile/oprofileui-server_git.bb
blob: 70a1fbf9c345c7ef6ec8dd2ed0d8a0c06f94e057 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
require oprofileui.inc

SRCREV = "f168b8bfdc63660033de1739c6ddad1abd97c379"
PV = "0.0+git${SRCPV}"

S = "${WORKDIR}/git"

SRC_URI = "git://git.yoctoproject.org/oprofileui \
           file://init \
           file://oprofileui-server.service "

EXTRA_OECONF += "--disable-client --enable-server"

RDEPENDS_${PN} = "oprofile"

do_install_append() {
	install -d ${D}${sysconfdir}/init.d
	install -m 0755 ${WORKDIR}/init ${D}${sysconfdir}/init.d/oprofileui-server

	install -d ${D}${systemd_unitdir}/system
	install -m 0644 ${WORKDIR}/oprofileui-server.service ${D}${systemd_unitdir}/system/
	sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g' \
		-e 's,@BINDIR@,${bindir},g' ${D}${systemd_unitdir}/system/oprofileui-server.service
}

inherit update-rc.d systemd

INITSCRIPT_NAME = "oprofileui-server"
INITSCRIPT_PARAMS = "start 999 5 2 . stop 20 0 1 6 ."

SYSTEMD_SERVICE_${PN} = "oprofileui-server.service"
SYSTEMD_AUTO_ENABLE = "disable"