Thanks to their work!
with the build versions of er2off used here
You will now be able to run Minecraft 1.20.2+ on FreeBSD.
And Minecraft will be able to recognize multiple cpu cores!(for me, only 1.20.2 now, you maybe want Check the link above)
We will mostly be following the OpenBSD build instructions at https://prismlauncher.org/wiki/development/build-instructions/#openbsd.
sudo pkg install qt5 qt6 cmake kf5-extra-cmake-modules openjdk8 openjdk17 lwjgl glfw git
git clone --recursive https://github.com/PrismLauncher/PrismLauncher.git
and cd PrismLauncher
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX="/usr/local" -DCMAKE_PREFIX_PATH=/usr/local/lib/qt5/cmake -DENABLE_LTO=ON
cd build
and sudo make -j$(nproc) install
For FreeBSD 13.2+ or other version:
Qutoed from https://github.com/pog5/minecraft-freebsd/issues/8?notification_referrer_id=NT_kwDOA7VwZLM4NzA5Njk5ODcyOjYyMjIyNDM2#issuecomment-2031646216:@Gamer100Dev's solution worked for me. Yes, I'm on FreeBSD 14.0 RELEASE To be clearer, git clone https://github.com/LWGJL/lwjgl3. - Download https://github.com/pog5/minecraft-freebsd/blob/main/lwjgl3.tar.gz - Extract the tar.gz file - Copy the "Makefile" from the extracted tar.gz file into where you cloned lwjgl3; overwriting the original - Run this command inside of the lwjgl3 dir that you cloned: `/usr/local/bin/cmake -E env JAVACMD=/usr/local/openjdk17/bin/java JAVA8_HOME=/usr/local/openjdk8 ant all && /usr/local/bin/cmake -E env JAVACMD=/usr/local/openjdk17/bin/java JAVA8_HOME=/usr/local/openjdk8 ant release -Dbuild.offline=yes -Djavadoc.skip=yes` - Run: `# mkdir /usr/local/share/java/classes/lwjgl3 /usr/local/lib/lwjgl3` - Run: `# find /PATH/TO/GIT/lwjgl3 -name "*.so" -exec cp {} /usr/local/lib/lwjgl3/ \;` - Run: `find /PATH/TO/GIT/lwjgl3 -name "*.jar" -exec cp {} /usr/local/share/java/classes/lwjgl3/ \;` - Install minecraft-client & openjdk17-jre: `# pkg install minecraft-client openjdk17-jre` - Overwrite the original minecraft-runtime file with the one from the extracted tar: `# cp /PATH/TO/EXTRACTED/TAR/lwjgl3/minecraft-runtime /usr/loca/share/minecraft-client/minecraft-runtime` - In PrismLauncher, go to `Settings` > `Java` and set "Java Path" to: `/usr/local/share/minecraft-client/minecraft-runtime`
You need to add -Dorg.lwjgl.librarypath=/usr/local/lib/lwjgl
as a additional flag (Thanks to @er2off on Discord for this info.)