summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--recipes-bsp/rmc/rmc-db.bb13
1 files changed, 13 insertions, 0 deletions
diff --git a/recipes-bsp/rmc/rmc-db.bb b/recipes-bsp/rmc/rmc-db.bb
index f24ed11c..7ec824a8 100644
--- a/recipes-bsp/rmc/rmc-db.bb
+++ b/recipes-bsp/rmc/rmc-db.bb
@@ -17,6 +17,8 @@ inherit rmc-db
17RMC_BOARD_DATA_DIRS ?= "${THISDIR}/boards/" 17RMC_BOARD_DATA_DIRS ?= "${THISDIR}/boards/"
18RMC_DB_DIR = "${WORKDIR}/db" 18RMC_DB_DIR = "${WORKDIR}/db"
19 19
20FILES_${PN} = "/boot/rmc.db"
21
20# Let sstate be aware of change in any added board directories 22# Let sstate be aware of change in any added board directories
21do_generate_rmc_db[file-checksums] = "${@get_rmc_top_dirs_list(d)}" 23do_generate_rmc_db[file-checksums] = "${@get_rmc_top_dirs_list(d)}"
22 24
@@ -46,4 +48,15 @@ do_deploy () {
46 fi 48 fi
47} 49}
48 50
51do_install () {
52 install -d ${D}/boot
53 if [ -f ${RMC_DB_DIR}/rmc.db ]; then
54 install -m 0400 ${RMC_DB_DIR}/rmc.db ${D}/boot/
55 else
56 rm -f ${D}/rmc.db
57 echo "Warning: no RMC central database found, skip installation."
58 fi
59}
60do_install[depends] += "${PN}:do_generate_rmc_db"
61
49addtask deploy after do_generate_rmc_db 62addtask deploy after do_generate_rmc_db