connectcore-demo: avoid removal of board image file for the ccimx6qpsbc

Commit c4f2fce4d3 added logic to do_install()
that saves space by removing board image files that don't match the machine
name. However, the ccimx6qpsbc uses the ccimx6sbc board image file, and it was
being removed from the demo, breaking the demo's landing page.

Avoid this by specifying the correct filename for the ccimx6qpsbc.

Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
This commit is contained in:
Gabriel Valcazar 2024-01-24 17:48:27 +01:00 committed by Arturo Buzarra
parent 568d142b11
commit b3391941dd
1 changed files with 6 additions and 1 deletions

View File

@ -30,12 +30,17 @@ S = "${WORKDIR}/connectcore-demo-example"
inherit systemd update-rc.d inherit systemd update-rc.d
BOARD_IMAGE_FILE ?= "${MACHINE}_board.png"
# The ccimx6qpsbc re-uses the ccimx6sbc board image
BOARD_IMAGE_FILE:ccimx6qpsbc = "ccimx6sbc_board.png"
do_install() { do_install() {
install -d ${D}/srv/www install -d ${D}/srv/www
cp -r ${WORKDIR}/git/connectcore-demo-example/* ${D}/srv/www/ cp -r ${WORKDIR}/git/connectcore-demo-example/* ${D}/srv/www/
# Remove unused images # Remove unused images
find ${D}/srv/www/static/images/ -type f -name '*_board.png' -not -name '${MACHINE}_board.png' -delete find ${D}/srv/www/static/images/ -type f -name '*_board.png' -not -name '${BOARD_IMAGE_FILE}' -delete
# Install systemd service # Install systemd service
if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then