From 7eb92a6f02ad96134219dfe215716ace7661b3a3 Mon Sep 17 00:00:00 2001 From: Alex Shepeliev Date: Sat, 14 Sep 2024 18:36:45 +0300 Subject: [PATCH 1/3] Update README.md --- README.md | 53 ++++++++++++++++++++++++----------------------------- 1 file changed, 24 insertions(+), 29 deletions(-) diff --git a/README.md b/README.md index 3dcb2ad6..c5d5bce2 100644 --- a/README.md +++ b/README.md @@ -17,53 +17,48 @@ Current revision: M125 ## Installation The library is published to [Maven Central](https://search.maven.org/artifact/com.shepeliev/webrtc-kmp). -Shared module build.gradle.kts -```Kotlin + +### Add dependency to your common source set: +```kotlin +commonMain.dependencies { + dependencies { + api("com.shepeliev:webrtc-kmp:$webRtcKmpVersion") + } +} +``` + +### Running on iOS +On iOS the WebRTC SDK is not linked as transitive dependency. You need to add it to your iOS project manually. +This can be done using CocoaPods or SPM. The concrete implementation depends on your project setup. +Here is an example how to link the WebRTC SDK using CocoaPods in gradle.build.kts: + +```kotlin kotlin { cocoapods { version = "1.0.0" summary = "Shared module" homepage = "not published" - ios.deploymentTarget = "11.0" + ios.deploymentTarget = "13.0" - pod("WebRTC-SDK") { - version = "125.6422.02" - linkOnly = true + pod("WebRTC-SDK") { + version = "125.6422.04" + moduleName = "WebRTC" } podfile = project.file("../iosApp/Podfile") framework { baseName = "shared" - export("com.shepeliev:webrtc-kmp:$webRtcKmpVersion") - transitiveExport = true + isStatic = true } xcodeConfigurationToNativeBuildType["CUSTOM_DEBUG"] = NativeBuildType.DEBUG xcodeConfigurationToNativeBuildType["CUSTOM_RELEASE"] = NativeBuildType.RELEASE } - - android() - - ios() - iosSimulatorArm64() - - js { - useCommonJs() - browser() - } - - sourceSets { - val commonMain by getting { - dependencies { - api("com.shepeliev:webrtc-kmp:$webRtcKmpVersion") - } - } - val iosMain by getting - val iosSimulatorArm64Main by getting - iosSimulatorArm64Main.dependsOn(iosMain) - } + iosX64() + iosArm64() + iosSimulatorArm64() } ``` From c9f2bab4f5c602238bcf78ab2b964efcd1573aff Mon Sep 17 00:00:00 2001 From: Alex Shepeliev Date: Sat, 14 Sep 2024 18:38:19 +0300 Subject: [PATCH 2/3] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index c5d5bce2..3e779e85 100644 --- a/README.md +++ b/README.md @@ -22,7 +22,7 @@ The library is published to [Maven Central](https://search.maven.org/artifact/co ```kotlin commonMain.dependencies { dependencies { - api("com.shepeliev:webrtc-kmp:$webRtcKmpVersion") + implementation("com.shepeliev:webrtc-kmp:$webRtcKmpVersion") } } ``` From 5b803348e0796121447c1585281fa32e8d3d89fd Mon Sep 17 00:00:00 2001 From: Alex Shepeliev Date: Sun, 15 Sep 2024 10:09:17 +0300 Subject: [PATCH 3/3] Update README.md --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 3e779e85..cb03162e 100644 --- a/README.md +++ b/README.md @@ -28,9 +28,9 @@ commonMain.dependencies { ``` ### Running on iOS -On iOS the WebRTC SDK is not linked as transitive dependency. You need to add it to your iOS project manually. -This can be done using CocoaPods or SPM. The concrete implementation depends on your project setup. -Here is an example how to link the WebRTC SDK using CocoaPods in gradle.build.kts: +On iOS, the WebRTC SDK is not linked as a transitive dependency, so you need to add it to your iOS project manually. +This can be done using CocoaPods or SPM, depending on your project setup. Here is an example of how to link +the WebRTC SDK using CocoaPods in `build.gradle.kts`: ```kotlin kotlin {