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

Error installing Darklaf theme on M1 Mac #240

Closed
Syer10 opened this issue Jun 23, 2021 · 32 comments · Fixed by #241
Closed

Error installing Darklaf theme on M1 Mac #240

Syer10 opened this issue Jun 23, 2021 · 32 comments · Fixed by #241
Labels
bug Something isn't working macOS Related to the macOS operating system

Comments

@Syer10
Copy link

Syer10 commented Jun 23, 2021

Describe the bug
On the M1 Mac architecture(aarch64), installing Darklaf themes throws an error about wrong architecture with libdarklaf-macos.dylib

To Reproduce

  1. Have a M1 mac
  2. Install a Darklaf theme with LafManager

Additional Information:

  • OS: macOS
  • OS Version: 11.4
  • Darklaf Version: 2.6.1

Additional context
Relevant stacktrace from my application, TachideskJUI

[2021-06-23 16:15:36] [SEVERE] Could not load library libdarklaf-macos.dylib. [at com.github.weisj.darklaf.platform.AbstractLibrary]
java.lang.UnsatisfiedLinkError: /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils177379658590417912731646977618469/libdarklaf-macos.dylib: dlopen(/private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils177379658590417912731646977618469/libdarklaf-macos.dylib, 1): no suitable image found.  Did find:
	/private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils177379658590417912731646977618469/libdarklaf-macos.dylib: mach-o, but wrong architecture
	/private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils177379658590417912731646977618469/libdarklaf-macos.dylib: mach-o, but wrong architecture
	at java.base/jdk.internal.loader.NativeLibraries.load(Native Method)
	at java.base/jdk.internal.loader.NativeLibraries$NativeLibraryImpl.open(NativeLibraries.java:383)
	at java.base/jdk.internal.loader.NativeLibraries.loadLibrary(NativeLibraries.java:227)
	at java.base/jdk.internal.loader.NativeLibraries.loadLibrary(NativeLibraries.java:169)
	at java.base/java.lang.ClassLoader.loadLibrary(ClassLoader.java:2407)
	at java.base/java.lang.Runtime.load0(Runtime.java:747)
	at java.base/java.lang.System.load(System.java:1857)
	at com.github.weisj.darklaf.platform.NativeUtil.loadLibraryFromJar(NativeUtil.java:103)
	at com.github.weisj.darklaf.platform.AbstractLibrary.loadLibrary(AbstractLibrary.java:60)
	at com.github.weisj.darklaf.platform.AbstractLibrary.updateLibrary(AbstractLibrary.java:48)
	at com.github.weisj.darklaf.platform.macos.MacOSDecorationsProvider.initialize(MacOSDecorationsProvider.java:49)
	at com.github.weisj.darklaf.platform.DecorationsHandler.initialize(DecorationsHandler.java:99)
	at com.github.weisj.darklaf.DarkLaf.setupDecorations(DarkLaf.java:131)
	at com.github.weisj.darklaf.DarkLaf.initialize(DarkLaf.java:123)
	at java.desktop/javax.swing.UIManager.setLookAndFeel(UIManager.java:586)
	at com.github.weisj.darklaf.LafInstaller.install(LafInstaller.java:48)
	at com.github.weisj.darklaf.LafManager.install(LafManager.java:438)
	at com.github.weisj.darklaf.LafManager.installTheme(LafManager.java:419)
	at com.github.weisj.darklaf.LafManager.install(LafManager.java:429)
	at ca.gosyer.ui.main.MainKt$main$1$1.invokeSuspend(main.kt:92)
	at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
	at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
	at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:316)
	at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:770)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715)
	at java.base/java.security.AccessController.doPrivileged(AccessController.java:391)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
	at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:740)
	at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
	at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)
@Syer10 Syer10 added the bug Something isn't working label Jun 23, 2021
Syer10 referenced this issue in Suwayomi/Suwayomi-JUI Jun 23, 2021
@weisJ
Copy link
Owner

weisJ commented Jun 23, 2021

What does System.getProperty("sun.arch.data.model") return on M1?

@Syer10
Copy link
Author

Syer10 commented Jun 23, 2021

64

weisJ added a commit that referenced this issue Jun 23, 2021
…ded, when selecting the decorations provider.

To do this properly we add new flags to SystemInfo indicating whether the current arch supports X86 or is an ARM/M1 based cpu. The X86 support detection is most definitely incorrect but will work for most common processors. Relates to #240
@weisJ
Copy link
Owner

weisJ commented Jun 23, 2021

For now I'll disable the native features for M1 based macs. I'll try to get the binaries compiled for M1 though.

@Syer10
Copy link
Author

Syer10 commented Jun 23, 2021

Got it 👌

@weisJ weisJ linked a pull request Jul 6, 2021 that will close this issue
@weisJ
Copy link
Owner

weisJ commented Jul 7, 2021

I was now able to build the native libraries for M1 targets. However I cannot test, whether the produced binary can actually be loaded. Could you please try out the version from #241?

@weisJ weisJ added the macOS Related to the macOS operating system label Jul 7, 2021
@Syer10
Copy link
Author

Syer10 commented Jul 7, 2021

I dont think it is being loaded, this is what shows up in the logs

