-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
addpkg(main/openjdk-21): 21.0.5 #20793
Conversation
Duplicate of: |
Duplicate of #19682 |
Note that this one is based on mainline java, and there is no TERMUX_PACKAGE_REPLACES=openjdk-17 |
The problem is not your approach. |
dfc748c
to
4b45cf9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please comment on the patches, any differences compared to what is checked in at https://github.com/termux/openjdk-mobile-termux/tree/termux/jdk-21?
I think it would help to add an "openjdk" package as well, that depends on openjdk-17 | openjdk-21
, and that provides some java selector script (for example similar to archlinux's archlinux-java). We can then also make packages depend on openjdk
instead of a specific openjdk version, where applicable (but that can be done later).
difference is that patches are to adapted for applying on mainline branch, in order to provide a more "vanilla" build.
The current Debian management on JDK isn't intuitive. While unable to provide a choice for user to fill the virtual package ( :/etc/apt$ sudo apt install java-compiler
[sudo] password for :
Package java-compiler is a virtual package provided by:
openjdk-8-jdk 8u412-ga-1
openjdk-23-jdk-headless 23~28ea-1
openjdk-23-jdk 23~28ea-1
openjdk-22-jdk-headless 22.0.1+8-2
openjdk-22-jdk 22.0.1+8-2
openjdk-21-jdk-headless 21.0.4~6ea-1
openjdk-21-jdk 21.0.4~6ea-1
openjdk-20-jdk-headless 20.0.2+9-1+b6
openjdk-20-jdk 20.0.2+9-1+b6
openjdk-19-jdk-headless 19.0.2+7-4
openjdk-19-jdk 19.0.2+7-4
openjdk-17-jdk-headless 17.0.12~6ea-1
openjdk-17-jdk 17.0.12~6ea-1
openjdk-11-jdk-headless 11.0.24~7ea-1
openjdk-11-jdk 11.0.24~7ea-1
You should explicitly select one to install.
Error: Package 'java-compiler' has no installation candidate As for java management, Debian do have something called |
|
looks like mainline java is unable to enable features on
|
Well - normally Java can be in different versions. I don't see a problem why Java 17 and 21 shouldn't be in one repo |
I've cherry-picked the setup-ubuntu.sh openjdk-21 commit to master, so that it is added to docker image. Please rebase, and in future changes CI will not have to build a custom docker image every time. edit: CI build failed, so openjdk-21 has not been added to docker image yet |
fe4b2b9
to
8280b22
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me now, thanks!
Commit messages should be updated, FIXME: fix: type redefinition introduced in 21.0.2
should be squashed, and the chore and enhance commits should be rewritten so that it is clear that they are related to openjdk-21 (i.e. start with chore(main/openjdk-21):
or enhance(main/openjdk-21):
instead)
8280b22
to
4b6abbb
Compare
(This is a pre-written, saved reply.) After downloading the build artifact, make sure to Detailed instructions, if needed.
# finding out what architecture you need
# architecture is just below the TERMUX_VERSION
termux-info
# e.g.
# [...]
# TERMUX_MAIN_PACKAGE_FORMAT=debian
# TERMUX_VERSION=0.118.0
# TERMUX__USER_ID=0
# Packages CPU architecture:
# aarch64
# [...]
# =======================
# make sure `unzip` and `tar` are installed using
pkg install unzip tar
# unzip the artifact (if you have a different architecture this might be arm, i686 or x86_64 instead)
unzip debs-aarch64-*.zip
# untar the artifact
tar xf debs-aarch64-*.tar
# You should now have a debs/ directory in your current working directory
# Install the packages from the local source using
pkg install -- ./debs/*.deb
# to clean up, you can remove the debs/ directory, .tar file and .zip file
rm -rfi debs debs-aarch64-*.zip debs-aarch64-*.tar |
I will do some tests locally, and merge this within a day assuming everything works fine. Thanks! |
For reference, here's debian's
Built files are below.
Here's the debian docs. |
4b6abbb
to
f69590e
Compare
Error with latest build, aarch64 version not available |
f69590e
to
c6da26d
Compare
cherry-pick all patches, apply them on upstream JDK, and adapted for newer $UPDATE version fix: type redefinition introduced in 21.0.2
…rrange - change base version to 21.0.3, and track GA build for upgrade - move make JOBS arg to configure stage - configure args resort - strip version string, add vendor name (Termux)
update-alternatives take the path to the real file as argument, not the symlink installation path.
update-alternatives take the path to the real file as argument, not the symlink installation path.
c6da26d
to
3c8c1ff
Compare
As done in 94fd264 for openjdk-17. See issue termux#21327.
Let's merge this? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
Thanks @nexplorer-3e ! |
cherry-pick patches from openjdk-termux-mobile, adopted for latest update
TODO: enable or disable auto updatecurrently set to tracking ga releases.