From 519628de5cc9480e722773829892f9a67faf3d05 Mon Sep 17 00:00:00 2001 From: yves tessier Date: Tue, 19 Oct 2021 12:29:59 -0400 Subject: [PATCH 1/2] fix compilation with xcode 13 --- build.gradle.kts | 3 +-- firebase-app/build.gradle.kts | 2 +- firebase-auth/build.gradle.kts | 2 +- firebase-config/build.gradle.kts | 2 +- firebase-database/build.gradle.kts | 2 +- firebase-firestore/build.gradle.kts | 2 +- firebase-functions/build.gradle.kts | 2 +- 7 files changed, 7 insertions(+), 8 deletions(-) diff --git a/build.gradle.kts b/build.gradle.kts index e512e1f2a..1bf79cd0b 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -162,8 +162,7 @@ subprojects { args( it, "--project-directory", projectDir.resolve("src/nativeInterop/cinterop"), - "--platform", "iOS", - "--cache-builds" + "--platform", "iOS" ) } } diff --git a/firebase-app/build.gradle.kts b/firebase-app/build.gradle.kts index eff011173..530e4ba3e 100644 --- a/firebase-app/build.gradle.kts +++ b/firebase-app/build.gradle.kts @@ -90,7 +90,7 @@ kotlin { compilations.getByName("main") { cinterops.create("FirebaseCore") { compilerOpts(nativeFrameworkPaths.map { "-F$it" }) - extraOpts("-verbose") + extraOpts = listOf("-compiler-option", "-DNS_FORMAT_ARGUMENT(A)=", "-verbose") } } } diff --git a/firebase-auth/build.gradle.kts b/firebase-auth/build.gradle.kts index 00c0a4be8..1402f4358 100644 --- a/firebase-auth/build.gradle.kts +++ b/firebase-auth/build.gradle.kts @@ -119,7 +119,7 @@ kotlin { compilations.getByName("main") { cinterops.create("FirebaseAuth") { compilerOpts(nativeFrameworkPaths.map { "-F$it" }) - extraOpts("-verbose") + extraOpts = listOf("-compiler-option", "-DNS_FORMAT_ARGUMENT(A)=", "-verbose") } } } diff --git a/firebase-config/build.gradle.kts b/firebase-config/build.gradle.kts index 6af6ec0ea..6b113bdcd 100644 --- a/firebase-config/build.gradle.kts +++ b/firebase-config/build.gradle.kts @@ -104,7 +104,7 @@ kotlin { compilations.getByName("main") { cinterops.create("FirebaseRemoteConfig") { compilerOpts(nativeFrameworkPaths.map { "-F$it" }) - extraOpts("-verbose") + extraOpts = listOf("-compiler-option", "-DNS_FORMAT_ARGUMENT(A)=", "-verbose") } } } diff --git a/firebase-database/build.gradle.kts b/firebase-database/build.gradle.kts index 8b5c08b7d..ab68f72d1 100644 --- a/firebase-database/build.gradle.kts +++ b/firebase-database/build.gradle.kts @@ -95,7 +95,7 @@ kotlin { compilations.getByName("main") { cinterops.create("FirebaseDatabase") { compilerOpts(nativeFrameworkPaths.map { "-F$it" }) - extraOpts("-verbose") + extraOpts = listOf("-compiler-option", "-DNS_FORMAT_ARGUMENT(A)=", "-verbose") } } } diff --git a/firebase-firestore/build.gradle.kts b/firebase-firestore/build.gradle.kts index bff60b38e..243bf2cd1 100644 --- a/firebase-firestore/build.gradle.kts +++ b/firebase-firestore/build.gradle.kts @@ -102,7 +102,7 @@ kotlin { compilations.getByName("main") { cinterops.create("FirebaseFirestore") { compilerOpts(nativeFrameworkPaths.map { "-F$it" }) - extraOpts("-verbose") + extraOpts = listOf("-compiler-option", "-DNS_FORMAT_ARGUMENT(A)=", "-verbose") } } } diff --git a/firebase-functions/build.gradle.kts b/firebase-functions/build.gradle.kts index f9e42f1ce..6174f47d0 100644 --- a/firebase-functions/build.gradle.kts +++ b/firebase-functions/build.gradle.kts @@ -90,7 +90,7 @@ kotlin { compilations.getByName("main") { cinterops.create("FirebaseFunctions") { compilerOpts(nativeFrameworkPaths.map { "-F$it" }) - extraOpts("-verbose") + extraOpts = listOf("-compiler-option", "-DNS_FORMAT_ARGUMENT(A)=", "-verbose") } } } From 3d23095716dc263cc2ce3e409883e08c11a0fccb Mon Sep 17 00:00:00 2001 From: yves tessier Date: Tue, 19 Oct 2021 13:10:01 -0400 Subject: [PATCH 2/2] fir crash when calling following code from ios val remoteConf = Firebase.remoteConfig remoteConf.settings { minimumFetchIntervalInSeconds = 60 } remoteConf.setDefaults(*defaults) remoteConf.fetch() remoteConfig = remoteConf.all --- build.gradle.kts | 6 +++--- firebase-app/package.json | 2 +- firebase-auth/package.json | 2 +- firebase-common/package.json | 2 +- firebase-config/package.json | 2 +- firebase-database/package.json | 2 +- firebase-firestore/package.json | 2 +- firebase-functions/package.json | 2 +- 8 files changed, 10 insertions(+), 10 deletions(-) diff --git a/build.gradle.kts b/build.gradle.kts index 1bf79cd0b..760fcc914 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -194,12 +194,12 @@ subprojects { } dependencies { - "commonMainImplementation"("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.5.2") - "androidMainImplementation"("org.jetbrains.kotlinx:kotlinx-coroutines-play-services:1.5.2") + "commonMainImplementation"("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.5.2-native-mt") + "androidMainImplementation"("org.jetbrains.kotlinx:kotlinx-coroutines-play-services:1.5.2-native-mt") "androidMainImplementation"(platform("com.google.firebase:firebase-bom:28.4.1")) "commonTestImplementation"(kotlin("test-common")) "commonTestImplementation"(kotlin("test-annotations-common")) - "commonTestImplementation"("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.5.2") + "commonTestImplementation"("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.5.2-native-mt") "jsTestImplementation"(kotlin("test-js")) "androidAndroidTestImplementation"(kotlin("test-junit")) "androidAndroidTestImplementation"("junit:junit:4.13.2") diff --git a/firebase-app/package.json b/firebase-app/package.json index b04ec1a26..73d3e36d1 100644 --- a/firebase-app/package.json +++ b/firebase-app/package.json @@ -26,6 +26,6 @@ "@gitlive/firebase-common": "1.4.3", "firebase": "8.10.0", "kotlin": "1.5.31", - "kotlinx-coroutines-core": "1.5.2" + "kotlinx-coroutines-core": "1.5.2-native-mt" } } diff --git a/firebase-auth/package.json b/firebase-auth/package.json index e2668ff1f..fb6171b87 100644 --- a/firebase-auth/package.json +++ b/firebase-auth/package.json @@ -26,6 +26,6 @@ "@gitlive/firebase-app": "1.4.3", "firebase": "8.10.0", "kotlin": "1.5.31", - "kotlinx-coroutines-core": "1.5.2" + "kotlinx-coroutines-core": "1.5.2-native-mt" } } diff --git a/firebase-common/package.json b/firebase-common/package.json index 96cfb72d1..399ac777a 100644 --- a/firebase-common/package.json +++ b/firebase-common/package.json @@ -25,7 +25,7 @@ "dependencies": { "firebase": "8.10.0", "kotlin": "1.5.31", - "kotlinx-coroutines-core": "1.5.2", + "kotlinx-coroutines-core": "1.5.2-native-mt", "kotlinx-serialization-kotlinx-serialization-runtime": "1.3.0" } } diff --git a/firebase-config/package.json b/firebase-config/package.json index a1a774ef7..dd8e4d6fc 100644 --- a/firebase-config/package.json +++ b/firebase-config/package.json @@ -26,6 +26,6 @@ "@gitlive/firebase-app": "1.4.3", "firebase": "8.10.0", "kotlin": "1.5.31", - "kotlinx-coroutines-core": "1.5.2" + "kotlinx-coroutines-core": "1.5.2-native-mt" } } diff --git a/firebase-database/package.json b/firebase-database/package.json index a18360057..56ae61424 100644 --- a/firebase-database/package.json +++ b/firebase-database/package.json @@ -26,6 +26,6 @@ "@gitlive/firebase-app": "1.4.3", "firebase": "8.10.0", "kotlin": "1.5.31", - "kotlinx-coroutines-core": "1.5.2" + "kotlinx-coroutines-core": "1.5.2-native-mt" } } diff --git a/firebase-firestore/package.json b/firebase-firestore/package.json index 4583702a3..f07d979b6 100644 --- a/firebase-firestore/package.json +++ b/firebase-firestore/package.json @@ -26,6 +26,6 @@ "@gitlive/firebase-app": "1.4.3", "firebase": "8.10.0", "kotlin": "1.5.31", - "kotlinx-coroutines-core": "1.5.2" + "kotlinx-coroutines-core": "1.5.2-native-mt" } } diff --git a/firebase-functions/package.json b/firebase-functions/package.json index a5ec276fb..410f1f0d3 100644 --- a/firebase-functions/package.json +++ b/firebase-functions/package.json @@ -26,6 +26,6 @@ "@gitlive/firebase-app": "1.4.3", "firebase": "8.10.0", "kotlin": "1.5.31", - "kotlinx-coroutines-core": "1.5.2" + "kotlinx-coroutines-core": "1.5.2-native-mt" } }