Github messages for voidlinux
 help / color / mirror / Atom feed
From: classabbyamp <classabbyamp@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: Re: [PR PATCH] [Merged]: [RFC] fix the openjdk alternatives mess
Date: Sun, 24 Dec 2023 14:39:54 +0100	[thread overview]
Message-ID: <20231224133954.6JBVFzoadaUmUoiJoYXEX2F_AueoIPJgHuZhbgfeyVI@z> (raw)
In-Reply-To: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-47866@inbox.vuxu.org>

[-- Attachment #1: Type: text/plain, Size: 1276 bytes --]

There's a merged pull request on the void-packages repository

[RFC] fix the openjdk alternatives mess
https://github.com/void-linux/void-packages/pull/47866

Description:
The current way the alternatives groups work for openjdk packages really sucks. They overlap and cause pkgdb errors, can get out-of-sync, and more. This approach hopes to fix (or at least improve) that.

The new package `openjdk-common` replaces the xbps trigger that added the profile script for openjdk (which was a flawed approach and should have never been done).

Instead of using alternative groups for specific JRE/JDK binaries, this approach uses just two symlinks, `/usr/lib/jvm/default-jdk` and `/usr/lib/jvm/default-jre`, which point to the selected `JAVA_HOME` (`/usr/lib/jvm/openjdkN`).  The profile script in `openjdk-common` prefers `default-jdk` to `default-jre`, and just adds them to `PATH` and `MANPATH` instead of putting things in `/usr/bin`.

With this approach, the selected JDK and JRE can probably still get out of sync, but the preference behaviour of the profile script should help mitigate this. I don't think it's currently possible to sanely deconflict/sync the alternatives groups.

#### Testing the changes
- I tested the changes in this PR: **YES**

[ci skip]

      parent reply	other threads:[~2023-12-24 13:39 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-21 23:38 [PR PATCH] " classabbyamp
2023-12-22  1:23 ` ahesford
2023-12-22  1:55 ` [PR PATCH] [Updated] " classabbyamp
2023-12-22  1:57 ` classabbyamp
2023-12-22  2:34 ` classabbyamp
2023-12-22  3:04 ` classabbyamp
2023-12-22 20:03 ` classabbyamp
2023-12-22 22:05 ` classabbyamp
2023-12-23  0:27 ` classabbyamp
2023-12-24 13:39 ` classabbyamp [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20231224133954.6JBVFzoadaUmUoiJoYXEX2F_AueoIPJgHuZhbgfeyVI@z \
    --to=classabbyamp@users.noreply.github.com \
    --cc=ml@inbox.vuxu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).