phosphor-software-manager: Create a new mmc bbclass

Add a bbclass for the mmc configuration option.

(From meta-phosphor rev: 7df4aa01e4d35e6ec7294f08e4bd3f1d18e61f01)

Change-Id: I6602362e511bcffae1e185a72861ae1edec050f9
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
diff --git a/meta-phosphor/classes/phosphor-software-manager-mmc.bbclass b/meta-phosphor/classes/phosphor-software-manager-mmc.bbclass
new file mode 100644
index 0000000..955e65e
--- /dev/null
+++ b/meta-phosphor/classes/phosphor-software-manager-mmc.bbclass
@@ -0,0 +1,7 @@
+# eMMC-specific configuration for the phosphor-manager-software package
+
+PACKAGECONFIG_append = " mmc_layout"
+
+EXTRA_OEMESON += "-Dactive-bmc-max-allowed=2"
+EXTRA_OEMESON += "-Dmedia-dir='/media'"
+
diff --git a/meta-phosphor/recipes-phosphor/flash/phosphor-software-manager_git.bb b/meta-phosphor/recipes-phosphor/flash/phosphor-software-manager_git.bb
index 0ab2a75..d561eba 100644
--- a/meta-phosphor/recipes-phosphor/flash/phosphor-software-manager_git.bb
+++ b/meta-phosphor/recipes-phosphor/flash/phosphor-software-manager_git.bb
@@ -12,6 +12,7 @@
     ${PN}-download-mgr \
     ${PN}-updater \
     ${PN}-updater-ubi \
+    ${PN}-updater-mmc \
     ${PN}-sync \
 "
 PACKAGE_BEFORE_PN += "${SOFTWARE_MGR_PACKAGES}"
@@ -26,12 +27,14 @@
 PACKAGECONFIG[verify_signature] = "-Dverify-signature=enabled, -Dverify-signature=disabled"
 PACKAGECONFIG[sync_bmc_files] = "-Dsync-bmc-files=enabled, -Dsync-bmc-files=disabled"
 PACKAGECONFIG[ubifs_layout] = "-Dbmc-layout=ubi"
+PACKAGECONFIG[mmc_layout] = "-Dbmc-layout=mmc"
 PACKAGECONFIG[flash_bios] = "-Dhost-bios-upgrade=enabled, -Dhost-bios-upgrade=disabled"
 
 inherit meson pkgconfig
 inherit obmc-phosphor-dbus-service
 inherit python3native
 inherit ${@bb.utils.contains('DISTRO_FEATURES', 'obmc-ubi-fs', 'phosphor-software-manager-ubi-fs', '', d)}
+inherit ${@bb.utils.contains('DISTRO_FEATURES', 'phosphor-mmc', 'phosphor-software-manager-mmc', '', d)}
 
 DEPENDS += " \
     openssl \
diff --git a/meta-phosphor/recipes-phosphor/packagegroups/packagegroup-obmc-apps.bb b/meta-phosphor/recipes-phosphor/packagegroups/packagegroup-obmc-apps.bb
index 81895eb..186fdbe 100644
--- a/meta-phosphor/recipes-phosphor/packagegroups/packagegroup-obmc-apps.bb
+++ b/meta-phosphor/recipes-phosphor/packagegroups/packagegroup-obmc-apps.bb
@@ -108,6 +108,10 @@
         phosphor-software-manager-updater-ubi \
         "
 
+${PN}-software-extras_df-phosphor-mmc = " \
+        phosphor-software-manager-updater-mmc \
+        "
+
 SUMMARY_${PN}-software = "Software applications"
 RDEPENDS_${PN}-software = " \
         ${VIRTUAL-RUNTIME_obmc-bmc-download-mgr} \