Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 792279 - net-wireless/unifi does not work with openjdk-11
Summary: net-wireless/unifi does not work with openjdk-11
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Conrad Kostecki
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: jdk11
  Show dependency tree
 
Reported: 2021-05-26 17:30 UTC by Joakim Tjernlund
Modified: 2022-04-10 15:25 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Joakim Tjernlund 2021-05-26 17:30:39 UTC
unifi just uses the system jdk/jre and if this is java-11 the browser connection
fails with a secure connection failed msg

I believe you can use java-utils-2.eclass to get at JAVE_HOME etc as
the ebuild uses virtual/jre:1.8 already.
Comment 1 Ben Kohler gentoo-dev 2021-05-27 12:19:07 UTC
Just to clarify-- you have manually unmasked the gentoo-vm flag, so this isn't affecting most users, for now.  Right?
Comment 2 Joakim Tjernlund 2021-05-27 12:40:32 UTC
(In reply to Ben Kohler from comment #1)
> Just to clarify-- you have manually unmasked the gentoo-vm flag, so this
> isn't affecting most users, for now.  Right?

Yes, I have gentoo-vm
Comment 3 Joakim Tjernlund 2022-01-14 12:06:14 UTC
(In reply to Ben Kohler from comment #1)
> Just to clarify-- you have manually unmasked the gentoo-vm flag, so this
> isn't affecting most users, for now.  Right?

gentoo-vm is no longer masked I think
Comment 4 Conrad Kostecki gentoo-dev 2022-02-09 12:54:05 UTC
Hi,
first of all, UniFi currently does not support Java 11 or newer. Nothing I can really do about it.

(In reply to Joakim Tjernlund from comment #0)
> unifi just uses the system jdk/jre and if this is java-11 the browser
> connection
> fails with a secure connection failed msg
> 
> I believe you can use java-utils-2.eclass to get at JAVE_HOME etc as
> the ebuild uses virtual/jre:1.8 already.

Have a look at /etc/conf.d/unifi. You can override JAVA_HOME.
If using openjdk-8, you could set it to /usr/lib64/openjdk-8.
For next release, I will also make a default for using openjdk-8.

Conrad
Comment 5 Joakim Tjernlund 2022-02-09 15:19:54 UTC
(In reply to Conrad Kostecki from comment #4)
> Hi,
> first of all, UniFi currently does not support Java 11 or newer. Nothing I
> can really do about it.

Yes, that is kind of the point with this ticket.

> 
> (In reply to Joakim Tjernlund from comment #0)
> > unifi just uses the system jdk/jre and if this is java-11 the browser
> > connection
> > fails with a secure connection failed msg
> > 
> > I believe you can use java-utils-2.eclass to get at JAVE_HOME etc as
> > the ebuild uses virtual/jre:1.8 already.
> 
> Have a look at /etc/conf.d/unifi. You can override JAVA_HOME.
> If using openjdk-8, you could set it to /usr/lib64/openjdk-8.
> For next release, I will also make a default for using openjdk-8.

I have already done that fix for me but unifi ebuild should really enforce
java 8, regardless of system java vm. You can do that by using the java-utils-2.eclass.
https://wiki.gentoo.org/wiki/Java_Developer_Guide has some clues.
Comment 6 Larry the Git Cow gentoo-dev 2022-02-09 22:57:31 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f66b68c65f82d22b0d23ecf007e01acb5a0c2a7d

commit f66b68c65f82d22b0d23ecf007e01acb5a0c2a7d
Author:     Conrad Kostecki <conikost@gentoo.org>
AuthorDate: 2022-02-09 22:53:46 +0000
Commit:     Conrad Kostecki <conikost@gentoo.org>
CommitDate: 2022-02-09 22:56:54 +0000

    net-wireless/unifi: force java8
    
    As UniFi needs Java8, we need to force Java8, even, when user-vm or
    system-vm is set to a higher version.
    
    This is accompilshed by creating a launcher with java-pkg_dolauncher.
    
    Bug: https://bugs.gentoo.org/792279
    Signed-off-by: Conrad Kostecki <conikost@gentoo.org>

 net-wireless/unifi/files/unifi.initd-r2   | 22 +++++++
 net-wireless/unifi/files/unifi.service-r1 | 14 +++++
 net-wireless/unifi/unifi-7.0.21-r1.ebuild | 96 +++++++++++++++++++++++++++++++
 3 files changed, 132 insertions(+)
Comment 7 Larry the Git Cow gentoo-dev 2022-04-10 15:25:02 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=eeaac5e6063359e940fd8599bea9cd130b68c4c5

commit eeaac5e6063359e940fd8599bea9cd130b68c4c5
Author:     Conrad Kostecki <conikost@gentoo.org>
AuthorDate: 2022-04-10 15:15:19 +0000
Commit:     Conrad Kostecki <conikost@gentoo.org>
CommitDate: 2022-04-10 15:24:49 +0000

    net-wireless/unifi: force java8
    
    Closes: https://bugs.gentoo.org/792279
    Signed-off-by: Conrad Kostecki <conikost@gentoo.org>

 net-wireless/unifi/files/unifi.initd-r1            | 25 ----------------------
 net-wireless/unifi/files/unifi.service             | 14 ------------
 ...{unifi-6.5.55.ebuild => unifi-6.5.55-r1.ebuild} | 15 +++++++++----
 3 files changed, 11 insertions(+), 43 deletions(-)