Compare commits

...

23 Commits

Author SHA1 Message Date
Vyacheslav Gerasimov
7c191673c5 Minor: Cleanup jps.gradle.kts 2019-06-03 17:32:00 +03:00
Vyacheslav Gerasimov
26ae490215 Build: Add compiler libs to library configuration 2019-06-03 17:32:00 +03:00
Vyacheslav Gerasimov
1fc5f6bca9 Build: Fix jps import for jvm-abi-gen plugin 2019-06-03 17:32:00 +03:00
Vyacheslav Gerasimov
36dccea59a Build: Add jps artifact for kotlin compiler dist 2019-06-03 17:32:00 +03:00
Vyacheslav Gerasimov
bdfda45ab5 Build: Drop obsolete jps artifact generation 2019-06-03 17:32:00 +03:00
Vyacheslav Gerasimov
4e88281338 Build: Add JPS artifact for kotlin-compiler.jar
JPS build assumes fat jar is built from embedded configuration,
but we can't use it in gradle build in :prepare:compiler project
since slightly more complex processing is required like stripping
metadata & services from some jars
2019-06-03 17:32:00 +03:00
Vyacheslav Gerasimov
f8d9d1478f Build: extract jarContentsFromConfiguration dsl helper 2019-06-03 17:32:00 +03:00
Vyacheslav Gerasimov
f24df8805d Minor: cleanup :prepare:compiler build script 2019-06-03 17:32:00 +03:00
Vyacheslav Gerasimov
7cfb522e44 Build: Add workaround dist root artifact referencing auto-generated dist
We can't set output-path and build-on-make from idea-ext plugin
2019-06-03 17:32:00 +03:00
Vyacheslav Gerasimov
cd36fdbde9 Build: Fix idea plugin dependencies for JPS build
we interpret embedded configuration as runtime in JPS and need to exclude embedded jars while copying libs
2019-06-03 17:32:00 +03:00
Vyacheslav Gerasimov
6bcc77d228 Build: Add JPS artifact for dist 2019-06-03 17:31:59 +03:00
Vyacheslav Gerasimov
7f6d4cf9a2 Build: Add jps artifact for kotlin-reflect 2019-06-03 17:31:59 +03:00
Vyacheslav Gerasimov
2e782cb9da Build: Add jps artifact for kotlin-compiler-client-embeddable 2019-06-03 17:31:59 +03:00
Vyacheslav Gerasimov
df0aae1098 Build: Use embedded configuration in kotlin-compiler-client-embeddable 2019-06-03 17:31:59 +03:00
Vyacheslav Gerasimov
e57519dc8c Build: Add jps artifact for kotlin-main-kts 2019-06-03 17:31:59 +03:00
Vyacheslav Gerasimov
6dd627dc26 Build: Extract kotlin-plugin.jar to separate jps artifact 2019-06-03 17:31:59 +03:00
Vyacheslav Gerasimov
3ea4c671fe Build: add jps artifact for kotlin-imports-compiler-dumper 2019-06-03 17:31:59 +03:00
Vyacheslav Gerasimov
b13b3846e8 Build: include project main sourceset output in jar 2019-06-03 17:31:59 +03:00
Vyacheslav Gerasimov
8d0a582de6 Build: add jps artifact generation for kotlin-daemon-client 2019-06-03 17:31:59 +03:00
Vyacheslav Gerasimov
c76d9a29bb Build: use default jar task in kotlin-daemon-client 2019-06-03 17:31:58 +03:00
Vyacheslav Gerasimov
70cc1bb564 Build: generate jps artifact for kotlin-jps-plugin.jar 2019-06-03 17:31:58 +03:00
Vyacheslav Gerasimov
c71c21ee89 Build: Fix intellij dependency leak from FIR modules 2019-06-03 17:29:55 +03:00
Vyacheslav Gerasimov
55fb7cb191 Build: Improve sourcesJar helper
- Add sources from embedded projects
 - Add artifact to sources configuration
 - Use register instead of create

 #KT-30237 Fixed
2019-06-03 00:34:59 +03:00
64 changed files with 410 additions and 1597 deletions

10
.gitignore vendored
View File

@@ -36,7 +36,17 @@ build/
.idea/inspectionProfiles/profiles_settings.xml
.idea/.name
.idea/artifacts/dist_auto_*
.idea/artifacts/dist.xml
.idea/artifacts/ideaPlugin.xml
.idea/artifacts/kotlinc.xml
.idea/artifacts/kotlin_compiler_jar.xml
.idea/artifacts/kotlin_plugin_jar.xml
.idea/artifacts/kotlin_jps_plugin_jar.xml
.idea/artifacts/kotlin_daemon_client_jar.xml
.idea/artifacts/kotlin_imports_dumper_compiler_plugin_jar.xml
.idea/artifacts/kotlin_main_kts_jar.xml
.idea/artifacts/kotlin_compiler_client_embeddable_jar.xml
.idea/artifacts/kotlin_reflect_jar.xml
kotlin-ultimate/
node_modules/
.rpt2_cache/

View File

@@ -1,27 +0,0 @@
<component name="ArtifactManager">
<artifact build-on-make="true" name="dist">
<output-path>$PROJECT_DIR$/dist</output-path>
<root id="root">
<element id="directory" name="artifacts">
<element id="directory" name="ideaPlugin">
<element id="artifact" artifact-name="ideaPlugin" />
</element>
</element>
<element id="file-copy" path="$PROJECT_DIR$/build/build.txt" />
<element id="file-copy" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib-minimal-for-test/1.3.50-dev-526/7c531c6c6db03b6ebf0ff0e15027bb6aee5d2452/kotlin-stdlib-minimal-for-test-1.3.50-dev-526.jar" output-file-name="kotlin-stdlib-minimal-for-test.jar" />
<element id="directory" name="common">
<element id="file-copy" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib-common/1.3.50-dev-526/7a06077a97c805bc4d99aaa17c8e8accf86bfe7c/kotlin-stdlib-common-1.3.50-dev-526.jar" output-file-name="kotlin-stdlib-common.jar" />
<element id="file-copy" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib-common/1.3.50-dev-526/784cfd305e170c525b1a6987584dd8bebc4e0e6a/kotlin-stdlib-common-1.3.50-dev-526-sources.jar" output-file-name="kotlin-stdlib-common-sources.jar" />
</element>
<element id="directory" name="js">
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib-js/1.3.50-dev-526/8a798b744fdbd46a7d93814f0f0b97c664c064d2/kotlin-stdlib-js-1.3.50-dev-526.jar" path-in-jar="/" />
</element>
<element id="directory" name="maven">
<element id="file-copy" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib/1.3.50-dev-526/21e04af851994238d364653c103df336bf45fd4d/kotlin-stdlib-1.3.50-dev-526-sources.jar" output-file-name="kotlin-stdlib-sources.jar" />
</element>
<element id="directory" name="kotlinc">
<element id="artifact" artifact-name="kotlinc" />
</element>
</root>
</artifact>
</component>

8
.idea/artifacts/dist_root.xml generated Normal file
View File

@@ -0,0 +1,8 @@
<component name="ArtifactManager">
<artifact build-on-make="true" name="dist_root">
<output-path>$PROJECT_DIR$/dist</output-path>
<root id="root">
<element id="artifact" artifact-name="dist" />
</root>
</artifact>
</component>

View File

@@ -1,29 +0,0 @@
<component name="ArtifactManager">
<artifact type="jar" name="kotlin-compiler-client-embeddable.jar">
<output-path>$PROJECT_DIR$/out/artifacts/kotlin_compiler_client_embeddable_jar</output-path>
<root id="archive" name="kotlin-compiler-client-embeddable.jar">
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/prepare/compiler-client-embeddable/build/tmp/shadowJar/MANIFEST.MF" />
</element>
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform/0.14/48341d68b4456bea76ca952b6d38b877881350f7/native-platform-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-freebsd-amd64-libcpp/0.14/b45561900830d676e9e0040561e68abe86fbc10e/native-platform-freebsd-amd64-libcpp-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-freebsd-amd64-libstdcpp/0.14/bcc4e58ef4db56052fe9512d2d1265f11dc9242f/native-platform-freebsd-amd64-libstdcpp-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-freebsd-i386-libcpp/0.14/50b15724c82808c2b7fefd9b0b7c6dd977623f35/native-platform-freebsd-i386-libcpp-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-freebsd-i386-libstdcpp/0.14/d98be0a75890523a6a70dc93795101145828a5da/native-platform-freebsd-i386-libstdcpp-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-linux-amd64/0.14/d0ac539a32015e91e309c20e493d220aae88811b/native-platform-linux-amd64-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-linux-amd64-ncurses5/0.14/6dece223855317a75c371fb72d826582893351c6/native-platform-linux-amd64-ncurses5-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-linux-amd64-ncurses6/0.14/8effac668ad781893fc33fd86f993c5de559d355/native-platform-linux-amd64-ncurses6-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-linux-i386/0.14/6576c08a9a514a6ae5623e6f8da04502cac23bde/native-platform-linux-i386-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-linux-i386-ncurses5/0.14/80ec77af683abeaa58ed11b9c2cad2d02837e55f/native-platform-linux-i386-ncurses5-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-linux-i386-ncurses6/0.14/615dea7e75ca704bba1de9b671652283a9743894/native-platform-linux-i386-ncurses6-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-osx-amd64/0.14/5e5c113c32c0bac5cf2dcd3a59e4b021023d86a1/native-platform-osx-amd64-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-osx-i386/0.14/fd86b7eedbf5a0df003cf946f0b0c80c06c103ee/native-platform-osx-i386-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-windows-amd64/0.14/bdf519fab10700fadc9953526a07e8104fad1d07/native-platform-windows-amd64-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-windows-i386/0.14/65b00e123554f42ecd0da054a747033be5da608d/native-platform-windows-i386-0.14.jar" path-in-jar="/" />
<element id="module-output" name="kotlin.compiler.cli-common.main" />
<element id="module-output" name="kotlin.compiler.daemon-common.main" />
<element id="module-output" name="kotlin.kotlin-compiler-client-embeddable.main" />
<element id="module-output" name="kotlin.kotlin-daemon-client.main" />
</root>
</artifact>
</component>

View File

