Skip to content

Commit 3af2a9f

Browse files
Move to Kotlin 2.0.0 and link iOS directly.
* Kotlin 2.0.0 and directly linking for iOS * Try static build * Update build.gradle.kts Roll back static framework config * Update to new Compose compiler. * Update iOS GH action. * Update xcodebuild-action in iOS GHA workflow. * Rollback xcodebuild-action version update. * Run xcodebuild without xcpretty (hopefully prints more information). * Don't require code signing on CI. * Remove development team from signing. * Fix empty code signing setting. --------- Co-authored-by: Tadeas Kriz <[email protected]>
1 parent f4dab27 commit 3af2a9f

39 files changed

+39
-1476
lines changed

.github/workflows/KaMPKit-iOS.yml

+4-5
Original file line numberDiff line numberDiff line change
@@ -24,18 +24,17 @@ jobs:
2424
distribution: corretto
2525
java-version: 17
2626

27-
- name: Build
27+
- name: Run tests
2828
run: ./gradlew :shared:iosX64Test
2929

3030
- name: Build
3131
uses: sersoft-gmbh/xcodebuild-action@v1
3232
with:
33-
workspace: ios/KaMPKitiOS.xcworkspace
33+
project: ios/KaMPKitiOS.xcodeproj
3434
scheme: KaMPKitiOS
3535
destination: name=iPhone 8
3636
sdk: iphoneos
3737
configuration: Debug
3838
action: build
39-
40-
41-
39+
use-xcpretty: false
40+
build-settings: CODE_SIGN_IDENTITY= CODE_SIGNING_REQUIRED=NO

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,4 @@
1212
*.xcbkptlist
1313
!/.idea/codeStyles/*
1414
!/.idea/inspectionProfiles/*
15+
.kotlin

README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,8 @@ The central part of the "Kit" is the starter app. It includes a set of libraries
7272
You will need the following:
7373

7474
- JVM 17
75-
- Android SDK and the latest stable Android Studio (2022.3+) or IntelliJ(2023.2+)
76-
- Mac with Xcode 14+ for the iOS build
75+
- Android SDK and the latest stable Android Studio (2023.3+) or IntelliJ(2024.1+)
76+
- Mac with Xcode 15+ for the iOS build
7777

7878
For a more detailed guide targeted at iOS developers, see [DETAILED_DEV_SETUP](docs/DETAILED_DEV_SETUP.md).
7979

app/build.gradle.kts

+1-4
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
plugins {
22
alias(libs.plugins.android.application)
33
alias(libs.plugins.kotlin.android)
4+
alias(libs.plugins.compose.compiler)
45
}
56

67
android {
@@ -41,10 +42,6 @@ android {
4142
compose = true
4243
buildConfig = true
4344
}
44-
45-
composeOptions {
46-
kotlinCompilerExtensionVersion = libs.versions.composeCompiler.get()
47-
}
4845
}
4946

5047
dependencies {

build.gradle.kts

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ plugins {
77
alias(libs.plugins.android.application) apply false
88
alias(libs.plugins.kotlin.serialization) apply false
99
alias(libs.plugins.skie) apply false
10-
alias(libs.plugins.cocoapods) apply false
10+
alias(libs.plugins.compose.compiler) apply false
1111
}
1212

1313
subprojects {

gradle/libs.versions.toml

+12-15
Original file line numberDiff line numberDiff line change
@@ -5,30 +5,30 @@ targetSdk = "34"
55
compileSdk = "34"
66

77
# Dependencies
8-
kotlin = "1.9.22"
8+
kotlin = "2.0.0"
99

10-
android-gradle-plugin = "8.2.2"
10+
android-gradle-plugin = "8.2.0"
1111
ktlint-gradle = "12.1.0"
1212

13-
compose = "1.5.4"
14-
composeCompiler = "1.5.8"
13+
compose = "1.6.7"
1514

1615
android-desugaring = "2.0.4"
17-
androidx-core = "1.12.0"
16+
androidx-core = "1.13.1"
1817
androidx-test-junit = "1.1.5"
19-
androidx-activity-compose = "1.8.2"
18+
androidx-activity-compose = "1.9.0"
19+
# TODO: Update to 2.8.+ when updating to Compose 1.7.+
2020
androidx-lifecycle = "2.7.0"
2121

2222
junit = "4.13.2"
2323

24-
coroutines = "1.7.3"
25-
kotlinx-datetime = "0.5.0"
26-
ktor = "2.3.7"
24+
coroutines = "1.8.1"
25+
kotlinx-datetime = "0.6.0"
26+
ktor = "2.3.11"
2727

2828
robolectric = "4.10.3"
2929

30-
kermit = "2.0.2"
31-
skie = "0.6.1"
30+
kermit = "2.0.3"
31+
skie = "0.8.0"
3232

3333
koin = "3.5.3"
3434
multiplatformSettings = "1.1.1"
@@ -43,7 +43,6 @@ androidx-lifecycle-viewmodel = { module = "androidx.lifecycle:lifecycle-viewmode
4343
androidx-lifecycle-compose = { module = "androidx.lifecycle:lifecycle-runtime-compose", version.ref = "androidx-lifecycle" }
4444
androidx-test-junit = { module = "androidx.test.ext:junit-ktx", version.ref = "androidx-test-junit" }
4545

46-
compose-compiler = { module = "androidx.compose.compiler:compiler", version.ref = "composeCompiler" }
4746
compose-ui = { module = "androidx.compose.ui:ui", version.ref = "compose" }
4847
compose-tooling = { module = "androidx.compose.ui:ui-tooling", version.ref = "compose" }
4948
compose-foundation = { module = "androidx.compose.foundation:foundation", version.ref = "compose" }
@@ -95,11 +94,10 @@ android-application = { id = "com.android.application", version.ref = "android-g
9594
android-library = { id = "com.android.library", version.ref = "android-gradle-plugin" }
9695
kotlin-serialization = { id = "org.jetbrains.kotlin.plugin.serialization", version.ref = "kotlin" }
9796
skie = { id = "co.touchlab.skie", version.ref = "skie" }
98-
cocoapods = { id = "org.jetbrains.kotlin.native.cocoapods", version.ref = "kotlin" }
97+
compose-compiler = { id = "org.jetbrains.kotlin.plugin.compose", version.ref = "kotlin" }
9998

10099
[bundles]
101100
app-ui = [
102-
"compose-compiler",
103101
"androidx-core",
104102
"androidx-lifecycle-runtime",
105103
"androidx-lifecycle-viewmodel",
@@ -125,4 +123,3 @@ shared-androidTest = [
125123
"roboelectric",
126124
"sqlDelight-jvm"
127125
]
128-

gradle/wrapper/gradle-wrapper.properties

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.7-bin.zip
44
networkTimeout=10000
55
validateDistributionUrl=true
66
zipStoreBase=GRADLE_USER_HOME

ios/KaMPKitiOS.xcodeproj/project.pbxproj

+6-70
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,10 @@
33
archiveVersion = 1;
44
classes = {
55
};
6-
objectVersion = 51;
6+
objectVersion = 50;
77
objects = {
88

99
/* Begin PBXBuildFile section */
10-
3DFF917C64A18A83DA010EE1 /* Pods_KaMPKitiOS.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B859F3FB23133D22AB9DD835 /* Pods_KaMPKitiOS.framework */; };
1110
46A5B5EF26AF54F7002EFEAA /* BreedListScreen.swift in Sources */ = {isa = PBXBuildFile; fileRef = 46A5B5EE26AF54F7002EFEAA /* BreedListScreen.swift */; };
1211
46A5B60826B04921002EFEAA /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 46A5B60626B04920002EFEAA /* Main.storyboard */; };
1312
46B5284D249C5CF400A7725D /* Koin.swift in Sources */ = {isa = PBXBuildFile; fileRef = 46B5284C249C5CF400A7725D /* Koin.swift */; };
@@ -36,13 +35,9 @@
3635
/* End PBXContainerItemProxy section */
3736

