0
0
mirror of https://github.com/termux/termux-packages.git synced 2025-01-07 15:58:46 +00:00
Henrik Grimler 716cf39086 fix(main/openjdk-21): fix update-alternative paths in prerm script
update-alternatives take the path to the real file as argument, not
the symlink installation path.
2024-10-17 14:02:06 +02:00

15 lines
492 B
Bash

#!@TERMUX_PREFIX@/bin/sh
if [ "$1" != "upgrade" ]; then
if [ -x "@TERMUX_PREFIX@/bin/update-alternatives" ]; then
update-alternatives --remove java-profile @TERMUX_PREFIX@/lib/jvm/java-21-openjdk/etc/profile.d/java.sh
for tool in @binaries@; do
update-alternatives --remove $tool @TERMUX_PREFIX@/lib/jvm/java-21-openjdk/bin/$tool
done
for manpage in @manpages@; do
update-alternatives --remove $manpage @TERMUX_PREFIX@/lib/jvm/java-21-openjdk/man/man1/$manpage
done
fi
fi