Hi all, does anyone have any experience with movin...
# multiplatform
t
Hi all, does anyone have any experience with moving the kmm module outside of the app directory. In my case, my app is in 
main -> fixture -> android/ios
. and the module is in 
mmain -> kmm -> kmmtestmodule
 The pod istall and import works fine, but xcode build fails and I cant call any functions from the kotlin pod. Xcode Build Error:
Copy code
build.gradle.kts' line: 3

* What went wrong:
Plugin [id: 'org.jetbrains.kotlin.multiplatform'] was not found in any of the following sources:

- Gradle Core Plugins (plugin is not in 'org.gradle' namespace)
- Plugin Repositories (plugin dependency must include a version number for this source)
g
You may have a line that define the multiplatform plugin version in the app?
t
this is the line `
Copy code
kotlin("multiplatform")
I tried changing to
id("org.jetbrains.kotlin.multiplatform")
but thats not working either
tried adding the version too but then it gives me another error that I cant specify the version twice
g
I'm thinking about a dependency for the multiplatform plugin in your buildscript
t
can you explain that a bit more?
g
Well in my case I use gradle kts, and I've a buildSrc/build.gradle.kts dependency to :
implementation("org.jetbrains.kotlinkotlin gradle plugin1.5.31")
That's the kotlin version source right there.
If this is somewhere in the app but not in the lib maybe it's conflicting in some ways (pure speculation, sorry 🙂)
t
ahh! I dont have that in my dependencies in my module's build.gradle.kts file. Let me try adding that
I added this to my module's build.gradle.kts file but thats not helping. After sync> pod install > build still failed
Copy code
buildscript {
    repositories {
        google()
        mavenCentral()
        jcenter()
    }
    dependencies {
        classpath("com.android.tools.build:gradle:4.0.2")
        classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:1.5.30")
    }
}
g
If it's open-source, I may have a look in the next hours. (If not, it's a bit tricky to me to help without code.)
t
its not open source unfortunately. But this does seem like a path I can dig further. I will keep you posted.
🤞 1