Skip to content

Commit d566dfd

Browse files
committed
Add a convenience configuration to enable distributable builds.
1 parent 3106329 commit d566dfd

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

SKIE/skie-gradle/plugin-api/src/common/kotlin/co/touchlab/skie/plugin/configuration/SkieBuildConfiguration.kt

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
@file:Suppress("MemberVisibilityCanBePrivate")
1+
@file:Suppress("MemberVisibilityCanBePrivate", "unused")
22

33
package co.touchlab.skie.plugin.configuration
44

@@ -47,6 +47,19 @@ abstract class SkieBuildConfiguration @Inject constructor(objects: ObjectFactory
4747
*/
4848
val freeSwiftCompilerArgs: ListProperty<String> = objects.listProperty(String::class.java)
4949

50+
/**
51+
* Configures SKIE to produce distributable frameworks.
52+
*
53+
* This option is only needed when the produced framework will be compiled against on another machine.
54+
* On the other hand, this option is unnecessary when the framework is only used locally, including as a dependency for a binary that is then distributed to other machines.
55+
*
56+
* Enables Swift Library Evolution and `-no-clang-module-breadcrumbs` flag.
57+
*/
58+
fun produceDistributableFramework() {
59+
enableSwiftLibraryEvolution.set(true)
60+
noClangModuleBreadcrumbsInStaticFrameworks.set(true)
61+
}
62+
5063
internal fun buildConfigurationFlags(): Set<SkieConfigurationFlag> =
5164
setOfNotNull(
5265
SkieConfigurationFlag.Build_SwiftLibraryEvolution takeIf enableSwiftLibraryEvolution,

0 commit comments

Comments
 (0)