[2021-07-07 15:48:01] [FINE] Setting log level to ALL [at com.github.weisj.darklaf.LafManager]
[2021-07-07 15:48:01] [FINE] Setting theme to IntelliJ [at com.github.weisj.darklaf.LafInstaller]
[2021-07-07 15:48:01] [FINE] Setting theme to IntelliJ [at com.github.weisj.darklaf.LafInstaller]
[2021-07-07 15:48:01] [FINE] Installing theme IntelliJ [at com.github.weisj.darklaf.LafInstaller]
[2021-07-07 15:48:02] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/b10bf80aab5c5536df1c656b1698d2ed41254c8d/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowUp.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 15:48:02] [FINER] Inferred size of icon 'arrowUp.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 15:48:02] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/b10bf80aab5c5536df1c656b1698d2ed41254c8d/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowDown.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 15:48:02] [FINER] Inferred size of icon 'arrowDown.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 15:48:02] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/b10bf80aab5c5536df1c656b1698d2ed41254c8d/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowRight.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 15:48:02] [FINER] Inferred size of icon 'arrowRight.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 15:48:02] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/b10bf80aab5c5536df1c656b1698d2ed41254c8d/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/horizontalGrip.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 15:48:02] [FINER] Inferred size of icon 'horizontalGrip.svg' to java.awt.Dimension[width=5,height=20] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 15:48:02] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/b10bf80aab5c5536df1c656b1698d2ed41254c8d/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowDownDisabled.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 15:48:02] [FINER] Inferred size of icon 'arrowDownDisabled.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 15:48:02] [INFO] Setting installed theme: IntelliJ [at com.github.weisj.darklaf.LafManager]

@weisJ
Copy link
Owner

weisJ commented Jul 7, 2021

Oh I forgot to remove the check that disables library loading on non x86-64 architectures. I have released a new snapshot, which fixes that.

@Syer10
Copy link
Author

Syer10 commented Jul 7, 2021

There doesnt seem to be any changes with the new snapshot, its the same logs

@weisJ
Copy link
Owner

weisJ commented Jul 7, 2021

It may take some time until the snapshot is available. If you depend on darklaf-macos-m1 you can check, whether MacOSLibrary matches the source in the PR just to be sure.

I found the mistake. Just issued a new snapshot

@Syer10
Copy link
Author

Syer10 commented Jul 7, 2021

New error

[2021-07-07 17:03:53] [FINE] Setting log level to ALL [at com.github.weisj.darklaf.LafManager]
[2021-07-07 17:03:53] [FINE] Setting theme to IntelliJ [at com.github.weisj.darklaf.LafInstaller]
[2021-07-07 17:03:53] [FINE] Setting theme to Darcula [at com.github.weisj.darklaf.LafInstaller]
[2021-07-07 17:03:53] [FINE] Installing theme Darcula [at com.github.weisj.darklaf.LafInstaller]
[2021-07-07 17:03:53] [SEVERE] Could not load library libdarklaf-macos.dylib. [at com.github.weisj.darklaf.platform.AbstractLibrary]
java.lang.UnsatisfiedLinkError: /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils847845429165005717147072479709593/libdarklaf-macos.dylib: dlopen(/private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils847845429165005717147072479709593/libdarklaf-macos.dylib, 1): Library not loaded: @rpath/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation
  Referenced from: /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils847845429165005717147072479709593/libdarklaf-macos.dylib
  Reason: image not found
	at java.base/jdk.internal.loader.NativeLibraries.load(Native Method)
	at java.base/jdk.internal.loader.NativeLibraries$NativeLibraryImpl.open(NativeLibraries.java:383)
	at java.base/jdk.internal.loader.NativeLibraries.loadLibrary(NativeLibraries.java:227)
	at java.base/jdk.internal.loader.NativeLibraries.loadLibrary(NativeLibraries.java:169)
	at java.base/java.lang.ClassLoader.loadLibrary(ClassLoader.java:2407)
	at java.base/java.lang.Runtime.load0(Runtime.java:747)
	at java.base/java.lang.System.load(System.java:1857)
	at com.github.weisj.darklaf.platform.NativeUtil.loadLibraryFromJar(NativeUtil.java:103)
	at com.github.weisj.darklaf.platform.AbstractLibrary.loadLibrary(AbstractLibrary.java:60)
	at com.github.weisj.darklaf.platform.AbstractLibrary.updateLibrary(AbstractLibrary.java:48)
	at com.github.weisj.darklaf.platform.macos.MacOSDecorationsProvider.initialize(MacOSDecorationsProvider.java:58)
	at com.github.weisj.darklaf.platform.DecorationsHandler.initialize(DecorationsHandler.java:99)
	at com.github.weisj.darklaf.DarkLaf.setupDecorations(DarkLaf.java:131)
	at com.github.weisj.darklaf.DarkLaf.initialize(DarkLaf.java:123)
	at java.desktop/javax.swing.UIManager.setLookAndFeel(UIManager.java:586)
	at com.github.weisj.darklaf.LafInstaller.install(LafInstaller.java:48)
	at com.github.weisj.darklaf.LafManager.install(LafManager.java:438)
	at com.github.weisj.darklaf.LafManager.installTheme(LafManager.java:419)
	at com.github.weisj.darklaf.LafManager.install(LafManager.java:429)
	at ca.gosyer.ui.main.MainKt$main$1$1.invokeSuspend(main.kt:92)
	at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
	at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
	at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:316)
	at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:770)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715)
	at java.base/java.security.AccessController.doPrivileged(AccessController.java:391)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
	at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:740)
	at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
	at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)
[2021-07-07 17:03:54] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/b81ef18976906f84b4f94d363b2954e4cd03beea/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowUp.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:03:54] [FINER] Inferred size of icon 'arrowUp.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:03:54] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/b81ef18976906f84b4f94d363b2954e4cd03beea/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowDown.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:03:54] [FINER] Inferred size of icon 'arrowDown.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:03:54] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/b81ef18976906f84b4f94d363b2954e4cd03beea/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowRight.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:03:54] [FINER] Inferred size of icon 'arrowRight.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:03:54] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/b81ef18976906f84b4f94d363b2954e4cd03beea/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/horizontalGrip.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:03:54] [FINER] Inferred size of icon 'horizontalGrip.svg' to java.awt.Dimension[width=5,height=20] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:03:54] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/b81ef18976906f84b4f94d363b2954e4cd03beea/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowDownDisabled.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:03:54] [FINER] Inferred size of icon 'arrowDownDisabled.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:03:54] [INFO] Setting installed theme: Darcula [at com.github.weisj.darklaf.LafManager]

@weisJ
Copy link
Owner

weisJ commented Jul 7, 2021

That is an error I expected would occur. What is the system framework path on you machine (probably something like /System/Library/Frameworks/) and where is the JavaNativeFoundation.framework located in it (this one may be inside the JavaVM framework)

@Syer10
Copy link
Author

Syer10 commented Jul 7, 2021

I found 2 of them on my machine, the Azul one is the jdk I am using for my application

/Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework
/Library/Java/JavaVirtualMachines/zulu-11.jre/Contents/Home/lib/JavaNativeFoundation.framework

And there is a MacHD/Library/Frameworks folder, but only Mono and ITunes are there

@weisJ
Copy link
Owner

weisJ commented Jul 7, 2021

Where is the java executable located relative to the framework (in both cases)?

@Syer10
Copy link
Author

Syer10 commented Jul 7, 2021

'java' being the executable

/Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/bin/java
/Library/Java/JavaVirtualMachines/zulu-11.jre/Contents/Home/bin/java

@weisJ
Copy link
Owner

weisJ commented Jul 7, 2021

I just released a snapshot with an additional search path in the library

@Syer10
Copy link
Author

Syer10 commented Jul 7, 2021

Seems to be the same crash, I also invalidated caches and tried again and got this

[2021-07-07 17:51:43] [FINE] Setting log level to ALL [at com.github.weisj.darklaf.LafManager]
[2021-07-07 17:51:43] [FINE] Setting theme to IntelliJ [at com.github.weisj.darklaf.LafInstaller]
[2021-07-07 17:51:43] [FINE] Setting theme to Darcula [at com.github.weisj.darklaf.LafInstaller]
[2021-07-07 17:51:43] [FINE] Installing theme Darcula [at com.github.weisj.darklaf.LafInstaller]
[2021-07-07 17:51:43] [SEVERE] Could not load library libdarklaf-macos.dylib. [at com.github.weisj.darklaf.platform.AbstractLibrary]
java.lang.UnsatisfiedLinkError: /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils876545716972086661471941844564102/libdarklaf-macos.dylib: dlopen(/private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils876545716972086661471941844564102/libdarklaf-macos.dylib, 1): Library not loaded: @rpath/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation
  Referenced from: /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils876545716972086661471941844564102/libdarklaf-macos.dylib
  Reason: image not found
	at java.base/jdk.internal.loader.NativeLibraries.load(Native Method)
	at java.base/jdk.internal.loader.NativeLibraries$NativeLibraryImpl.open(NativeLibraries.java:383)
	at java.base/jdk.internal.loader.NativeLibraries.loadLibrary(NativeLibraries.java:227)
	at java.base/jdk.internal.loader.NativeLibraries.loadLibrary(NativeLibraries.java:169)
	at java.base/java.lang.ClassLoader.loadLibrary(ClassLoader.java:2407)
	at java.base/java.lang.Runtime.load0(Runtime.java:747)
	at java.base/java.lang.System.load(System.java:1857)
	at com.github.weisj.darklaf.platform.NativeUtil.loadLibraryFromJar(NativeUtil.java:103)
	at com.github.weisj.darklaf.platform.AbstractLibrary.loadLibrary(AbstractLibrary.java:60)
	at com.github.weisj.darklaf.platform.AbstractLibrary.updateLibrary(AbstractLibrary.java:48)
	at com.github.weisj.darklaf.platform.macos.MacOSDecorationsProvider.initialize(MacOSDecorationsProvider.java:58)
	at com.github.weisj.darklaf.platform.DecorationsHandler.initialize(DecorationsHandler.java:99)
	at com.github.weisj.darklaf.DarkLaf.setupDecorations(DarkLaf.java:131)
	at com.github.weisj.darklaf.DarkLaf.initialize(DarkLaf.java:123)
	at java.desktop/javax.swing.UIManager.setLookAndFeel(UIManager.java:586)
	at com.github.weisj.darklaf.LafInstaller.install(LafInstaller.java:48)
	at com.github.weisj.darklaf.LafManager.install(LafManager.java:438)
	at com.github.weisj.darklaf.LafManager.installTheme(LafManager.java:419)
	at com.github.weisj.darklaf.LafManager.install(LafManager.java:429)
	at ca.gosyer.ui.main.MainKt$main$1$1.invokeSuspend(main.kt:92)
	at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
	at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
	at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:316)
	at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:770)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715)
	at java.base/java.security.AccessController.doPrivileged(AccessController.java:391)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
	at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:740)
	at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
	at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)
[2021-07-07 17:51:44] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/b81ef18976906f84b4f94d363b2954e4cd03beea/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowUp.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:51:44] [FINER] Inferred size of icon 'arrowUp.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:51:44] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/b81ef18976906f84b4f94d363b2954e4cd03beea/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowDown.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:51:44] [FINER] Inferred size of icon 'arrowDown.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:51:44] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/b81ef18976906f84b4f94d363b2954e4cd03beea/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowRight.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:51:44] [FINER] Inferred size of icon 'arrowRight.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:51:44] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/b81ef18976906f84b4f94d363b2954e4cd03beea/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/horizontalGrip.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:51:44] [FINER] Inferred size of icon 'horizontalGrip.svg' to java.awt.Dimension[width=5,height=20] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:51:44] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/b81ef18976906f84b4f94d363b2954e4cd03beea/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowDownDisabled.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:51:44] [FINER] Inferred size of icon 'arrowDownDisabled.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-07 17:51:44] [INFO] Setting installed theme: Darcula [at com.github.weisj.darklaf.LafManager]

@weisJ
Copy link
Owner

weisJ commented Jul 7, 2021

I'll have to investigate this a bit further. There should be away to load the JavaNativeFoundation framwork, which resides inside the jdk.

@weisJ
Copy link
Owner

weisJ commented Jul 8, 2021

It seems like that JavaNativeFoundation has been deprecated for arm64. I’ll probably include the framework myself then (it isn’t that large to begin with)

@weisJ
Copy link
Owner

weisJ commented Jul 9, 2021

I have now published a snapshot which includes the framwork. Let me know if the lastest snapshot works for you.

