diff --git a/Gemfile b/Gemfile index 0166ca6..db85755 100644 --- a/Gemfile +++ b/Gemfile @@ -1,5 +1,4 @@ source 'https://rubygems.org' -gem 'cocoapods', '~> 1.13' +gem 'cocoapods', '~> 1.14' gem 'cocoapods-generate', '~> 2.2' -gem 'activesupport', '7.0.8' # Temporary workaround to fix cocoapods plugin crashing with v7.1.1 diff --git a/Gemfile.lock b/Gemfile.lock index 46fca56..25bbe7d 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -3,10 +3,15 @@ GEM specs: CFPropertyList (3.0.6) rexml - activesupport (7.0.8) + activesupport (7.1.2) + base64 + bigdecimal concurrent-ruby (~> 1.0, >= 1.0.2) + connection_pool (>= 2.2.5) + drb i18n (>= 1.6, < 2) minitest (>= 5.1) + mutex_m tzinfo (~> 2.0) addressable (2.8.5) public_suffix (>= 2.0.2, < 6.0) @@ -14,13 +19,15 @@ GEM httpclient (~> 2.8, >= 2.8.3) json (>= 1.5.1) atomos (0.1.3) + base64 (0.2.0) + bigdecimal (3.1.4) claide (1.1.0) - cocoapods (1.13.0) + cocoapods (1.14.3) addressable (~> 2.8) claide (>= 1.0.2, < 2.0) - cocoapods-core (= 1.13.0) + cocoapods-core (= 1.14.3) cocoapods-deintegrate (>= 1.0.3, < 2.0) - cocoapods-downloader (>= 1.6.0, < 2.0) + cocoapods-downloader (>= 2.1, < 3.0) cocoapods-plugins (>= 1.0.0, < 2.0) cocoapods-search (>= 1.0.0, < 2.0) cocoapods-trunk (>= 1.6.0, < 2.0) @@ -33,7 +40,7 @@ GEM nap (~> 1.0) ruby-macho (>= 2.3.0, < 3.0) xcodeproj (>= 1.23.0, < 2.0) - cocoapods-core (1.13.0) + cocoapods-core (1.14.3) activesupport (>= 5.0, < 8) addressable (~> 2.8) algoliasearch (~> 1.0) @@ -45,7 +52,7 @@ GEM typhoeus (~> 1.0) cocoapods-deintegrate (1.0.5) cocoapods-disable-podfile-validations (0.2.0) - cocoapods-downloader (1.6.3) + cocoapods-downloader (2.1) cocoapods-generate (2.2.4) cocoapods-disable-podfile-validations (>= 0.1.1, < 0.3.0) cocoapods-plugins (1.0.0) @@ -57,6 +64,9 @@ GEM cocoapods-try (1.2.0) colored2 (3.1.2) concurrent-ruby (1.2.2) + connection_pool (2.4.1) + drb (2.2.0) + ruby2_keywords escape (0.0.4) ethon (0.16.0) ffi (>= 1.15.0) @@ -70,13 +80,15 @@ GEM json (2.6.3) minitest (5.20.0) molinillo (0.8.0) + mutex_m (0.2.0) nanaimo (0.3.0) nap (1.1.0) netrc (0.11.0) public_suffix (4.0.7) rexml (3.2.6) ruby-macho (2.5.1) - typhoeus (1.4.0) + ruby2_keywords (0.0.5) + typhoeus (1.4.1) ethon (>= 0.9.0) tzinfo (2.0.6) concurrent-ruby (~> 1.0) @@ -92,8 +104,7 @@ PLATFORMS ruby DEPENDENCIES - activesupport (= 7.0.8) - cocoapods (~> 1.13) + cocoapods (~> 1.14) cocoapods-generate (~> 2.2) BUNDLED WITH diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index dcc546c..b0f3e0b 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -1,10 +1,10 @@ [versions] -androidComposeCompiler = "1.5.3" -androidGradlePlugin = "8.1.2" -androidxActivityCompose = "1.8.0" +androidComposeCompiler = "1.5.6" +androidGradlePlugin = "8.2.0" +androidxActivityCompose = "1.8.1" androidxAppcompat = "1.6.1" androidxComposeBom = "2023.10.01" -kotlin = "1.9.10" +kotlin = "1.9.21" kotlinxCoroutines = "1.7.3" kotlinxSerialization = "1.6.0" ktlint = "11.6.1" diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 7cd02cf..6cbcc97 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ #Thu Oct 12 13:41:45 EDT 2023 distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.2-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/ios/Gemfile b/ios/Gemfile index 0927832..116623c 100644 --- a/ios/Gemfile +++ b/ios/Gemfile @@ -1,3 +1,3 @@ source 'https://rubygems.org' -gem 'cocoapods', '~> 1.13' +gem 'cocoapods', '~> 1.14' diff --git a/ios/Gemfile.lock b/ios/Gemfile.lock index 684e139..de785c8 100644 --- a/ios/Gemfile.lock +++ b/ios/Gemfile.lock @@ -3,10 +3,15 @@ GEM specs: CFPropertyList (3.0.6) rexml - activesupport (7.0.8) + activesupport (7.1.2) + base64 + bigdecimal concurrent-ruby (~> 1.0, >= 1.0.2) + connection_pool (>= 2.2.5) + drb i18n (>= 1.6, < 2) minitest (>= 5.1) + mutex_m tzinfo (~> 2.0) addressable (2.8.5) public_suffix (>= 2.0.2, < 6.0) @@ -14,13 +19,15 @@ GEM httpclient (~> 2.8, >= 2.8.3) json (>= 1.5.1) atomos (0.1.3) + base64 (0.2.0) + bigdecimal (3.1.4) claide (1.1.0) - cocoapods (1.13.0) + cocoapods (1.14.3) addressable (~> 2.8) claide (>= 1.0.2, < 2.0) - cocoapods-core (= 1.13.0) + cocoapods-core (= 1.14.3) cocoapods-deintegrate (>= 1.0.3, < 2.0) - cocoapods-downloader (>= 1.6.0, < 2.0) + cocoapods-downloader (>= 2.1, < 3.0) cocoapods-plugins (>= 1.0.0, < 2.0) cocoapods-search (>= 1.0.0, < 2.0) cocoapods-trunk (>= 1.6.0, < 2.0) @@ -33,7 +40,7 @@ GEM nap (~> 1.0) ruby-macho (>= 2.3.0, < 3.0) xcodeproj (>= 1.23.0, < 2.0) - cocoapods-core (1.13.0) + cocoapods-core (1.14.3) activesupport (>= 5.0, < 8) addressable (~> 2.8) algoliasearch (~> 1.0) @@ -44,7 +51,7 @@ GEM public_suffix (~> 4.0) typhoeus (~> 1.0) cocoapods-deintegrate (1.0.5) - cocoapods-downloader (1.6.3) + cocoapods-downloader (2.1) cocoapods-plugins (1.0.0) nap cocoapods-search (1.0.1) @@ -54,6 +61,9 @@ GEM cocoapods-try (1.2.0) colored2 (3.1.2) concurrent-ruby (1.2.2) + connection_pool (2.4.1) + drb (2.2.0) + ruby2_keywords escape (0.0.4) ethon (0.16.0) ffi (>= 1.15.0) @@ -67,13 +77,15 @@ GEM json (2.6.3) minitest (5.20.0) molinillo (0.8.0) + mutex_m (0.2.0) nanaimo (0.3.0) nap (1.1.0) netrc (0.11.0) public_suffix (4.0.7) rexml (3.2.6) ruby-macho (2.5.1) - typhoeus (1.4.0) + ruby2_keywords (0.0.5) + typhoeus (1.4.1) ethon (>= 0.9.0) tzinfo (2.0.6) concurrent-ruby (~> 1.0) @@ -89,7 +101,7 @@ PLATFORMS arm64-darwin-23 DEPENDENCIES - cocoapods (~> 1.13) + cocoapods (~> 1.14) BUNDLED WITH 2.4.20 diff --git a/ios/Podfile.lock b/ios/Podfile.lock index 67c3147..2389a29 100644 --- a/ios/Podfile.lock +++ b/ios/Podfile.lock @@ -20,4 +20,4 @@ SPEC CHECKSUMS: PODFILE CHECKSUM: 83ebf5d7b61ce65029f18160027c7392430ee27f -COCOAPODS: 1.13.0 +COCOAPODS: 1.14.3 diff --git a/ios/iosApp/GreetingView.swift b/ios/iosApp/GreetingView.swift index 36b0f57..321d1ed 100644 --- a/ios/iosApp/GreetingView.swift +++ b/ios/iosApp/GreetingView.swift @@ -10,8 +10,6 @@ struct GreetingView: View { } } -struct GreetingView_Previews: PreviewProvider { - static var previews: some View { - GreetingView() - } +#Preview { + GreetingView() } diff --git a/shared/Shared.podspec b/shared/Shared.podspec index 59d76af..9e1ee67 100644 --- a/shared/Shared.podspec +++ b/shared/Shared.podspec @@ -11,6 +11,17 @@ Pod::Spec.new do |spec| + if !Dir.exist?('build/cocoapods/framework/Shared.framework') || Dir.empty?('build/cocoapods/framework/Shared.framework') + raise " + + Kotlin framework 'Shared' doesn't exist yet, so a proper Xcode project can't be generated. + 'pod install' should be executed after running ':generateDummyFramework' Gradle task: + + ./gradlew :shared:generateDummyFramework + + Alternatively, proper pod installation is performed during Gradle sync in the IDE (if Podfile location is set)" + end + spec.pod_target_xcconfig = { 'KOTLIN_PROJECT_PATH' => ':shared', 'PRODUCT_MODULE_NAME' => 'Shared', diff --git a/shared/build.gradle.kts b/shared/build.gradle.kts index 215619f..a2d40a9 100644 --- a/shared/build.gradle.kts +++ b/shared/build.gradle.kts @@ -1,5 +1,7 @@ @file:Suppress("UNUSED_VARIABLE") +import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi + plugins { alias(libs.plugins.kotlin.multiplatform) alias(libs.plugins.kotlin.native.cocoapods) @@ -16,7 +18,8 @@ kotlin { androidTarget { publishAllLibraryVariants() } - ios() + iosX64() + iosArm64() iosSimulatorArm64() cocoapods { @@ -38,33 +41,24 @@ kotlin { } } - val commonMain by getting { + commonMain { dependencies { implementation(libs.kotlinx.coroutines.core) implementation(libs.kotlinx.serialization.json) } } - val commonTest by getting { + + commonTest { dependencies { implementation(kotlin("test")) implementation(libs.kotlinx.coroutines.test) } } - val androidMain by getting - val androidUnitTest by getting + } - val iosX64Main by getting - val iosArm64Main by getting - val iosSimulatorArm64Main by getting - val iosMain by getting { - iosSimulatorArm64Main.dependsOn(this) - } - val iosX64Test by getting - val iosArm64Test by getting - val iosSimulatorArm64Test by getting - val iosTest by getting { - iosSimulatorArm64Test.dependsOn(this) - } + @OptIn(ExperimentalKotlinGradlePluginApi::class) + compilerOptions { + freeCompilerArgs.add("-Xexpect-actual-classes") } } @@ -76,7 +70,6 @@ android { defaultConfig { minSdk = 21 } - compileOptions { sourceCompatibility = JavaVersion.VERSION_17 targetCompatibility = JavaVersion.VERSION_17