diff --git a/recipes-bsp/fng-install/fng-install/fng-install.sh b/recipes-bsp/fng-install/fng-install/fng-install.sh index c16a5cec887c5890887abba944d84393b1714034..66dfab4b77916b025dc192b9ac9c4db587a8152e 100644 --- a/recipes-bsp/fng-install/fng-install/fng-install.sh +++ b/recipes-bsp/fng-install/fng-install/fng-install.sh @@ -1053,14 +1053,18 @@ load_and_write_files() # Load overlays that are provided via the script's arguments. # Overlays are placed in /boot/overlays and are activated by - # adding them to the overlays.txt (via the append_overlay - # function). + # adding them to the overlays.txt file. mkdir -p "${TMP_MOUNT_POINT}/overlays" for DT in ${DEVICETREEOV}; do DTBASE=$( basename "$DT" ) load_file "${DT}" "${TMP_MOUNT_POINT}/overlays/${DTBASE}" - append_overlay "${DTBASE}" "${TMP_MOUNT_POINT}" + + if [ ! -f "${TMP_MOUNT_POINT}/overlays.txt" ]; then + echo "overlays=" >> "${TMP_MOUNT_POINT}/overlays.txt" + fi + + sed -i "/^overlays=/s/$/ overlays\/${DTBASE}/" "${TMP_MOUNT_POINT}/overlays.txt" done #================================================