meta-ibm: witherspoon: fans: switch to non-native
meta-phosphor recently enabled target class config recipes. Those are
preferable to native class config recipes because native recipes cannot
be overridden based on MACHINE, so switch to target class config
recipes.
Switching to target class recipes consists of temporarily setting
PHOSPHOR_FAN_CONFIG_USE_NATIVE_SYSROOT to 0, overriding the phosphor
distro default of 1. After all OpenBMC BSP layers have moved to target
class config recipes PHOSPHOR_FAN_CONFIG_USE_NATIVE_SYSROOT can be
removed from meta-phosphor and any BSP layers.
Any references to -native recipes are replaced with their target class
counterparts.
Any -native bbappends are re-worked to apply to their target class
counterparts.
Finally, use BPN instead of PN when setting FILESEXTRAPATHS, to avoid
unfortunate directory hierarchies if these bbappends are copy/pasted and
then used to bbappend a native recipe. Since this patch moves to target
class recipes, this is a noop; however, this avoids unfortunate
directory hierarchies with native bbappends such as:
meta-base/recipes-foo/bar/baz-native.bb
meta-base/recipes-foo/bar/baz/a-file
meta-append/recipes-foo/bar/baz-native.bbappend
meta-append/recipes-foo/bar/baz-native/b-file
Using "${THISDIR}/${BPN}:" enables a more sensible hierarchy:
meta-base/recipes-foo/bar/baz-native.bb
meta-base/recipes-foo/bar/baz/a-file
meta-append/recipes-foo/bar/baz-native.bbappend
meta-append/recipes-foo/bar/baz/b-file
This behavior occurs because By default FILESPATH is set in base.bbclass
(in OE-Core) to look for files in ${BP}, ${BPN} and files (and a number
of subdirectories of those based on ${FILESOVERRIDES}).
(From meta-ibm rev: 6587e6ca03ca50411bc11cf87b5e11971dfe343f)
Change-Id: Ib2c3f0052c1e01a84416da2eb868a54d8810e750
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
diff --git a/meta-ibm/meta-witherspoon/conf/machine/witherspoon.conf b/meta-ibm/meta-witherspoon/conf/machine/witherspoon.conf
index c6f9434..c5af218 100644
--- a/meta-ibm/meta-witherspoon/conf/machine/witherspoon.conf
+++ b/meta-ibm/meta-witherspoon/conf/machine/witherspoon.conf
@@ -2,6 +2,7 @@
KERNEL_DEVICETREE = "${KMACHINE}-bmc-opp-${MACHINE}.dtb"
KERNEL_FEATURES_append = " phosphor-wdt-on-panic"
+PHOSPHOR_FAN_CONFIG_USE_NATIVE_SYSROOT = "0"
UBOOT_MACHINE = "ast_g5_ncsi_config"
OBMC_POWER_SUPPLY_INSTANCES = "0 1"
@@ -23,8 +24,8 @@
# Inhibit phosphor-fan-presence-mrw-native
PREFERRED_PROVIDER_virtual/phosphor-fan-presence-config_df-mrw = \
- "phosphor-fan-presence-config-native"
+ "phosphor-fan-presence-config"
# Inhibit phosphor-fan-control-fan-config-mrw-native
PREFERRED_PROVIDER_virtual/phosphor-fan-control-fan-config_df-mrw = \
- "phosphor-fan-control-fan-config-native"
+ "phosphor-fan-control-fan-config"
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-events-config-native.bbappend b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-events-config-native.bbappend
deleted file mode 100644
index 72d991c..0000000
--- a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-events-config-native.bbappend
+++ /dev/null
@@ -1 +0,0 @@
-FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-events-config.bbappend b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-events-config.bbappend
new file mode 100644
index 0000000..8f2097c
--- /dev/null
+++ b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-events-config.bbappend
@@ -0,0 +1 @@
+FILESEXTRAPATHS_prepend := "${THISDIR}/${BPN}:"
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-events-config-native/witherspoon/events.yaml b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-events-config/witherspoon/events.yaml
similarity index 100%
rename from meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-events-config-native/witherspoon/events.yaml
rename to meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-events-config/witherspoon/events.yaml
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-fan-config-native.bbappend b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-fan-config-native.bbappend
deleted file mode 100644
index 72d991c..0000000
--- a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-fan-config-native.bbappend
+++ /dev/null
@@ -1 +0,0 @@
-FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-fan-config.bbappend b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-fan-config.bbappend
new file mode 100644
index 0000000..8f2097c
--- /dev/null
+++ b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-fan-config.bbappend
@@ -0,0 +1 @@
+FILESEXTRAPATHS_prepend := "${THISDIR}/${BPN}:"
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-fan-config-native/swift/fans.yaml b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-fan-config/swift/fans.yaml
similarity index 100%
rename from meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-fan-config-native/swift/fans.yaml
rename to meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-fan-config/swift/fans.yaml
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-fan-config-native/witherspoon/fans.yaml b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-fan-config/witherspoon/fans.yaml
similarity index 100%
rename from meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-fan-config-native/witherspoon/fans.yaml
rename to meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-fan-config/witherspoon/fans.yaml
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-conditions-config-native.bbappend b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-conditions-config-native.bbappend
deleted file mode 100644
index 72d991c..0000000
--- a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-conditions-config-native.bbappend
+++ /dev/null
@@ -1 +0,0 @@
-FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-conditions-config.bbappend b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-conditions-config.bbappend
new file mode 100644
index 0000000..8f2097c
--- /dev/null
+++ b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-conditions-config.bbappend
@@ -0,0 +1 @@
+FILESEXTRAPATHS_prepend := "${THISDIR}/${BPN}:"
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-conditions-config-native/swift/zone_conditions.yaml b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-conditions-config/swift/zone_conditions.yaml
similarity index 100%
rename from meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-conditions-config-native/swift/zone_conditions.yaml
rename to meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-conditions-config/swift/zone_conditions.yaml
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-conditions-config-native/witherspoon/zone_conditions.yaml b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-conditions-config/witherspoon/zone_conditions.yaml
similarity index 100%
rename from meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-conditions-config-native/witherspoon/zone_conditions.yaml
rename to meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-conditions-config/witherspoon/zone_conditions.yaml
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-config-native.bbappend b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-config-native.bbappend
deleted file mode 100644
index 72d991c..0000000
--- a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-config-native.bbappend
+++ /dev/null
@@ -1 +0,0 @@
-FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-config.bbappend b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-config.bbappend
new file mode 100644
index 0000000..8f2097c
--- /dev/null
+++ b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-config.bbappend
@@ -0,0 +1 @@
+FILESEXTRAPATHS_prepend := "${THISDIR}/${BPN}:"
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-config-native/swift/zones.yaml b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-config/swift/zones.yaml
similarity index 100%
rename from meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-config-native/swift/zones.yaml
rename to meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-config/swift/zones.yaml
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-config-native/witherspoon/zones.yaml b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-config/witherspoon/zones.yaml
similarity index 100%
rename from meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-config-native/witherspoon/zones.yaml
rename to meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-zone-config/witherspoon/zones.yaml
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-monitor-config-native.bbappend b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-monitor-config-native.bbappend
deleted file mode 100644
index 72d991c..0000000
--- a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-monitor-config-native.bbappend
+++ /dev/null
@@ -1 +0,0 @@
-FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-monitor-config.bbappend b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-monitor-config.bbappend
new file mode 100644
index 0000000..8f2097c
--- /dev/null
+++ b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-monitor-config.bbappend
@@ -0,0 +1 @@
+FILESEXTRAPATHS_prepend := "${THISDIR}/${BPN}:"
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-monitor-config-native/witherspoon/monitor.yaml b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-monitor-config/witherspoon/monitor.yaml
similarity index 100%
rename from meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-monitor-config-native/witherspoon/monitor.yaml
rename to meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-monitor-config/witherspoon/monitor.yaml
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-presence-config-native.bbappend b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-presence-config-native.bbappend
deleted file mode 100644
index 72d991c..0000000
--- a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-presence-config-native.bbappend
+++ /dev/null
@@ -1 +0,0 @@
-FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-presence-config.bbappend b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-presence-config.bbappend
new file mode 100644
index 0000000..8f2097c
--- /dev/null
+++ b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-presence-config.bbappend
@@ -0,0 +1 @@
+FILESEXTRAPATHS_prepend := "${THISDIR}/${BPN}:"
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-presence-config-native/witherspoon/config.yaml b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-presence-config/witherspoon/config.yaml
similarity index 100%
rename from meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-presence-config-native/witherspoon/config.yaml
rename to meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-presence-config/witherspoon/config.yaml
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan_%.bbappend b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan_%.bbappend
index a3fc74e..58c1a5f 100644
--- a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan_%.bbappend
+++ b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan_%.bbappend
@@ -1,4 +1,4 @@
-FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
+FILESEXTRAPATHS_prepend := "${THISDIR}/${BPN}:"
# Package configuration
FAN_PACKAGES += " \
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/swift-phosphor-fan-monitor-config-native/monitor.yaml b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/swift-phosphor-fan-monitor-config/monitor.yaml
similarity index 100%
rename from meta-ibm/meta-witherspoon/recipes-phosphor/fans/swift-phosphor-fan-monitor-config-native/monitor.yaml
rename to meta-ibm/meta-witherspoon/recipes-phosphor/fans/swift-phosphor-fan-monitor-config/monitor.yaml
diff --git a/meta-ibm/meta-witherspoon/recipes-phosphor/fans/swift-phosphor-fan-presence-config-native/config.yaml b/meta-ibm/meta-witherspoon/recipes-phosphor/fans/swift-phosphor-fan-presence-config/config.yaml
similarity index 100%
rename from meta-ibm/meta-witherspoon/recipes-phosphor/fans/swift-phosphor-fan-presence-config-native/config.yaml
rename to meta-ibm/meta-witherspoon/recipes-phosphor/fans/swift-phosphor-fan-presence-config/config.yaml