diff options
author | A. Wilcox <AWilcox@Wilcox-Tech.com> | 2019-02-26 19:59:11 +0000 |
---|---|---|
committer | A. Wilcox <AWilcox@Wilcox-Tech.com> | 2019-02-26 20:10:47 +0000 |
commit | d71ae2f9370d6d61af17b9e922e44476b3b5e261 (patch) | |
tree | e2eeaf03eac04738051e51165ad4901140a0b4a9 | |
parent | 3ca1b80226ab3a45e9173e15ff3b84e8cb855e9c (diff) | |
download | packages-d71ae2f9370d6d61af17b9e922e44476b3b5e261.tar.gz packages-d71ae2f9370d6d61af17b9e922e44476b3b5e261.tar.bz2 packages-d71ae2f9370d6d61af17b9e922e44476b3b5e261.tar.xz packages-d71ae2f9370d6d61af17b9e922e44476b3b5e261.zip |
user/java-common: new package
-rw-r--r-- | user/java-common/APKBUILD | 22 | ||||
-rw-r--r-- | user/java-common/java-common.trigger | 13 |
2 files changed, 35 insertions, 0 deletions
diff --git a/user/java-common/APKBUILD b/user/java-common/APKBUILD new file mode 100644 index 000000000..12259b209 --- /dev/null +++ b/user/java-common/APKBUILD @@ -0,0 +1,22 @@ +# Maintainer: A. Wilcox <awilfox@adelielinux.org> +pkgname=java-common +pkgver=6 +pkgrel=0 +pkgdesc="Default Java runtime binary symlinks" +url=" " +arch="noarch" +options="!check" # Symlinks only. +license="Public-Domain" +depends="" +makedepends="" +subpackages="" +source="" +triggers="java-common.trigger=/usr/lib/jvm" + +package() { + mkdir -p "$pkgdir"/usr/bin + ln -sf ../lib/jvm/default-jvm/jre/bin/java "$pkgdir"/usr/bin + ln -sf ../lib/jvm/default-jvm/jre/bin/rmiregistry "$pkgdir"/usr/bin + ln -sf ../lib/jvm/default-jvm/jre/bin/keytool "$pkgdir"/usr/bin + ln -sf ../lib/jvm/default-jvm/bin/appletviewer "$pkgdir"/usr/bin +} diff --git a/user/java-common/java-common.trigger b/user/java-common/java-common.trigger new file mode 100644 index 000000000..6d0613d48 --- /dev/null +++ b/user/java-common/java-common.trigger @@ -0,0 +1,13 @@ +#!/bin/sh + +if [ -x /usr/lib/jvm/forced-jvm ]; then + ln -sfn forced-jvm default-jvm + exit 0 +fi + +cd /usr/lib/jvm +LATEST=`ls -d java-* | sort -r | head -1` +if [ "$LATEST" ]; then + ln -sfn $LATEST default-jvm +fi + |