MultiMC / Launcher

A custom launcher for Minecraft that allows you to easily manage multiple installations of Minecraft at once
https://multimc.org/
Other
4.32k stars 883 forks source link

[LWJGL] Failed to load a library #4693

Closed chrisdickmmann closed 2 years ago

chrisdickmmann commented 2 years ago

Operating System

macOS

Description of bug

I can't get access to the Discord for reasons I don't know.

reported:[LWJGL] Failed to load a library. Possible solutions: a) Add the directory that contains the shared library to -Djava.library.path or -Dorg.lwjgl.librarypath. b) Add the JAR that contains the shared library to the classpath.

I don't know which directory it refers to, neither do I have the /D in macOS, and the /java in / Macintosh HD does not have a library file. I haven't learned about java or any other computer science and I have no idea how to fix the problem.

below shows the output when failure " [09:12:49] [Render thread/INFO]: [STDERR]: [LWJGL] Failed to load a library. Possible solutions: a) Add the directory that contains the shared library to -Djava.library.path or -Dorg.lwjgl.librarypath. b) Add the JAR that contains the shared library to the classpath. [09:12:49] [Render thread/INFO]: [STDERR]: [LWJGL] Enable debug mode with -Dorg.lwjgl.util.Debug=true for better diagnostics. [09:12:49] [Render thread/INFO]: [STDERR]: [LWJGL] Enable the SharedLibraryLoader debug mode with -Dorg.lwjgl.util.DebugLoader=true for better diagnostics. [09:12:50] [Render thread/INFO]: [STDERR]: Failed to start Minecraft:

[09:12:50] [Render thread/INFO]: [STDERR]: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [09:12:50] [Render thread/INFO]: [STDERR]: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) [09:12:50] [Render thread/INFO]: [STDERR]: at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [09:12:50] [Render thread/INFO]: [STDERR]: at java.base/java.lang.reflect.Method.invoke(Method.java:568) [09:12:50] [Render thread/INFO]: [STDERR]: at org.multimc.onesix.OneSixLauncher.launchWithMainClass(OneSixLauncher.java:210) [09:12:50] [Render thread/INFO]: [STDERR]: at org.multimc.onesix.OneSixLauncher.launch(OneSixLauncher.java:245) [09:12:50] [Render thread/INFO]: [STDERR]: at org.multimc.EntryPoint.listen(EntryPoint.java:143) [09:12:50] [Render thread/INFO]: [STDERR]: at org.multimc.EntryPoint.main(EntryPoint.java:34) [09:12:50] [Render thread/INFO]: [STDERR]: Caused by: java.lang.NoClassDefFoundError: Could not initialize class com.mojang.blaze3d.systems.RenderSystem [09:12:50] [Render thread/INFO]: [STDERR]: at ac.a(SourceFile:65) [09:12:50] [Render thread/INFO]: [STDERR]: at dyr.a(SourceFile:2394) [09:12:50] [Render thread/INFO]: [STDERR]: at dyr.a(SourceFile:2389) [09:12:50] [Render thread/INFO]: [STDERR]: at net.minecraft.client.main.Main.main(SourceFile:206) [09:12:50] [Render thread/INFO]: [STDERR]: ... 8 more [09:12:50] [Render thread/INFO]: [STDOUT]: Exiting with -1 Process exited with code 255. "

Steps to reproduce

· download the jdk-17.0.3.1.jdk in /Macintosh HD/library/java (followed the instructions by clicking 'confirm',none configuration) · download the Multi mc and follow the in instructions · trying to launch · failed

Suspected cause

No response

This issue is unique

phit commented 2 years ago

pleasse post your full log, start the game, then click upload log in the console window and paste the link here

chrisdickmmann commented 2 years ago

Thank a lot for your reply. I did the thing as you told but the upload failed with a prompt:Socket operation timed out. I am not sure if the following goes the same.

" MultiMC version: 0.6.15-3246

Launched instance in online mode

