archrelease: copy trunk to extra-x86_64
[arch-packages.git] / java11-openjdk / trunk / install_jre-openjdk.sh
blob8fca4d1bd78b16b90fc7e79b223ab7d3886465cf
1 THIS_JRE='java-11-openjdk'
3 fix_default() {
4 if [ ! -x /usr/bin/java ]; then
5 /usr/bin/archlinux-java unset
6 echo ""
7 else
8 /usr/bin/archlinux-java get
9 fi
12 post_install() {
13 default=$(fix_default)
14 case ${default} in
15 "")
16 /usr/bin/archlinux-java set ${THIS_JRE}
18 ${THIS_JRE})
19 # Nothing
22 echo "Default Java environment is already set to '${default}'"
23 echo "See 'archlinux-java help' to change it"
25 esac
27 echo "when you use a non-reparenting window manager,"
28 echo "set _JAVA_AWT_WM_NONREPARENTING=1 in /etc/profile.d/jre.sh"
31 post_upgrade() {
32 if [ -z "$(fix_default)" ]; then
33 /usr/bin/archlinux-java set ${THIS_JRE}