From f3ee14a2ef601d0bbcf0d7f70dc23be3bacf29d3 Mon Sep 17 00:00:00 2001 From: Matthew Barth Date: Thu, 19 Aug 2021 10:48:58 -0500 Subject: meta-phosphor:fans:control: Enable JSON config install from repo Enable installing fan control's JSON config files into the image from the repository by machine name. Change-Id: I2d35783df55c5a154539972d70fb9564b5cb4038 Signed-off-by: Matthew Barth --- meta-phosphor/recipes-phosphor/fans/phosphor-fan_git.bb | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'meta-phosphor/recipes-phosphor/fans') diff --git a/meta-phosphor/recipes-phosphor/fans/phosphor-fan_git.bb b/meta-phosphor/recipes-phosphor/fans/phosphor-fan_git.bb index 0c018beab..ccf079b81 100644 --- a/meta-phosphor/recipes-phosphor/fans/phosphor-fan_git.bb +++ b/meta-phosphor/recipes-phosphor/fans/phosphor-fan_git.bb @@ -73,10 +73,11 @@ FILES:${PN}-presence-tach += "${@bb.utils.contains('PACKAGECONFIG', 'json', \ # -------------------------------------- # ${PN}-control specific configuration PACKAGECONFIG[control] = "--enable-control \ - FAN_DEF_YAML_FILE=${STAGING_DIR_HOST}${control_datadir}/fans.yaml \ - FAN_ZONE_YAML_FILE=${STAGING_DIR_HOST}${control_datadir}/zones.yaml \ - ZONE_EVENTS_YAML_FILE=${STAGING_DIR_HOST}${control_datadir}/events.yaml \ - ZONE_CONDITIONS_YAML_FILE=${STAGING_DIR_HOST}${control_datadir}/zone_conditions.yaml, \ + MACHINE=${PKG_DEFAULT_MACHINE} \ + FAN_DEF_YAML_FILE=${STAGING_DIR_HOST}${control_datadir}/fans.yaml \ + FAN_ZONE_YAML_FILE=${STAGING_DIR_HOST}${control_datadir}/zones.yaml \ + ZONE_EVENTS_YAML_FILE=${STAGING_DIR_HOST}${control_datadir}/events.yaml \ + ZONE_CONDITIONS_YAML_FILE=${STAGING_DIR_HOST}${control_datadir}/zone_conditions.yaml, \ --disable-control, \ virtual/phosphor-fan-control-fan-config \ phosphor-fan-control-zone-config \ @@ -110,6 +111,10 @@ SYSTEMD_LINK_${PN}-control += "${@bb.utils.contains('PACKAGECONFIG', 'json', \ compose_list(d, 'FMT_CONTROL_PWRON', 'OBMC_CHASSIS_INSTANCES'), \ compose_list(d, 'FMT_CONTROL_INIT', 'OBMC_CHASSIS_INSTANCES'), d)}" +# Package the JSON config files installed from the repo +FILES:${PN}-control += "${@bb.utils.contains('PACKAGECONFIG', 'json', \ + '${datadir}/phosphor-fan-presence/control/*', '', d)}" + # -------------------------------------- # ${PN}-monitor specific configuration PACKAGECONFIG[monitor] = "--enable-monitor \ -- cgit v1.2.3