From 33a3e4ed91d4fd031065b5f7a4f3ab584783441e Mon Sep 17 00:00:00 2001 From: Leonid Pliushch Date: Sun, 26 Jul 2020 14:19:30 +0300 Subject: [PATCH] apksigner, beanshell, dx, ecj: remove OAT cache after installation/upgrade --- packages/apksigner/build.sh | 10 +++++++++- packages/beanshell/build.sh | 10 +++++++++- packages/dx/build.sh | 10 +++++++++- packages/ecj/build.sh | 10 +++++++++- 4 files changed, 36 insertions(+), 4 deletions(-) diff --git a/packages/apksigner/build.sh b/packages/apksigner/build.sh index a6280ac9c..4b99e8564 100644 --- a/packages/apksigner/build.sh +++ b/packages/apksigner/build.sh @@ -2,7 +2,7 @@ TERMUX_PKG_HOMEPAGE=https://developer.android.com/studio/command-line/apksigner TERMUX_PKG_DESCRIPTION="APK signing tool" TERMUX_PKG_LICENSE="Apache-2.0" TERMUX_PKG_VERSION=${TERMUX_ANDROID_BUILD_TOOLS_VERSION} -TERMUX_PKG_REVISION=1 +TERMUX_PKG_REVISION=2 TERMUX_PKG_BUILD_IN_SRC=true TERMUX_PKG_PLATFORM_INDEPENDENT=true TERMUX_PKG_SKIP_SRC_EXTRACT=true @@ -51,3 +51,11 @@ termux_step_make_install() { echo "dalvikvm -Xcompiler-option --compiler-filter=speed -cp $TERMUX_PREFIX/share/dex/apksigner.jar com.android.apksigner.ApkSignerTool \$@" >> $TERMUX_PREFIX/bin/apksigner chmod +x $TERMUX_PREFIX/bin/apksigner } + +termux_step_create_debscripts() { + cat <<- EOF > ./postinst + #!${TERMUX_PREFIX}/bin/sh + rm -f $TERMUX_PREFIX/share/dex/oat/*/apksigner.* >/dev/null 2>&1 + exit 0 + EOF +} diff --git a/packages/beanshell/build.sh b/packages/beanshell/build.sh index 9405452c0..ba1b4ecd7 100644 --- a/packages/beanshell/build.sh +++ b/packages/beanshell/build.sh @@ -3,7 +3,7 @@ TERMUX_PKG_DESCRIPTION="Small, free, embeddable, source level Java interpreter w TERMUX_PKG_LICENSE="Apache-2.0" TERMUX_PKG_MAINTAINER="Leonid Pliushch " TERMUX_PKG_VERSION=2.0b6 -TERMUX_PKG_REVISION=5 +TERMUX_PKG_REVISION=6 TERMUX_PKG_SRCURL=https://github.com/beanshell/beanshell/releases/download/$TERMUX_PKG_VERSION/bsh-$TERMUX_PKG_VERSION.jar TERMUX_PKG_SHA256=a17955976070c0573235ee662f2794a78082758b61accffce8d3f8aedcd91047 TERMUX_PKG_DEPENDS="dash, termux-tools" @@ -34,3 +34,11 @@ termux_step_make_install() { chmod 700 "$TERMUX_PREFIX"/bin/beanshell ln -sfr "$TERMUX_PREFIX"/bin/beanshell "$TERMUX_PREFIX"/bin/bsh } + +termux_step_create_debscripts() { + cat <<- EOF > ./postinst + #!${TERMUX_PREFIX}/bin/sh + rm -f $TERMUX_PREFIX/share/dex/oat/*/beanshell.* >/dev/null 2>&1 + exit 0 + EOF +} diff --git a/packages/dx/build.sh b/packages/dx/build.sh index 01e57407c..7ee802f99 100644 --- a/packages/dx/build.sh +++ b/packages/dx/build.sh @@ -2,7 +2,7 @@ TERMUX_PKG_HOMEPAGE=http://developer.android.com/tools/help/index.html TERMUX_PKG_DESCRIPTION="Command which takes in Java class files and converts them to format executable by Dalvik VM" TERMUX_PKG_LICENSE="Apache-2.0" TERMUX_PKG_VERSION=1:1.16 -TERMUX_PKG_REVISION=3 +TERMUX_PKG_REVISION=4 TERMUX_PKG_SRCURL=https://dl.bintray.com/xeffyr/sources/dx/dx-android-${TERMUX_PKG_VERSION:2}.jar TERMUX_PKG_SHA256=b9b7917267876b74c8ff6707e7a576c93b6dfe8cacc4f1cc791d606bcbbb7bd5 TERMUX_PKG_SKIP_SRC_EXTRACT=true @@ -36,3 +36,11 @@ termux_step_make_install() { EOF chmod 700 "$TERMUX_PREFIX"/bin/dx-merge } + +termux_step_create_debscripts() { + cat <<- EOF > ./postinst + #!${TERMUX_PREFIX}/bin/sh + rm -f $TERMUX_PREFIX/share/dex/oat/*/dx.* >/dev/null 2>&1 + exit 0 + EOF +} diff --git a/packages/ecj/build.sh b/packages/ecj/build.sh index 2564f36c2..46764a3dd 100644 --- a/packages/ecj/build.sh +++ b/packages/ecj/build.sh @@ -5,7 +5,7 @@ TERMUX_PKG_LICENSE="EPL-2.0" _VERSION=4.12 local _DATE=201906051800 TERMUX_PKG_VERSION=1:${_VERSION} -TERMUX_PKG_REVISION=1 +TERMUX_PKG_REVISION=2 TERMUX_PKG_SRCURL=http://archive.eclipse.org/eclipse/downloads/drops${_VERSION:0:1}/R-${_VERSION}-${_DATE}/ecj-${_VERSION}.jar TERMUX_PKG_SHA256=69dad18a1fcacd342a7d44c5abf74f50e7529975553a24c64bce0b29b86af497 TERMUX_PKG_PLATFORM_INDEPENDENT=true @@ -83,3 +83,11 @@ termux_step_make() { install $TERMUX_PKG_BUILDER_DIR/ecj-$TERMUX_PKG_API_LEVEL $TERMUX_PREFIX/bin/ecj-$TERMUX_PKG_API_LEVEL perl -p -i -e "s%\@TERMUX_PREFIX\@%${TERMUX_PREFIX}%g" $TERMUX_PREFIX/bin/ecj-$TERMUX_PKG_API_LEVEL } + +termux_step_create_debscripts() { + cat <<- EOF > ./postinst + #!${TERMUX_PREFIX}/bin/sh + rm -f $TERMUX_PREFIX/share/dex/oat/*/ecj.* >/dev/null 2>&1 + exit 0 + EOF +}