Last active
February 18, 2020 20:58
-
-
Save wongk/b53b7346df5fc9b5fe894ea88b4c4918 to your computer and use it in GitHub Desktop.
Blog - KMP publishing - target configuration
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
kotlin { | |
android { | |
publishAllLibraryVariants() | |
} | |
iosX64("ios") { | |
mavenPublication { | |
artifactId = "${project.name}-iosx64" | |
} | |
} | |
iosArm64 { | |
compilations["main"].defaultSourceSet { | |
dependsOn(sourceSets["iosMain"]) | |
} | |
// Remove the test compilation for Arm64, because it is not needed. | |
compilations.remove(compilations["test"]) | |
} | |
targets.withType<KotlinNativeTarget> { | |
binaries.framework(listOf(RELEASE)) | |
} | |
... | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment