The configure does a check of the version but the wrong line is grepped if the warning line that _JAVA_OPTIONS is set is displayed We should unset _JAVA_OPTIONS in the configure or fix the grep
can you please provide example output and show how it's exactly wrong?
axion /home/fireburn # /opt/openjdk-bin-11.0.2_p7/bin/java -version Picked up _JAVA_OPTIONS: -Dawt.useSystemAAFontSettings=on -Dswing.aatext=true -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel openjdk version "11.0.2" 2018-10-16 OpenJDK Runtime Environment AdoptOpenJDK (build 11.0.2+7) OpenJDK 64-Bit Server VM AdoptOpenJDK (build 11.0.2+7, mixed mode)
Created attachment 563710 [details] Build log
BOOT_JDK=/opt/openjdk-bin-11.0.2_p7/ HEAD=head ECHO=echo EGREP=egrep DEFAULT_ACCEPTABLE_BOOT_VERSIONS="10 11" echo ${BOOT_JDK} "$BOOT_JDK/bin/java" -version BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` echo ${BOOT_JDK_VERSION} FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP "\"(${DEFAULT_ACCEPTABLE_BOOT_VERSIONS// /|})([\.+-].*)?\""` echo ${FOUND_CORRECT_VERSION}
thanks, that was helpful. can see it now. will commit a fix a bit later today, probably just unset the var as quickest fix.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3f6b5753f261cf3a48c19a57e1eb684a4b892cb5 commit 3f6b5753f261cf3a48c19a57e1eb684a4b892cb5 Author: Georgy Yakovlev <gyakovlev@gentoo.org> AuthorDate: 2019-02-05 05:09:29 +0000 Commit: Georgy Yakovlev <gyakovlev@gentoo.org> CommitDate: 2019-02-05 05:13:14 +0000 dev-java/openjdk: unset _JAVA_OPTIONS If build vm is a unregistered one (built without gentoo-vm flag) java-pkg-2_pkg_setup() and hence java-pkg_init() is not called and _JAVA_OPTIONS is not handled. Just unset it. Closes: https://bugs.gentoo.org/677236 Package-Manager: Portage-2.3.59, Repoman-2.3.12 Signed-off-by: Georgy Yakovlev <gyakovlev@gentoo.org> dev-java/openjdk/openjdk-11.0.2_p7.ebuild | 1 + dev-java/openjdk/openjdk-8.202_p08.ebuild | 1 + 2 files changed, 2 insertions(+)
This seems to have worked for openjdk:8 but I still had to unset _JAVA_OPTIONS manually on openjdk:11
Ah, it probably should be unset along with "unset JAVA JAVAC XARGS" just before configure Where it currently us means it isn't unset if you're using a non "-bin" version for compiling
the logic is the following: if you are using blessed gentoo openjdk (built with gentoo-vm useflag unmasked) to build new openjdk the eclass should handle unsetting https://github.com/gentoo/gentoo/blob/master/eclass/java-utils-2.eclass#L2168-L2185 , unless you have I_WANT_GLOBAL_JAVA_OPTIONS set. in case you don't use gentoo-vm useflag ebuild should unset it via the fix I committed. anyway, makes sense to just unset it all the time, because there is no chance of building it with this variable without patching.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=95024cde4a946017684c37fbe99f1b1609ff6bf1 commit 95024cde4a946017684c37fbe99f1b1609ff6bf1 Author: Georgy Yakovlev <gyakovlev@gentoo.org> AuthorDate: 2019-02-23 20:21:45 +0000 Commit: Georgy Yakovlev <gyakovlev@gentoo.org> CommitDate: 2019-02-23 20:25:18 +0000 dev-java/openjdk: unset _JAVA_OPTIONS before econf Closes: https://bugs.gentoo.org/677236 Package-Manager: Portage-2.3.62, Repoman-2.3.12 Signed-off-by: Georgy Yakovlev <gyakovlev@gentoo.org> dev-java/openjdk/openjdk-11.0.1_p13.ebuild | 2 +- dev-java/openjdk/openjdk-11.0.2_p7.ebuild | 3 +-- dev-java/openjdk/openjdk-8.202_p08.ebuild | 3 +-- 3 files changed, 3 insertions(+), 5 deletions(-)
Thanks