phosphor-software-manager: Add MEDIA_DIR config
Configure MEDIA_DIR to /run/media for static flash layout;
Configure MEDIA_DIR to /media which is default for ubi-fs.
Resolves openbmc/phosphor-bmc-code-mgmt#3
Tested: Verify that the MEDIA_DIR is set to /run/media for Romulus
build, and set to /media for Witherspoon build.
Change-Id: I20ff59c2f03c5f5fc4e004b0bf5d464a210a1654
Signed-off-by: Lei YU <mine260309@gmail.com>
diff --git a/classes/phosphor-software-manager-ubi-fs.bbclass b/classes/phosphor-software-manager-ubi-fs.bbclass
index 466d3ce..42e08ce 100644
--- a/classes/phosphor-software-manager-ubi-fs.bbclass
+++ b/classes/phosphor-software-manager-ubi-fs.bbclass
@@ -10,6 +10,16 @@
/usr/local \
"
+# Remove default configs
+EXTRA_OECONF_remove_df-obmc-ubi-fs += " \
+ MEDIA_DIR=/run/media \
+"
+
+# Add ubi-fs configs
+EXTRA_OECONF_append_df-obmc-ubi-fs += " \
+ MEDIA_DIR=/media \
+"
+
SYSTEMD_SERVICE_phosphor-software-manager-updater-ubi += " \
obmc-flash-bmc-ubirw.service \
obmc-flash-bmc-ubiro@.service \