3837
/* Begin PBXFileReference section */
39-
1DFCC00C8DAA719770A18D1A /* Pods-KaMPKitiOS.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-KaMPKitiOS.release.xcconfig"; path = "Pods/Target Support Files/Pods-KaMPKitiOS/Pods-KaMPKitiOS.release.xcconfig"; sourceTree = "<group>"; };
40-
2A1ED6A4A2A53F5F75C58E5F /* Pods-KaMPKitiOS.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-KaMPKitiOS.release.xcconfig"; path = "Pods/Target Support Files/Pods-KaMPKitiOS/Pods-KaMPKitiOS.release.xcconfig"; sourceTree = "<group>"; };
4138
46A5B5EE26AF54F7002EFEAA /* BreedListScreen.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BreedListScreen.swift; sourceTree = "<group>"; };
4239
46A5B60726B04920002EFEAA /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = "<group>"; };
4340
46B5284C249C5CF400A7725D /* Koin.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Koin.swift; sourceTree = "<group>"; };
44-
B859F3FB23133D22AB9DD835 /* Pods_KaMPKitiOS.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_KaMPKitiOS.framework; sourceTree = BUILT_PRODUCTS_DIR; };
45-
ED1F782AF3705197012D0C33 /* Pods-KaMPKitiOS.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-KaMPKitiOS.debug.xcconfig"; path = "Pods/Target Support Files/Pods-KaMPKitiOS/Pods-KaMPKitiOS.debug.xcconfig"; sourceTree = "<group>"; };
4641
F1465EFD23AA94BF0055F7C3 /* KaMPKitiOS.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = KaMPKitiOS.app; sourceTree = BUILT_PRODUCTS_DIR; };
4742
F1465F0023AA94BF0055F7C3 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
4843
F1465F0923AA94BF0055F7C3 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
@@ -54,15 +49,13 @@
5449
F1465F1E23AA94C00055F7C3 /* KaMPKitiOSUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = KaMPKitiOSUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
5550
F1465F2223AA94C00055F7C3 /* KaMPKitiOSUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = KaMPKitiOSUITests.swift; sourceTree = "<group>"; };
5651
F1465F2423AA94C00055F7C3 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
57-
F9C259C83C689DF8F4602F38 /* Pods-KaMPKitiOS.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-KaMPKitiOS.debug.xcconfig"; path = "Pods/Target Support Files/Pods-KaMPKitiOS/Pods-KaMPKitiOS.debug.xcconfig"; sourceTree = "<group>"; };
5852
/* End PBXFileReference section */
5953