authserver.mojang.com resolves to: [99.86.219.64, 99.86.219.35, 99.86.219.57, 99.86.219.50]

session.minecraft.net resolves to: [52.7.153.255, 54.173.66.187, 54.164.34.185]

textures.minecraft.net resolves to: [13.226.237.106, 13.226.237.8, 13.226.237.116, 13.226.237.16]

api.mojang.com resolves to: [65.8.161.67, 65.8.161.102, 65.8.161.28, 65.8.161.79]

Minecraft folder is: /Applications/MultiMC.app/Data/instances/1.18.2/.minecraft

Java path is: /usr/bin/java

Checking Java version... Java is version 17.0.3.1, using 32-bit architecture, from Oracle Corporation.

Your Java architecture is not matching your system architecture. You might want to install a 64bit Java version.

Main Class: net.minecraft.client.main.Main

Native path: /Applications/MultiMC.app/Data/instances/1.18.2/natives

Traits: traits XR:Initial traits FirstThreadOnMacOS

Libraries: /Applications/MultiMC.app/Data/libraries/org/lwjgl/lwjgl-glfw/3.2.2/lwjgl-glfw-3.2.2.jar /Applications/MultiMC.app/Data/libraries/org/lwjgl/lwjgl-jemalloc/3.2.2/lwjgl-jemalloc-3.2.2.jar /Applications/MultiMC.app/Data/libraries/org/lwjgl/lwjgl-openal/3.2.2/lwjgl-openal-3.2.2.jar /Applications/MultiMC.app/Data/libraries/org/lwjgl/lwjgl-opengl/3.2.2/lwjgl-opengl-3.2.2.jar /Applications/MultiMC.app/Data/libraries/org/lwjgl/lwjgl-stb/3.2.2/lwjgl-stb-3.2.2.jar /Applications/MultiMC.app/Data/libraries/org/lwjgl/lwjgl-tinyfd/3.2.2/lwjgl-tinyfd-3.2.2.jar /Applications/MultiMC.app/Data/libraries/org/lwjgl/lwjgl/3.2.2/lwjgl-3.2.2.jar /Applications/MultiMC.app/Data/libraries/com/mojang/logging/1.0.0/logging-1.0.0.jar /Applications/MultiMC.app/Data/libraries/com/mojang/blocklist/1.0.10/blocklist-1.0.10.jar /Applications/MultiMC.app/Data/libraries/com/mojang/patchy/2.2.10/patchy-2.2.10.jar /Applications/MultiMC.app/Data/libraries/com/github/oshi/oshi-core/5.8.5/oshi-core-5.8.5.jar /Applications/MultiMC.app/Data/libraries/net/java/dev/jna/jna/5.10.0/jna-5.10.0.jar /Applications/MultiMC.app/Data/libraries/net/java/dev/jna/jna-platform/5.10.0/jna-platform-5.10.0.jar /Applications/MultiMC.app/Data/libraries/org/slf4j/slf4j-api/1.8.0-beta4/slf4j-api-1.8.0-beta4.jar /Applications/MultiMC.app/Data/libraries/org/apache/logging/log4j/log4j-slf4j18-impl/2.16.0/log4j-slf4j18-impl-2.16.0.jar /Applications/MultiMC.app/Data/libraries/com/ibm/icu/icu4j/70.1/icu4j-70.1.jar /Applications/MultiMC.app/Data/libraries/com/mojang/javabridge/1.2.24/javabridge-1.2.24.jar /Applications/MultiMC.app/Data/libraries/net/sf/jopt-simple/jopt-simple/5.0.4/jopt-simple-5.0.4.jar /Applications/MultiMC.app/Data/libraries/io/netty/netty-all/4.1.68.Final/netty-all-4.1.68.Final.jar /Applications/MultiMC.app/Data/libraries/com/google/guava/failureaccess/1.0.1/failureaccess-1.0.1.jar /Applications/MultiMC.app/Data/libraries/com/google/guava/guava/31.0.1-jre/guava-31.0.1-jre.jar /Applications/MultiMC.app/Data/libraries/org/apache/commons/commons-lang3/3.12.0/commons-lang3-3.12.0.jar /Applications/MultiMC.app/Data/libraries/commons-io/commons-io/2.11.0/commons-io-2.11.0.jar /Applications/MultiMC.app/Data/libraries/commons-codec/commons-codec/1.15/commons-codec-1.15.jar /Applications/MultiMC.app/Data/libraries/com/mojang/brigadier/1.0.18/brigadier-1.0.18.jar /Applications/MultiMC.app/Data/libraries/com/mojang/datafixerupper/4.1.27/datafixerupper-4.1.27.jar /Applications/MultiMC.app/Data/libraries/com/google/code/gson/gson/2.8.9/gson-2.8.9.jar /Applications/MultiMC.app/Data/libraries/com/mojang/authlib/3.3.39/authlib-3.3.39.jar /Applications/MultiMC.app/Data/libraries/org/apache/commons/commons-compress/1.21/commons-compress-1.21.jar /Applications/MultiMC.app/Data/libraries/org/apache/httpcomponents/httpclient/4.5.13/httpclient-4.5.13.jar /Applications/MultiMC.app/Data/libraries/commons-logging/commons-logging/1.2/commons-logging-1.2.jar /Applications/MultiMC.app/Data/libraries/org/apache/httpcomponents/httpcore/4.4.14/httpcore-4.4.14.jar /Applications/MultiMC.app/Data/libraries/it/unimi/dsi/fastutil/8.5.6/fastutil-8.5.6.jar /Applications/MultiMC.app/Data/libraries/org/apache/logging/log4j/log4j-api/2.16.0/log4j-api-2.16.0.jar /Applications/MultiMC.app/Data/libraries/org/apache/logging/log4j/log4j-core/2.16.0/log4j-core-2.16.0.jar /Applications/MultiMC.app/Data/libraries/com/mojang/text2speech/1.12.4/text2speech-1.12.4.jar /Applications/MultiMC.app/Data/libraries/ca/weblite/java-objc-bridge/1.0.0/java-objc-bridge-1.0.0.jar /Applications/MultiMC.app/Data/libraries/com/mojang/minecraft/1.18.2/minecraft-1.18.2-client.jar

