openjdk8: move /etc/profile.d/10-openjdk*.sh to trigger

This commit is contained in:
classabbyamp 2022-03-20 16:12:02 -04:00 committed by Andrew J. Hesford
parent 7e70ea35c9
commit 259cbdc15d

View File

@ -4,7 +4,7 @@
# TODO: config files?
pkgname=openjdk8
version=8u322b04
revision=1
revision=2
_jdk_update="${version#*u}"
_jdk_update="${_jdk_update%b*}"
_jdk_build="${version#*b}"
@ -221,6 +221,8 @@ openjdk8-jre_package() {
shlib_provides="libawt.so libawt_xawt.so libjava.so libjli.so libjvm.so libjawt.so"
short_desc+=" - runtime components"
provides="java-runtime-${version}_1"
depends="xbps-triggers>=0.122_1"
triggers="openjdk-profile"
alternatives="
java:/usr/bin/java:/${_jdk_home}/jre/bin/java
java:/usr/bin/jjs:/${_jdk_home}/jre/bin/jjs
@ -236,10 +238,6 @@ openjdk8-jre_package() {
"
pkg_install() {
vmove ${_jdk_home}/jre
vmkdir etc/profile.d
cat >>${PKGDESTDIR}/etc/profile.d/10_openjdk8.sh <<EOF
export JAVA_HOME=\${JAVA_HOME=/${_jdk_home}/jre}
EOF
}
}