diff --git a/scripts/build/termux_step_massage.sh b/scripts/build/termux_step_massage.sh index 5036ad2ce..73b4af74d 100644 --- a/scripts/build/termux_step_massage.sh +++ b/scripts/build/termux_step_massage.sh @@ -37,6 +37,10 @@ termux_step_massage() { sed --follow-symlinks -i -E "1 s@^#\!(.*)/bin/(.*)@#\!$TERMUX_PREFIX/bin/\2@" "$file" done < <(find -L . -type f -print0) + # Remove unneeded files created by rust/cargo. + rm -f .crates2.json + + # Remove files specified in TERMUX_PKG_RM_AFTER_INSTALL. test ! -z "$TERMUX_PKG_RM_AFTER_INSTALL" && rm -Rf $TERMUX_PKG_RM_AFTER_INSTALL find . -type d -empty -delete # Remove empty directories