Tell phosphor-logging about the LED error yaml

This needs to be done so phosphor-logging will know to grab
the error log's metadata from the journal and add it to
the log in the AdditionalData field.

Resolves openbmc/openbmc#3015

Tested: Check that the LED errors now show up in the elog-lookup.cpp
        file generated during the build by phosphor-logging.

Change-Id: I9bcbf1b1c8d7499e4ef8e384005c34b858d25a7d
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
diff --git a/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager-error-native.bb b/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager-error-native.bb
new file mode 100644
index 0000000..c8ec041
--- /dev/null
+++ b/meta-phosphor/common/recipes-phosphor/leds/phosphor-led-manager-error-native.bb
@@ -0,0 +1,21 @@
+SUMMARY = "Copy error yaml files to known path for elog parsing"
+PR = "r1"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://${PHOSPHORBASE}/COPYING.apache-2.0;md5=34400b68072d710fecd0a2940a0d1658"
+
+inherit native
+inherit phosphor-dbus-yaml
+
+require phosphor-led-manager.inc
+
+S = "${WORKDIR}/git"
+
+do_install_append() {
+    SRC=${S}/xyz/openbmc_project/Led/
+    DEST=${D}${yaml_dir}/xyz/openbmc_project/Led/
+    install -d ${DEST}/Fru
+    install ${SRC}/*.errors.yaml ${DEST}
+    install ${SRC}/*.metadata.yaml ${DEST}
+    install ${SRC}/Fru/*.errors.yaml ${DEST}/Fru
+    install ${SRC}/Fru/*.metadata.yaml ${DEST}/Fru
+}