build-package.sh: fix rm problems when builddir/srcdir contains RO files

This commit is contained in:
Leonid Pliushch 2019-07-04 14:09:44 +03:00
parent 1dba788409
commit f45ed59766

View File

@ -92,6 +92,10 @@ termux_step_start_build() {
done<<<$(./scripts/buildorder.py "$TERMUX_PKG_BUILDER_DIR" $TERMUX_PACKAGES_DIRECTORIES || echo "ERROR")
fi
# Following directories may contain objects with RO-only permissions which
# makes them undeletable. We need fix that.
chmod +w -R "$TERMUX_PKG_BUILDDIR" "$TERMUX_PKG_SRCDIR"
# Cleanup old state:
rm -Rf "$TERMUX_PKG_BUILDDIR" \
"$TERMUX_PKG_PACKAGEDIR" \