diff --git a/ipk-source/sdxpinn-mount-fix/CONTROL/preinst b/ipk-source/sdxpinn-mount-fix/CONTROL/preinst index c8ef6f4..e883afd 100644 --- a/ipk-source/sdxpinn-mount-fix/CONTROL/preinst +++ b/ipk-source/sdxpinn-mount-fix/CONTROL/preinst @@ -2,8 +2,9 @@ # Define the location of detected packages file DETECTED_PACKAGES_FILE="/tmp/detected_packages.tmp" +LIST_FILE_DELETED=false -# Check if specific packages are installed and delete their list files +# Function to check if a specific package is installed and delete its list file detect_and_remove_list_files() { local package_name="$1" local list_file="/usr/lib/opkg/info/${package_name}.list" @@ -13,6 +14,7 @@ detect_and_remove_list_files() { echo "$package_name is already installed. Deleting $list_file to avoid conflicts." rm -f "$list_file" echo "$package_name" >> "$DETECTED_PACKAGES_FILE" + LIST_FILE_DELETED=true else echo "$package_name is not installed." fi @@ -30,6 +32,19 @@ else echo "No pre-existing bundled packages detected." fi +# If any list files were deleted, show a warning message at the end of the script +if [ "$LIST_FILE_DELETED" = true ]; then + echo -e "\e[31m================================================\e[0m" + echo -e "\e[31mPre-bundled packages detected\e[0m" + echo -e "\e[32mAssociation between said packages and respective files has been removed\e[0m" + echo -e "\e[31m================================================\e[0m" + echo -e "\e[31mopkg will fail now\e[0m" + echo -e "\e[32mYou need to try installing this package again\e[0m" + echo -e "\e[32mThen it will work\e[0m" + echo -e "\e[31m================================================\e[0m" + echo -e "\e[32m================================================\e[0m" +fi + # Check if /etc is mounted if grep -qs '/etc ' /proc/mounts; then echo "Unmounting /etc..." diff --git a/ipk/sdxpinn-mount-fix_1.0.8_aarch64_cortex-a53.ipk b/ipk/sdxpinn-mount-fix_1.0.8_aarch64_cortex-a53.ipk deleted file mode 100644 index 02640d7..0000000 Binary files a/ipk/sdxpinn-mount-fix_1.0.8_aarch64_cortex-a53.ipk and /dev/null differ