Perhaps more of a gradle question, but thought oth...
# kotlin-native
t
Perhaps more of a gradle question, but thought others here would have seen the same thing: I am doing a Kotlin shared lib/framework across Android and iOS as laid out in the MULTIPLATFORM doc. All is good so far. One little thing that bugs is that in Android Studio I see the whole ios section. How can I adjust my settings.gradle to not include the ios when gradle is run from within AS?
a
Remove the include for greeting:ios on the android project. It doesn't need it. I did not follow this doc (https://github.com/JetBrains/kotlin-native/blob/master/MULTIPLATFORM.md) and don't have it in my project. Works great for me.
t
And it still works for the iOS build for you? I am building the common for both Android and iOS. I will try it, but have my doubts. 🙂
a
It was similar to the part 3, where it says: Alternatively you can add the multiplatform library subprojects right into the Android Studio one instead of creating a composite build. To do this you need to declare them along with their directories in androidApp/settings.gradle:
The iOS build works too. I actually started with the iOS first, since was less sure of that one. So, that was built using an appcode template. Then, created the android project and included just the common and android in it directly.
t
okay, i guess i was doing the former - i use an includeBuild in my app that points to the common section which contains the android, common and ios like in their sample. thank you!