diff options
author | dengke.du@windriver.com <dengke.du@windriver.com> | 2016-09-28 16:36:26 +0800 |
---|---|---|
committer | Martin Jansa <Martin.Jansa@gmail.com> | 2016-10-05 18:20:49 +0200 |
commit | ba54b98daf377c778eb78d0b86437388514104c4 (patch) | |
tree | dc447618c879a703ae5ac89f7a9c5f7354bdeacf | |
parent | 6ee4e5379e205ebf72eb188a64e8220e09c32510 (diff) | |
download | meta-openembedded-ba54b98daf377c778eb78d0b86437388514104c4.tar.gz |
edac-utils: add systemd support and required dependencies for edac
Changed in V2:
Change the title to eliminate confused.
Add systemd unit files for edac-utils.
Signed-off-by: Dengke Du <dengke.du@windriver.com>
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
-rw-r--r-- | meta-oe/recipes-support/edac-utils/edac-utils_git.bb | 14 | ||||
-rw-r--r-- | meta-oe/recipes-support/edac-utils/files/edac.service | 11 |
2 files changed, 24 insertions, 1 deletions
diff --git a/meta-oe/recipes-support/edac-utils/edac-utils_git.bb b/meta-oe/recipes-support/edac-utils/edac-utils_git.bb index c0ad6656d..b3ff1cc2c 100644 --- a/meta-oe/recipes-support/edac-utils/edac-utils_git.bb +++ b/meta-oe/recipes-support/edac-utils/edac-utils_git.bb | |||
@@ -14,9 +14,10 @@ S = "${WORKDIR}/git" | |||
14 | SRC_URI = "git://github.com/grondo/edac-utils \ | 14 | SRC_URI = "git://github.com/grondo/edac-utils \ |
15 | file://make-init-script-be-able-to-automatically-load-EDAC-.patch \ | 15 | file://make-init-script-be-able-to-automatically-load-EDAC-.patch \ |
16 | file://add-restart-to-initscript.patch \ | 16 | file://add-restart-to-initscript.patch \ |
17 | file://edac.service \ | ||
17 | " | 18 | " |
18 | 19 | ||
19 | inherit autotools-brokensep | 20 | inherit autotools-brokensep systemd |
20 | 21 | ||
21 | do_configure_prepend () { | 22 | do_configure_prepend () { |
22 | touch ${S}/ChangeLog | 23 | touch ${S}/ChangeLog |
@@ -31,4 +32,15 @@ RDEPENDS_${PN}_powerpc = "dmidecode" | |||
31 | RDEPENDS_${PN}_powerpc64 = "dmidecode" | 32 | RDEPENDS_${PN}_powerpc64 = "dmidecode" |
32 | RDEPENDS_${PN}_append = " \ | 33 | RDEPENDS_${PN}_append = " \ |
33 | perl-module-file-basename perl-module-file-find perl-module-getopt-long perl-module-posix \ | 34 | perl-module-file-basename perl-module-file-find perl-module-getopt-long perl-module-posix \ |
35 | perl-module-overload \ | ||
36 | perl-module-overloading \ | ||
37 | perl-module-file-glob \ | ||
34 | " | 38 | " |
39 | |||
40 | do_install_append() { | ||
41 | install -d ${D}${systemd_unitdir}/system | ||
42 | install -m 644 ${WORKDIR}/edac.service ${D}/${systemd_unitdir}/system | ||
43 | sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}/${systemd_unitdir}/system/edac.service | ||
44 | } | ||
45 | |||
46 | SYSTEMD_SERVICE_${PN} = "edac.service" | ||
diff --git a/meta-oe/recipes-support/edac-utils/files/edac.service b/meta-oe/recipes-support/edac-utils/files/edac.service new file mode 100644 index 000000000..9f687a8af --- /dev/null +++ b/meta-oe/recipes-support/edac-utils/files/edac.service | |||
@@ -0,0 +1,11 @@ | |||
1 | [Unit] | ||
2 | Description=Initialize EDAC Drivers For Machine Hardware | ||
3 | |||
4 | [Service] | ||
5 | Type=oneshot | ||
6 | ExecStart=@SBINDIR@/edac-ctl --register-labels | ||
7 | ExecStop=@SBINDIR@/edac-ctl --unload | ||
8 | RemainAfterExit=yes | ||
9 | |||
10 | [Install] | ||
11 | WantedBy=multi-user.target | ||