Hi everyone, I tried since yesterday to make a Ko...
# multiplatform
r
Hi everyone, I tried since yesterday to make a Kotlin Multiplatorm project who share Android / iOS / Desktop. The project build without problem just with Android / iOS platform, but since I try to implement desktop with Jetbrains Compose I have this error (in thread).
🧵 1
Copy code
Execution failed for task ':shared:cinteropAFNetworkingIos'.
> Could not resolve all files for configuration ':shared:iosAFNetworkingCInterop'.
   > Could not find runtime-0.4.0-build188-samplessources.jar (org.jetbrains.compose.runtime:runtime:0.4.0-build188).
     Searched in the following locations:
         <https://maven.pkg.jetbrains.space/public/p/compose/dev/org/jetbrains/compose/runtime/runtime/0.4.0-build188/runtime-0.4.0-build188-samplessources.jar>
   > Could not find foundation-0.4.0-build188-samplessources.jar (org.jetbrains.compose.foundation:foundation:0.4.0-build188).
     Searched in the following locations:
         <https://maven.pkg.jetbrains.space/public/p/compose/dev/org/jetbrains/compose/foundation/foundation/0.4.0-build188/foundation-0.4.0-build188-samplessources.jar>
   > Could not find material-0.4.0-build188-samplessources.jar (org.jetbrains.compose.material:material:0.4.0-build188).
     Searched in the following locations:
         <https://maven.pkg.jetbrains.space/public/p/compose/dev/org/jetbrains/compose/material/material/0.4.0-build188/material-0.4.0-build188-samplessources.jar>

Possible solution:
 - Declare repository providing the artifact, see the documentation at <https://docs.gradle.org/current/userguide/declaring_repositories.html>
I see that following location to download dependencies add a
-samplessources
... Do you have an idea please 🤔 ?
r
It has to do with a dependency not resolving, for example if you're trying to use a dependency in common that wasn't build for one of the platforms you're using. See https://youtrack.jetbrains.com/issue/KTIJ-10769
r
I didn’t understand the problem in this way 😮 I remove these dependencies from `commonMain`:
Copy code
api(compose.runtime)
                api(compose.foundation)
                api(compose.material)
And the build works! Thank you @russhwolf
r
yeah it's a confusing error message. There's another ticket linked in there about updating the error to be more clear
🙂 1