@@ -1,74 +0,0 @@
<component name="ArtifactManager">
<artifact type="jar" name="kotlin-compiler.jar">
<output-path>$PROJECT_DIR$/out/artifacts/kotlin_compiler_jar</output-path>
<root id="archive" name="kotlin-compiler.jar">
<element id="directory" name="META-INF">
<element id="directory" name="extensions">
<element id="file-copy" path="$PROJECT_DIR$/idea/resources/META-INF/extensions/compiler.xml" />
</element>
<element id="file-copy" path="$PROJECT_DIR$/prepare/compiler/build/tmp/packCompiler/MANIFEST.MF" />
</element>
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/builtins/1.3.50-dev-526/7dbbf186f7b89e37e7a8f91cb86db2f50440dcc4/builtins-1.3.50-dev-526.jar" path-in-jar="/" />
<element id="extracted-dir" path="$PROJECT_DIR$/dependencies/repo/kotlin.build/ideaIC/191.6707.61/artifacts/lib/asm-all-7.0.1.jar" path-in-jar="/" />
<element id="extracted-dir" path="$PROJECT_DIR$/dependencies/repo/kotlin.build/ideaIC/191.6707.61/artifacts/lib/guava-25.1-jre.jar" path-in-jar="/" />
<element id="extracted-dir" path="$PROJECT_DIR$/dependencies/repo/kotlin.build/intellij-core/191.6707.61/artifacts/intellij-core.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.fusesource.jansi/jansi/1.16/b1aaf0028852164ab6b4057192ccd0ba7dedd3a5/jansi-1.16.jar" path-in-jar="/" />
<element id="extracted-dir" path="$PROJECT_DIR$/dependencies/repo/kotlin.build/intellij-core/191.6707.61/artifacts/java-compatibility-1.0.1.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/io.javaslang/javaslang/2.0.6/415b0d40db4890849270c2a5cb50050fc6ee7636/javaslang-2.0.6.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/io.javaslang/javaslang-match/2.0.6/d57a666939103b659813de52102d3ff0baa8ad5f/javaslang-match-2.0.6.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/javax.inject/javax.inject/1/6975da39a7040257bd51d21a231b76c915872d38/javax.inject-1.jar" path-in-jar="/" />
<element id="extracted-dir" path="$PROJECT_DIR$/dependencies/repo/kotlin.build/ideaIC/191.6707.61/artifacts/lib/jdom.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jline/jline/3.3.1/d8a30137fe4ee2246b71b3915baac767d348c5bb/jline-3.3.1.jar" path-in-jar="/" />
<element id="extracted-dir" path="$PROJECT_DIR$/dependencies/repo/kotlin.build/ideaIC/191.6707.61/artifacts/lib/jna-platform.jar" path-in-jar="/" />
<element id="extracted-dir" path="$PROJECT_DIR$/dependencies/repo/kotlin.build/ideaIC/191.6707.61/artifacts/lib/jna.jar" path-in-jar="/" />
<element id="extracted-dir" path="$PROJECT_DIR$/dependencies/repo/kotlin.build/jps-standalone/191.6707.61/artifacts/jps-model.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/com.google.code.findbugs/jsr305/1.3.9/40719ea6961c0cb6afaeb6a921eaa1f6afd4cfdf/jsr305-1.3.9.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlinx/kotlinx-coroutines-core/1.0.1/f33e8dab753f33d1bbb07cca664fd6f13d993d7e/kotlinx-coroutines-core-1.0.1.jar" path-in-jar="/" />
<element id="extracted-dir" path="$PROJECT_DIR$/dependencies/repo/kotlin.build/ideaIC/191.6707.61/artifacts/lib/log4j.jar" path-in-jar="/" />
<element id="extracted-dir" path="$PROJECT_DIR$/dependencies/repo/kotlin.build/ideaIC/191.6707.61/artifacts/lib/lz4-1.3.0.jar" path-in-jar="/" />
<element id="extracted-dir" path="$PROJECT_DIR$/dependencies/repo/kotlin.build/ideaIC/191.6707.61/artifacts/lib/oro-2.0.8.jar" path-in-jar="/" />
<element id="extracted-dir" path="$PROJECT_DIR$/dependencies/repo/kotlin.build/ideaIC/191.6707.61/artifacts/lib/picocontainer-1.2.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/protobuf-relocated/2.6.1/9a9536949348fae596f4878243dffd0ed351993d/protobuf-relocated-2.6.1.jar" path-in-jar="/" />
<element id="extracted-dir" path="$PROJECT_DIR$/dependencies/repo/kotlin.build/ideaIC/191.6707.61/artifacts/lib/streamex-0.6.7.jar" path-in-jar="/" />
<element id="module-output" name="kotlin.compiler.backend-common.main" />
<element id="module-output" name="kotlin.compiler.backend.js.main" />
<element id="module-output" name="kotlin.compiler.backend.jvm.main" />
<element id="module-output" name="kotlin.compiler.backend.main" />
<element id="module-output" name="kotlin.compiler.cli-common.main" />
<element id="module-output" name="kotlin.compiler.cli.main" />
<element id="module-output" name="kotlin.compiler.main" />
<element id="module-output" name="kotlin.compiler.container.main" />
<element id="module-output" name="kotlin.compiler.daemon-common.main" />
<element id="module-output" name="kotlin.compiler.daemon.main" />
<element id="module-output" name="kotlin.core.descriptors.jvm.main" />
<element id="module-output" name="kotlin.core.descriptors.main" />
<element id="module-output" name="kotlin.core.deserialization.main" />
<element id="module-output" name="kotlin.compiler.frontend.java.main" />
<element id="module-output" name="kotlin.compiler.frontend.main" />
<element id="module-output" name="kotlin.compiler.incremental-compilation-impl.main" />
<element id="module-output" name="kotlin.compiler.ir.backend.common.main" />
<element id="module-output" name="kotlin.compiler.ir.psi2ir.main" />
<element id="module-output" name="kotlin.compiler.ir.tree.main" />
<element id="module-output" name="kotlin.js.js.ast.main" />
<element id="module-output" name="kotlin.js.js.dce.main" />
<element id="module-output" name="kotlin.js.js.frontend.main" />
<element id="module-output" name="kotlin.js.js.parser.main" />
<element id="module-output" name="kotlin.js.js.serializer.main" />
<element id="module-output" name="kotlin.js.js.translator.main" />
<element id="module-output" name="kotlin.kotlin-build-common.main" />
<element id="module-output" name="kotlin.compiler.light-classes.main" />
<element id="module-output" name="kotlin.core.metadata.jvm.main" />
<element id="module-output" name="kotlin.core.metadata.main" />
<element id="module-output" name="kotlin.compiler.plugin-api.main" />
<element id="module-output" name="kotlin.compiler.psi.main" />
<element id="module-output" name="kotlin.compiler.resolution.main" />
<element id="module-output" name="kotlin.compiler.serialization.main" />
<element id="module-output" name="kotlin.core.util.runtime.main" />
<element id="module-output" name="kotlin.compiler.util.main" />
<element id="module-output" name="kotlin.compiler.frontend.common.main" />
<element id="module-output" name="kotlin.core.type-system.main" />
<element id="module-output" name="kotlin.compiler.ir.serialization.common.main" />
<element id="module-output" name="kotlin.compiler.ir.serialization.js.main" />
</root>
</artifact>
</component>

View File

@@ -1,27 +0,0 @@
<component name="ArtifactManager">
<artifact type="jar" name="kotlin-daemon-client.jar">
<output-path>$PROJECT_DIR$/out/artifacts/kotlin_daemon_client_jar</output-path>
<root id="archive" name="kotlin-daemon-client.jar">
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform/0.14/48341d68b4456bea76ca952b6d38b877881350f7/native-platform-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-freebsd-amd64-libcpp/0.14/b45561900830d676e9e0040561e68abe86fbc10e/native-platform-freebsd-amd64-libcpp-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-freebsd-amd64-libstdcpp/0.14/bcc4e58ef4db56052fe9512d2d1265f11dc9242f/native-platform-freebsd-amd64-libstdcpp-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-freebsd-i386-libcpp/0.14/50b15724c82808c2b7fefd9b0b7c6dd977623f35/native-platform-freebsd-i386-libcpp-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-freebsd-i386-libstdcpp/0.14/d98be0a75890523a6a70dc93795101145828a5da/native-platform-freebsd-i386-libstdcpp-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-linux-amd64/0.14/d0ac539a32015e91e309c20e493d220aae88811b/native-platform-linux-amd64-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-linux-amd64-ncurses5/0.14/6dece223855317a75c371fb72d826582893351c6/native-platform-linux-amd64-ncurses5-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-linux-amd64-ncurses6/0.14/8effac668ad781893fc33fd86f993c5de559d355/native-platform-linux-amd64-ncurses6-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-linux-i386/0.14/6576c08a9a514a6ae5623e6f8da04502cac23bde/native-platform-linux-i386-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-linux-i386-ncurses5/0.14/80ec77af683abeaa58ed11b9c2cad2d02837e55f/native-platform-linux-i386-ncurses5-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-linux-i386-ncurses6/0.14/615dea7e75ca704bba1de9b671652283a9743894/native-platform-linux-i386-ncurses6-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-osx-amd64/0.14/5e5c113c32c0bac5cf2dcd3a59e4b021023d86a1/native-platform-osx-amd64-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-osx-i386/0.14/fd86b7eedbf5a0df003cf946f0b0c80c06c103ee/native-platform-osx-i386-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-windows-amd64/0.14/bdf519fab10700fadc9953526a07e8104fad1d07/native-platform-windows-amd64-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-windows-i386/0.14/65b00e123554f42ecd0da054a747033be5da608d/native-platform-windows-i386-0.14.jar" path-in-jar="/" />
<element id="module-output" name="kotlin.compiler.daemon-common.main" />
<element id="module-output" name="kotlin.kotlin-daemon-client.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/compiler/daemon/daemon-client/build/tmp/shadowJar/MANIFEST.MF" />
</element>
</root>
</artifact>
</component>

View File

@@ -1,12 +0,0 @@
<component name="ArtifactManager">
<artifact type="jar" name="kotlin-imports-dumper-compiler-plugin.jar">
<output-path>$PROJECT_DIR$/out/artifacts/kotlin_imports_dumper_compiler_plugin_jar</output-path>
<root id="archive" name="kotlin-imports-dumper-compiler-plugin.jar">
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/plugins/imports-dumper/build/tmp/jar/MANIFEST.MF" />
</element>
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlinx/kotlinx-serialization-runtime/0.4.2/e343c68c9fa77a190225484c1e03b1485fbb5f1f/kotlinx-serialization-runtime-0.4.2.jar" path-in-jar="/" />
<element id="module-output" name="kotlin.kotlin-imports-dumper-compiler-plugin.main" />
</root>
</artifact>
</component>

View File

@@ -1,39 +0,0 @@
<component name="ArtifactManager">
<artifact type="jar" name="kotlin-jps-plugin.jar">
<output-path>$PROJECT_DIR$/out/artifacts/kotlin_jps_plugin_jar</output-path>
<root id="archive" name="kotlin-jps-plugin.jar">
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/prepare/jps-plugin/build/tmp/jar/MANIFEST.MF" />
</element>
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform/0.14/48341d68b4456bea76ca952b6d38b877881350f7/native-platform-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-freebsd-amd64-libcpp/0.14/b45561900830d676e9e0040561e68abe86fbc10e/native-platform-freebsd-amd64-libcpp-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-freebsd-amd64-libstdcpp/0.14/bcc4e58ef4db56052fe9512d2d1265f11dc9242f/native-platform-freebsd-amd64-libstdcpp-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-freebsd-i386-libcpp/0.14/50b15724c82808c2b7fefd9b0b7c6dd977623f35/native-platform-freebsd-i386-libcpp-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-freebsd-i386-libstdcpp/0.14/d98be0a75890523a6a70dc93795101145828a5da/native-platform-freebsd-i386-libstdcpp-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-linux-amd64/0.14/d0ac539a32015e91e309c20e493d220aae88811b/native-platform-linux-amd64-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-linux-amd64-ncurses5/0.14/6dece223855317a75c371fb72d826582893351c6/native-platform-linux-amd64-ncurses5-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-linux-amd64-ncurses6/0.14/8effac668ad781893fc33fd86f993c5de559d355/native-platform-linux-amd64-ncurses6-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-linux-i386/0.14/6576c08a9a514a6ae5623e6f8da04502cac23bde/native-platform-linux-i386-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-linux-i386-ncurses5/0.14/80ec77af683abeaa58ed11b9c2cad2d02837e55f/native-platform-linux-i386-ncurses5-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-linux-i386-ncurses6/0.14/615dea7e75ca704bba1de9b671652283a9743894/native-platform-linux-i386-ncurses6-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-osx-amd64/0.14/5e5c113c32c0bac5cf2dcd3a59e4b021023d86a1/native-platform-osx-amd64-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-osx-i386/0.14/fd86b7eedbf5a0df003cf946f0b0c80c06c103ee/native-platform-osx-i386-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-windows-amd64/0.14/bdf519fab10700fadc9953526a07e8104fad1d07/native-platform-windows-amd64-0.14.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.rubygrapefruit/native-platform-windows-i386/0.14/65b00e123554f42ecd0da054a747033be5da608d/native-platform-windows-i386-0.14.jar" path-in-jar="/" />
<element id="module-output" name="kotlin.compiler.cli-common.main" />
<element id="module-output" name="kotlin.compiler.daemon-common.main" />
<element id="module-output" name="kotlin.core.descriptors.jvm.main" />
<element id="module-output" name="kotlin.core.descriptors.main" />
<element id="module-output" name="kotlin.idea.idea-jps-common.main" />
<element id="module-output" name="kotlin.jps-plugin.main" />
<element id="module-output" name="kotlin.kotlin-build-common.main" />
<element id="module-output" name="kotlin.kotlin-compiler-runner.main" />
<element id="module-output" name="kotlin.kotlin-daemon-client.main" />
<element id="module-output" name="kotlin.kotlin-preloader.main" />
<element id="module-output" name="kotlin.core.util.runtime.main" />
<element id="module-output" name="kotlin.compiler.util.main" />
<element id="module-output" name="kotlin.core.type-system.main" />
<element id="file-copy" path="$PROJECT_DIR$/resources/kotlinManifest.properties" />
</root>
</artifact>
</component>

View File

@@ -1,17 +0,0 @@
<component name="ArtifactManager">
<artifact type="jar" name="kotlin-main-kts.jar">
<output-path>$PROJECT_DIR$/out/artifacts/kotlin_main_kts_jar</output-path>
<root id="archive" name="kotlin-main-kts.jar">
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/tools/kotlin-main-kts/build/tmp/packJar/MANIFEST.MF" />
</element>
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.apache.ivy/ivy/2.4.0/5abe4c24bbe992a9ac07ca563d5bd3e8d569e9ed/ivy-2.4.0.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlinx/kotlinx-coroutines-core/1.0.1/f33e8dab753f33d1bbb07cca664fd6f13d993d7e/kotlinx-coroutines-core-1.0.1.jar" path-in-jar="/" />
<element id="module-output" name="kotlin.kotlin-main-kts.main" />
<element id="module-output" name="kotlin.kotlin-script-runtime.main" />
<element id="module-output" name="kotlin.kotlin-script-util.main" />
<element id="module-output" name="kotlin.kotlin-scripting-common.main" />
<element id="module-output" name="kotlin.kotlin-scripting-jvm.main" />
</root>
</artifact>
</component>

View File

@@ -1,22 +0,0 @@
<component name="ArtifactManager">
<artifact type="jar" name="kotlin-reflect.jar">
<output-path>$PROJECT_DIR$/out/artifacts/kotlin_reflect_jar</output-path>
<root id="archive" name="kotlin-reflect.jar">
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/reflect/build/tmp/result/MANIFEST.MF" />
</element>
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/javax.inject/javax.inject/1/6975da39a7040257bd51d21a231b76c915872d38/javax.inject-1.jar" path-in-jar="/" />
<element id="extracted-dir" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/protobuf-lite/2.6.1/9af39e6d6cbd4404d06ae2ae63505b6247e6760b/protobuf-lite-2.6.1.jar" path-in-jar="/" />
<element id="module-output" name="kotlin.core.descriptors.jvm.main" />
<element id="module-output" name="kotlin.core.descriptors.runtime.main" />
<element id="module-output" name="kotlin.core.descriptors.main" />
<element id="module-output" name="kotlin.core.deserialization.main" />
<element id="module-output" name="kotlin.kotlin-reflect-api.main" />
<element id="module-output" name="kotlin.kotlin-reflect.main" />
<element id="module-output" name="kotlin.core.metadata.jvm.main" />
<element id="module-output" name="kotlin.core.metadata.main" />
<element id="module-output" name="kotlin.core.util.runtime.main" />
<element id="module-output" name="kotlin.core.type-system.main" />
</root>
</artifact>
</component>

View File

