Anyone had issues with `SqlDelight 1.4.3` `native...
# multiplatform
n
Anyone had issues with
SqlDelight 1.4.3
native
dependency? Can’t seem to resolve
NativeSqliteDriver
, while
AndroidSqliteDriver
worsk well. Kotlin
1.4.0
AS 4.0.1, Gradle 6.1.1
l
#squarelibraries, also give more details on how you set it up and how it's failing exactly for people to be able to help.
j
fwiw I'm using sqldelight in following (with Kotlin 1.4.0) if you want to compare setup https://github.com/joreilly/PeopleInSpace
👍 1
n
@louiscad I’ve been following the official doc, and the issue is that with the
com.squareup.sqldelight:native-driver
dependency I can’t import the
com.squareup.sqldelight.drivers.native.NativeSqliteDriver
. I can see however that there’s a
NativeSqliteDriver
which implements
SqlDriver
pulled in with
native-driver.klib
, but it’s not accessible from
iosMain
(It’s strange, since other ios dependencies work well)
Copy code
val iosMain by getting {
    dependencies {
        implementation(Versions.iOS.SQLITE_DRIVER)
    }
}
l
@nrobi Did you enable HMPP in your
gradle.properties
file?
n
I’m not sure what you mean by HMPP, I’ve enabled the hierarchical project structure with the
1.4.0
kotlin migration:
Copy code
kotlin.mpp.enableGranularSourceSetsMetadata=true
kotlin.native.enableDependencyPropagation=false
l
Yes, this is HMPP (Hierarchical MultiPlatform Projects) enabling flags. Then I don't know what would cause the issue. I'd try to compare with John's project linked above, and/or report an issue with all the relevant details.
👍 1
j
still getting that same issue with 1.4.4. Are you still using the
if/else
workaround instead of the
ios()
target?
n
Yepp
j
I’m running into this now after replacing ios target
KotlinTarget with name 'iosX64' not found.
Have you experienced that too?
n
You probably have something like
val targetName = "ios" + if (sdkName.startsWith("iphoneos")) "Arm64" else "X64"
in your
packForXcode
task. You should remove the suffixes and use
"ios"
only (the target name might be different, in my case I’m using
iosArm64("ios")
and
iosX64("ios")
)
j
Right, I didn’t think of check that. Thanks for the help! 🙂
👍 1