blob: ce3f6ed9de218baf23a114ae380c2fa1b5f4f9e2 [file] [log] [blame]
Matt Spinler23f28832016-09-07 13:39:18 -05001SUMMARY = "Phosphor Inventory Generation"
2DESCRIPTION = "Generates inventory data from the machine readable workbook"
3PR = "r1"
4
5S = "${WORKDIR}/git"
6
Matt Spinler6f5fba12016-09-13 16:20:01 -05007PROVIDES += "virtual/obmc-inventory-data"
8RPROVIDES_${PN} += "virtual-obmc-inventory-data"
Matt Spinler23f28832016-09-07 13:39:18 -05009
10inherit allarch
11inherit obmc-phosphor-license
Patrick Williamsd30c9292016-10-31 15:45:17 -050012inherit mrw-rev
Matt Spinler23f28832016-09-07 13:39:18 -050013
14DEPENDS += "mrw-native mrw-api-native"
15
Patrick Williamsd30c9292016-10-31 15:45:17 -050016SRC_URI += "${MRW_PATCH_SRC_URI}"
17SRCREV = "${MRW_PATCH_SRCREV}"
Matt Spinler23f28832016-09-07 13:39:18 -050018
19FILES_${PN} += "${datadir}/inventory"
20
21do_compile() {
22 ${STAGING_BINDIR_NATIVE}/perl-native/perl ${S}/inventory.pl \
23 -x ${STAGING_DATADIR_NATIVE}/obmc-mrw/${MACHINE}.xml -o inventory.json
24}
25
26do_install() {
27 install -d ${D}${datadir}/inventory
28 install -m 0644 inventory.json ${D}${datadir}/inventory/inventory.json
29}