@@ -1,255 +0,0 @@
<component name="ArtifactManager">
<artifact name="kotlinc">
<output-path>$PROJECT_DIR$/out/artifacts/kotlinc</output-path>
<root id="root">
<element id="directory" name="bin">
<element id="dir-copy" path="$PROJECT_DIR$/compiler/cli/bin" />
</element>
<element id="directory" name="lib">
<element id="file-copy" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains/annotations/13.0/919f0dfe192fb4e063e7dacadee7f8bb9a2672a9/annotations-13.0.jar" />
<element id="file-copy" path="$PROJECT_DIR$/dependencies/repo/kotlin.build/ideaIC/191.6707.61/artifacts/lib/trove4j.jar" />
<element id="archive" name="allopen-compiler-plugin.jar">
<element id="module-output" name="kotlin.kotlin-allopen-compiler-plugin.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/plugins/allopen/allopen-cli/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="android-extensions-runtime.jar">
<element id="module-output" name="kotlin.kotlin-android-extensions-runtime.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/plugins/android-extensions/android-extensions-runtime/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-annotation-processing.jar">
<element id="module-output" name="kotlin.kotlin-annotation-processing.main" />
<element id="module-output" name="kotlin.kotlin-annotation-processing-runtime.main" />
<element id="module-output" name="kotlin.kotlin-annotation-processing-cli.main" />
<element id="module-output" name="kotlin.kotlin-annotation-processing-base.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/plugins/kapt3/kapt3-compiler/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-annotation-processing-cli.jar">
<element id="module-output" name="kotlin.kotlin-annotation-processing-cli.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/plugins/kapt3/kapt3-cli/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-annotation-processing-runtime.jar">
<element id="module-output" name="kotlin.kotlin-annotation-processing-runtime.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/plugins/kapt3/kapt3-runtime/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-annotations-android.jar">
<element id="module-output" name="kotlin.kotlin-annotations-android.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/tools/kotlin-annotations-android/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-annotations-jvm.jar">
<element id="module-output" name="kotlin.kotlin-annotations-jvm.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/tools/kotlin-annotations-jvm/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-annotations-jvm-sources.jar">
<element id="dir-copy" path="$PROJECT_DIR$/libraries/tools/kotlin-annotations-jvm/src" />
<element id="directory" name="main">
<element id="directory" name="resources" />
<element id="directory" name="kotlin" />
<element id="directory" name="java" />
</element>
<element id="directory" name="test">
<element id="directory" name="resources" />
</element>
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/tools/kotlin-annotations-jvm/build/tmp/sourcesJar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-ant.jar">
<element id="module-output" name="kotlin.kotlin-ant.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/ant/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="noarg-compiler-plugin.jar">
<element id="module-output" name="kotlin.kotlin-noarg-compiler-plugin.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/plugins/noarg/noarg-cli/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-preloader.jar">
<element id="module-output" name="kotlin.kotlin-preloader.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/compiler/preloader/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-reflect-sources.jar">
<element id="dir-copy" path="$PROJECT_DIR$/core/descriptors/src" />
<element id="dir-copy" path="$PROJECT_DIR$/core/descriptors.jvm/src" />
<element id="dir-copy" path="$PROJECT_DIR$/core/descriptors.runtime/src" />
<element id="dir-copy" path="$PROJECT_DIR$/core/deserialization/src" />
<element id="dir-copy" path="$PROJECT_DIR$/core/util.runtime/src" />
<element id="dir-copy" path="$PROJECT_DIR$/core/reflection.jvm/src" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/reflect/build/tmp/sourcesJar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-runner.jar">
<element id="module-output" name="kotlin.kotlin-runner.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/compiler/cli/cli-runner/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="sam-with-receiver-compiler-plugin.jar">
<element id="module-output" name="kotlin.kotlin-sam-with-receiver-compiler-plugin.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/plugins/sam-with-receiver/sam-with-receiver-cli/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-script-runtime.jar">
<element id="module-output" name="kotlin.kotlin-script-runtime.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/tools/script-runtime/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-script-runtime-sources.jar">
<element id="dir-copy" path="$PROJECT_DIR$/core/script.runtime/src" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/tools/script-runtime/build/tmp/sourcesJar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-scripting-common.jar">
<element id="module-output" name="kotlin.kotlin-scripting-common.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/scripting/common/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-scripting-compiler.jar">
<element id="module-output" name="kotlin.kotlin-scripting-compiler.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/plugins/scripting/scripting-compiler/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-scripting-compiler-impl.jar">
<element id="module-output" name="kotlin.kotlin-scripting-compiler-impl.main" />
</element>
<element id="archive" name="kotlin-scripting-jvm.jar">
<element id="module-output" name="kotlin.kotlin-scripting-jvm.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/scripting/jvm/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-source-sections-compiler-plugin.jar">
<element id="module-output" name="kotlin.kotlin-source-sections-compiler-plugin.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/plugins/source-sections/source-sections-compiler/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-test-js.jar">
<element id="module-output" name="kotlin.kotlin-test.kotlin-test-js.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/kotlin.test/js/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-test-js-sources.jar">
<element id="dir-copy" path="$PROJECT_DIR$/libraries/kotlin.test/js/src/main/kotlin" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/kotlin.test/js/build/tmp/sourcesJar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-test-junit.jar">
<element id="module-output" name="kotlin.kotlin-test.kotlin-test-junit.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/kotlin.test/junit/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-test-junit-sources.jar">
<element id="dir-copy" path="$PROJECT_DIR$/libraries/kotlin.test/junit/src/main/kotlin" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/kotlin.test/junit/build/tmp/sourcesJar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-test-junit5.jar">
<element id="module-output" name="kotlin.kotlin-test.kotlin-test-junit5.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/kotlin.test/junit5/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-test-junit5-sources.jar">
<element id="dir-copy" path="$PROJECT_DIR$/libraries/kotlin.test/junit5/src/main/kotlin" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/kotlin.test/junit5/build/tmp/sourcesJar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-test.jar">
<element id="module-output" name="kotlin.kotlin-test.kotlin-test-jvm.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/kotlin.test/jvm/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-test-sources.jar">
<element id="dir-copy" path="$PROJECT_DIR$/libraries/kotlin.test/jvm/src/main/kotlin" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/kotlin.test/jvm/build/tmp/sourcesJar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-test-testng.jar">
<element id="module-output" name="kotlin.kotlin-test.kotlin-test-testng.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/kotlin.test/testng/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlin-test-testng-sources.jar">
<element id="dir-copy" path="$PROJECT_DIR$/libraries/kotlin.test/testng/src/main/kotlin" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/kotlin.test/testng/build/tmp/sourcesJar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="kotlinx-serialization-compiler-plugin.jar">
<element id="module-output" name="kotlin.kotlinx-serialization-compiler-plugin.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/plugins/kotlin-serialization/kotlin-serialization-compiler/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="mutability-annotations-compat.jar">
<element id="module-output" name="kotlin.libraries.tools.mutability-annotations-compat.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/libraries/tools/mutability-annotations-compat/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="archive" name="android-extensions-compiler.jar">
<element id="module-output" name="kotlin.plugins.android-extensions-compiler.main" />
<element id="module-output" name="kotlin.kotlin-android-extensions-runtime.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/plugins/android-extensions/android-extensions-compiler/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
<element id="file-copy" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib-jdk8/1.3.50-dev-526/d9da4521258618dcc687690f81e7430544098a80/kotlin-stdlib-jdk8-1.3.50-dev-526.jar" output-file-name="kotlin-stdlib-jdk8.jar" />
<element id="file-copy" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib-jdk7/1.3.50-dev-526/8c795ad16d3e2edd465d97cda4063f906a4ecbaa/kotlin-stdlib-jdk7-1.3.50-dev-526.jar" output-file-name="kotlin-stdlib-jdk7.jar" />
<element id="file-copy" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib/1.3.50-dev-526/2fbb7e5d5a32d0754ee33e8ca38696fa22a3b70b/kotlin-stdlib-1.3.50-dev-526.jar" output-file-name="kotlin-stdlib.jar" />
<element id="file-copy" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib-jdk7/1.3.50-dev-526/7c73dd25222b54224562d17184296dc8450c80cf/kotlin-stdlib-jdk7-1.3.50-dev-526-sources.jar" output-file-name="kotlin-stdlib-jdk7-sources.jar" />
<element id="file-copy" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib-jdk8/1.3.50-dev-526/e9f538ede7b49a4d60265aa90f907d39993417d9/kotlin-stdlib-jdk8-1.3.50-dev-526-sources.jar" output-file-name="kotlin-stdlib-jdk8-sources.jar" />
<element id="file-copy" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib-js/1.3.50-dev-526/f171da8782d7f0000142818532b5e49693becb99/kotlin-stdlib-js-1.3.50-dev-526-sources.jar" />
<element id="file-copy" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib-js/1.3.50-dev-526/8a798b744fdbd46a7d93814f0f0b97c664c064d2/kotlin-stdlib-js-1.3.50-dev-526.jar" output-file-name="kotlin-stdlib-js.jar" />
<element id="file-copy" path="$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib/1.3.50-dev-526/21e04af851994238d364653c103df336bf45fd4d/kotlin-stdlib-1.3.50-dev-526-sources.jar" output-file-name="kotlin-stdlib-sources.jar" />
<element id="artifact" artifact-name="kotlin-compiler.jar" />
<element id="artifact" artifact-name="kotlin-reflect.jar" />
<element id="artifact" artifact-name="kotlin-daemon-client.jar" />
<element id="artifact" artifact-name="kotlin-main-kts.jar" />
<element id="artifact" artifact-name="kotlin-imports-dumper-compiler-plugin.jar" />
<element id="archive" name="jvm-abi-gen.jar">
<element id="module-output" name="kotlin.plugins.jvm-abi-gen.main" />
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/plugins/jvm-abi-gen/build/tmp/jar/MANIFEST.MF" />
</element>
</element>
</element>
<element id="directory" name="license">
<element id="dir-copy" path="$PROJECT_DIR$/license" />
</element>
<element id="file-copy" path="$PROJECT_DIR$/bootstrap/build.txt" />
</root>
</artifact>
</component>

View File

@@ -1,7 +0,0 @@
<component name="InspectionProjectProfileManager">
<settings>
<option name="PROJECT_PROFILE" value="idea.default" />
<option name="USE_PROJECT_PROFILE" value="true" />
<version value="1.0" />
</settings>
</component>

View File

