Brandon Kim | 0547cc4 | 2021-07-20 15:59:47 -0700 | [diff] [blame] | 1 | SUMMARY = "Google BMC Inplace Update Script" |
| 2 | DESCRIPTION = "Google BMC Inplace Update Script" |
| 3 | PR = "r1" |
| 4 | |
| 5 | LICENSE = "Apache-2.0" |
| 6 | LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10" |
| 7 | |
| 8 | inherit obmc-phosphor-systemd |
| 9 | |
| 10 | PROVIDES += "virtual/bmc-update" |
Willy Tu | 4dd03ca | 2021-08-06 09:37:35 -0700 | [diff] [blame] | 11 | RPROVIDES:${PN} += "virtual/bmc-update" |
Brandon Kim | 0547cc4 | 2021-07-20 15:59:47 -0700 | [diff] [blame] | 12 | |
William A. Kennington III | 32e440d | 2021-12-03 18:19:07 -0800 | [diff] [blame] | 13 | RDEPENDS:${PN} += " \ |
| 14 | bash \ |
| 15 | gbmc-update \ |
| 16 | google-key \ |
| 17 | " |
Brandon Kim | 0547cc4 | 2021-07-20 15:59:47 -0700 | [diff] [blame] | 18 | |
| 19 | SRC_URI += " \ |
| 20 | file://config-bmc.json \ |
| 21 | file://inplace-gbmc-verify.service \ |
| 22 | file://inplace-gbmc-verify.sh \ |
| 23 | file://inplace-gbmc-version.service \ |
| 24 | file://inplace-gbmc-version.sh \ |
William A. Kennington III | 32e440d | 2021-12-03 18:19:07 -0800 | [diff] [blame] | 25 | file://75-inplace-gbmc-upgrade.sh \ |
Brandon Kim | 0547cc4 | 2021-07-20 15:59:47 -0700 | [diff] [blame] | 26 | " |
| 27 | |
Willy Tu | 4dd03ca | 2021-08-06 09:37:35 -0700 | [diff] [blame] | 28 | SYSTEMD_SERVICE:${PN} += "inplace-gbmc-verify.service" |
| 29 | SYSTEMD_SERVICE:${PN} += "inplace-gbmc-version.service" |
Brandon Kim | 0547cc4 | 2021-07-20 15:59:47 -0700 | [diff] [blame] | 30 | |
Willy Tu | 4dd03ca | 2021-08-06 09:37:35 -0700 | [diff] [blame] | 31 | FILES:${PN} += "${datadir}/phosphor-ipmi-flash" |
William A. Kennington III | 32e440d | 2021-12-03 18:19:07 -0800 | [diff] [blame] | 32 | FILES:${PN} += "${datadir}/gbmc-br-dhcp" |
Brandon Kim | 0547cc4 | 2021-07-20 15:59:47 -0700 | [diff] [blame] | 33 | |
| 34 | do_install() { |
| 35 | sed -i 's,@ALLOW_DEV@,,' ${WORKDIR}/inplace-gbmc-verify.sh |
| 36 | |
| 37 | install -d ${D}${bindir} |
| 38 | install -m 0755 ${WORKDIR}/*.sh ${D}${bindir} |
| 39 | |
| 40 | install -d ${D}${systemd_system_unitdir} |
| 41 | install -m 0644 ${WORKDIR}/*.service ${D}${systemd_system_unitdir} |
| 42 | |
| 43 | install -d ${D}${datadir}/phosphor-ipmi-flash |
| 44 | install -m 0644 ${WORKDIR}/config-bmc.json ${D}${datadir}/phosphor-ipmi-flash |
William A. Kennington III | 32e440d | 2021-12-03 18:19:07 -0800 | [diff] [blame] | 45 | |
| 46 | install -d ${D}${datadir}/gbmc-br-dhcp |
| 47 | install -m 0644 ${WORKDIR}/75-inplace-gbmc-upgrade.sh ${D}${datadir}/gbmc-br-dhcp/ |
Brandon Kim | 0547cc4 | 2021-07-20 15:59:47 -0700 | [diff] [blame] | 48 | } |
| 49 | |
Willy Tu | 4dd03ca | 2021-08-06 09:37:35 -0700 | [diff] [blame] | 50 | do_install:prepend:dev() { |
Brandon Kim | 0547cc4 | 2021-07-20 15:59:47 -0700 | [diff] [blame] | 51 | sed -i 's,@ALLOW_DEV@,--allow-dev,' ${WORKDIR}/inplace-gbmc-verify.sh |
| 52 | } |