Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 1 | SUMMARY = "Runs postinstall scripts on first boot of the target device" |
Andrew Geissler | 90fd73c | 2021-03-05 15:25:55 -0600 | [diff] [blame] | 2 | DESCRIPTION = "${SUMMARY}" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 3 | SECTION = "devel" |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 4 | PR = "r10" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 5 | LICENSE = "MIT" |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 6 | LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 7 | |
| 8 | SRC_URI = "file://run-postinsts \ |
| 9 | file://run-postinsts.init \ |
| 10 | file://run-postinsts.service" |
| 11 | |
| 12 | S = "${WORKDIR}" |
| 13 | |
| 14 | inherit allarch systemd update-rc.d |
| 15 | |
| 16 | INITSCRIPT_NAME = "run-postinsts" |
| 17 | INITSCRIPT_PARAMS = "start 99 S ." |
| 18 | |
| 19 | SYSTEMD_SERVICE_${PN} = "run-postinsts.service" |
| 20 | |
| 21 | do_configure() { |
| 22 | : |
| 23 | } |
| 24 | |
| 25 | do_compile () { |
| 26 | : |
| 27 | } |
| 28 | |
| 29 | do_install() { |
| 30 | install -d ${D}${sbindir} |
| 31 | install -m 0755 ${WORKDIR}/run-postinsts ${D}${sbindir}/ |
| 32 | |
| 33 | install -d ${D}${sysconfdir}/init.d/ |
| 34 | install -m 0755 ${WORKDIR}/run-postinsts.init ${D}${sysconfdir}/init.d/run-postinsts |
| 35 | |
| 36 | install -d ${D}${systemd_unitdir}/system/ |
| 37 | install -m 0644 ${WORKDIR}/run-postinsts.service ${D}${systemd_unitdir}/system/ |
| 38 | |
| 39 | sed -i -e 's:#SYSCONFDIR#:${sysconfdir}:g' \ |
| 40 | -e 's:#SBINDIR#:${sbindir}:g' \ |
| 41 | -e 's:#BASE_BINDIR#:${base_bindir}:g' \ |
| 42 | -e 's:#LOCALSTATEDIR#:${localstatedir}:g' \ |
| 43 | ${D}${sbindir}/run-postinsts \ |
| 44 | ${D}${systemd_unitdir}/system/run-postinsts.service |
| 45 | } |