@@ -3,15 +3,17 @@
import org.gradle.api.GradleException
import org.gradle.api.Project
import org.gradle.api.Task
import org.gradle.api.UnknownDomainObjectException
import org.gradle.api.artifacts.ConfigurablePublishArtifact
import org.gradle.api.artifacts.Configuration
import org.gradle.api.artifacts.ConfigurationContainer
import org.gradle.api.artifacts.component.ProjectComponentIdentifier
import org.gradle.api.file.DuplicatesStrategy
import org.gradle.api.internal.artifacts.publish.ArchivePublishArtifact
import org.gradle.api.file.SourceDirectorySet
import org.gradle.api.plugins.BasePluginConvention
import org.gradle.api.plugins.JavaPluginConvention
import org.gradle.api.tasks.AbstractCopyTask
import org.gradle.api.tasks.Copy
import org.gradle.api.tasks.TaskProvider
import org.gradle.api.tasks.Upload
import org.gradle.api.tasks.javadoc.Javadoc
import org.gradle.jvm.tasks.Jar
@@ -88,23 +90,32 @@ fun <T : Jar> Project.runtimeJar(task: T, body: T.() -> Unit = {}): T {
fun Project.runtimeJar(body: Jar.() -> Unit = {}): Jar = runtimeJar(getOrCreateTask("jar", body), { })
fun Project.sourcesJar(sourceSet: String? = "main", body: Jar.() -> Unit = {}): Jar =
getOrCreateTask("sourcesJar") {
setDuplicatesStrategy(DuplicatesStrategy.EXCLUDE)
classifier = "sources"
try {
if (sourceSet != null) {
project.pluginManager.withPlugin("java-base") {
from(project.javaPluginConvention().sourceSets[sourceSet].allSource)
}
}
} catch (e: UnknownDomainObjectException) {
// skip default sources location
fun Project.sourcesJar(body: Jar.() -> Unit = {}): TaskProvider<Jar> {
val task = tasks.register<Jar>("sourcesJar") {
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
archiveClassifier.set("sources")
from(project.mainSourceSet.allSource)
project.configurations.findByName("embedded")?.let { embedded ->
from(provider {
embedded.resolvedConfiguration
.resolvedArtifacts
.map { it.id.componentIdentifier }
.filterIsInstance<ProjectComponentIdentifier>()
.map { project(it.projectPath).mainSourceSet.allSource }
})
}
body()
project.addArtifact("archives", this, this)
}
addArtifact("archives", task)
addArtifact("sources", task)
return task
}
fun Project.javadocJar(body: Jar.() -> Unit = {}): Jar = getOrCreateTask("javadocJar") {
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
classifier = "javadoc"
@@ -194,6 +205,11 @@ fun Project.addArtifact(configuration: Configuration, task: Task, artifactRef: A
fun Project.addArtifact(configurationName: String, task: Task, artifactRef: Any, body: ConfigurablePublishArtifact.() -> Unit = {}) =
addArtifact(configurations.getOrCreate(configurationName), task, artifactRef, body)
fun <T : Task> Project.addArtifact(configurationName: String, task: TaskProvider<T>, body: ConfigurablePublishArtifact.() -> Unit = {}) {
configurations.maybeCreate(configurationName)
artifacts.add(configurationName, task, body)
}
fun Project.cleanArtifacts() {
configurations["archives"].artifacts.let { artifacts ->
artifacts.forEach {

View File

@@ -1,136 +0,0 @@
/*
* Copyright 2010-2018 JetBrains s.r.o. and Kotlin Programming Language contributors.
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
*/
package idea
import groovy.lang.Closure
import org.gradle.api.Action
import org.gradle.api.Transformer
import org.gradle.api.file.ContentFilterable
import org.gradle.api.file.DuplicatesStrategy
import org.gradle.api.file.FileCopyDetails
import org.gradle.api.file.RelativePath
import java.io.File
import java.io.FilterReader
import java.io.InputStream
import java.io.OutputStream
class DistCopyDetailsMock(val context: DistModelBuildContext, srcName: String) : FileCopyDetails {
private var relativePath = RelativePath(true, srcName)
lateinit var lastAction: Action<in FileCopyDetails>
class E : Exception() {
// skip stack trace filling
override fun fillInStackTrace(): Throwable = this
}
fun logUnsupported(methodName: String): Nothing {
context.logUnsupported("COPY ACTION FileCopyDetails mock: $methodName", lastAction)
throw E()
}
override fun setDuplicatesStrategy(strategy: DuplicatesStrategy) {
logUnsupported("setDuplicatesStrategy")
}
override fun getSourcePath(): String {
logUnsupported("getSourcePath")
}
override fun getName(): String {
logUnsupported("getName")
}
override fun getSize(): Long {
logUnsupported("getSize")
}
override fun getRelativePath(): RelativePath = relativePath
override fun getRelativeSourcePath(): RelativePath {
logUnsupported("getRelativeSourcePath")
}
override fun expand(properties: MutableMap<String, *>): ContentFilterable {
logUnsupported("expand")
}
override fun getMode(): Int {
logUnsupported("getMode")
}
override fun getSourceName(): String {
logUnsupported("getSourceName")
}
override fun filter(properties: MutableMap<String, *>, filterType: Class<out FilterReader>): ContentFilterable {
logUnsupported("filter")
}
override fun filter(filterType: Class<out FilterReader>): ContentFilterable {
logUnsupported("filter")
}
override fun filter(closure: Closure<*>): ContentFilterable {
logUnsupported("filter")
}
override fun filter(transformer: Transformer<String, String>): ContentFilterable {
logUnsupported("filter")
}
override fun getFile(): File {
logUnsupported("getFile")
}
override fun setMode(mode: Int) {
logUnsupported("setMode")
}
override fun copyTo(output: OutputStream) {
logUnsupported("copyTo")
}
override fun copyTo(target: File): Boolean {
logUnsupported("copyTo")
}
override fun open(): InputStream {
logUnsupported("open")
}
override fun setRelativePath(path: RelativePath) {
relativePath = path
}
override fun getPath(): String {
logUnsupported("getPath")
}
override fun isDirectory(): Boolean {
logUnsupported("isDirectory")
}
override fun getDuplicatesStrategy(): DuplicatesStrategy {
logUnsupported("getDuplicatesStrategy")
}
override fun setName(name: String) {
logUnsupported("setName")
}
override fun getLastModified(): Long {
logUnsupported("getLastModified")
}
override fun setPath(path: String) {
logUnsupported("setPath")
}
override fun exclude() {
logUnsupported("exclude")
}
}

View File

@@ -1,96 +0,0 @@
package org.jetbrains.kotlin.buildUtils.idea
import org.gradle.api.Action
import org.gradle.api.file.FileCopyDetails
import java.io.File
import java.io.PrintWriter
class DistVFile(
val parent: DistVFile?,
val name: String,
val file: File = File(parent!!.file, name)
) {
val child = mutableMapOf<String, DistVFile>()
val contents = mutableSetOf<DistContentElement>()
override fun toString(): String = name
val hasContents: Boolean = file.exists() || contents.isNotEmpty()
fun relativePath(path: String): DistVFile {
val pathComponents = path.split(File.separatorChar)
return pathComponents.fold(this) { parent: DistVFile, childName: String ->
try {
parent.getOrCreateChild(childName)
} catch (t: Throwable) {
throw Exception("Error while processing path `$path`, components: `$pathComponents`, element: `$childName`", t)
}
}
}
fun getOrCreateChild(name: String): DistVFile = child.getOrPut(name) {
DistVFile(this, name)
}
fun addContents(contents: DistContentElement) {
this.contents.add(contents)
}
fun removeAll(matcher: (String) -> Boolean) {
child.keys.filter(matcher).forEach {
child.remove(it)
}
}
fun printTree(p: PrintWriter, depth: String = "") {
p.println("$depth${file.path} ${if (file.exists()) "EXISTED" else ""}:")
contents.forEach {
p.println("$depth $it")
}
child.values.forEach {
it.printTree(p, "$depth ")
}
}
}
sealed class DistContentElement()
class DistCopy(
target: DistVFile,
val src: DistVFile,
val customTargetName: String? = null,
val copyActions: Collection<Action<in FileCopyDetails>> = listOf()
) : DistContentElement() {
init {
target.addContents(this)
}
override fun toString(): String =
"COPY OF ${src.file}" +
if (customTargetName != null) " -> $customTargetName" else ""
}
class DistModuleOutput(parent: DistVFile, val projectId: String) : DistContentElement() {
init {
parent.addContents(this)
}
override fun toString(): String = "COMPILE OUTPUT $projectId"
override fun equals(other: Any?): Boolean {
if (this === other) return true
if (javaClass != other?.javaClass) return false
other as DistModuleOutput
if (projectId != other.projectId) return false
return true
}
override fun hashCode(): Int {
return projectId.hashCode()
}
}

View File

@@ -1,76 +0,0 @@
package idea
import org.gradle.api.Action
import org.gradle.api.file.FileCopyDetails
import org.jetbrains.kotlin.buildUtils.idea.DistVFile
import org.jetbrains.kotlin.buildUtils.idea.logger
/**
* Used for logging and nesting properties
*/
class DistModelBuildContext(
val parent: DistModelBuildContext?,
val kind: String,
val title: String,
val report: Appendable? = parent?.report,
val shade: Boolean = parent?.shade ?: false
) {
val logEnabled = false
val allCopyActions = mutableSetOf<Action<in FileCopyDetails>>()
var destination: DistVFile? = parent?.destination // todo: don't nest destination between tasks visiting
val logPrefix: String = if (parent != null) "${parent.logPrefix}-" else ""
init {
report?.appendln(toString())
if (parent != null) {
allCopyActions.addAll(parent.allCopyActions)
}
}
fun log(kind: String, title: String = "", print: Boolean = false) {
if (logEnabled) {
report?.appendln("$logPrefix- $kind $title")
if (print) {
logger.error("$kind $title, while visiting:")
var p = this
while (p.parent != null) {
logger.error(" - ${p.kind} ${p.title}")
p = p.parent!!
}
}
}
}
fun logUnsupported(kind: String, obj: Any? = null) {
val objInfo = if (obj != null) {
val javaClass = obj.javaClass
val superclass = javaClass.superclass as Class<*>
"$obj [$javaClass extends $superclass implements ${javaClass.interfaces.map { it.canonicalName }}]"
} else ""
log("UNSUPPORTED $kind", objInfo, true)
}
override fun toString() = "$logPrefix $kind $title"
inline fun child(
kind: String,
title: String = "",
shade: Boolean = false,
body: (DistModelBuildContext) -> Unit = {}
): DistModelBuildContext {
val result = DistModelBuildContext(this, kind, title, shade = shade)
body(result)
return result
}
fun addCopyActions(allCopyActions: Collection<Action<in FileCopyDetails>>) {
allCopyActions.forEach {
log("COPY ACTION", "$it")
}
this.allCopyActions.addAll(allCopyActions)
}
}

View File

@@ -1,317 +0,0 @@
/*
* Copyright 2010-2018 JetBrains s.r.o. and Kotlin Programming Language contributors.
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
*/
package org.jetbrains.kotlin.buildUtils.idea
import IntelliJInstrumentCodeTask
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
import idea.DistCopyDetailsMock
import idea.DistModelBuildContext
import org.codehaus.groovy.runtime.GStringImpl
import org.gradle.api.Project
import org.gradle.api.Task
import org.gradle.api.artifacts.Configuration
import org.gradle.api.file.FileCollection
import org.gradle.api.file.FileVisitDetails
import org.gradle.api.file.FileVisitor
import org.gradle.api.file.SourceDirectorySet
import org.gradle.api.internal.file.*
import org.gradle.api.internal.file.archive.ZipFileTree
import org.gradle.api.internal.file.collections.*
import org.gradle.api.internal.file.copy.CopySpecInternal
import org.gradle.api.internal.file.copy.DefaultCopySpec
import org.gradle.api.internal.file.copy.DestinationRootCopySpec
import org.gradle.api.internal.file.copy.SingleParentCopySpec
import org.gradle.api.tasks.AbstractCopyTask
import org.gradle.api.tasks.Copy
import org.gradle.api.tasks.SourceSetOutput
import org.gradle.api.tasks.Sync
import org.gradle.api.tasks.bundling.AbstractArchiveTask
import org.gradle.api.tasks.compile.AbstractCompile
import org.gradle.api.tasks.util.PatternSet
import org.gradle.internal.file.PathToFileResolver
import org.gradle.jvm.tasks.Jar
import java.io.File
import java.io.PrintWriter
import java.util.concurrent.Callable
open class DistModelBuilder(val rootProject: Project, pw: PrintWriter) {
val rootCtx = DistModelBuildContext(null, "ROOT", "dist", pw)
val visited = mutableMapOf<Task, DistModelBuildContext>()
val vfsRoot = DistVFile(null, "<root>", File(""))
val refs = mutableSetOf<DistVFile>()
fun visitInstrumentTask(it: IntelliJInstrumentCodeTask): DistModelBuildContext = visited.getOrPut(it) {
val ctx = rootCtx.child("INSTRUMENT", it.path)
ctx.setDest(it.output!!.path)
processSourcePath(it.originalClassesDirs, ctx)
val dest = ctx.destination
if (dest != null) {
DistModuleOutput(dest, it.project.path)
}
ctx
}
fun visitCompileTask(it: AbstractCompile): DistModelBuildContext = visited.getOrPut(it) {
val ctx = rootCtx.child("COMPILE", it.path)
ctx.setDest(it.destinationDir.path)
val dest = ctx.destination
if (dest != null) DistModuleOutput(dest, it.project.path)
else ctx.logUnsupported("Cannot add contents: destination is unknown", it)
ctx
}
fun visitCopyTask(
copy: AbstractCopyTask,
shade: Boolean = false
): DistModelBuildContext = visited.getOrPut(copy) {
val context = rootCtx.child("COPY", copy.path, shade)
val rootSpec = copy.rootSpec
when (copy) {
is Copy -> copy.destinationDir?.also { context.setDest(it.path) }
is Sync -> copy.destinationDir?.also { context.setDest(it.path) }
is AbstractArchiveTask -> copy.archivePath?.also { context.setDest(it.path) }
}
when (copy) {
is ShadowJar -> copy.configurations.forEach {
processSourcePath(it, context)
}
}
processCopySpec(rootSpec, context)
context
}
fun processCopySpec(spec: CopySpecInternal, ctx: DistModelBuildContext) {
spec.children.forEach {
when (it) {
is DestinationRootCopySpec -> ctx.child("DESTINATION ROOT COPY SPEC") { newCtx ->
newCtx.setDest(getRelativePath(it.destinationDir.path))
processCopySpec(it, newCtx)
}
is DefaultCopySpec -> ctx.child("DEFAULT COPY SPEC") { newCtx ->
if (ctx.destination != null) {
val buildRootResolver = it.buildRootResolver()
ctx.addCopyActions(buildRootResolver.allCopyActions)
newCtx.setDest(buildRootResolver.destPath.getFile(ctx.destination!!.file).path)
processCopySpec(it, newCtx)
it.includes
newCtx.child("SINGE PARENT COPY SPEC") { child ->
it.sourcePaths.forEach {
processSourcePath(it, child)
}
}
}
}
is SingleParentCopySpec -> ctx.child("OTHER SINGE PARENT COPY SPEC") { child ->
it.sourcePaths.forEach {
processSourcePath(it, child)
}
}
is CopySpecInternal -> processCopySpec(it, ctx)
else -> ctx.logUnsupported("CopySpec", spec)
}
}
}
fun processSourcePath(sourcePath: Any?, ctx: DistModelBuildContext) {
when {
sourcePath == null -> Unit
sourcePath is Jar -> ctx.child("JAR") { child ->
child.addCopyOf(sourcePath.archivePath.path)
}
sourcePath is SourceSetOutput -> ctx.child("COMPILE") { child ->
sourcePath.classesDirs.files.forEach {
child.addCopyOf(it.path)
}
}
sourcePath is Configuration -> {
ctx.child("CONFIGURATION") { child ->
sourcePath.resolve().forEach {
child.addCopyOf(it.path)
}
}
}
sourcePath is SourceDirectorySet -> {
ctx.child("SOURCES") { child ->
sourcePath.srcDirs.forEach {
child.addCopyOf(it.path)
}
}
}
sourcePath is MinimalFileSet -> ctx.child("MINIMAL FILE SET (${sourcePath.javaClass.simpleName})") { child ->
sourcePath.files.forEach {
processSourcePath(it, child)
}
}
sourcePath is MinimalFileTree -> ctx.child("MINIMAL FILE TREE (${sourcePath.javaClass.simpleName})") { child ->
sourcePath.visit(object : FileVisitor {
override fun visitDir(dirDetails: FileVisitDetails) {
processSourcePath(dirDetails.file, child)
}
override fun visitFile(fileDetails: FileVisitDetails) {
processSourcePath(fileDetails.file, child)
}
})
}
sourcePath is FileTreeAdapter && sourcePath.tree is GeneratedSingletonFileTree -> ctx.child("FILE TREE ADAPTER OF MAP FILE TREE (${sourcePath.javaClass.simpleName})") { child ->
sourcePath.visitContents(object : FileCollectionResolveContext {
override fun add(element: Any): FileCollectionResolveContext {
processSourcePath(element, child)
return this
}
override fun newContext(): ResolvableFileCollectionResolveContext {
error("not supported")
}
override fun push(fileResolver: PathToFileResolver): FileCollectionResolveContext {
return this
}
})
}
sourcePath is CompositeFileCollection -> ctx.child("COMPOSITE FILE COLLECTION") { child ->
sourcePath.visitLeafCollections(object : FileCollectionLeafVisitor {
override fun visitFileTree(file: File, patternSet: PatternSet) {
child.child("FILE TREE") {
it.addCopyOf(file.path)
}
}
override fun visitGenericFileTree(fileTree: FileTreeInternal) {
child.child("TREE") {
processSourcePath(fileTree, it)
}
}
override fun visitCollection(fileCollection: FileCollectionInternal) {
processSourcePath(fileCollection, child)
}
})
}
sourcePath is FileTreeAdapter && sourcePath.tree is ZipFileTree -> ctx.child("ZIP FILE TREE ADAPTER") { child ->
val tree = sourcePath.tree
val field = tree.javaClass.declaredFields.find { it.name == "zipFile" }!!
field.isAccessible = true
val zipFile = field.get(tree) as File
child.addCopyOf(zipFile.path)
}
sourcePath is FileTreeInternal -> ctx.child("FILE TREE INTERNAL") { child ->
// todo: preserve or warn about filtering
sourcePath.visitTreeOrBackingFile(object : FileVisitor {
override fun visitFile(fileDetails: FileVisitDetails) {
child.addCopyOf(fileDetails.file.path)
}
override fun visitDir(dirDetails: FileVisitDetails) {
child.addCopyOf(dirDetails.file.path)
}
})
}
sourcePath is FileCollection -> ctx.child("OTHER FILE COLLECTION (${sourcePath.javaClass})") { child ->
try {
sourcePath.files.forEach {
child.addCopyOf(it.path)
}
} catch (t: Throwable) {
child.logUnsupported("FILE COLLECTION (${t.message})", sourcePath)
}
}
sourcePath is String || sourcePath is GStringImpl -> ctx.child("STRING") { child ->
child.addCopyOf(sourcePath.toString())
}
sourcePath is Callable<*> -> ctx.child("CALLABLE") { child ->
processSourcePath(sourcePath.call(), child)
}
sourcePath is Collection<*> -> ctx.child("COLLECTION") { child ->
sourcePath.forEach {
processSourcePath(it, child)
}
}
sourcePath is Copy -> ctx.child("COPY OUTPUT") { child ->
val src = visitCopyTask(sourcePath).destination
if (src != null) child.addCopyOf(src)
// else it is added to `it`, because destination is inhereted by context
}
sourcePath is File -> ctx.child("FILE ${sourcePath.path}") { child ->
child.addCopyOf(sourcePath.path)
}
else -> ctx.logUnsupported("SOURCE PATH", sourcePath)
}
}
inline fun DistModelBuildContext.addCopyOf(
src: String,
body: (src: DistVFile, target: DistVFile) -> Unit = { _, _ -> Unit }
) {
addCopyOf(requirePath(src), body)
}
fun DistModelBuildContext.transformName(srcName: String): String? {
val detailsMock = DistCopyDetailsMock(this, srcName)
allCopyActions.forEach {
detailsMock.lastAction = it
try {
it.execute(detailsMock)
} catch (t: DistCopyDetailsMock.E) {
// skip
}
}
val name1 = detailsMock.relativePath.lastName
return if (name1.endsWith(".jar")) transformJarName(name1) else name1
}
// todo: investigate why allCopyActions not working
open fun transformJarName(name: String): String = name
inline fun DistModelBuildContext.addCopyOf(
src: DistVFile,
body: (src: DistVFile, target: DistVFile) -> Unit = { _, _ -> Unit }
) {
val destination = destination
if (destination != null) {
body(src, destination)
val customTargetName = transformName(src.name)
DistCopy(destination, src, customTargetName)
log("+DistCopy", "${getRelativePath(src.file.path)} -> ${getRelativePath(destination.file.path)}/$customTargetName")
} else logUnsupported("Cannot add copy of `$src`: destination is unknown")
}
fun DistModelBuildContext.setDest(path: String) {
destination = vfsRoot.relativePath(path)
log("INTO", getRelativePath(path))
}
fun checkRefs() {
refs.forEach {
if (!it.hasContents && it.contents.isEmpty() && it.file.path.contains("${File.pathSeparator}build${File.pathSeparator}")) {
logger.error("UNRESOLVED ${it.file}")
it.contents.forEach {
logger.error("+ ${it}")
}
}
}
}
fun getRelativePath(path: String) = path.replace(rootProject.projectDir.path, "$")
fun requirePath(targetPath: String): DistVFile {
val target = vfsRoot.relativePath(targetPath)
if (!File(targetPath).exists()) refs.add(target)
return target
}
}

View File

@@ -1,67 +0,0 @@
/*
* Copyright 2010-2018 JetBrains s.r.o. and Kotlin Programming Language contributors.
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
*/
package org.jetbrains.kotlin.buildUtils.idea
class DistModelFlattener() {
val stack = mutableSetOf<DistVFile>()
val common = mutableSetOf<DistVFile>()
fun DistVFile.flatten(): DistVFile {
val new = DistVFile(parent, name, file)
copyFlattenedContentsTo(new)
return new
}
private fun DistVFile.copyFlattenedContentsTo(new: DistVFile, inJar: Boolean = false) {
if (!stack.add(this)) {
return
}
try {
contents.forEach {
if (!shouldSkip(new, it)) {
when (it) {
is DistCopy -> {
val srcName = it.customTargetName ?: it.src.name
if (it.src.file.exists()) {
DistCopy(new, it.src, srcName)
}
if (!inJar && srcName.endsWith(".jar")) {
val newChild = new.getOrCreateChild(srcName)
it.src.copyFlattenedContentsTo(newChild, inJar = true)
} else {
it.src.copyFlattenedContentsTo(new, inJar)
}
}
is DistModuleOutput -> DistModuleOutput(new, it.projectId)
}
}
}
child.values.forEach { oldChild ->
if (inJar) {
val newChild =
if (oldChild.name.endsWith(".jar")) new
else new.getOrCreateChild(oldChild.name)
oldChild.copyFlattenedContentsTo(newChild, inJar = true)
} else {
val newChild = new.getOrCreateChild(oldChild.name)
oldChild.copyFlattenedContentsTo(newChild)
}
}
} finally {
stack.remove(this)
}
}
private fun shouldSkip(
new: DistVFile,
content: DistContentElement
) =
new.name == "kotlin-jps-plugin.jar" && content is DistCopy && content.customTargetName == "kotlin-compiler-runner.jar"
}

View File

@@ -1,61 +0,0 @@
/*
* Copyright 2010-2018 JetBrains s.r.o. and Kotlin Programming Language contributors.
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
*/
package org.jetbrains.kotlin.buildUtils.idea
import org.gradle.api.Project
import org.gradle.plugins.ide.idea.model.IdeaModel
import org.jetbrains.gradle.ext.ArtifactType
import org.jetbrains.gradle.ext.RecursiveArtifact
class DistModelIdeaArtifactBuilder(val rootProject: Project) {
fun RecursiveArtifact.addFiles(vFile: DistVFile, inJar: Boolean = false) {
val files = mutableSetOf<String>()
vFile.contents.forEach {
when (it) {
is DistCopy -> {
val file = it.src.file
when {
inJar && file.name.endsWith(".jar") -> extractedDirectory(file.path)
file.isDirectory -> {
files.add(file.name)
directoryContent(file.path)
}
else -> {
files.add(file.name)
file(file.path)
}
}
}
is DistModuleOutput -> {
val name = it.ideaModuleName
if (name.result != null) moduleOutput(name.result + "_main")
else logger.warn("Cannot find idea module name for project `${it.projectId}`: ${name.error}")
}
}
}
vFile.child.values.forEach {
if (it.name !in files) {
when {
it.name.endsWith(".jar") -> archive(it.name).addFiles(it, true)
else -> directory(it.name).addFiles(it, inJar)
}
}
}
}
class Result<T: Any>(val result: T? = null, val error: String? = null)
val DistModuleOutput.ideaModuleName: Result<String>
get() {
val findProject = rootProject.findProject(projectId) ?: return Result(error = "cannot find gradle project $projectId")
val idea = findProject.extensions?.findByName("idea") as? IdeaModel ?: return Result(error = "cannot find idea model for gradle project $projectId")
val name = idea.module?.name ?: return Result(error = "idea model for project $projectId has no module name")
return Result(name)
}
}

View File

@@ -1,130 +0,0 @@
/*
* Copyright 2010-2018 JetBrains s.r.o. and Kotlin Programming Language contributors.
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
*/
package org.jetbrains.kotlin.buildUtils.idea
import IntelliJInstrumentCodeTask
import org.gradle.api.NamedDomainObjectContainer
import org.gradle.api.Project
import org.gradle.api.tasks.AbstractCopyTask
import org.gradle.api.tasks.compile.AbstractCompile
import org.jetbrains.gradle.ext.TopLevelArtifact
import org.slf4j.LoggerFactory
import java.io.File
/**
* Temporary solution for configuring IDEA artifacts based on Gradle copy tasks configurations.
* This should be replaced with DSL that produces both Gradle copy tasks and IDEA artifacts configuration.
*
* TODO: remove this package when DSL described above will be implemented
*/
fun generateIdeArtifacts(rootProject: Project, artifactsFactory: NamedDomainObjectContainer<TopLevelArtifact>) {
val reportsDir = File(path(rootProject.buildDir.path, "reports", "idea-artifacts-cfg"))
reportsDir.mkdirs()
val projectDir = rootProject.projectDir
File(reportsDir, "01-visitor.report.txt").printWriter().use { visitorReport ->
val modelBuilder = object : DistModelBuilder(rootProject, visitorReport) {
// todo: investigate why allCopyActions not working
override fun transformJarName(name: String): String {
val name1 = name.replace(Regex("-${java.util.regex.Pattern.quote(rootProject.version.toString())}"), "")
val name2 = when (name1) {
"kotlin-runtime-common.jar" -> "kotlin-runtime.jar"
"kotlin-compiler-before-proguard.jar" -> "kotlin-compiler.jar"
"kotlin-main-kts-before-proguard.jar" -> "kotlin-main-kts.jar"
"kotlin-allopen-compiler-plugin.jar" -> "allopen-compiler-plugin.jar"
"kotlin-noarg-compiler-plugin.jar" -> "noarg-compiler-plugin.jar"
"kotlin-sam-with-receiver-compiler-plugin.jar" -> "sam-with-receiver-compiler-plugin.jar"
"kotlin-android-extensions-runtime.jar" -> "android-extensions-runtime.jar"
else -> name1
}
val name3 = name2.removePrefix("dist-")
return name3
}
}
fun visitAllTasks(project: Project) {
project.tasks.forEach {
try {
when {
it is AbstractCopyTask -> modelBuilder.visitCopyTask(it)
it is AbstractCompile -> modelBuilder.visitCompileTask(it)
it is IntelliJInstrumentCodeTask -> modelBuilder.visitInstrumentTask(it)
it.name == "stripMetadata" -> {
modelBuilder.rootCtx.log(
"STRIP METADATA",
"${it.inputs.files.singleFile} -> ${it.outputs.files.singleFile}"
)
DistCopy(
modelBuilder.requirePath(it.outputs.files.singleFile.path),
modelBuilder.requirePath(it.inputs.files.singleFile.path)
)
}
}
} catch (t: Throwable) {
logger.error("Error while visiting `$it`", t)
}
}
project.subprojects.forEach {
visitAllTasks(it)
}
}
visitAllTasks(rootProject)
// proguard
DistCopy(
target = modelBuilder.requirePath(
path(
projectDir.path,
"libraries",
"reflect",
"build",
"libs",
"kotlin-reflect-proguard.jar"
)
),
src = modelBuilder.requirePath(path(projectDir.path, "libraries", "reflect", "build", "libs", "kotlin-reflect-shadow.jar"))
)
File(reportsDir, "02-vfs.txt").printWriter().use {
modelBuilder.vfsRoot.printTree(it)
}
modelBuilder.checkRefs()
with(DistModelFlattener()) {
with(DistModelIdeaArtifactBuilder(rootProject)) {
File(reportsDir, "03-flattened-vfs.txt").printWriter().use { report ->
fun getFlattenned(vfsPath: String): DistVFile =
modelBuilder.vfsRoot.relativePath(path(projectDir.path, vfsPath))
.flatten()
val all = getFlattenned("dist")
all.child["artifacts"]
?.removeAll { it != "ideaPlugin" }
all.child["artifacts"]
?.child?.get("ideaPlugin")
?.child?.get("Kotlin")
?.removeAll { it != "kotlinc" && it != "lib" }
all.removeAll { it.endsWith(".zip") }
all.printTree(report)
val dist = artifactsFactory.create("dist_auto_reference_dont_use")
dist.addFiles(all)
}
}
}
}
}
private fun path(vararg components: String) = components.joinToString(File.separator)
internal val logger = LoggerFactory.getLogger("ide-artifacts")

View File

@@ -23,7 +23,7 @@ dependencies {
testCompile(project(":compiler:frontend.java"))
testCompile(projectTests(":jps-plugin"))
testCompile(commonDep("junit:junit"))
testCompile(intellijDep()) { includeJars("openapi", "idea", "idea_rt", "groovy-all", "jps-builders", rootProject = rootProject) }
testCompile(intellijDep()) { includeJars("openapi", "util", "idea", "idea_rt", "groovy-all", "jps-builders", rootProject = rootProject) }
testCompile(jpsStandalone()) { includeJars("jps-model") }
testCompile(jpsBuildTest())
}

View File

@@ -10,7 +10,8 @@ dependencies {
compile(project(":compiler:frontend"))
compile(project(":compiler:frontend.java"))
compile(project(":compiler:serialization"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core", "asm-all", rootProject = rootProject) }
compileOnly(intellijCoreDep()) { includeJars("intellij-core", "asm-all", "guava", rootProject = rootProject) }
compileOnly(intellijDep()) { includeJars("trove4j", rootProject = rootProject) }
}
sourceSets {

View File

@@ -19,6 +19,8 @@ dependencies {
compile(project(":js:js.serializer"))
compile(project(":js:js.dce"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core", rootProject = rootProject) }
testCompile(project(":compiler:backend"))
testCompile(project(":compiler:cli"))
testCompile(projectTests(":compiler:tests-common"))

View File

@@ -23,7 +23,10 @@ dependencies {
compile(project(":compiler:incremental-compilation-impl"))
compile(commonDep("org.fusesource.jansi", "jansi"))
compile(commonDep("org.jline", "jline"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijDep()) { includeJars("trove4j") }
runtime(project(":kotlin-reflect"))
embedded(project(":daemon-common")) { isTransitive = false }

View File

@@ -1,5 +1,3 @@
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
description = "Kotlin Daemon Client"
plugins {
@@ -47,11 +45,7 @@ sourceSets {
publish()
noDefaultJar()
runtimeJar(task<ShadowJar>("shadowJar")) {
from(mainSourceSet.output)
}
runtimeJar()
sourcesJar()

View File

@@ -22,6 +22,8 @@ dependencies {
compile(project(":compiler:cli"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijDep()) { includeJars("commons-lang-2.4") }
compile("org.jetbrains.kotlinx:kotlinx-html-jvm:0.6.12")
}

View File

@@ -19,7 +19,7 @@ dependencies {
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
testCompileOnly(intellijDep()) { includeJars("openapi", "idea", "idea_rt", "util", "asm-all", rootProject = rootProject) }
testCompileOnly(intellijDep())
testRuntime(intellijDep())

View File

@@ -9,7 +9,10 @@ plugins {
}
dependencies {
testCompileOnly(intellijDep()) { includeJars("openapi", "idea", "idea_rt", "util", "asm-all", rootProject = rootProject) }
testCompileOnly(intellijDep()) {
includeJars("openapi", "java-api", "extensions", "idea", "idea_rt", "util", "asm-all", rootProject = rootProject)
}
testRuntime(intellijDep())
testCompile(commonDep("junit:junit"))

View File

@@ -14,9 +14,9 @@ dependencies {
compile(project(":compiler:fir:tree"))
compile(project(":compiler:ir.tree"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
testRuntime(intellijDep())
compileOnly(intellijCoreDep()) { includeJars("intellij-core", "guava", rootProject = rootProject) }
testCompile(intellijDep())
testCompile(commonDep("junit:junit"))
testCompileOnly(project(":kotlin-test:kotlin-test-jvm"))
@@ -25,8 +25,6 @@ dependencies {
testCompileOnly(project(":kotlin-reflect-api"))
testRuntime(project(":kotlin-reflect"))
}
sourceSets {

View File

@@ -10,9 +10,9 @@ dependencies {
compile(project(":compiler:fir:cones"))
compile(project(":compiler:fir:tree"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijCoreDep()) { includeJars("intellij-core", "guava", rootProject = rootProject) }
testCompileOnly(intellijDep()) { includeJars("openapi", "idea", "idea_rt", "util", "asm-all", rootProject = rootProject) }
testCompileOnly(intellijDep()) { includeJars("openapi", "java-api", "idea", "idea_rt", "util", "asm-all", "extensions", rootProject = rootProject) }
testRuntime(intellijDep())

View File

@@ -10,15 +10,17 @@ plugins {
id("jps-compatible")
}
val runtimeOnly by configurations
val compileOnly by configurations
runtimeOnly.extendsFrom(compileOnly)
dependencies {
compile(project(":compiler:psi"))
compile(intellijCoreDep()) { includeJars("intellij-core") }
compile(intellijDep()) {
compileOnly(intellijCoreDep()) { includeJars("intellij-core", "guava", rootProject = rootProject) }
compileOnly(intellijDep()) {
includeJars("trove4j", "picocontainer", rootProject = rootProject)
isTransitive = false
}
compile(intellijDep()) { includeJars("guava", rootProject = rootProject) }
}
val writeCopyright by task<WriteCopyrightToFile> {

View File

@@ -9,7 +9,8 @@ dependencies {
compile(project(":compiler:ir.tree"))
compile(project(":compiler:ir.psi2ir"))
compile(project(":compiler:ir.backend.common"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core", "asm-all", rootProject = rootProject) }
compileOnly(intellijCoreDep()) { includeJars("intellij-core", "asm-all", "guava", rootProject = rootProject) }
compileOnly(intellijDep()) { includeJars("trove4j", rootProject = rootProject) }
}
sourceSets {

View File

@@ -5,7 +5,6 @@ plugins {
}
dependencies {
compile(intellijDep())
compile(project(":compiler:util"))
compile(project(":compiler:frontend"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }

View File

@@ -10,6 +10,7 @@ dependencies {
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
testCompile(intellijCoreDep()) { includeJars("intellij-core") }
testCompile(project(":compiler:frontend"))
testCompile(project(":compiler:cli"))
testCompile(project(":compiler:util"))

View File

@@ -40,7 +40,7 @@ dependencies {
testCompile(androidDxJar()) { isTransitive = false }
testCompileOnly(intellijCoreDep()) { includeJars("intellij-core") }
testCompile(intellijDep()) {
includeJars("openapi", "platform-api", "platform-impl", "idea", "idea_rt", "guava", "trove4j", "picocontainer", "asm-all", "log4j", "jdom", "bootstrap", rootProject = rootProject)
includeJars("openapi", "util", "platform-api", "platform-impl", "idea", "idea_rt", "guava", "trove4j", "picocontainer", "asm-all", "log4j", "jdom", "bootstrap", rootProject = rootProject)
isTransitive = false
}
}

View File

@@ -5,7 +5,7 @@ plugins {
}
dependencies {
compile(intellijDep()) { includeJars("util") }
testCompile(intellijDep()) { includeJars("util") }
testCompile(project(":core:util.runtime"))
testCompile(projectTests(":compiler:tests-common"))
testCompile(kotlinStdlib())

View File

@@ -1,6 +1,8 @@
@file:Suppress("UnstableApiUsage")
import org.jetbrains.gradle.ext.*
import org.jetbrains.kotlin.ideaExt.*
import org.jetbrains.kotlin.buildUtils.idea.*
val ideaPluginDir: File by extra
val ideaSandboxDir: File by extra
@@ -11,7 +13,7 @@ val intellijUltimateEnabled: Boolean by rootProject.extra
val ideaUltimatePluginDir: File by rootProject.extra
val ideaUltimateSandboxDir: File by rootProject.extra
fun org.jetbrains.gradle.ext.JUnit.configureForKotlin() {
fun JUnit.configureForKotlin() {
vmParameters = listOf(
"-ea",
"-XX:+HeapDumpOnOutOfMemoryError",
@@ -56,9 +58,27 @@ if (kotlinBuildProperties.isInJpsBuildIdeaSync) {
project {
settings {
ideArtifacts {
generateIdeArtifacts(rootProject, this@ideArtifacts)
kotlinCompilerJar()
kotlinPluginJar()
kotlinReflectJar()
kotlinCompilerClientEmbeddableJar()
kotlinMainKtsJar()
kotlinImportsDumperCompilerPluginJar()
kotlinDaemonClientJar()
kotlinJpsPluginJar()
kotlinc()
ideaPlugin()
dist()
}
compiler {
@@ -111,7 +131,7 @@ if (kotlinBuildProperties.isInJpsBuildIdeaSync) {
mainClass = "org.jetbrains.kotlin.pill.generateAllTests.Main"
}
defaults<org.jetbrains.gradle.ext.JUnit> {
defaults<JUnit> {
configureForKotlin()
}
@@ -160,6 +180,115 @@ if (kotlinBuildProperties.isInJpsBuildIdeaSync) {
}
}
val jarArtifactProjects = listOf(
"kotlin-compiler-client-embeddable",
"kotlin-compiler",
"kotlin-daemon-client",
"kotlin-imports-dumper-compiler-plugin",
"kotlin-jps-plugin",
"kotlin-main-kts",
"kotlin-reflect"
)
fun NamedDomainObjectContainer<TopLevelArtifact>.kotlinCompilerJar() =
jarFromProject(project(":kotlin-compiler"), "kotlin-compiler.jar")
fun NamedDomainObjectContainer<TopLevelArtifact>.kotlinReflectJar() =
jarFromProject(project(":kotlin-reflect"))
fun NamedDomainObjectContainer<TopLevelArtifact>.kotlinCompilerClientEmbeddableJar() =
jarFromProject(project(":kotlin-compiler-client-embeddable"))
fun NamedDomainObjectContainer<TopLevelArtifact>.kotlinMainKtsJar() =
jarFromProject(project(":kotlin-main-kts"))
fun NamedDomainObjectContainer<TopLevelArtifact>.kotlinPluginJar() =
jarFromProject(project(":prepare:idea-plugin"), "kotlin-plugin.jar")
fun NamedDomainObjectContainer<TopLevelArtifact>.kotlinImportsDumperCompilerPluginJar() =
jarFromProject(project(":kotlin-imports-dumper-compiler-plugin"))
fun NamedDomainObjectContainer<TopLevelArtifact>.kotlinDaemonClientJar() =
jarFromProject(project(":kotlin-daemon-client"))
fun NamedDomainObjectContainer<TopLevelArtifact>.kotlinJpsPluginJar() {
val jpsPluginProject = project(":kotlin-jps-plugin")
jarFromProject(jpsPluginProject) {
file("${jpsPluginProject.rootDir}/resources/kotlinManifest.properties")
}
}
fun NamedDomainObjectContainer<TopLevelArtifact>.dist() {
val distLibrariesProject = project(":kotlin-stdlib:jps-build")
val stdlibMinimal by distLibrariesProject.configurations
val commonStdlib by distLibrariesProject.configurations
val commonStdlibSources by distLibrariesProject.configurations
val stdlibJS by distLibrariesProject.configurations
val stdlibSources by distLibrariesProject.configurations
create("dist") {
file("$rootDir/build/build.txt")
// Use output-file-name when fixed https://github.com/JetBrains/gradle-idea-ext-plugin/issues/63
archive("kotlin-stdlib-minimal-for-test.jar") {
extractedDirectory(stdlibMinimal.singleFile)
}
directory("artifacts") {
directory("ideaPlugin") {
artifact("ideaPlugin")
}
}
directory("common") {
// Use output-file-name when fixed https://github.com/JetBrains/gradle-idea-ext-plugin/issues/63
archive("kotlin-stdlib-common.jar") {
extractedDirectory(commonStdlib.singleFile)
}
// Use output-file-name when fixed https://github.com/JetBrains/gradle-idea-ext-plugin/issues/63
archive("kotlin-stdlib-common-sources.jar") {
extractedDirectory(commonStdlibSources.singleFile)
}
}
directory("js") {
extractedDirectory(stdlibJS.singleFile)
}
directory("kotlinc") {
artifact("kotlinc")
}
directory("maven") {
// Use output-file-name when fixed https://github.com/JetBrains/gradle-idea-ext-plugin/issues/63
archive("kotlin-stdlib-sources.jar") {
extractedDirectory(stdlibSources.singleFile)
}
}
}
}
fun NamedDomainObjectContainer<TopLevelArtifact>.kotlinc() {
val kotlinCompilerProject = project(":kotlin-compiler")
val libraries by kotlinCompilerProject.configurations
create("kotlinc") {
directory("bin") {
directoryContent("$rootDir/compiler/cli/bin")
}
directory("lib") {
jarsFromConfiguration(libraries)
}
directory("license") {
directoryContent("$rootDir/license")
}
file("$rootDir/bootstrap/build.txt")
}
}
fun NamedDomainObjectContainer<TopLevelArtifact>.ideaPlugin() {
val ideaPluginProject = project(":prepare:idea-plugin")
val libraries by ideaPluginProject.configurations
@@ -172,42 +301,46 @@ fun NamedDomainObjectContainer<TopLevelArtifact>.ideaPlugin() {
}
directory("lib") {
archive("kotlin-plugin.jar") {
directory("META-INF") {
file("$buildDir/tmp/jar/MANIFEST.MF")
}
artifact("kotlin-plugin.jar")
file("${ideaPluginProject.rootDir}/resources/kotlinManifest.properties")
jarFromEmbedded(ideaPluginProject)
}
directoryFromConfiguration(libraries)
jarsFromConfiguration(libraries)
directory("jps") {
directoryFromConfiguration(jpsPlugin)
jarsFromConfiguration(jpsPlugin)
}
}
}
}
}
val jarArtifactProjects = listOf(
"kotlin-compiler-client-embeddable",
"kotlin-compiler",
"kotlin-daemon-client",
"kotlin-imports-dumper-compiler-plugin",
"kotlin-jps-plugin",
"kotlin-main-kts",
"kotlin-reflect"
)
fun NamedDomainObjectContainer<TopLevelArtifact>.jarFromProject(project: Project, name: String? = null, configureAction: RecursiveArtifact.() -> Unit = {}) {
val jarName = name ?: project.name + ".jar"
create(jarName) {
archive(jarName) {
directory("META-INF") {
file("${project.buildDir}/tmp/jar/MANIFEST.MF")
}
if (project.sourceSets.names.contains("main")) {
moduleOutput(moduleName(project.path))
}
jarContentsFromEmbeddedConfiguration(project)
configureAction()
}
}
}
fun moduleName(projectPath: String) = rootProject.name + projectPath.replace(':', '.') + ".main"
fun RecursiveArtifact.jarFromEmbedded(project: Project) {
fun RecursiveArtifact.jarContentsFromEmbeddedConfiguration(project: Project) {
val embedded = project.configurations.findByName("embedded") ?: return
jarContentsFromConfiguration(embedded)
}
val resolvedArtifacts = embedded
fun RecursiveArtifact.jarContentsFromConfiguration(configuration: Configuration) {
val resolvedArtifacts = configuration
.resolvedConfiguration
.resolvedArtifacts
@@ -220,11 +353,11 @@ fun RecursiveArtifact.jarFromEmbedded(project: Project) {
.filterIsInstance<ProjectComponentIdentifier>()
.forEach {
moduleOutput(moduleName(it.projectPath))
jarFromEmbedded(project(it.projectPath))
jarContentsFromEmbeddedConfiguration(project(it.projectPath))
}
}
fun RecursiveArtifact.directoryFromConfiguration(configuration: Configuration) {
fun RecursiveArtifact.jarsFromConfiguration(configuration: Configuration) {
val resolvedArtifacts = configuration
.resolvedConfiguration
.resolvedArtifacts

View File

@@ -10,8 +10,7 @@ dependencies {
compileOnly(project(":idea:idea-gradle"))
compileOnly(project(":idea:idea-jvm"))
compile(intellijDep())
runtimeOnly(intellijDep())
runtimeOnly(intellijRuntimeAnnotations())
runtimeOnly(files(toolsJar()))
}

View File

@@ -20,9 +20,8 @@ dependencies {
compile(project(":idea:idea-core"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijDep()) { includeJars("util", "openapi", "idea", "asm-all", "jdom", "trove4j", "guava", rootProject = rootProject) }
compileOnly(intellijPluginDep("gradle")) //{ includeJars("gradle-tooling-api", "gradle", rootProject = rootProject) }
compileOnly(intellijDep())
compileOnly(intellijPluginDep("gradle"))
}
sourceSets {

View File

@@ -20,12 +20,8 @@ dependencies {
compile(project(":kotlin-scripting-compiler-impl"))
compile(commonDep("org.jetbrains.kotlinx", "kotlinx-coroutines-core")) { isTransitive = false }
compile(commonDep("org.jetbrains.kotlinx", "kotlinx-coroutines-jdk8")) { isTransitive = false }
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijDep()) {
Ide.IJ191.orHigher {
this@compileOnly.includeJars("platform-api")
}
}
compileOnly(intellijDep())
compileOnly(intellijPluginDep("gradle"))
}

View File

@@ -6,6 +6,8 @@ plugins {
dependencies {
compile(project(":j2k"))
compile(project(":idea:idea-core"))
compileOnly(intellijDep())
}
sourceSets {

View File

@@ -10,6 +10,9 @@ dependencies {
compile(project(":compiler:frontend"))
compileOnly(intellijDep())
compile(project(":kotlin-native:kotlin-native-library-reader"))
testCompileOnly(intellijDep())
testRuntimeOnly(intellijDep())
}
sourceSets {

View File

@@ -7,7 +7,7 @@ dependencies {
compile(kotlinStdlib())
compile(project(":compiler:backend"))
compile(files(toolsJar()))
compileOnly(intellijDep()) { includeJars("asm-all", rootProject = rootProject) }
compileOnly(intellijCoreDep()) { includeJars("intellij-core", "asm-all", rootProject = rootProject) }
testCompile(project(":kotlin-test:kotlin-test-junit"))
testCompile(commonDep("junit:junit"))
testCompile(intellijDep()) { includeJars("asm-all", rootProject = rootProject) }

View File

@@ -12,6 +12,7 @@ dependencies {
compile(project(":idea:jvm-debugger:jvm-debugger-util"))
compile(files("${System.getProperty("java.home")}/../lib/tools.jar"))
compileOnly(intellijDep())
compileOnly(intellijPluginDep("stream-debugger"))
testCompile(project(":kotlin-test:kotlin-test-junit"))

View File

@@ -11,6 +11,8 @@ dependencies {
compile(project(":idea:jvm-debugger:jvm-debugger-util"))
compile(files("${System.getProperty("java.home")}/../lib/tools.jar"))
compileOnly(intellijDep())
testCompile(project(":kotlin-test:kotlin-test-junit"))
testCompile(commonDep("junit:junit"))
}

View File

@@ -8,6 +8,7 @@ dependencies {
compile(project(":idea:ide-common"))
compile(files("${System.getProperty("java.home")}/../lib/tools.jar"))
compileOnly(intellijDep())
compileOnly(intellijPluginDep("stream-debugger"))
testCompile(project(":kotlin-test:kotlin-test-junit"))

View File

@@ -13,6 +13,8 @@ dependencies {
compile(files("${System.getProperty("java.home")}/../lib/tools.jar"))
compileOnly(intellijDep())
testCompile(commonDep("junit:junit"))
}

View File

@@ -22,10 +22,8 @@ dependencies {
testCompile(project(":kotlin-test:kotlin-test-junit"))
testCompile(commonDep("junit:junit"))
when {
Ide.IJ181.orHigher() || Ide.AS33.orHigher() -> testCompileOnly(intellijDep()) { includeJars("platform-api", "platform-impl") }
Ide.AS32() -> testCompileOnly(intellijDep()) { includeJars("idea") }
}
testCompileOnly(intellijDep())
testCompile(project(":idea:idea-native")) { isTransitive = false }
testCompile(project(":idea:idea-gradle-native")) { isTransitive = false }

View File

@@ -37,16 +37,14 @@ dependencies {
Ide.IJ {
testCompile(intellijDep("devkit"))
}
if (Platform[181].orHigher()) {
testCompileOnly(intellijDep()) { includeJars("openapi", "idea", "platform-api", "log4j") }
} else {
testCompileOnly(intellijDep()) { includeJars("openapi", "idea", "log4j") }
}
testCompile(intellijDep())
testCompile(jpsBuildTest())
compilerModules.forEach {
testRuntime(project(it))
}
testRuntime(intellijDep())
testRuntime(project(":kotlin-reflect"))
testRuntime(project(":kotlin-script-runtime"))
}

View File

@@ -177,12 +177,17 @@ val relocateCoreSources by task<Copy> {
tasks.getByName("jar").enabled = false
val sourcesJar = sourcesJar(sourceSet = null) {
val sourcesJar = tasks.register<Jar>("sourcesJar") {
archiveClassifier.set("sources")
dependsOn(relocateCoreSources)
from(relocatedCoreSrc)
from("$core/reflection.jvm/src")
}
addArtifact("archives", sourcesJar)
addArtifact("sources", sourcesJar)
val result by task<Jar> {
dependsOn(proguard)
from(zipTree(file(proguardOutput)))

View File

@@ -13,7 +13,7 @@ dependencies {
compileOnly(project(":kotlin-scripting-compiler"))
compileOnly(project(":compiler:cli"))
compileOnly(project(":kotlin-reflect-api"))
compileOnly(intellijCoreDep())
compileOnly(intellijCoreDep()) { includeJars("intellij-core", rootProject = rootProject) }
runtime(project(":kotlin-compiler"))
runtime(project(":kotlin-scripting-compiler"))
runtime(project(":kotlin-reflect"))

View File

@@ -4,66 +4,51 @@ import java.util.regex.Pattern
description = "Stdlib configuration for JPS build (to be interpreted during IDEA project import)"
val distLib by configurations.creating
val distCommon by configurations.creating
val distRoot by configurations.creating
val stdlibMinimal by configurations.creating
val stdlibJS by configurations.creating
val stdlibSources by configurations.creating
val compilerLib by configurations.creating
val commonStdlib by configurations.creating
val commonStdlibSources by configurations.creating
val builtins by configurations.creating
dependencies {
distRoot("org.jetbrains.kotlin:kotlin-stdlib-minimal-for-test:$bootstrapKotlinVersion")
stdlibMinimal("org.jetbrains.kotlin:kotlin-stdlib-minimal-for-test:$bootstrapKotlinVersion")
stdlibJS("org.jetbrains.kotlin:kotlin-stdlib-js:$bootstrapKotlinVersion") { isTransitive = false }
stdlibSources("org.jetbrains.kotlin:kotlin-stdlib:$bootstrapKotlinVersion:sources") { isTransitive = false }
builtins("org.jetbrains.kotlin:builtins:$bootstrapKotlinVersion")
distLib("org.jetbrains.kotlin:kotlin-stdlib:$bootstrapKotlinVersion")
distLib("org.jetbrains.kotlin:kotlin-stdlib-js:$bootstrapKotlinVersion")
distLib("org.jetbrains.kotlin:kotlin-stdlib-jdk7:$bootstrapKotlinVersion")
distLib("org.jetbrains.kotlin:kotlin-stdlib-jdk8:$bootstrapKotlinVersion")
compilerLib("org.jetbrains.kotlin:kotlin-stdlib:$bootstrapKotlinVersion")
compilerLib("org.jetbrains.kotlin:kotlin-stdlib-js:$bootstrapKotlinVersion")
compilerLib("org.jetbrains.kotlin:kotlin-stdlib-jdk7:$bootstrapKotlinVersion")
compilerLib("org.jetbrains.kotlin:kotlin-stdlib-jdk8:$bootstrapKotlinVersion")
distLib("org.jetbrains.kotlin:kotlin-stdlib:$bootstrapKotlinVersion:sources")
distLib("org.jetbrains.kotlin:kotlin-stdlib-js:$bootstrapKotlinVersion:sources")
distLib("org.jetbrains.kotlin:kotlin-stdlib-jdk7:$bootstrapKotlinVersion:sources")
distLib("org.jetbrains.kotlin:kotlin-stdlib-jdk8:$bootstrapKotlinVersion:sources")
compilerLib("org.jetbrains.kotlin:kotlin-stdlib:$bootstrapKotlinVersion:sources")
compilerLib("org.jetbrains.kotlin:kotlin-stdlib-js:$bootstrapKotlinVersion:sources")
compilerLib("org.jetbrains.kotlin:kotlin-stdlib-jdk7:$bootstrapKotlinVersion:sources")
compilerLib("org.jetbrains.kotlin:kotlin-stdlib-jdk8:$bootstrapKotlinVersion:sources")
distCommon("org.jetbrains.kotlin:kotlin-stdlib-common:$bootstrapKotlinVersion")
distCommon("org.jetbrains.kotlin:kotlin-stdlib-common:$bootstrapKotlinVersion:sources")
commonStdlib("org.jetbrains.kotlin:kotlin-stdlib-common:$bootstrapKotlinVersion")
commonStdlibSources("org.jetbrains.kotlin:kotlin-stdlib-common:$bootstrapKotlinVersion:sources")
}
val distDir: String by rootProject.extra
val distLibDir: File by rootProject.extra
fun TopLevelArtifact.addFromConfiguration(configuration: Configuration) {
configuration.resolve().forEach {
file(it)
}
}
afterEvaluate {
rootProject.idea {
project {
settings {
ideArtifacts {
create("dist_auto_stdlib_reference_dont_use") {
addFromConfiguration(distRoot)
addFromConfiguration(distCommon)
addFromConfiguration(distLib)
addFromConfiguration(builtins)
}
}
}
}
}
}
task<Copy>("distRoot") {
destinationDir = File(distDir)
dependsOn(distRoot)
from(distRoot)
dependsOn(stdlibMinimal)
from(stdlibMinimal)
rename("-${Pattern.quote(bootstrapKotlinVersion)}", "")
}
task<Copy>("distLib") {
destinationDir = distLibDir
dependsOn(distLib)
from(distLib)
dependsOn(compilerLib)
from(compilerLib)
rename("-${Pattern.quote(bootstrapKotlinVersion)}", "")
}

View File

@@ -75,7 +75,8 @@ dependencies {
compileOnly("com.android.tools.build:gradle-core:3.0.0") { isTransitive = false }
compileOnly("com.android.tools.build:builder-model:3.0.0") { isTransitive = false }
testCompileOnly (project(":compiler"))
testCompileOnly(intellijDep()) { includeJars("serviceMessages", "junit", rootProject = rootProject) }
testCompileOnly(project(":compiler"))
testCompile(projectTests(":kotlin-build-common"))
testCompile(project(":kotlin-android-extensions"))
testCompile(project(":kotlin-compiler-runner"))

View File

@@ -15,7 +15,9 @@ dependencies {
compile(project(":compiler:frontend.java"))
compile(project(":compiler:light-classes"))
compile(project(":compiler:util"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijCoreDep()) { includeJars("intellij-core", "guava", rootProject = rootProject) }
compileOnly(intellijDep()) { includeJars("platform-api", "java-impl", "platform-impl", rootProject = rootProject) }
testCompile(project(":idea"))
testCompile(projectTests(":j2k"))
@@ -25,10 +27,8 @@ dependencies {
testCompile(project(":kotlin-test:kotlin-test-junit"))
testCompile(commonDep("junit:junit"))
when {
Ide.IJ181.orHigher() || Ide.AS33.orHigher() -> testCompileOnly(intellijDep()) { includeJars("platform-api", "platform-impl") }
Ide.AS32() -> testCompileOnly(intellijDep()) { includeJars("idea") }
}
testCompileOnly(intellijDep())
testCompile(project(":idea:idea-native")) { isTransitive = false }
testCompile(project(":idea:idea-gradle-native")) { isTransitive = false }

View File

@@ -15,7 +15,9 @@ dependencies {
compileOnly(project(":compiler:plugin-api"))
compileOnly(project(":kotlin-build-common"))
runtimeOnly(project(":kotlin-compiler"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core", "asm-all", rootProject = rootProject) }
testRuntimeOnly(project(":kotlin-compiler"))
testCompile(commonDep("junit:junit"))
testCompile(projectTests(":compiler:tests-common"))

View File

@@ -6,6 +6,8 @@ plugins {
dependencies {
compile(project(":compiler:cli"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core", rootProject = rootProject) }
testCompile(projectTests(":compiler:tests-common"))
testCompile(projectTests(":compiler"))
testCompile(commonDep("junit:junit"))

View File

@@ -6,7 +6,7 @@ plugins {
}
dependencies {
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijCoreDep()) { includeJars("intellij-core", "asm-all", rootProject = rootProject) }
compile(project(":compiler:plugin-api"))
compile(project(":compiler:frontend"))

View File

@@ -15,6 +15,9 @@ dependencies {
compileOnly(intellijDep())
excludeInAndroidStudio(rootProject) { compileOnly(intellijPluginDep("maven")) }
compileOnly(intellijPluginDep("gradle"))
testCompileOnly(intellijDep())
testRuntimeOnly(intellijDep())
}
sourceSets {

View File

@@ -21,9 +21,9 @@ dependencies {
compile(project(":idea"))
compile(project(":idea:idea-jvm"))
compile(intellijDep()) { includeJars("openapi", "extensions", "util") }
compileOnly(intellijDep()) { includeJars("openapi", "extensions", "util") }
Platform[181].orHigher {
compile(intellijDep()) { includeJars("platform-api") }
compileOnly(intellijDep()) { includeJars("platform-api") }
}
}

View File

@@ -12,11 +12,9 @@ dependencies {
compile(project(":compiler:frontend.java"))
compile(project(":compiler:light-classes"))
Platform[181].orHigher {
// BEWARE: Uast should not depend on IDEA.
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijDep()) { includeJars("java-api", "java-impl", "asm-all", rootProject = rootProject) }
}
// BEWARE: Uast should not depend on IDEA.
compileOnly(intellijCoreDep()) { includeJars("intellij-core", "asm-all", rootProject = rootProject) }
compileOnly(intellijDep()) { includeJars("java-api", "java-impl") }
testCompile(project(":kotlin-test:kotlin-test-jvm"))
testCompile(projectTests(":compiler:tests-common"))
@@ -25,9 +23,8 @@ dependencies {
testCompile(project(":compiler:cli"))
testCompile(projectTests(":idea:idea-test-framework"))
Platform[181].orHigher {
testCompileOnly(intellijDep()) { includeJars("java-api", "java-impl") }
}
testCompileOnly(intellijCoreDep()) { includeJars("intellij-core") }
testCompileOnly(intellijDep()) { includeJars("java-api", "java-impl") }
testCompile(project(":idea:idea-native")) { isTransitive = false }
testCompile(project(":idea:idea-gradle-native")) { isTransitive = false }

View File

@@ -1,5 +1,3 @@
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
description = "Kotlin compiler client embeddable"
plugins {
@@ -7,17 +5,16 @@ plugins {
kotlin("jvm")
}
val jarContents by configurations.creating
val testRuntimeCompilerJar by configurations.creating
val testStdlibJar by configurations.creating
val testScriptRuntimeJar by configurations.creating
val archives by configurations
dependencies {
jarContents(project(":compiler:cli-common")) { isTransitive = false }
jarContents(project(":daemon-common")) { isTransitive = false }
jarContents(project(":daemon-common-new")) { isTransitive = false }
jarContents(projectRuntimeJar(":kotlin-daemon-client"))
embedded(project(":compiler:cli-common")) { isTransitive = false }
embedded(project(":daemon-common")) { isTransitive = false }
embedded(project(":daemon-common-new")) { isTransitive = false }
embedded(projectRuntimeJar(":kotlin-daemon-client"))
testCompile(project(":compiler:cli-common"))
testCompile(project(":daemon-common"))
testCompile(project(":daemon-common-new"))
@@ -53,11 +50,8 @@ projectTest {
publish()
noDefaultJar()
runtimeJar(task<ShadowJar>("shadowJar")) {
from(jarContents)
}
runtimeJar()
sourcesJar()
javadocJar()

View File

@@ -10,23 +10,31 @@ plugins {
}
// You can run Gradle with "-Pkotlin.build.proguard=true" to enable ProGuard run on kotlin-compiler.jar (on TeamCity, ProGuard always runs)
val shrink =
findProperty("kotlin.build.proguard")?.toString()?.toBoolean()
?: hasProperty("teamcity")
val shrink = findProperty("kotlin.build.proguard")?.toString()?.toBoolean() ?: hasProperty("teamcity")
val fatJarContents by configurations.creating
val fatJarContentsStripMetadata by configurations.creating
val fatJarContentsStripServices by configurations.creating
val fatJar by configurations.creating
val compilerJar by configurations.creating
// JPS build assumes fat jar is built from embedded configuration,
// but we can't use it in gradle build since slightly more complex processing is required like stripping metadata & services from some jars
if (kotlinBuildProperties.isInJpsBuildIdeaSync) {
val embedded by configurations
embedded.apply {
extendsFrom(fatJarContents)
extendsFrom(fatJarContentsStripMetadata)
extendsFrom(fatJarContentsStripServices)
}
}
val runtimeJar by configurations.creating
val compile by configurations // maven plugin writes pom compile scope from compile configuration by default
val libraries by configurations.creating {
val proguardLibraries by configurations.creating {
extendsFrom(compile)
}
val trove4jJar by configurations.creating
val ktorNetworkJar by configurations.creating
// Libraries to copy to the lib directory
val libraries by configurations.creating
val default by configurations
default.extendsFrom(runtimeJar)
@@ -43,8 +51,8 @@ dependencies {
compile(project(":kotlin-reflect"))
compile(commonDep("org.jetbrains.intellij.deps", "trove4j"))
libraries(project(":kotlin-annotations-jvm"))
libraries(
proguardLibraries(project(":kotlin-annotations-jvm"))
proguardLibraries(
files(
firstFromJavaHomeThatExists("jre/lib/rt.jar", "../Classes/classes.jar"),
firstFromJavaHomeThatExists("jre/lib/jsse.jar", "../Classes/jsse.jar"),
@@ -56,8 +64,43 @@ dependencies {
fatJarContents(project(it)) { isTransitive = false }
}
trove4jJar(intellijDep()) { includeIntellijCoreJarDependencies(project) { it.startsWith("trove4j") } }
ktorNetworkJar(commonDep("io.ktor", "ktor-network"))
libraries(intellijDep()) { includeIntellijCoreJarDependencies(project) { it.startsWith("trove4j") } }
libraries(commonDep("io.ktor", "ktor-network"))
libraries(kotlinStdlib("jdk8"))
libraries(project(":kotlin-annotation-processing-runtime")) { isTransitive = false }
libraries(project(":kotlin-android-extensions-runtime")) { isTransitive = false }
libraries(project(":kotlin-scripting-jvm")) { isTransitive = false }
libraries(project(":kotlin-annotations-android")) { isTransitive = false }
libraries(project(":kotlin-annotation-processing")) { isTransitive = false }
libraries(project(":kotlin-reflect")) { isTransitive = false }
libraries(project(":plugins:android-extensions-compiler")) { isTransitive = false }
libraries(project(":kotlin-compiler")) { isTransitive = false }
libraries(project(":kotlin-scripting-compiler")) { isTransitive = false }
libraries(project(":plugins:jvm-abi-gen")) { isTransitive = false }
libraries(project(":kotlin-scripting-common")) { isTransitive = false }
libraries(project(":kotlin-test:kotlin-test-testng")) { isTransitive = false }
libraries(project(":kotlin-annotation-processing-cli")) { isTransitive = false }
libraries(project(":kotlin-runner")) { isTransitive = false }
libraries(project(":kotlin-test:kotlin-test-junit5")) { isTransitive = false }
libraries(project(":kotlin-imports-dumper-compiler-plugin")) { isTransitive = false }
libraries(project(":kotlin-test:kotlin-test-js")) { isTransitive = false }
libraries(project(":kotlin-annotations-jvm")) { isTransitive = false }
libraries(project(":kotlinx-serialization-compiler-plugin")) { isTransitive = false }
libraries(project(":kotlin-daemon-client")) { isTransitive = false }
libraries(project(":kotlin-test:kotlin-test-jvm")) { isTransitive = false }
libraries(project(":kotlin-test:kotlin-test-common")) { isTransitive = false }
libraries(project(":kotlin-test:kotlin-test-junit")) { isTransitive = false }
libraries(project(":kotlin-sam-with-receiver-compiler-plugin")) { isTransitive = false }
libraries(project(":kotlin-preloader")) { isTransitive = false }
libraries(project(":kotlin-allopen-compiler-plugin")) { isTransitive = false }
libraries(project(":kotlin-noarg-compiler-plugin")) { isTransitive = false }
libraries(project(":kotlin-main-kts")) { isTransitive = false }
libraries(project(":kotlin-source-sections-compiler-plugin")) { isTransitive = false }
libraries(project(":kotlin-script-runtime")) { isTransitive = false }
libraries(project(":kotlin-ant")) { isTransitive = false }
libraries(project(":kotlin-test:kotlin-test-annotations-common")) { isTransitive = false }
libraries(project(":libraries:tools:mutability-annotations-compat")) { isTransitive = false }
fatJarContents(kotlinBuiltins())
fatJarContents(commonDep("javax.inject"))
@@ -88,6 +131,7 @@ dependencies {
}
fatJarContentsStripServices(jpsStandalone()) { includeJars("jps-model") }
fatJarContentsStripMetadata(intellijDep()) { includeJars("oro-2.0.8", "jdom", "log4j" ) }
}
@@ -96,14 +140,12 @@ publish()
noDefaultJar()
val packCompiler by task<ShadowJar> {
configurations = listOf(fatJar)
setDuplicatesStrategy(DuplicatesStrategy.EXCLUDE)
configurations = listOf(fatJarContents)
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
destinationDir = File(buildDir, "libs")
setupPublicJar(compilerBaseName, "before-proguard")
from(fatJarContents)
dependsOn(fatJarContentsStripServices)
from {
fatJarContentsStripServices.files.map {
@@ -131,13 +173,7 @@ val proguard by task<ProGuardTask> {
inputs.files(packCompiler.outputs.files.singleFile)
outputs.file(outputJar)
// TODO: remove after dropping compatibility with ant build
doFirst {
System.setProperty("kotlin-compiler-jar-before-shrink", packCompiler.outputs.files.singleFile.canonicalPath)
System.setProperty("kotlin-compiler-jar", outputJar.canonicalPath)
}
libraryjars(mapOf("filter" to "!META-INF/versions/**"), libraries)
libraryjars(mapOf("filter" to "!META-INF/versions/**"), proguardLibraries)
printconfiguration("$buildDir/compiler.pro.dump")
}
@@ -145,8 +181,7 @@ val proguard by task<ProGuardTask> {
val pack = if (shrink) proguard else packCompiler
dist(targetName = "$compilerBaseName.jar", fromTask = pack) {
from(trove4jJar)
from(ktorNetworkJar)
from(libraries)
}
runtimeJarArtifactBy(pack, pack.outputs.files.singleFile) {
@@ -163,3 +198,11 @@ sourcesJar {
}
javadocJar()
tasks.register("listDistProjects") {
doLast {
rootProject.getTasksByName("dist", true).forEach {
println(it.project.path)
}
}
}

View File

@@ -122,19 +122,18 @@ dependencies {
libraries(commonDep("io.javaslang", "javaslang"))
libraries(kotlinStdlib("jdk8"))
libraries(project(":kotlin-reflect"))
libraries(project(":kotlin-compiler-client-embeddable"))
libraries(project(":kotlin-daemon-client"))
libraries(project(":kotlin-reflect")) { isTransitive = false }
libraries(project(":kotlin-compiler-client-embeddable")) { isTransitive = false }
libraries(project(":kotlin-daemon-client")) { isTransitive = false }
libraries(project(":kotlin-daemon-client-new"))
libraries(project(":kotlin-daemon")) {
isTransitive = false
}
libraries(project(":kotlin-script-runtime"))
libraries(project(":kotlin-script-util"))
libraries(project(":kotlin-scripting-common"))
libraries(project(":kotlin-scripting-compiler-impl"))
libraries(project(":kotlin-scripting-intellij"))
libraries(project(":kotlin-scripting-jvm"))
libraries(project(":kotlin-daemon")) { isTransitive = false }
libraries(project(":kotlin-script-runtime")) { isTransitive = false }
libraries(project(":kotlin-script-util")) { isTransitive = false }
libraries(project(":kotlin-scripting-common")) { isTransitive = false }
libraries(project(":kotlin-scripting-compiler-impl")) { isTransitive = false }
libraries(project(":kotlin-scripting-intellij")) { isTransitive = false }
libraries(project(":kotlin-scripting-jvm")) { isTransitive = false }
gradleToolingModel(project(":idea:kotlin-gradle-tooling")) { isTransitive = false }
gradleToolingModel(project(":sam-with-receiver-ide-plugin")) { isTransitive = false }
@@ -143,7 +142,7 @@ dependencies {
gradleToolingModel(project(":noarg-ide-plugin")) { isTransitive = false }
gradleToolingModel(project(":allopen-ide-plugin")) { isTransitive = false }
jpsPlugin(project(":kotlin-jps-plugin"))
jpsPlugin(project(":kotlin-jps-plugin")) { isTransitive = false }
}
val jar = runtimeJar {

View File

@@ -9,7 +9,7 @@ dependencies {
compileOnly(project(":idea:idea-gradle"))
compileOnly(project(":idea:idea-jvm"))
compile(intellijDep())
runtimeOnly(intellijDep())
runtimeOnly(files(toolsJar()))
}