Native libraries: /Applications/MultiMC.app/Data/libraries/org/lwjgl/lwjgl-glfw/3.2.2/lwjgl-glfw-3.2.2-natives-macos.jar /Applications/MultiMC.app/Data/libraries/org/lwjgl/lwjgl-jemalloc/3.2.2/lwjgl-jemalloc-3.2.2-natives-macos.jar /Applications/MultiMC.app/Data/libraries/org/lwjgl/lwjgl-openal/3.2.2/lwjgl-openal-3.2.2-natives-macos.jar /Applications/MultiMC.app/Data/libraries/org/lwjgl/lwjgl-opengl/3.2.2/lwjgl-opengl-3.2.2-natives-macos.jar /Applications/MultiMC.app/Data/libraries/org/lwjgl/lwjgl-stb/3.2.2/lwjgl-stb-3.2.2-natives-macos.jar /Applications/MultiMC.app/Data/libraries/org/lwjgl/lwjgl-tinyfd/3.2.2/lwjgl-tinyfd-3.2.2-natives-macos.jar /Applications/MultiMC.app/Data/libraries/org/lwjgl/lwjgl/3.2.2/lwjgl-3.2.2-natives-macos.jar /Applications/MultiMC.app/Data/libraries/ca/weblite/java-objc-bridge/1.0.0/java-objc-bridge-1.0.0-natives-osx.jar

Params: --username --version MultiMC5 --gameDir /Applications/MultiMC.app/Data/instances/1.18.2/.minecraft --assetsDir /Applications/MultiMC.app/Data/assets --assetIndex 1.18 --uuid --accessToken --userType --versionType release

Window size: 854 x 480

Java Arguments: [-Xdock:icon=icon.png, -Xdock:name="MultiMC: 1.18.2", -XstartOnFirstThread, -Xms512m, -Xmx1024m, -Duser.language=en]

Minecraft process ID: 43366

Using onesix launcher.

[16:58:45] [Render thread/INFO]: [STDERR]: [LWJGL] Failed to load a library. Possible solutions: a) Add the directory that contains the shared library to -Djava.library.path or -Dorg.lwjgl.librarypath. b) Add the JAR that contains the shared library to the classpath. [16:58:45] [Render thread/INFO]: [STDERR]: [LWJGL] Enable debug mode with -Dorg.lwjgl.util.Debug=true for better diagnostics. [16:58:45] [Render thread/INFO]: [STDERR]: [LWJGL] Enable the SharedLibraryLoader debug mode with -Dorg.lwjgl.util.DebugLoader=true for better diagnostics. [16:58:45] [Render thread/INFO]: [STDERR]: Failed to start Minecraft:

[16:58:45] [Render thread/INFO]: [STDERR]: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [16:58:45] [Render thread/INFO]: [STDERR]: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) [16:58:45] [Render thread/INFO]: [STDERR]: at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [16:58:45] [Render thread/INFO]: [STDERR]: at java.base/java.lang.reflect.Method.invoke(Method.java:568) [16:58:45] [Render thread/INFO]: [STDERR]: at org.multimc.onesix.OneSixLauncher.launchWithMainClass(OneSixLauncher.java:210) [16:58:45] [Render thread/INFO]: [STDERR]: at org.multimc.onesix.OneSixLauncher.launch(OneSixLauncher.java:245) [16:58:45] [Render thread/INFO]: [STDERR]: at org.multimc.EntryPoint.listen(EntryPoint.java:143) [16:58:45] [Render thread/INFO]: [STDERR]: at org.multimc.EntryPoint.main(EntryPoint.java:34) [16:58:45] [Render thread/INFO]: [STDERR]: Caused by: java.lang.NoClassDefFoundError: Could not initialize class com.mojang.blaze3d.systems.RenderSystem [16:58:45] [Render thread/INFO]: [STDERR]: at ac.a(SourceFile:65) [16:58:45] [Render thread/INFO]: [STDERR]: at dyr.a(SourceFile:2394) [16:58:45] [Render thread/INFO]: [STDERR]: at dyr.a(SourceFile:2389) [16:58:45] [Render thread/INFO]: [STDERR]: at net.minecraft.client.main.Main.main(SourceFile:206) [16:58:45] [Render thread/INFO]: [STDERR]: ... 8 more [16:58:45] [Render thread/INFO]: [STDOUT]: Exiting with -1 Process exited with code 255. MultiMC: Log upload triggered at: 18 May 2022 16:58:49 +0800 MultiMC: Log upload failed! "

phit commented 2 years ago

if you are on a new M1 Mac you will need to download Java for x86_64 not ARM(aarch64)

chrisdickmmann commented 2 years ago

It's working fine now, glad that you are patient with my issue, thanks again.

rebelAlliance09 commented 1 year ago

Hi I have the same problem but I can't find where to install java 17 x86_64 any help?

chrisdickmmann commented 1 year ago

Hi I have the same problem but I can't find where to install java 17 x86_64 any help? I don't recall exactly how I installed it. Commonly, I use bing to search an app with its name. And this is what I've got: ''' https://www.oracle.com/java/technologies/downloads/#jdk19-linux ''' This site of oracle offer java downloads for mutiple platforms. There are many choice button as you filp the page. Beware to choose the one fits.

In the upper case, I guess you should try /java17/macOS/x64 DMG Installer

Hope it might help.

phit commented 1 year ago

@rebelAlliance09 https://github.com/MultiMC/Launcher/wiki/Using-the-right-Java#macos

tarbaII commented 8 months ago

Using x64 Java seems like more of a temporary solution than a permanent one. Is there any solution to this problem for ARM64 Java?

phit commented 8 months ago

not at this time https://github.com/MultiMC/Launcher/issues/5075