forked from JetBrains/compose-multiplatform-core
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsettings.gradle
263 lines (242 loc) · 12.6 KB
/
settings.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
import org.gradle.nativeplatform.platform.internal.DefaultNativePlatform
pluginManagement {
repositories {
mavenCentral()
google()
maven {
url = "https://plugins.gradle.org/m2/"
}
}
}
buildscript {
ext.supportRootFolder = buildscript.sourceFile.getParentFile()
apply(from: "buildSrc/repos.gradle")
repos.addMavenRepositories(repositories)
}
// Makes strong assumptions about the project structure.
def prebuiltsRoot = new File(
buildscript.sourceFile.parentFile,
"prebuilts"
).absolutePath
def rootProjectRepositories
apply from: "buildSrc/out.gradle"
def (outDir, buildSrcOut) = init.getOutDir()
getGradle().beforeProject {
// Migrate to dependencyResolutionManagement.repositories when
// https://github.com/gradle/gradle/issues/17295 is fixed
if (it.path == ":") {
repos.addMavenRepositories(it.repositories)
rootProjectRepositories = it.repositories
// Set buildSrcOut and outDir extras on root project
it.ext.buildSrcOut = buildSrcOut
it.ext.outDir = outDir
} else {
// Performance optimization because it is more efficient to reuse
// repositories from the root project than recreate identical ones
// on each project
it.repositories.addAll(rootProjectRepositories)
}
it.ext.prebuiltsRoot = prebuiltsRoot
// Expected out directory structure for :foo:bar is out/androidx/foo/bar
it.buildDir = new File(outDir, "androidx/${it.path.replace(":", "/")}/build")
}
rootProject.name = "compose-multiplatform-core"
dependencyResolutionManagement {
versionCatalogs {
libs {
def metalavaOverride = System.getenv("METALAVA_VERSION")
if (metalavaOverride != null) {
logger.warn("Using custom version ${metalavaOverride} of metalava due to METALAVA_VERSION being set.")
version('metalava', metalavaOverride)
}
def skikoOverride = System.getenv("SKIKO_VERSION")
if (skikoOverride != null) {
logger.warn("Using custom version ${skikoOverride} of SKIKO due to SKIKO_VERSION being set.")
version('skiko', skikoOverride)
}
String os = System.getProperty("os.name").toLowerCase(Locale.US)
String currentOsArtifact
if (os.contains("mac os x") || os.contains("darwin") || os.contains("osx")) {
def arch = System.getProperty("os.arch")
if (arch == "aarch64") {
currentOsArtifact = "skiko-awt-runtime-macos-arm64"
} else {
currentOsArtifact = "skiko-awt-runtime-macos-x64"
}
} else if (os.startsWith("win")) {
currentOsArtifact = "skiko-awt-runtime-windows-x64"
} else if (os.startsWith("linux") ) {
def arch = System.getProperty("os.arch")
if (arch == "aarch64") {
currentOsArtifact = "skiko-awt-runtime-linux-arm64"
} else {
currentOsArtifact = "skiko-awt-runtime-linux-x64"
}
} else {
throw GradleException("Unsupported operating system $os")
}
library("skikoCurrentOs", "org.jetbrains.skiko", currentOsArtifact).versionRef("skiko")
}
}
}
def includeProject(name) {
includeProject(name, null)
}
def includeProject(name, filePath) {
settings.include(name)
def file
if (filePath != null) {
if (filePath instanceof String) {
if ((":" + filePath.replace("/",":")).equals(name)) {
throw new IllegalArgumentException("Redundant filepath for $name, please remove it")
}
file = new File(rootDir, filePath)
} else {
file = filePath
}
project(name).projectDir = file
}
}
includeProject(":annotation:annotation")
includeProject(":annotation:annotation-sampled")
includeProject(":collection:collection")
includeProject(":compose:animation")
includeProject(":compose:animation:animation")
includeProject(":compose:animation:animation-lint")
includeProject(":compose:animation:animation-core")
includeProject(":compose:animation:animation-core-lint")
includeProject(":compose:animation:animation-core:animation-core-samples", "compose/animation/animation-core/samples")
includeProject(":compose:animation:animation-tooling-internal")
includeProject(":compose:animation:animation:integration-tests:animation-demos")
includeProject(":compose:animation:animation:animation-samples", "compose/animation/animation/samples")
includeProject(":compose:animation:animation-graphics")
includeProject(":compose:animation:animation-graphics:animation-graphics-samples", "compose/animation/animation-graphics/samples")
includeProject(":compose:compiler:compiler")
includeProject(":compose:compiler:compiler:integration-tests")
includeProject(":compose:compiler:compiler-hosted")
includeProject(":compose:compiler:compiler-hosted:integration-tests")
includeProject(":compose:compiler:compiler-hosted:integration-tests:kotlin-compiler-repackaged")
includeProject(":compose:compiler:compiler-daemon")
includeProject(":compose:compiler:compiler-daemon:integration-tests")
includeProject(":compose:desktop")
includeProject(":compose:desktop:desktop")
includeProject(":compose:desktop:desktop:desktop-samples", "compose/desktop/desktop/samples")
includeProject(":compose:desktop:desktop:desktop-samples-material3", "compose/desktop/desktop/samples-material3")
includeProject(":compose:mpp")
includeProject(":compose:mpp:demo")
// workaround for issue that on linux and windows CommonizeCInterop task fails
// It seems that this workaround can be removed after Kotlin 1.8.20
if (DefaultNativePlatform.getCurrentOperatingSystem().isMacOsX()) {
includeProject(":compose:mpp:demo-uikit")
}
includeProject(":compose:foundation")
includeProject(":compose:foundation:foundation")
includeProject(":compose:foundation:foundation-layout")
includeProject(":compose:foundation:foundation-layout:integration-tests:foundation-layout-demos", "compose/foundation/foundation-layout/integration-tests/layout-demos")
includeProject(":compose:foundation:foundation-layout:foundation-layout-samples", "compose/foundation/foundation-layout/samples")
includeProject(":compose:foundation:foundation-lint")
includeProject(":compose:foundation:foundation:integration-tests:foundation-demos")
includeProject(":compose:foundation:foundation:foundation-samples", "compose/foundation/foundation/samples")
includeProject(":compose:integration-tests")
//includeProject(":compose:integration-tests:demos")
includeProject(":compose:integration-tests:demos:common")
includeProject(":compose:integration-tests:docs-snippets")
includeProject(":compose:integration-tests:material-catalog")
includeProject(":compose:lint")
includeProject(":compose:lint:internal-lint-checks")
includeProject(":compose:lint:common")
includeProject(":compose:lint:common-test")
includeProject(":compose:material")
includeProject(":compose:material3:material3")
//includeProject(":compose:material3:material3-adaptive")
includeProject(":compose:material3:material3-lint")
includeProject(":compose:material3:material3-window-size-class")
includeProject(":compose:material3:material3-window-size-class:material3-window-size-class-samples", "compose/material3/material3-window-size-class/samples")
includeProject(":compose:material:material")
includeProject(":compose:material:material-lint")
includeProject(":compose:material:material-icons-core")
includeProject(":compose:material:material-icons-core:material-icons-core-samples", "compose/material/material-icons-core/samples")
includeProject(":compose:material:material-icons-extended")
includeProject(":compose:material:material-ripple")
includeProject(":compose:material:material:icons:generator")
// on an empty project it causes an error during sync in IDEA
// Corrupt serialized resolution result. Cannot find selected module (287) for releaseVariantReleaseRuntimePublication -> androidx.lifecycle:lifecycle-common-java8:2.5.1
//includeProject(":compose:material:material:integration-tests:material-demos")
//includeProject(":compose:material:material:integration-tests:material-catalog")
//includeProject(":compose:material3:material3:integration-tests:material3-demos")
//includeProject(":compose:material3:material3:integration-tests:material3-catalog")
includeProject(":compose:material:material:material-samples", "compose/material/material/samples")
includeProject(":compose:material3:material3:material3-samples", "compose/material3/material3/samples")
includeProject(":compose:runtime")
includeProject(":compose:runtime:runtime")
includeProject(":compose:runtime:runtime-lint")
includeProject(":compose:runtime:runtime-livedata")
includeProject(":compose:runtime:runtime-livedata:runtime-livedata-samples", "compose/runtime/runtime-livedata/samples")
includeProject(":compose:runtime:runtime-tracing")
includeProject(":compose:runtime:runtime-rxjava2")
includeProject(":compose:runtime:runtime-rxjava2:runtime-rxjava2-samples", "compose/runtime/runtime-rxjava2/samples")
includeProject(":compose:runtime:runtime-rxjava3")
includeProject(":compose:runtime:runtime-rxjava3:runtime-rxjava3-samples", "compose/runtime/runtime-rxjava3/samples")
includeProject(":compose:runtime:runtime-saveable")
includeProject(":compose:runtime:runtime-saveable-lint")
includeProject(":compose:runtime:runtime-saveable:runtime-saveable-samples", "compose/runtime/runtime-saveable/samples")
includeProject(":compose:runtime:runtime:integration-tests")
includeProject(":compose:runtime:runtime:runtime-samples", "compose/runtime/runtime/samples")
includeProject(":compose:test-utils")
includeProject(":compose:ui")
includeProject(":compose:ui:ui")
includeProject(":compose:ui:ui-android-stubs")
includeProject(":compose:ui:ui-geometry")
includeProject(":compose:ui:ui-graphics")
includeProject(":compose:ui:ui-graphics-lint")
includeProject(":compose:ui:ui-graphics:ui-graphics-samples", "compose/ui/ui-graphics/samples")
includeProject(":compose:ui:ui-lint")
includeProject(":compose:ui:ui-test")
includeProject(":compose:ui:ui-test:ui-test-samples", "compose/ui/ui-test/samples")
includeProject(":compose:ui:ui-test-junit4")
includeProject(":compose:ui:ui-test-manifest")
includeProject(":compose:ui:ui-test-manifest-lint")
includeProject(":compose:ui:ui-test-manifest:integration-tests:testapp")
includeProject(":compose:ui:ui-text")
includeProject(":compose:ui:ui-text-google-fonts")
includeProject(":compose:ui:ui-text:ui-text-samples", "compose/ui/ui-text/samples")
includeProject(":compose:ui:ui-tooling")
includeProject(":compose:ui:ui-tooling-data")
includeProject(":compose:ui:ui-tooling-preview")
includeProject(":compose:ui:ui-unit")
includeProject(":compose:ui:ui-unit:ui-unit-samples", "compose/ui/ui-unit/samples")
includeProject(":compose:ui:ui-util")
includeProject(":compose:ui:ui-viewbinding")
includeProject(":compose:ui:ui-viewbinding:ui-viewbinding-samples", "compose/ui/ui-viewbinding/samples")
includeProject(":compose:ui:ui:integration-tests:ui-demos")
includeProject(":compose:ui:ui:ui-samples", "compose/ui/ui/samples")
includeProject(":compose:ui:ui-uikit")
includeProject(":kruth:kruth")
includeProject(":lint-checks")
includeProject(":lint-checks:integration-tests")
includeProject(":core:core-bundle")
includeProject(":lifecycle:lifecycle-common")
includeProject(":lifecycle:lifecycle-runtime")
includeProject(":lifecycle:lifecycle-runtime-compose")
includeProject(":lifecycle:lifecycle-runtime-lint")
includeProject(":lifecycle:lifecycle-viewmodel")
includeProject(":lifecycle:lifecycle-viewmodel-compose")
includeProject(":lifecycle:lifecycle-viewmodel-savedstate")
includeProject(":navigation:navigation-common")
includeProject(":navigation:navigation-compose")
includeProject(":navigation:navigation-runtime")
includeProject(":navigation:navigation-testing")
includeProject(":savedstate:savedstate")
includeProject(":internal-testutils-common", "testutils/testutils-common",)
includeProject(":internal-testutils-runtime", "testutils/testutils-runtime")
includeProject(":internal-testutils-espresso", "testutils/testutils-espresso")
includeProject(":internal-testutils-fonts", "testutils/testutils-fonts")
includeProject(":internal-testutils-truth", "testutils/testutils-truth")
includeProject(":internal-testutils-ktx", "testutils/testutils-ktx")
includeProject(":internal-testutils-navigation", "testutils/testutils-navigation")
includeProject(":internal-testutils-paging", "testutils/testutils-paging")
includeProject(":internal-testutils-gradle-plugin", "testutils/testutils-gradle-plugin")
includeProject(":internal-testutils-mockito", "testutils/testutils-mockito")
// Workaround for b/203825166
includeBuild("placeholder")
includeProject(":mpp")