Bug 277394

Summary: java/javavmwrapper-2.7.10 doesn't detect openjdk 8 (net/serviio fails to start)
Product: Ports & Packages Reporter: bsdbugs_mr
Component: Individual Port(s)Assignee: Greg Lewis <glewis>
Status: New ---    
Severity: Affects Some People CC: bsdbugs_mr, michaelo, netchild
Priority: ---    
Version: Latest   
Hardware: Any   
OS: Any   

Description bsdbugs_mr 2024-02-29 18:30:38 UTC
Running with javavmwrapper-2.7.10:
java: error: no suitable JavaVMs found

rollback to javavmwrapper-2.7.9 - works as before.
Comment 1 Alexander Leidinger freebsd_committer freebsd_triage 2024-03-01 07:04:28 UTC
Hi Greg,

javavmwrapper 1.7.10 doesn't detect openjdk 8 anymore:

(211) root@ttypts/2 # checkvms                      

(212) root@ttypts/2 # pkg info | grep java        
java-zoneinfo-2021.e           Updated Java timezone definitions
javavmwrapper-2.7.10           Wrapper script for various Java Virtual Machines

(213) root@ttypts/2 # pkg info | grep jdk 
openjdk8-8.402.06.1_1          Java Development Kit 8

There's also a bug in the serviio start script that it doesn't specify the JAVA_VERSION, but if only openjdk 8 is installed, it should be detected and tried. Correct?

Bye,
Alexander.
Comment 2 Alexander Leidinger freebsd_committer freebsd_triage 2024-03-01 10:30:17 UTC
I found the issue, javavmwrapper doesn't accept JAVA_VERSION 1.8 anymore, it expects JAVA_VERSION 8 instead (serviiod sets it at a different place than I remembered...).
Comment 3 Alexander Leidinger freebsd_committer freebsd_triage 2024-03-01 11:10:33 UTC
To the bug reporter: a temp workaround is to edit /usr/local/sbin/serviiod and change JAVA_VERSION="1.8+" to JAVA_VERSION="8+".

I'm testing compatibility with openjdk 11 (seems to work, at least according to the serviio forum) and higher and will commit a fix with a higher java version once I'm confident what works or not.
Comment 4 Alexander Leidinger freebsd_committer freebsd_triage 2024-03-07 13:39:27 UTC
Note, the serviio port has been fixed by moving on to Java 21, but the compatibility part of the javavmwrapper may be something those on the quarterly branch may need for their own use (outside of the ports collection).