hey everyone, after upgrading to ```compose-plugin...
# compose-ios
h
hey everyone, after upgrading to
Copy code
compose-plugin = "1.8.0-beta01"
androidx-navigation = "2.9.0-alpha15"
androidx-navigation-material = "1.8.0-beta01"
kotlin = "2.1.20"
ksp = "2.1.20-1.0.31"
i could not build my CMP app on iOS, i’m met with this error, check 🧵
👀 1
image.png,image.png
k
try to disable caches in the gradle.properties
kotlin.native.cacheKind=none
h
hmm, still fails, do i need to enable k2 in Android studio? also is there something clashing with my properties that i also need to remove/change because the build fails when i try to build it with xcode I saw this issue https://youtrack.jetbrains.com/issue/CMP-7571
I tried enabling k2, doesn't work :l
m
I just had the same issue, apparently the problem seems to be with the navigation library. after reverting back to version 2.8.0-alpha13, it works again. I'm not sure how to make it work with 2.9.0-alpha15 though. If someone has suggestions, I'd be happy to listen 🙏
k
let's try to check with a new generated project: https://terrakok.github.io/Compose-Multiplatform-Wizard/ it is configured with all latest versions already.
h
same issue in the
1.8.0-beta02
😞 only iOS can’t compile, same error
k
what is Xcode version?
h
Version 16.2 (16C5032a)
k
have you check a new generated project?
h
This is an existing project already in production iOS, android, backend I'm not sure how that'll help me, care to explain if you don't mind?
k
it will check your environment at least
h
yeap, it works, builds fine
i can share the project at this point somehow just to fix this issue, it’s annoying
k
could you share an output of
./gradlew :app:dependencies > out.txt
I guess the problem is in androidx-navigation-material
h
it’s a multi module project is there another way to aggregate them except from Android, for Android here they are
k
I will take a look on the next week
h
this is my structure, the ui:root aggregates everything together and builds the iOS framework, thank you
image.png
no matter which version of the navigation i bump, it causes these issue latest working versions
Copy code
androidx-navigation = "2.8.0-alpha12"
androidx-navigation-material = "1.7.0-beta02"
compose-plugin = "1.7.3"
e
Hi! Have you checked with Kotlin version
2.1.20-RC3
or newer according to this task?
h
hi Ekaterina, no, i am running
2.1.20
will check it, is there a matching KSP version for
2.1.20-RC3
that i should be also using?
e
I suppose not, 2.1.20-1.0.31 is fine
👍 1
h
just tried, same error 😕
even tried newer versions
Copy code
kotlin = "2.1.20"
ksp = "2.1.20-2.0.0"
same error
e
Sorry, have you tried with
2.1.20-RC3
Kotlin, right? You mentioned 2.1.20 above And with
kotlin.native.cacheKind=none
?
h
Yeap doesn't work
🙁 1
Do we know if/when this'll be fixed, I really want to ship predictive back on iOS 🥲
m
For me, it finally worked! It was a "death/success by a thousand cuts"-approach. I made a new project from the kmp-starter @Konstantin Tskhovrebov mentioned (awesome tool by the way! ❤️ ) and made my application work again (finally, after about 30 hours of try and error) My findings: • Apparently, the standard structure did change. My main.kt file for iOS now needs to be directly in the kotlin-folder, not in a sub-package • The linking (for me it was sqlite) now needs to happen in the Build Phases -> Link Binary With Libraries instead of Build Settings -> other linker flags • After that, I still had a problem with my ViewModels that was solved by
kotlin.native.cacheKind=none
Copy code
kotlin = "2.1.20"
compose = "1.8.0-beta02"
androidx-navigation = "2.9.0-alpha16"
androidx-lifecycle = "2.9.0-alpha06"
This was my final working configuration
h
@Konstantin Tskhovrebov the first finding, why? I have it in a sub package
m
Maybe it's some configuration change that I haven't found/seen in the build.gradle.kts file. At least I wasn't able to make it run with the previous folder structure