@Syer10
Copy link
Author

Syer10 commented Jul 9, 2021

New error

objc[26522]: Class JNFException is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12e6c90a0) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils9468530113975013743513791943550805/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x166a690a0). One of the two will be used. Which one is undefined.
objc[26522]: Class JNFTypeCoercer is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12e6c90f0) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils9468530113975013743513791943550805/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x166a690f0). One of the two will be used. Which one is undefined.
objc[26522]: Class JNFInternalJavaClassToCoersionHolder is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12e6c9118) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils9468530113975013743513791943550805/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x166a69118). One of the two will be used. Which one is undefined.
objc[26522]: Class JNFStringCoercion is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12e6c91b8) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils9468530113975013743513791943550805/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x166a691b8). One of the two will be used. Which one is undefined.
objc[26522]: Class JNFNumberCoercion is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12e6c9208) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils9468530113975013743513791943550805/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x166a69208). One of the two will be used. Which one is undefined.
objc[26522]: Class JNFDateCoercion is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12e6c9258) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils9468530113975013743513791943550805/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x166a69258). One of the two will be used. Which one is undefined.
objc[26522]: Class JNFMapCoercion is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12e6c92a8) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils9468530113975013743513791943550805/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x166a692a8). One of the two will be used. Which one is undefined.
objc[26522]: Class JNFListCoercion is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12e6c92f8) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils9468530113975013743513791943550805/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x166a692f8). One of the two will be used. Which one is undefined.
objc[26522]: Class JNFSetCoercion is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12e6c9348) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils9468530113975013743513791943550805/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x166a69348). One of the two will be used. Which one is undefined.
objc[26522]: Class JNFDefaultCoercions is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12e6c9370) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils9468530113975013743513791943550805/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x166a69370). One of the two will be used. Which one is undefined.
objc[26522]: Class JNFJObjectWrapper is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12e6c93c0) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils9468530113975013743513791943550805/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x166a693c0). One of the two will be used. Which one is undefined.
objc[26522]: Class JNFWeakJObjectWrapper is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12e6c9410) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils9468530113975013743513791943550805/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x166a69410). One of the two will be used. Which one is undefined.
objc[26522]: Class JNFRunLoop is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12e6c9488) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils9468530113975013743513791943550805/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x166a69488). One of the two will be used. Which one is undefined.
objc[26522]: Class JNFRunnableWrapper is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12e6c94d8) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils9468530113975013743513791943550805/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x166a694d8). One of the two will be used. Which one is undefined.
objc[26522]: Class JNFRunnable is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12e6c9528) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils9468530113975013743513791943550805/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x166a69528). One of the two will be used. Which one is undefined.
[2021-07-09 14:39:02] [INFO] Loaded libdarklaf-macos.dylib. [at com.github.weisj.darklaf.platform.AbstractLibrary]
[2021-07-09 14:39:02] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/bb65827e00b1ecb3249a35249fe03f132dddbe70/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowUp.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 14:39:02] [FINER] Inferred size of icon 'arrowUp.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 14:39:02] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/bb65827e00b1ecb3249a35249fe03f132dddbe70/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowDown.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 14:39:02] [FINER] Inferred size of icon 'arrowDown.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 14:39:02] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/bb65827e00b1ecb3249a35249fe03f132dddbe70/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowRight.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 14:39:02] [FINER] Inferred size of icon 'arrowRight.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 14:39:02] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/bb65827e00b1ecb3249a35249fe03f132dddbe70/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/horizontalGrip.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 14:39:02] [FINER] Inferred size of icon 'horizontalGrip.svg' to java.awt.Dimension[width=5,height=20] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 14:39:02] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/bb65827e00b1ecb3249a35249fe03f132dddbe70/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowDownDisabled.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 14:39:02] [FINER] Inferred size of icon 'arrowDownDisabled.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
Exception in thread "DefaultDispatcher-worker-2 @coroutine#5" java.lang.UnsatisfiedLinkError: 'long com.github.weisj.darklaf.platform.macos.JNIDecorationsMacOS.getComponentPointer(java.awt.Window)'
	at com.github.weisj.darklaf.platform.macos.JNIDecorationsMacOS.getComponentPointer(Native Method)
	at com.github.weisj.darklaf.platform.macos.ui.MacOSDecorationsUtil.installDecorations(MacOSDecorationsUtil.java:46)
	at com.github.weisj.darklaf.platform.macos.ui.MacOSTitlePane.install(MacOSTitlePane.java:126)
	at com.github.weisj.darklaf.platform.decorations.CustomTitlePane.addNotify(CustomTitlePane.java:40)
	at java.desktop/java.awt.Container.addImpl(Container.java:1146)
	at java.desktop/javax.swing.JLayeredPane.addImpl(JLayeredPane.java:233)
	at java.desktop/java.awt.Container.add(Container.java:997)
	at com.github.weisj.darklaf.ui.rootpane.DarkRootPaneUI.setTitlePane(DarkRootPaneUI.java:180)
	at com.github.weisj.darklaf.ui.rootpane.DarkRootPaneUI.installClientDecorations(DarkRootPaneUI.java:156)
	at com.github.weisj.darklaf.ui.rootpane.DarkRootPaneUI.updateClientDecoration(DarkRootPaneUI.java:235)
	at com.github.weisj.darklaf.ui.rootpane.DarkRootPaneUI.installUI(DarkRootPaneUI.java:71)
	at java.desktop/javax.swing.JComponent.setUI(JComponent.java:685)
	at java.desktop/javax.swing.JRootPane.setUI(JRootPane.java:445)
	at java.desktop/javax.swing.JRootPane.updateUI(JRootPane.java:455)
	at java.desktop/javax.swing.SwingUtilities.updateComponentTreeUI0(SwingUtilities.java:1363)
	at java.desktop/javax.swing.SwingUtilities.updateComponentTreeUI0(SwingUtilities.java:1378)
	at java.desktop/javax.swing.SwingUtilities.updateComponentTreeUI(SwingUtilities.java:1354)
	at com.github.weisj.darklaf.LafInstaller.updateLafRecursively(LafInstaller.java:67)
	at com.github.weisj.darklaf.LafInstaller.updateLaf(LafInstaller.java:59)
	at com.github.weisj.darklaf.LafInstaller.install(LafInstaller.java:49)
	at com.github.weisj.darklaf.LafManager.install(LafManager.java:438)
	at com.github.weisj.darklaf.LafManager.installTheme(LafManager.java:419)
	at com.github.weisj.darklaf.LafManager.install(LafManager.java:429)
	at ca.gosyer.ui.main.MainKt$main$1$1.invokeSuspend(main.kt:92)
	(Coroutine boundary)
	at ca.gosyer.ui.main.MainKt$main$1.invokeSuspend(main.kt:91)
	at kotlinx.coroutines.flow.FlowKt__TransformKt$onEach$$inlined$unsafeTransform$1$2.emit(Transform.kt:136)
	at kotlinx.coroutines.flow.FlowKt__ChannelsKt.emitAllImpl$FlowKt__ChannelsKt(Channels.kt:62)
	at kotlinx.coroutines.flow.internal.ChannelFlow$collect$2.invokeSuspend(ChannelFlow.kt:123)
	at kotlinx.coroutines.flow.FlowKt__CollectKt$launchIn$1.invokeSuspend(Collect.kt:50)
	(Coroutine creation stacktrace)
	at kotlin.coroutines.intrinsics.IntrinsicsKt__IntrinsicsJvmKt.createCoroutineUnintercepted(IntrinsicsJvm.kt:122)
	at kotlinx.coroutines.intrinsics.CancellableKt.startCoroutineCancellable(Cancellable.kt:30)
	at kotlinx.coroutines.flow.FlowKt__CollectKt.launchIn(Collect.kt:49)
	at kotlinx.coroutines.flow.FlowKt.launchIn(Unknown Source)
	at ca.gosyer.ui.main.MainKt.main(main.kt:95)
	at ca.gosyer.ui.main.MainKt.main(main.kt)
