Gunnar Mills | 8c6516f | 2017-10-04 15:38:33 -0500 | [diff] [blame] | 1 | # Generates MRW settings override yaml for phosphor-settings-manager |
| 2 | # The default YAML file, mrw-override-settings.yaml, is empty, therefore no |
| 3 | # settings will be overwritten. To override, modify mrw-override-settings.yaml. |
| 4 | |
| 5 | SUMMARY = "Generates MRW settings override YAML for phosphor-settings-manager." |
| 6 | PR = "r1" |
Brad Bishop | 75f0387 | 2018-11-03 09:41:57 -0700 | [diff] [blame] | 7 | LICENSE = "Apache-2.0" |
Brad Bishop | 6f3f0aa | 2019-09-13 12:14:05 -0400 | [diff] [blame] | 8 | LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10" |
Gunnar Mills | 8c6516f | 2017-10-04 15:38:33 -0500 | [diff] [blame] | 9 | |
Gunnar Mills | 8c6516f | 2017-10-04 15:38:33 -0500 | [diff] [blame] | 10 | inherit phosphor-settings-manager |
Matt Spinler | 0a8ea63 | 2017-12-14 13:31:55 -0600 | [diff] [blame] | 11 | inherit mrw-xml |
Joseph Reynolds | 79809ea | 2021-02-26 15:37:31 -0600 | [diff] [blame] | 12 | inherit native |
Gunnar Mills | 8c6516f | 2017-10-04 15:38:33 -0500 | [diff] [blame] | 13 | |
Gunnar Mills | 8c6516f | 2017-10-04 15:38:33 -0500 | [diff] [blame] | 14 | DEPENDS += "mrw-native mrw-perl-tools-native" |
| 15 | |
| 16 | SRC_URI += "file://mrw-override-settings.yaml" |
| 17 | |
| 18 | S = "${WORKDIR}" |
| 19 | |
Matt Spinler | 8280d07 | 2018-03-09 11:04:05 -0600 | [diff] [blame] | 20 | MRW_EXPRESSION_VARS ?= "" |
| 21 | |
Gunnar Mills | 8c6516f | 2017-10-04 15:38:33 -0500 | [diff] [blame] | 22 | do_install() { |
| 23 | DEST=${D}${config_datadir} |
| 24 | install -D mrw-override-settings.yaml ${DEST}/mrw-override-settings.yaml |
| 25 | |
| 26 | SETTINGS=${D}${settings_datadir} |
| 27 | install -d ${SETTINGS} |
| 28 | |
| 29 | # gen_settings.pl replaces any MRW variables with their value |
| 30 | ${bindir}/perl-native/perl \ |
| 31 | ${bindir}/gen_settings.pl \ |
Matt Spinler | 0a8ea63 | 2017-12-14 13:31:55 -0600 | [diff] [blame] | 32 | -i ${mrw_datadir}/${MRW_XML} \ |
Gunnar Mills | 8c6516f | 2017-10-04 15:38:33 -0500 | [diff] [blame] | 33 | -s ${DEST}/mrw-override-settings.yaml \ |
| 34 | -o ${SETTINGS}/mrw-settings.override.yaml \ |
Matt Spinler | 8280d07 | 2018-03-09 11:04:05 -0600 | [diff] [blame] | 35 | ${MRW_EXPRESSION_VARS} \ |
Gunnar Mills | 8c6516f | 2017-10-04 15:38:33 -0500 | [diff] [blame] | 36 | -f |
| 37 | } |