diff --git a/files/initrd/opt/arc/arc.sh b/files/initrd/opt/arc/arc.sh index c61b07aa..1c6b0f15 100755 --- a/files/initrd/opt/arc/arc.sh +++ b/files/initrd/opt/arc/arc.sh @@ -460,6 +460,7 @@ function arcSettings() { dialog --backtitle "$(backtitle)" --colors --title "DSM Addons" \ --infobox "Loading Addons Table..." 3 35 # Add Arc Addons + writeConfigKey "addons.acpid" "" "${USER_CONFIG_FILE}" writeConfigKey "addons.cpuinfo" "" "${USER_CONFIG_FILE}" # Select Addons addonSelection diff --git a/files/initrd/opt/arc/ramdisk-patch.sh b/files/initrd/opt/arc/ramdisk-patch.sh index 595c49d4..66dc00c8 100755 --- a/files/initrd/opt/arc/ramdisk-patch.sh +++ b/files/initrd/opt/arc/ramdisk-patch.sh @@ -163,7 +163,7 @@ echo "export LAYOUT=\"${LAYOUT}\"" >>"${RAMDISK_PATH}/addons/addons.sh" echo "export KEYMAP=\"${KEYMAP}\"" >>"${RAMDISK_PATH}/addons/addons.sh" chmod +x "${RAMDISK_PATH}/addons/addons.sh" -# This order cannot be changed. +# System Addons for ADDON in "redpill" "revert" "misc" "eudev" "disks" "localrss" "notify" "updatenotify" "wol"; do PARAMS="" if [ "${ADDON}" = "disks" ]; then @@ -174,11 +174,33 @@ for ADDON in "redpill" "revert" "misc" "eudev" "disks" "localrss" "notify" "upda echo "/addons/${ADDON}.sh \${1} ${PARAMS}" >>"${RAMDISK_PATH}/addons/addons.sh" 2>>"${LOG_FILE}" || exit 1 done -# User addons +# User Addons for ADDON in ${!ADDONS[@]}; do - PARAMS=${ADDONS[${ADDON}]} - installAddon "${ADDON}" "${PLATFORM}" || exit 1 - echo "/addons/${ADDON}.sh \${1} ${PARAMS}" >>"${RAMDISK_PATH}/addons/addons.sh" 2>>"${LOG_FILE}" || exit 1 + if [[ "${ADDON}" == *"hdddb"* ]]; then + PARAMS=${ADDONS[${ADDON}]} + installAddon "${ADDON}" "${PLATFORM}" || exit 1 + echo "/addons/${ADDON}.sh \${1} ${PARAMS}" >>"${RAMDISK_PATH}/addons/addons.sh" 2>>"${LOG_FILE}" || exit 1 + elif [[ "${ADDON}" == *"deduplication"* ]]; then + PARAMS=${ADDONS[${ADDON}]} + installAddon "${ADDON}" "${PLATFORM}" || exit 1 + echo "/addons/${ADDON}.sh \${1} ${PARAMS}" >>"${RAMDISK_PATH}/addons/addons.sh" 2>>"${LOG_FILE}" || exit 1 + elif [[ "${ADDON}" == *"cpuinfo"* ]]; then + PARAMS=${ADDONS[${ADDON}]} + installAddon "${ADDON}" "${PLATFORM}" || exit 1 + echo "/addons/${ADDON}.sh \${1} ${PARAMS}" >>"${RAMDISK_PATH}/addons/addons.sh" 2>>"${LOG_FILE}" || exit 1 + elif [[ "${ADDON}" == *"acpid"* ]]; then + PARAMS=${ADDONS[${ADDON}]} + installAddon "${ADDON}" "${PLATFORM}" || exit 1 + echo "/addons/${ADDON}.sh \${1} ${PARAMS}" >>"${RAMDISK_PATH}/addons/addons.sh" 2>>"${LOG_FILE}" || exit 1 + elif [[ "${ADDON}" == *"cpufreqscaling"* ]]; then + PARAMS=${ADDONS[${ADDON}]} + installAddon "${ADDON}" "${PLATFORM}" || exit 1 + echo "/addons/${ADDON}.sh \${1} ${PARAMS}" >>"${RAMDISK_PATH}/addons/addons.sh" 2>>"${LOG_FILE}" || exit 1 + else + PARAMS=${ADDONS[${ADDON}]} + installAddon "${ADDON}" "${PLATFORM}" || exit 1 + echo "/addons/${ADDON}.sh \${1} ${PARAMS}" >>"${RAMDISK_PATH}/addons/addons.sh" 2>>"${LOG_FILE}" || exit 1 + fi done # Enable Telnet