Caused by: java.lang.UnsatisfiedLinkError: 'long com.github.weisj.darklaf.platform.macos.JNIDecorationsMacOS.getComponentPointer(java.awt.Window)'
	at com.github.weisj.darklaf.platform.macos.JNIDecorationsMacOS.getComponentPointer(Native Method)
	at com.github.weisj.darklaf.platform.macos.ui.MacOSDecorationsUtil.installDecorations(MacOSDecorationsUtil.java:46)
	at com.github.weisj.darklaf.platform.macos.ui.MacOSTitlePane.install(MacOSTitlePane.java:126)
	at com.github.weisj.darklaf.platform.decorations.CustomTitlePane.addNotify(CustomTitlePane.java:40)
	at java.desktop/java.awt.Container.addImpl(Container.java:1146)
	at java.desktop/javax.swing.JLayeredPane.addImpl(JLayeredPane.java:233)
	at java.desktop/java.awt.Container.add(Container.java:997)
	at com.github.weisj.darklaf.ui.rootpane.DarkRootPaneUI.setTitlePane(DarkRootPaneUI.java:180)
	at com.github.weisj.darklaf.ui.rootpane.DarkRootPaneUI.installClientDecorations(DarkRootPaneUI.java:156)
	at com.github.weisj.darklaf.ui.rootpane.DarkRootPaneUI.updateClientDecoration(DarkRootPaneUI.java:235)
	at com.github.weisj.darklaf.ui.rootpane.DarkRootPaneUI.installUI(DarkRootPaneUI.java:71)
	at java.desktop/javax.swing.JComponent.setUI(JComponent.java:685)
	at java.desktop/javax.swing.JRootPane.setUI(JRootPane.java:445)
	at java.desktop/javax.swing.JRootPane.updateUI(JRootPane.java:455)
	at java.desktop/javax.swing.SwingUtilities.updateComponentTreeUI0(SwingUtilities.java:1363)
	at java.desktop/javax.swing.SwingUtilities.updateComponentTreeUI0(SwingUtilities.java:1378)
	at java.desktop/javax.swing.SwingUtilities.updateComponentTreeUI(SwingUtilities.java:1354)
	at com.github.weisj.darklaf.LafInstaller.updateLafRecursively(LafInstaller.java:67)
	at com.github.weisj.darklaf.LafInstaller.updateLaf(LafInstaller.java:59)
	at com.github.weisj.darklaf.LafInstaller.install(LafInstaller.java:49)
	at com.github.weisj.darklaf.LafManager.install(LafManager.java:438)
	at com.github.weisj.darklaf.LafManager.installTheme(LafManager.java:419)
	at com.github.weisj.darklaf.LafManager.install(LafManager.java:429)
	at ca.gosyer.ui.main.MainKt$main$1$1.invokeSuspend(main.kt:92)
	at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
	at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
	at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:316)
	at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:770)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715)
	at java.base/java.security.AccessController.doPrivileged(AccessController.java:391)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
	at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:740)
	at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
	at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)

@weisJ
Copy link
Owner

weisJ commented Jul 9, 2021

Well at least it is now loading the packaged framework 😅. I think the problem is that the framework I am loading has the same name as the one inside the jdk, which trips the linker. So back to the drawing board it is. I can see two possibilities here:

  1. During linking change the install name of the packaged framework (rather hackish, but it would probably work)
  2. Try again to link against the framework packaged in the jdk and let the dynamic Linker decide whether it needs to load my own packaged version.

@weisJ
Copy link
Owner

weisJ commented Jul 9, 2021

How are you running your program? Is it packaged as its own application?

@Syer10
Copy link
Author

Syer10 commented Jul 9, 2021

How are you running your program? Is it packaged as its own application?

I provide fatjars and jpackage builds for my application, though for testing I use the gradle run task that jetbrains compose provides, which is basically like running the main function from a IDE.

@weisJ
Copy link
Owner

