The PrismLauncher package provides a Minecraft Launcher.
cmark-0.31.2, GameMode, libqrencode, libxkbcommon, Extra-CMake-Modules (ECM), libarchive, OpenGL (libglvnd or Mesa; Mesa's GL is not supported), OpenJDK-17.0.20.1-ga (and/or OpenJDK-20+), Qt-6, and toml++-3.4.0
While you can install the most recent version of OpenJDK (version 20 and above), you'll need to edit the build system of this package, tick an option in the launcher menu, and will lose support in older Minecraft versions, including mods and other things IF you did not make OpenJDK-17.0.20.1-ga the default JDK. This is because version 20 and above does not support Java 7. Version 19 and below supports Java 7. OpenJDK-17.0.20.1-ga is used as it's an LTS release that gets security updates.
Git and scdoc-1.11.5
If you installed OpenJDK-17.0.20.1-ga and it is currently not the
default JDK, but wish to make it the default, then run the following
command as the root user:
ln -v -nsf jdk-17.0.20.1-ga /opt/jdk
If you have installed OpenJDK version 20 or above and have made it the default JDK, edit the build system to allow building with Java 8 instead of 7:
sed -e 's/Java 1.7/Java 1.8/g' \
-e 's/-target 7/-target 8/g' \
-e 's/-source 7/-source 8/g' \
-i libraries/{javacheck,launcher}/CMakeLists.txtInstall PrismLauncher by running the following commands:
mkdir build &&
cd build &&
CXXFLAGS+=" -Wno-sfinae-incomplete" \
cmake -D CMAKE_INSTALL_PREFIX=/usr \
-D CMAKE_BUILD_TYPE=Release \
-W no-author -G Ninja .. &&
ninja
Now, as the root user:
ninja install
CXXFLAGS+=" -Wno-sfinae-incomplete": This disables a
warning that gives an error, warning about how some definitions were
previously incomplete in an SFINAE (Substitution Failure Is Not An Error)
context.
This launcher should walk you through how to set it up. However, one major thing needs to be done if you installed OpenJDK version 20 or above and made it the default. After you create an instance, you will need to edit that instance, go to the “Settings” section, then tick “Skip Java Compatibility Checks” to allow Minecraft to launch. This has to be done for every instance. If you installed OpenJDK-17.0.20.1-ga and made it the default JDK, this doesn't need to be done at all.
In the case that you are using a newer Minecraft instance and/or have
installed mods that require newer versions of a given JDK, you will need
to have a multi-JDK setup. This generally entails having multiple JDK
builds in /opt and having a
default JDK that gets used in all cases unless specified otherwise. An
ideal setup is to make OpenJDK-17.0.20.1-ga the default JDK, but
also install OpenJDK-20+ so that the JDK
version can be overridden per MC instance. Newer JDKs also require a
newer JDK than 17 to bootstrap from, so the one provided in this book will not
work for newer JDKs. In any case, you will need to copy the same steps in
the above paragraph, as well as changing the “Java
Installation” to point to the desired JDK. When installing the
newer JDK, it is recommended to skip making the symlink on that page so
that it doesn't become the default. If you made it the default beforehand
but wish to change it, run the following command as the root user:
ln -v -nsf jdk-17.0.20.1-ga /opt/jdk
A multi-JDK setup may look like this:
$ls /opt | grep jdkjdkjdk-17.0.20.1-gajdk-21.0.10+6...
jdk can be a symlink to either
or
jdk-21.0.10+6.
jdk-17.0.20.1-ga