6054
/* Begin PBXFrameworksBuildPhase section */
6155
F1465EFA23AA94BF0055F7C3 /* Frameworks */ = {
6256
isa = PBXFrameworksBuildPhase;
6357
buildActionMask = 2147483647;
6458
files = (
65-
3DFF917C64A18A83DA010EE1 /* Pods_KaMPKitiOS.framework in Frameworks */,
6659
);
6760
runOnlyForDeploymentPostprocessing = 0;
6861
};
@@ -86,30 +79,17 @@
8679
6278498AD96A4D949D39BF44 /* Frameworks */ = {
8780
isa = PBXGroup;
8881
children = (
89-
B859F3FB23133D22AB9DD835 /* Pods_KaMPKitiOS.framework */,
9082
);
9183
name = Frameworks;
9284
sourceTree = "<group>";
9385
};
94-
DF9BBECBCD175B90105DA8D9 /* Pods */ = {
95-
isa = PBXGroup;
96-
children = (
97-
F9C259C83C689DF8F4602F38 /* Pods-KaMPKitiOS.debug.xcconfig */,
98-
1DFCC00C8DAA719770A18D1A /* Pods-KaMPKitiOS.release.xcconfig */,
99-
ED1F782AF3705197012D0C33 /* Pods-KaMPKitiOS.debug.xcconfig */,
100-
2A1ED6A4A2A53F5F75C58E5F /* Pods-KaMPKitiOS.release.xcconfig */,
101-
);
102-
name = Pods;
103-
sourceTree = "<group>";
104-
};
10586
F1465EF423AA94BF0055F7C3 = {
10687
isa = PBXGroup;
10788
children = (
10889
F1465EFF23AA94BF0055F7C3 /* KaMPKitiOS */,
10990
F1465F1623AA94C00055F7C3 /* KaMPKitiOSTests */,
11091
F1465F2123AA94C00055F7C3 /* KaMPKitiOSUITests */,
11192
F1465EFE23AA94BF0055F7C3 /* Products */,
112-
DF9BBECBCD175B90105DA8D9 /* Pods */,
11393
6278498AD96A4D949D39BF44 /* Frameworks */,
11494
);
11595
sourceTree = "<group>";
@@ -163,12 +143,10 @@
163143
isa = PBXNativeTarget;
164144
buildConfigurationList = F1465F2723AA94C00055F7C3 /* Build configuration list for PBXNativeTarget "KaMPKitiOS" */;
165145
buildPhases = (
166-
DE3B37D33D11C1968D62DBBA /* [CP] Check Pods Manifest.lock */,
146+
9C16E6F82C0618F100154B87 /* ShellScript */,
167147
F1465EF923AA94BF0055F7C3 /* Sources */,
168-
451A87F626D69EA40013D7F8 /* SwiftLint */,
169148
F1465EFA23AA94BF0055F7C3 /* Frameworks */,
170149
F1465EFB23AA94BF0055F7C3 /* Resources */,
171-
9927C3E3A82FD5756098EAC1 /* [CP] Embed Pods Frameworks */,
172150
);
173151
buildRules = (
174152
);
@@ -286,62 +264,22 @@
286264
/* End PBXResourcesBuildPhase section */
287265

288266
/* Begin PBXShellScriptBuildPhase section */
289-
451A87F626D69EA40013D7F8 /* SwiftLint */ = {
290-
isa = PBXShellScriptBuildPhase;
291-
buildActionMask = 2147483647;
292-
files = (
293-
);
294-
inputFileListPaths = (
295-
);
296-
inputPaths = (
297-
);
298-
name = SwiftLint;
299-
outputFileListPaths = (
300-
);
301-
outputPaths = (
302-
);
303-
runOnlyForDeploymentPostprocessing = 0;
304-
shellPath = /bin/sh;
305-
shellScript = "# For reference: https://github.com/realm/SwiftLint\n\n${PODS_ROOT}/SwiftLint/swiftlint\n";
306-
};
307-
9927C3E3A82FD5756098EAC1 /* [CP] Embed Pods Frameworks */ = {
308-
isa = PBXShellScriptBuildPhase;
309-
buildActionMask = 2147483647;
310-
files = (
311-
);
312-
inputFileListPaths = (
313-
"${PODS_ROOT}/Target Support Files/Pods-KaMPKitiOS/Pods-KaMPKitiOS-frameworks-${CONFIGURATION}-input-files.xcfilelist",
314-
);
315-
name = "[CP] Embed Pods Frameworks";
316-
outputFileListPaths = (
317-
"${PODS_ROOT}/Target Support Files/Pods-KaMPKitiOS/Pods-KaMPKitiOS-frameworks-${CONFIGURATION}-output-files.xcfilelist",
318-
);
319-
runOnlyForDeploymentPostprocessing = 0;
320-
shellPath = /bin/sh;
321-
shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-KaMPKitiOS/Pods-KaMPKitiOS-frameworks.sh\"\n";
322-
showEnvVarsInLog = 0;
323-
};
324-
DE3B37D33D11C1968D62DBBA /* [CP] Check Pods Manifest.lock */ = {
267+
9C16E6F82C0618F100154B87 /* ShellScript */ = {
325268
isa = PBXShellScriptBuildPhase;
326269
buildActionMask = 2147483647;
327270
files = (
328271
);
329272
inputFileListPaths = (
330273
);
331274
inputPaths = (
332-
"${PODS_PODFILE_DIR_PATH}/Podfile.lock",
333-
"${PODS_ROOT}/Manifest.lock",
334275
);
335-
name = "[CP] Check Pods Manifest.lock";
336276
outputFileListPaths = (
337277
);
338278
outputPaths = (
339-
"$(DERIVED_FILE_DIR)/Pods-KaMPKitiOS-checkManifestLockResult.txt",
340279
);
341280
runOnlyForDeploymentPostprocessing = 0;
342281
shellPath = /bin/sh;
343-
shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
344-
showEnvVarsInLog = 0;
282+
shellScript = "# Type a script or drag a script file from your workspace to insert its path.\ncd \"$SRCROOT/..\"\n./gradlew embedAndSignAppleFrameworkForXcode\n";
345283
};
346284
/* End PBXShellScriptBuildPhase section */
347285

@@ -531,12 +469,11 @@
531469
};
532470
F1465F2823AA94C00055F7C3 /* Debug */ = {
533471
isa = XCBuildConfiguration;
534-
baseConfigurationReference = ED1F782AF3705197012D0C33 /* Pods-KaMPKitiOS.debug.xcconfig */;
535472
buildSettings = {
536473
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
537474
CODE_SIGN_IDENTITY = "Apple Development";
538475
CODE_SIGN_STYLE = Automatic;
539-
DEVELOPMENT_TEAM = 8UD86646U9;
476+
DEVELOPMENT_TEAM = "";
540477
INFOPLIST_FILE = KaMPKitiOS/Info.plist;
541478
IPHONEOS_DEPLOYMENT_TARGET = 15.0;
542479
LD_RUNPATH_SEARCH_PATHS = (
@@ -560,12 +497,11 @@
560497
};
561498
F1465F2923AA94C00055F7C3 /* Release */ = {
562499
isa = XCBuildConfiguration;
563-
baseConfigurationReference = 2A1ED6A4A2A53F5F75C58E5F /* Pods-KaMPKitiOS.release.xcconfig */;
564500
buildSettings = {
565501
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
566502
CODE_SIGN_IDENTITY = "Apple Development";
567503
CODE_SIGN_STYLE = Automatic;
568-
DEVELOPMENT_TEAM = 8UD86646U9;
504+
DEVELOPMENT_TEAM = "";
569505
INFOPLIST_FILE = KaMPKitiOS/Info.plist;
570506
IPHONEOS_DEPLOYMENT_TARGET = 15.0;
571507
LD_RUNPATH_SEARCH_PATHS = (

ios/KaMPKitiOS.xcworkspace/contents.xcworkspacedata

-20
This file was deleted.

ios/KaMPKitiOS.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist

-8
This file was deleted.

ios/Podfile

-10
This file was deleted.

ios/Podfile.lock

-23
This file was deleted.

0 commit comments

Comments
 (0)