weisJ commented Jul 9, 2021

New snapshot out.

@Syer10
Copy link
Author

Syer10 commented Jul 9, 2021

And new error is found 😄

[2021-07-09 17:58:21] [FINE] Setting log level to ALL [at com.github.weisj.darklaf.LafManager]
[2021-07-09 17:58:21] [FINE] Setting theme to IntelliJ [at com.github.weisj.darklaf.LafInstaller]
[2021-07-09 17:58:21] [FINE] Setting theme to Darcula [at com.github.weisj.darklaf.LafInstaller]
[2021-07-09 17:58:21] [FINE] Installing theme Darcula [at com.github.weisj.darklaf.LafInstaller]
objc[27311]: Class JNFException is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12f7110a0) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils102205547039166539630633926507479/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x13f3d90a0). One of the two will be used. Which one is undefined.
objc[27311]: Class JNFTypeCoercer is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12f7110f0) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils102205547039166539630633926507479/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x13f3d90f0). One of the two will be used. Which one is undefined.
objc[27311]: Class JNFInternalJavaClassToCoersionHolder is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12f711118) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils102205547039166539630633926507479/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x13f3d9118). One of the two will be used. Which one is undefined.
objc[27311]: Class JNFStringCoercion is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12f7111b8) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils102205547039166539630633926507479/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x13f3d91b8). One of the two will be used. Which one is undefined.
objc[27311]: Class JNFNumberCoercion is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12f711208) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils102205547039166539630633926507479/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x13f3d9208). One of the two will be used. Which one is undefined.
objc[27311]: Class JNFDateCoercion is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12f711258) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils102205547039166539630633926507479/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x13f3d9258). One of the two will be used. Which one is undefined.
objc[27311]: Class JNFMapCoercion is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12f7112a8) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils102205547039166539630633926507479/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x13f3d92a8). One of the two will be used. Which one is undefined.
objc[27311]: Class JNFListCoercion is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12f7112f8) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils102205547039166539630633926507479/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x13f3d92f8). One of the two will be used. Which one is undefined.
objc[27311]: Class JNFSetCoercion is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12f711348) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils102205547039166539630633926507479/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x13f3d9348). One of the two will be used. Which one is undefined.
objc[27311]: Class JNFDefaultCoercions is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12f711370) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils102205547039166539630633926507479/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x13f3d9370). One of the two will be used. Which one is undefined.
objc[27311]: Class JNFJObjectWrapper is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12f7113c0) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils102205547039166539630633926507479/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x13f3d93c0). One of the two will be used. Which one is undefined.
objc[27311]: Class JNFWeakJObjectWrapper is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12f711410) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils102205547039166539630633926507479/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x13f3d9410). One of the two will be used. Which one is undefined.
objc[27311]: Class JNFRunLoop is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12f711488) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils102205547039166539630633926507479/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x13f3d9488). One of the two will be used. Which one is undefined.
objc[27311]: Class JNFRunnableWrapper is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12f7114d8) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils102205547039166539630633926507479/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x13f3d94d8). One of the two will be used. Which one is undefined.
objc[27311]: Class JNFRunnable is implemented in both /Users/syer/Library/Java/JavaVirtualMachines/azul-15.0.3/Contents/Home/lib/JavaNativeFoundation.framework/JavaNativeFoundation (0x12f711528) and /private/var/folders/1z/t2wrxhz96h302wmq1vd52wpw0000gn/T/nativeutils102205547039166539630633926507479/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (0x13f3d9528). One of the two will be used. Which one is undefined.
[2021-07-09 17:58:21] [INFO] Loaded libdarklaf-macos.dylib. [at com.github.weisj.darklaf.platform.AbstractLibrary]
[2021-07-09 17:58:22] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/bb65827e00b1ecb3249a35249fe03f132dddbe70/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowUp.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 17:58:22] [FINER] Inferred size of icon 'arrowUp.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 17:58:22] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/bb65827e00b1ecb3249a35249fe03f132dddbe70/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowDown.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 17:58:22] [FINER] Inferred size of icon 'arrowDown.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 17:58:22] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/bb65827e00b1ecb3249a35249fe03f132dddbe70/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowRight.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 17:58:22] [FINER] Inferred size of icon 'arrowRight.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 17:58:22] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/bb65827e00b1ecb3249a35249fe03f132dddbe70/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/horizontalGrip.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 17:58:22] [FINER] Inferred size of icon 'horizontalGrip.svg' to java.awt.Dimension[width=5,height=20] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 17:58:22] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/bb65827e00b1ecb3249a35249fe03f132dddbe70/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowDownDisabled.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 17:58:22] [FINER] Inferred size of icon 'arrowDownDisabled.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-09 17:58:22] [INFO] Setting installed theme: Darcula [at com.github.weisj.darklaf.LafManager]
Exception in thread "AWT-EventQueue-0 @coroutine#10" java.lang.UnsatisfiedLinkError: 'long com.github.weisj.darklaf.platform.macos.JNIDecorationsMacOS.getComponentPointer(java.awt.Window)'
	at com.github.weisj.darklaf.platform.macos.JNIDecorationsMacOS.getComponentPointer(Native Method)
	at com.github.weisj.darklaf.platform.macos.ui.MacOSDecorationsUtil.installDecorations(MacOSDecorationsUtil.java:46)
	at com.github.weisj.darklaf.platform.macos.ui.MacOSTitlePane.install(MacOSTitlePane.java:126)
	at com.github.weisj.darklaf.platform.decorations.CustomTitlePane.addNotify(CustomTitlePane.java:40)
	at java.desktop/java.awt.Container.addNotify(Container.java:2800)
	at java.desktop/javax.swing.JComponent.addNotify(JComponent.java:4783)
	at java.desktop/java.awt.Container.addNotify(Container.java:2800)
	at java.desktop/javax.swing.JComponent.addNotify(JComponent.java:4783)
	at java.desktop/javax.swing.JRootPane.addNotify(JRootPane.java:729)
	at java.desktop/java.awt.Container.addNotify(Container.java:2800)
	at java.desktop/java.awt.Window.addNotify(Window.java:783)
	at java.desktop/java.awt.Frame.addNotify(Frame.java:490)
	at java.desktop/java.awt.Window.show(Window.java:1045)
	at java.desktop/java.awt.Component.show(Component.java:1717)
	at java.desktop/java.awt.Component.setVisible(Component.java:1664)
	at java.desktop/java.awt.Window.setVisible(Window.java:1028)
	at androidx.compose.desktop.ComposeWindow.setVisible(ComposeWindow.desktop.kt:110)
	at androidx.compose.desktop.AppWindow.show(AppWindow.desktop.kt:449)
	at androidx.compose.desktop.AppWindow.show$default(AppWindow.desktop.kt:435)
	at ca.gosyer.ui.main.MainKt$main$2.invokeSuspend(main.kt:134)
	at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
	at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
	at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:316)
	at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:770)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715)
	at java.base/java.security.AccessController.doPrivileged(AccessController.java:391)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
	at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:740)
	at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
	at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)
 

@weisJ
Copy link
Owner

weisJ commented Jul 9, 2021

I totally overlooked the fact that the JavaNativeFoundation path in your Jak is JavaNativeFoundation.framework/JavaNativeFoundation instead of the usual JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation (which is the path attempted to be loaded). Now I only have to figure out how to change the installation path of the framework in the binary and we should be good.

@weisJ
Copy link
Owner

weisJ commented Jul 10, 2021

The new snapshot should now hopefully actually find and load the library from the jdk. If that works it would be great if you could also test it for the packaged application, as the «executable_path may be different there

@Syer10
Copy link
Author

Syer10 commented Jul 10, 2021

Got a error 😅

[2021-07-10 12:12:29] [FINE] Setting log level to ALL [at com.github.weisj.darklaf.LafManager]
[2021-07-10 12:12:30] [FINE] Setting theme to IntelliJ [at com.github.weisj.darklaf.LafInstaller]
[2021-07-10 12:12:30] [FINE] Setting theme to Darcula [at com.github.weisj.darklaf.LafInstaller]
[2021-07-10 12:12:30] [FINE] Installing theme Darcula [at com.github.weisj.darklaf.LafInstaller]
[2021-07-10 12:12:30] [INFO] Loaded libdarklaf-macos.dylib. [at com.github.weisj.darklaf.platform.AbstractLibrary]
[2021-07-10 12:12:31] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/bb65827e00b1ecb3249a35249fe03f132dddbe70/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowUp.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-10 12:12:31] [FINER] Inferred size of icon 'arrowUp.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-10 12:12:31] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/bb65827e00b1ecb3249a35249fe03f132dddbe70/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowDown.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-10 12:12:31] [FINER] Inferred size of icon 'arrowDown.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-10 12:12:31] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/bb65827e00b1ecb3249a35249fe03f132dddbe70/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowRight.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-10 12:12:31] [FINER] Inferred size of icon 'arrowRight.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-10 12:12:31] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/bb65827e00b1ecb3249a35249fe03f132dddbe70/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/horizontalGrip.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-10 12:12:31] [FINER] Inferred size of icon 'horizontalGrip.svg' to java.awt.Dimension[width=5,height=20] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-10 12:12:31] [FINER] Loading icon 'jar:file:/Users/syer/.gradle/caches/modules-2/files-2.1/com.github.weisj/darklaf-core-m1/2.6.2-m1-SNAPSHOT/bb65827e00b1ecb3249a35249fe03f132dddbe70/darklaf-core-m1-2.6.2-m1-SNAPSHOT.jar!/com/github/weisj/darklaf/icons/navigation/arrow/thick/arrowDownDisabled.svg'. [at com.github.weisj.darklaf.icons.DarkSVGIcon]
[2021-07-10 12:12:31] [FINER] Inferred size of icon 'arrowDownDisabled.svg' to java.awt.Dimension[width=16,height=16] [at com.github.weisj.darklaf.icons.DarkSVGIcon]
Exception in thread "DefaultDispatcher-worker-2 @coroutine#5" java.lang.UnsatisfiedLinkError: 'long com.github.weisj.darklaf.platform.macos.JNIDecorationsMacOS.getComponentPointer(java.awt.Window)'
	at com.github.weisj.darklaf.platform.macos.JNIDecorationsMacOS.getComponentPointer(Native Method)
	at com.github.weisj.darklaf.platform.macos.ui.MacOSDecorationsUtil.installDecorations(MacOSDecorationsUtil.java:46)
	at com.github.weisj.darklaf.platform.macos.ui.MacOSTitlePane.install(MacOSTitlePane.java:126)
	at com.github.weisj.darklaf.platform.decorations.CustomTitlePane.addNotify(CustomTitlePane.java:40)
	at java.desktop/java.awt.Container.addImpl(Container.java:1146)
	at java.desktop/javax.swing.JLayeredPane.addImpl(JLayeredPane.java:233)
	at java.desktop/java.awt.Container.add(Container.java:997)
	at com.github.weisj.darklaf.ui.rootpane.DarkRootPaneUI.setTitlePane(DarkRootPaneUI.java:180)
	at com.github.weisj.darklaf.ui.rootpane.DarkRootPaneUI.installClientDecorations(DarkRootPaneUI.java:156)
	at com.github.weisj.darklaf.ui.rootpane.DarkRootPaneUI.updateClientDecoration(DarkRootPaneUI.java:235)
	at com.github.weisj.darklaf.ui.rootpane.DarkRootPaneUI.installUI(DarkRootPaneUI.java:71)
	at java.desktop/javax.swing.JComponent.setUI(JComponent.java:685)
	at java.desktop/javax.swing.JRootPane.setUI(JRootPane.java:445)
	at java.desktop/javax.swing.JRootPane.updateUI(JRootPane.java:455)
	at java.desktop/javax.swing.SwingUtilities.updateComponentTreeUI0(SwingUtilities.java:1363)
	at java.desktop/javax.swing.SwingUtilities.updateComponentTreeUI0(SwingUtilities.java:1378)
	at java.desktop/javax.swing.SwingUtilities.updateComponentTreeUI(SwingUtilities.java:1354)
	at com.github.weisj.darklaf.LafInstaller.updateLafRecursively(LafInstaller.java:67)
	at com.github.weisj.darklaf.LafInstaller.updateLaf(LafInstaller.java:59)
	at com.github.weisj.darklaf.LafInstaller.install(LafInstaller.java:49)
	at com.github.weisj.darklaf.LafManager.install(LafManager.java:438)
	at com.github.weisj.darklaf.LafManager.installTheme(LafManager.java:419)
	at com.github.weisj.darklaf.LafManager.install(LafManager.java:429)
	at ca.gosyer.ui.main.MainKt$main$1$1.invokeSuspend(main.kt:89)
	(Coroutine boundary)
	at ca.gosyer.ui.main.MainKt$main$1.invokeSuspend(main.kt:88)
	at kotlinx.coroutines.flow.FlowKt__TransformKt$onEach$$inlined$unsafeTransform$1$2.emit(Transform.kt:136)
	at kotlinx.coroutines.flow.FlowKt__ChannelsKt.emitAllImpl$FlowKt__ChannelsKt(Channels.kt:62)
	at kotlinx.coroutines.flow.internal.ChannelFlow$collect$2.invokeSuspend(ChannelFlow.kt:123)
	at kotlinx.coroutines.flow.FlowKt__CollectKt$launchIn$1.invokeSuspend(Collect.kt:50)
	(Coroutine creation stacktrace)
	at kotlin.coroutines.intrinsics.IntrinsicsKt__IntrinsicsJvmKt.createCoroutineUnintercepted(IntrinsicsJvm.kt:122)
	at kotlinx.coroutines.intrinsics.CancellableKt.startCoroutineCancellable(Cancellable.kt:30)
	at kotlinx.coroutines.flow.FlowKt__CollectKt.launchIn(Collect.kt:49)
	at kotlinx.coroutines.flow.FlowKt.launchIn(Unknown Source)
	at ca.gosyer.ui.main.MainKt.main(main.kt:92)
	at ca.gosyer.ui.main.MainKt.main(main.kt)
Caused by: java.lang.UnsatisfiedLinkError: 'long com.github.weisj.darklaf.platform.macos.JNIDecorationsMacOS.getComponentPointer(java.awt.Window)'
	at com.github.weisj.darklaf.platform.macos.JNIDecorationsMacOS.getComponentPointer(Native Method)
	at com.github.weisj.darklaf.platform.macos.ui.MacOSDecorationsUtil.installDecorations(MacOSDecorationsUtil.java:46)
	at com.github.weisj.darklaf.platform.macos.ui.MacOSTitlePane.install(MacOSTitlePane.java:126)
	at com.github.weisj.darklaf.platform.decorations.CustomTitlePane.addNotify(CustomTitlePane.java:40)
	at java.desktop/java.awt.Container.addImpl(Container.java:1146)
	at java.desktop/javax.swing.JLayeredPane.addImpl(JLayeredPane.java:233)
	at java.desktop/java.awt.Container.add(Container.java:997)
	at com.github.weisj.darklaf.ui.rootpane.DarkRootPaneUI.setTitlePane(DarkRootPaneUI.java:180)
	at com.github.weisj.darklaf.ui.rootpane.DarkRootPaneUI.installClientDecorations(DarkRootPaneUI.java:156)
	at com.github.weisj.darklaf.ui.rootpane.DarkRootPaneUI.updateClientDecoration(DarkRootPaneUI.java:235)
	at com.github.weisj.darklaf.ui.rootpane.DarkRootPaneUI.installUI(DarkRootPaneUI.java:71)
	at java.desktop/javax.swing.JComponent.setUI(JComponent.java:685)
	at java.desktop/javax.swing.JRootPane.setUI(JRootPane.java:445)
	at java.desktop/javax.swing.JRootPane.updateUI(JRootPane.java:455)
	at java.desktop/javax.swing.SwingUtilities.updateComponentTreeUI0(SwingUtilities.java:1363)
	at java.desktop/javax.swing.SwingUtilities.updateComponentTreeUI0(SwingUtilities.java:1378)
	at java.desktop/javax.swing.SwingUtilities.updateComponentTreeUI(SwingUtilities.java:1354)
	at com.github.weisj.darklaf.LafInstaller.updateLafRecursively(LafInstaller.java:67)
	at com.github.weisj.darklaf.LafInstaller.updateLaf(LafInstaller.java:59)
	at com.github.weisj.darklaf.LafInstaller.install(LafInstaller.java:49)
	at com.github.weisj.darklaf.LafManager.install(LafManager.java:438)
	at com.github.weisj.darklaf.LafManager.installTheme(LafManager.java:419)
	at com.github.weisj.darklaf.LafManager.install(LafManager.java:429)
	at ca.gosyer.ui.main.MainKt$main$1$1.invokeSuspend(main.kt:89)
	at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
	at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
	at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:316)
	at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:770)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715)
	at java.base/java.security.AccessController.doPrivileged(AccessController.java:391)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
	at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:740)
	at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
	at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)

@weisJ
Copy link
Owner

weisJ commented Jul 10, 2021

Apparently the arm64 binary doesn't export any symbols at all. That definitely shouldn't be the case.

@weisJ
Copy link
Owner

weisJ commented Jul 10, 2021

Which was caused by the library being compiled incorrectly. Symbols are now exported and a new snapshot is out

@Syer10
Copy link
Author

Syer10 commented Jul 10, 2021

No errors on run this time, looking good, Ill try the packaged builds now

@Syer10
Copy link
Author

Syer10 commented Jul 10, 2021

And the packaged build works perfect as well, I would say you have got M1 support complete!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working macOS Related to the macOS operating system
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants