diff options
| author | Kai Kang <kai.kang@windriver.com> | 2018-09-02 19:20:07 -0700 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2018-09-05 18:00:25 +0100 |
| commit | 3beda3d9219d7110caae960044847cde28788f44 (patch) | |
| tree | 771f592499bfd4c03c850c9aff3437caf83d2347 | |
| parent | eadd66da9b32be7ad7072c1909dc28b2dae65b48 (diff) | |
| download | poky-3beda3d9219d7110caae960044847cde28788f44.tar.gz | |
lttng-tools: add systemd support
Add systemd service file of lttng-tools from Fedora
ftp://fr2.rpmfind.net/linux/fedora/linux/development/rawhide
/Everything/source/tree/Packages/l/lttng-tools-2.10.5-1.fc29.src.rpm
It requires kernel configs CONFIG_STAGING and CONFIG_LTTNG2 to be set.
But linux-yocto doesn't meet the requirement. So disable the service by
default.
(From OE-Core rev: 29bc046d705beb9dac2e70fa31358da7719ba7a4)
Signed-off-by: Kai Kang <kai.kang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
| -rw-r--r-- | meta/recipes-kernel/lttng/lttng-tools/lttng-sessiond.service | 9 | ||||
| -rw-r--r-- | meta/recipes-kernel/lttng/lttng-tools_2.9.5.bb | 12 |
2 files changed, 20 insertions, 1 deletions
diff --git a/meta/recipes-kernel/lttng/lttng-tools/lttng-sessiond.service b/meta/recipes-kernel/lttng/lttng-tools/lttng-sessiond.service new file mode 100644 index 0000000000..aaf8130592 --- /dev/null +++ b/meta/recipes-kernel/lttng/lttng-tools/lttng-sessiond.service | |||
| @@ -0,0 +1,9 @@ | |||
| 1 | [Unit] | ||
| 2 | Description=LTTng 2.x central tracing registry session daemon | ||
| 3 | |||
| 4 | [Service] | ||
| 5 | Type=forking | ||
| 6 | ExecStart=/usr/bin/lttng-sessiond -d | ||
| 7 | |||
| 8 | [Install] | ||
| 9 | WantedBy=multi-user.target | ||
diff --git a/meta/recipes-kernel/lttng/lttng-tools_2.9.5.bb b/meta/recipes-kernel/lttng/lttng-tools_2.9.5.bb index e4969c3080..0314b53637 100644 --- a/meta/recipes-kernel/lttng/lttng-tools_2.9.5.bb +++ b/meta/recipes-kernel/lttng/lttng-tools_2.9.5.bb | |||
| @@ -31,12 +31,16 @@ SRC_URI = "https://lttng.org/files/lttng-tools/lttng-tools-${PV}.tar.bz2 \ | |||
| 31 | file://x32.patch \ | 31 | file://x32.patch \ |
| 32 | file://run-ptest \ | 32 | file://run-ptest \ |
| 33 | file://0001-Allow-multiple-attempts-to-connect-to-relayd.patch \ | 33 | file://0001-Allow-multiple-attempts-to-connect-to-relayd.patch \ |
| 34 | file://lttng-sessiond.service \ | ||
| 34 | " | 35 | " |
| 35 | 36 | ||
| 36 | SRC_URI[md5sum] = "051224eb991aee07f8721ff1877d0b96" | 37 | SRC_URI[md5sum] = "051224eb991aee07f8721ff1877d0b96" |
| 37 | SRC_URI[sha256sum] = "77839eb6fc6c652125f08acfd9369701c2516eb05cc2084160e7efc7a3fb731c" | 38 | SRC_URI[sha256sum] = "77839eb6fc6c652125f08acfd9369701c2516eb05cc2084160e7efc7a3fb731c" |
| 38 | 39 | ||
| 39 | inherit autotools ptest pkgconfig useradd python3-dir manpages | 40 | inherit autotools ptest pkgconfig useradd python3-dir manpages systemd |
| 41 | |||
| 42 | SYSTEMD_SERVICE_${PN} = "lttng-sessiond.service" | ||
| 43 | SYSTEMD_AUTO_ENABLE = "disable" | ||
| 40 | 44 | ||
| 41 | USERADD_PACKAGES = "${PN}" | 45 | USERADD_PACKAGES = "${PN}" |
| 42 | GROUPADD_PARAM_${PN} = "tracing" | 46 | GROUPADD_PARAM_${PN} = "tracing" |
| @@ -52,6 +56,12 @@ FILES_${PN}-dev += "${PYTHON_SITEPACKAGES_DIR}/*.la" | |||
| 52 | INSANE_SKIP_${PN} = "libexec dev-so" | 56 | INSANE_SKIP_${PN} = "libexec dev-so" |
| 53 | INSANE_SKIP_${PN}-dbg = "libexec" | 57 | INSANE_SKIP_${PN}-dbg = "libexec" |
| 54 | 58 | ||
| 59 | do_install_append () { | ||
| 60 | # install systemd unit file | ||
| 61 | install -d ${D}${systemd_unitdir}/system | ||
| 62 | install -m 0644 ${WORKDIR}/lttng-sessiond.service ${D}${systemd_unitdir}/system | ||
| 63 | } | ||
| 64 | |||
| 55 | do_install_ptest () { | 65 | do_install_ptest () { |
| 56 | for f in Makefile tests/Makefile tests/utils/utils.sh ; do | 66 | for f in Makefile tests/Makefile tests/utils/utils.sh ; do |
| 57 | install -D "${B}/$f" "${D}${PTEST_PATH}/$f" | 67 | install -D "${B}/$f" "${D}${PTEST_PATH}/$f" |
