Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

org.jetbrains.skiko.LibraryLoadException: Cannot find libskiko-macos-arm64.dylib.sha256, proper native dependency missing

I try to compile https://github.com/CuriousNikhil/k5-compose in IntelliJ (Apple-Silicon) on an M1 MacbookPro, I got the below error

Caused by: org.jetbrains.skiko.LibraryLoadException: Cannot find libskiko-macos-arm64.dylib.sha256, proper native dependency missing.
    at org.jetbrains.skiko.Library.load(Library.kt:71)
    at org.jetbrains.skiko.HardwareLayer.<clinit>(HardwareLayer.kt:10)

How can I solve this issue?

like image 582
Elye Avatar asked Jan 24 '26 06:01

Elye


2 Answers

In the build.gradle.kts of the project, change implementation(compose.desktop.currentOs) to implementation(compose.desktop.macos_arm64)

like image 120
Konstantin Annikov Avatar answered Jan 25 '26 19:01

Konstantin Annikov


While I found the accepted answer to work:

Changing

implementation(compose.desktop.currentOs)

to

implementation(compose.desktop.macos_arm64)

The documentation seems to indicate that you should just update the version of the wizard:

The Compose plugin version used in the wizard above might not be the latest. Update to the latest plugin version by editing the build.gradle.kts file and updating the version information as shown below. For the latest versions, see the latest versions site and the Kotlin site.

plugins {
    kotlin("jvm") version "1.7.20"
    id("org.jetbrains.compose") version "1.2.2"
}

Which also works, and I think should be preferred.

like image 27
Quintin Balsdon Avatar answered Jan 25 '26 19:01

Quintin Balsdon



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!