Skip to content
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

UnsatisfiedLinkError #155

Open
maxandersen opened this issue Sep 3, 2019 · 2 comments
Open

UnsatisfiedLinkError #155

maxandersen opened this issue Sep 3, 2019 · 2 comments

Comments

@maxandersen
Copy link

on first start (using java 11, osx, spacemacs) I get this:

WARNING: sun.reflect.Reflection.getCallerClass is not supported. This will impact performance.
[INFO ][Main      :  54] use java home: /Library/Java/JavaVirtualMachines/adoptopenjdk-11.jdk/Contents/Home
[INFO ][Main      :  55] use java runtime: OpenJDK Runtime Environment 11.0.4+11
[INFO ][Main      :  59] use java vm: OpenJDK 64-Bit Server VM 11.0.4+11
Exception in thread "main" java.lang.UnsatisfiedLinkError: /Users/max/Library/Caches/JNA/temp/jna15306059428763411822.tmp: dlopen(/Users/max/Library/Caches/JNA/temp/jna15306059428763411822.tmp, 1): no suitable image found.  Did find:
	/Users/max/Library/Caches/JNA/temp/jna15306059428763411822.tmp: code signature in (/Users/max/Library/Caches/JNA/temp/jna15306059428763411822.tmp) not valid for use in process using Library Validation: mapped file has no cdhash, completely unsigned? Code has to be at least ad-hoc signed.
	at java.base/java.lang.ClassLoader$NativeLibrary.load0(Native Method)
	at java.base/java.lang.ClassLoader$NativeLibrary.load(ClassLoader.java:2430)
	at java.base/java.lang.ClassLoader$NativeLibrary.loadLibrary(ClassLoader.java:2487)
	at java.base/java.lang.ClassLoader.loadLibrary0(ClassLoader.java:2684)
	at java.base/java.lang.ClassLoader.loadLibrary(ClassLoader.java:2617)
	at java.base/java.lang.Runtime.load0(Runtime.java:767)
	at java.base/java.lang.System.load(System.java:1831)
	at com.sun.jna.Native.loadNativeDispatchLibraryFromClasspath(Native.java:1018)
	at com.sun.jna.Native.loadNativeDispatchLibrary(Native.java:988)
	at com.sun.jna.Native.<clinit>(Native.java:195)
	at com.sun.jna.Structure.setAlignType(Structure.java:280)
	at com.sun.jna.Structure.<init>(Structure.java:197)
	at com.sun.jna.Structure.<init>(Structure.java:193)
	at com.sun.jna.Structure.<init>(Structure.java:180)
	at com.sun.jna.Structure.<init>(Structure.java:172)
	at com.sun.jna.platform.mac.SystemB$Timeval.<init>(SystemB.java:530)
	at oshi.hardware.platform.mac.MacCentralProcessor.<clinit>(MacCentralProcessor.java:58)
	at oshi.hardware.platform.mac.MacHardwareAbstractionLayer.getProcessor(MacHardwareAbstractionLayer.java:59)
	at meghanada.telemetry.TelemetryUtils.<clinit>(TelemetryUtils.java:113)
	at meghanada.Main.main(Main.java:69)
WARNING: sun.reflect.Reflection.getCallerClass is not supported. This will impact performance.
[INFO ][Main      :  54] use java home: /Library/Java/JavaVirtualMachines/adoptopenjdk-11.jdk/Contents/Home
[INFO ][Main      :  55] use java runtime: OpenJDK Runtime Environment 11.0.4+11
[INFO ][Main      :  59] use java vm: OpenJDK 64-Bit Server VM 11.0.4+11
Exception in thread "main" java.lang.UnsatisfiedLinkError: /Users/max/Library/Caches/JNA/temp/jna14540805177135675622.tmp: dlopen(/Users/max/Library/Caches/JNA/temp/jna14540805177135675622.tmp, 1): no suitable image found.  Did find:
	/Users/max/Library/Caches/JNA/temp/jna14540805177135675622.tmp: code signature in (/Users/max/Library/Caches/JNA/temp/jna14540805177135675622.tmp) not valid for use in process using Library Validation: mapped file has no cdhash, completely unsigned? Code has to be at least ad-hoc signed.
	at java.base/java.lang.ClassLoader$NativeLibrary.load0(Native Method)
	at java.base/java.lang.ClassLoader$NativeLibrary.load(ClassLoader.java:2430)
	at java.base/java.lang.ClassLoader$NativeLibrary.loadLibrary(ClassLoader.java:2487)
	at java.base/java.lang.ClassLoader.loadLibrary0(ClassLoader.java:2684)
	at java.base/java.lang.ClassLoader.loadLibrary(ClassLoader.java:2617)
	at java.base/java.lang.Runtime.load0(Runtime.java:767)
	at java.base/java.lang.System.load(System.java:1831)
	at com.sun.jna.Native.loadNativeDispatchLibraryFromClasspath(Native.java:1018)
	at com.sun.jna.Native.loadNativeDispatchLibrary(Native.java:988)
	at com.sun.jna.Native.<clinit>(Native.java:195)
	at com.sun.jna.Structure.setAlignType(Structure.java:280)
	at com.sun.jna.Structure.<init>(Structure.java:197)
	at com.sun.jna.Structure.<init>(Structure.java:193)
	at com.sun.jna.Structure.<init>(Structure.java:180)
	at com.sun.jna.Structure.<init>(Structure.java:172)
	at com.sun.jna.platform.mac.SystemB$Timeval.<init>(SystemB.java:530)
	at oshi.hardware.platform.mac.MacCentralProcessor.<clinit>(MacCentralProcessor.java:58)
	at oshi.hardware.platform.mac.MacHardwareAbstractionLayer.getProcessor(MacHardwareAbstractionLayer.java:59)
	at meghanada.telemetry.TelemetryUtils.<clinit>(TelemetryUtils.java:113)
	at meghanada.Main.main(Main.java:69)
@sekaiser
Copy link

sekaiser commented Dec 11, 2019

I experience the same issue using OpenJDK 64-Bit Server VM 12.0.2+10 on MacOS. I believe the issue is related to/similar to adoptium/temurin-build#1211.

When I changed the JDK version to 11.0.5+10 it worked.

@SkyloveQiu
Copy link

Switch jdk to 12.0.1 should fix it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants