Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 1 | SUMMARY = "Virtual EtherDrive blade AoE target" |
| 2 | SECTION = "admin" |
| 3 | |
Andrew Geissler | 9aee500 | 2022-03-30 16:27:02 +0000 | [diff] [blame^] | 4 | LICENSE = "GPL-2.0-only" |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 5 | LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f" |
| 6 | |
Brad Bishop | c342db3 | 2019-05-15 21:57:59 -0400 | [diff] [blame] | 7 | UPSTREAM_CHECK_URI = "https://sourceforge.net/projects/aoetools/files/vblade/" |
| 8 | |
Andrew Geissler | 72956ed | 2021-01-08 16:11:14 -0600 | [diff] [blame] | 9 | SRCREV = "5f1a0ba8b9815e3f08a3e2635a17f78bbf2a5b10" |
Andrew Geissler | 595f630 | 2022-01-24 19:11:47 +0000 | [diff] [blame] | 10 | SRC_URI = "git://github.com/OpenAoE/vblade;branch=master;protocol=https \ |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 11 | file://cross.patch \ |
| 12 | file://makefile-add-ldflags.patch \ |
| 13 | file://${BPN}.conf \ |
| 14 | file://${BPN}.init \ |
| 15 | file://${BPN}.service \ |
| 16 | file://volatiles.99_vblade \ |
| 17 | " |
| 18 | |
Andrew Geissler | bffdb3e | 2020-08-21 16:13:29 -0500 | [diff] [blame] | 19 | S = "${WORKDIR}/git" |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 20 | |
Andrew Geissler | bffdb3e | 2020-08-21 16:13:29 -0500 | [diff] [blame] | 21 | UPSTREAM_CHECK_URI = "https://github.com/OpenAoE/vblade/archive/" |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 22 | |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 23 | inherit autotools-brokensep update-rc.d systemd |
| 24 | |
| 25 | do_install() { |
| 26 | install -D -m 0755 ${S}/vblade ${D}/${sbindir}/vblade |
| 27 | install -D -m 0755 ${S}/vbladed ${D}/${sbindir}/vbladed |
| 28 | install -D -m 0644 ${S}/vblade.8 ${D}/${mandir}/man8/vblade.8 |
| 29 | |
| 30 | install -D -m 0644 ${WORKDIR}/${BPN}.conf ${D}/${sysconfdir}/${BPN}.conf |
| 31 | install -D -m 0755 ${WORKDIR}/${BPN}.init ${D}/${sysconfdir}/init.d/${BPN} |
| 32 | |
| 33 | if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then |
| 34 | install -d ${D}/${sysconfdir}/default/volatiles |
| 35 | install -m 0755 ${WORKDIR}/volatiles.99_vblade ${D}/${sysconfdir}/default/volatiles/99_vblade |
| 36 | fi |
| 37 | |
| 38 | if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then |
| 39 | install -d ${D}/${bindir} |
| 40 | install -m 0755 ${WORKDIR}/${BPN}.init ${D}/${bindir}/ |
| 41 | install -d ${D}${sysconfdir}/tmpfiles.d |
| 42 | echo "d /var/run/${BPN} 0755 root root -" > ${D}${sysconfdir}/tmpfiles.d/${BPN}.conf |
| 43 | |
| 44 | install -d ${D}${systemd_system_unitdir} |
| 45 | install -m 0644 ${WORKDIR}/vblade.service ${D}${systemd_system_unitdir} |
| 46 | sed -e 's,@BINDIR@,${bindir},g' -i ${D}${systemd_system_unitdir}/*.service |
| 47 | fi |
| 48 | |
| 49 | } |
| 50 | |
| 51 | INITSCRIPT_NAME = "vblade" |
| 52 | INITSCRIPT_PARAMS = "start 30 . stop 70 0 1 2 3 4 5 6 ." |
| 53 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 54 | SYSTEMD_SERVICE:${PN} = "vblade.service" |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 55 | SYSTEMD_AUTO_ENABLE = "disable" |