Skip to content

Commit

Permalink
[Build] Migrate ASM dependency to the version catalog
Browse files Browse the repository at this point in the history
  • Loading branch information
ALikhachev authored and qodana-bot committed Aug 15, 2024
1 parent c4cb038 commit 9bfb6e5
Show file tree
Hide file tree
Showing 35 changed files with 38 additions and 37 deletions.
2 changes: 1 addition & 1 deletion analysis/analysis-api/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ dependencies {
implementation(project(":analysis:kt-references"))

api(intellijCore())
api(commonDependency("org.jetbrains.intellij.deps:asm-all"))
api(libs.intellij.asm)
api(libs.guava)
}

Expand Down
2 changes: 1 addition & 1 deletion build-common/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ dependencies {
compileOnly(commonDependency("org.jetbrains.kotlin:kotlin-reflect")) { isTransitive = false }

compileOnly(intellijCore())
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)
compileOnly(project(":compiler:build-tools:kotlin-build-statistics"))

testCompileOnly(project(":compiler:cli-common"))
Expand Down
2 changes: 1 addition & 1 deletion compiler/backend.common.jvm/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ plugins {
dependencies {
api(project(":core:compiler.common.jvm"))
api(project(":compiler:config.jvm"))
api(commonDependency("org.jetbrains.intellij.deps:asm-all"))
api(libs.intellij.asm)
api(libs.guava)
compileOnly(intellijCore())
}
Expand Down
2 changes: 1 addition & 1 deletion compiler/backend/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ dependencies {
api(project(":compiler:backend.common.jvm"))
compileOnly(intellijCore())
compileOnly(commonDependency("org.jetbrains.intellij.deps.fastutil:intellij-deps-fastutil"))
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)
compileOnly(libs.guava)
}

Expand Down
2 changes: 1 addition & 1 deletion compiler/cli/cli-base/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ dependencies {
compileOnly(toolsJarApi())
compileOnly(intellijCore())
compileOnly(commonDependency("org.jetbrains.intellij.deps.fastutil:intellij-deps-fastutil"))
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)
runtimeOnly(libs.kotlinx.coroutines.core)
}

Expand Down
2 changes: 1 addition & 1 deletion compiler/cli/cli-common/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ dependencies {
compileOnly(commonDependency("org.jetbrains.kotlin:kotlin-reflect")) { isTransitive = false }
compileOnly(intellijCore())
compileOnly(libs.guava)
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)
}

sourceSets {
Expand Down
2 changes: 1 addition & 1 deletion compiler/config.jvm/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ plugins {
dependencies {
api(project(":compiler:config"))
api(project(":core:compiler.common.jvm"))
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)
}

sourceSets {
Expand Down
2 changes: 1 addition & 1 deletion compiler/fir/fir2ir/jvm-backend/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ dependencies {
compileOnly(project(":compiler:ir.actualization"))

compileOnly(intellijCore())
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)
}

optInToUnsafeDuringIrConstructionAPI()
Expand Down
2 changes: 1 addition & 1 deletion compiler/fir/java/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ dependencies {
implementation(project(":core:deserialization.common.jvm"))

compileOnly(intellijCore())
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)
}


Expand Down
2 changes: 1 addition & 1 deletion compiler/frontend.common.jvm/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ dependencies {
api(project(":core:deserialization.common.jvm"))
implementation(project(":core:compiler.common.jvm"))
compileOnly(intellijCore())
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)

implementation(project(":core:descriptors.jvm"))
api(project(":compiler:psi"))
Expand Down
2 changes: 1 addition & 1 deletion compiler/frontend.java/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ dependencies {
api(project(":compiler:frontend.common.jvm"))

compileOnly(intellijCore())
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)
compileOnly(libs.guava)
}

Expand Down
2 changes: 1 addition & 1 deletion compiler/ir/backend.jvm/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ dependencies {
api(project(":compiler:ir.backend.common"))
api(project(":compiler:backend.common.jvm"))
compileOnly(intellijCore())
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)
}

optInToUnsafeDuringIrConstructionAPI()
Expand Down
2 changes: 1 addition & 1 deletion compiler/light-classes/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ dependencies {
api(project(":compiler:frontend"))
api(project(":compiler:frontend.java"))
compileOnly(intellijCore())
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)
compileOnly(libs.guava)
compileOnly(commonDependency("org.jetbrains.intellij.deps.fastutil:intellij-deps-fastutil"))
}
Expand Down
2 changes: 1 addition & 1 deletion compiler/preloader/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ plugins {
}

dependencies {
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)
}

sourceSets {
Expand Down
2 changes: 1 addition & 1 deletion compiler/resolution.common.jvm/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ dependencies {
implementation(commonDependency("io.javaslang","javaslang"))
compileOnly(intellijCore())
compileOnly(libs.kotlinx.coroutines.core.jvm)
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)
compileOnly(commonDependency("org.jetbrains.intellij.deps.fastutil:intellij-deps-fastutil"))
compileOnly(libs.guava)
}
Expand Down
2 changes: 1 addition & 1 deletion compiler/tests-common/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ dependencies {
testApi(intellijJavaRt()) // for FileComparisonFailure

testImplementation(libs.guava)
testImplementation(commonDependency("org.jetbrains.intellij.deps:asm-all"))
testImplementation(libs.intellij.asm)
testImplementation(commonDependency("org.jetbrains.intellij.deps:log4j"))
testImplementation(intellijJDom())

Expand Down
2 changes: 1 addition & 1 deletion compiler/tests-compiler-utils/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ dependencies {

testApi(libs.guava)
testApi(commonDependency("org.jetbrains.intellij.deps:trove4j"))
testApi(commonDependency("org.jetbrains.intellij.deps:asm-all"))
testApi(libs.intellij.asm)
testApi(commonDependency("org.jetbrains.intellij.deps:log4j"))
testApi(intellijJDom())
}
Expand Down
2 changes: 1 addition & 1 deletion compiler/util/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ dependencies {

compileOnly(intellijCore())
compileOnly(commonDependency("org.jetbrains.intellij.deps:log4j"))
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)
compileOnly(jpsModel()) { isTransitive = false }
compileOnly(jpsModelImpl()) { isTransitive = false }

Expand Down
6 changes: 4 additions & 2 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,16 @@ opentest4j = "1.3.0" # should be consistent with the version brought by junit-pl
android-gradle-plugin = "7.3.1"
android-tools = "30.3.1"
gradle-node = "7.0.1"
commons-text="1.10.0"
lincheck="2.28.1"
commons-text = "1.10.0"
lincheck = "2.28.1"
xerces = "2.12.2"
# Compose versions used for Compose compiler plugin tests
compose-stable = "1.7.0-alpha08"
compose-snapshot-id = "12192498"
compose-snapshot-version = "1.8.0-SNAPSHOT"
ant = "1.10.14"
kotlin-for-gradle-plugins-compilation = "2.0.20-RC"
intellij-asm = "9.0"
# Wasm specific
wasmedge = "0.14.0"

Expand Down Expand Up @@ -97,6 +98,7 @@ android-tools-common = { module = "com.android.tools:common", version.ref = "and
xerces = { module = "xerces:xercesImpl", version.ref = "xerces" }

ant = { module = "org.apache.ant:ant", version.ref = "ant" }
intellij-asm = { module = "org.jetbrains.intellij.deps:asm-all", version.ref = "intellij-asm" }

[plugins]
jetbrains-ideaExt = { id = "org.jetbrains.gradle.plugin.idea-ext", version.ref = "jetbrains-ideaExt" }
Expand Down
1 change: 0 additions & 1 deletion gradle/versions.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ versions.intellijSdk=233.13135.103
# versions.* should match library versions used in IDEA from versions.intellijSdk

versions.annotations=21.0.0
versions.asm-all=9.0
versions.commons-lang=2.4
versions.aalto-xml=1.3.0
versions.gradle-api=4.5.1
Expand Down
2 changes: 1 addition & 1 deletion jps/jps-platform-api-signatures/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ plugins {

dependencies {
implementation(kotlinStdlib())
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)
compileOnly(intellijPlatformUtil())
}

Expand Down
2 changes: 1 addition & 1 deletion libraries/kotlinx-metadata/jvm/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ dependencies {
embedded(protobufLite())
testImplementation(kotlinTest("junit"))
testImplementation(libs.junit4)
testImplementation(commonDependency("org.jetbrains.intellij.deps:asm-all"))
testImplementation(libs.intellij.asm)
testImplementation(commonDependency("org.jetbrains.kotlin:kotlin-reflect")) { isTransitive = false }
}

Expand Down
2 changes: 1 addition & 1 deletion libraries/tools/abi-comparator/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ plugins {
}

dependencies {
implementation(commonDependency("org.jetbrains.intellij.deps:asm-all"))
implementation(libs.intellij.asm)
implementation(commonDependency("org.apache.commons:commons-text"))

implementation(project(":tools:kotlinp-jvm"))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ dependencies {

testRuntimeOnly(project(":compiler:tests-mutes"))

testCompileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
testCompileOnly(libs.intellij.asm)
}

val konanDataDir: String = System.getProperty("konanDataDirForIntegrationTests")
Expand Down
4 changes: 2 additions & 2 deletions libraries/tools/kotlin-gradle-plugin/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ dependencies {
commonCompileOnly(project(":kotlin-tooling-metadata"))
commonCompileOnly(project(":compiler:build-tools:kotlin-build-statistics"))
commonCompileOnly(project(":native:swift:swift-export-standalone"))
commonCompileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all")) { isTransitive = false }
commonCompileOnly(libs.intellij.asm) { isTransitive = false }

commonImplementation(project(":kotlin-gradle-plugin-idea"))
commonImplementation(project(":kotlin-gradle-plugin-idea-proto"))
Expand All @@ -157,7 +157,7 @@ dependencies {

embedded(project(":kotlin-gradle-build-metrics"))
embedded(project(":kotlin-gradle-statistics"))
embedded(commonDependency("org.jetbrains.intellij.deps:asm-all")) { isTransitive = false }
embedded(libs.intellij.asm) { isTransitive = false }
embedded(commonDependency("com.google.code.gson:gson")) { isTransitive = false }
embedded(libs.guava) { isTransitive = false }
embedded(commonDependency("org.jetbrains.teamcity:serviceMessages")) { isTransitive = false }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ dependencies {
compileOnly(project(":compiler:cli"))
compileOnly(project(":kotlin-android-extensions-runtime"))
compileOnly(intellijCore())
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)

testApi(project(":compiler:util"))
testApi(project(":compiler:backend"))
Expand Down
2 changes: 1 addition & 1 deletion plugins/atomicfu/atomicfu-compiler/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ repositories {

dependencies {
compileOnly(intellijCore())
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)

compileOnly(project(":compiler:plugin-api"))
compileOnly(project(":compiler:cli-common"))
Expand Down
2 changes: 1 addition & 1 deletion plugins/fir-plugin-prototype/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ dependencies {
compileOnly(project(":compiler:fir:entrypoint"))
compileOnly(project(":compiler:plugin-api"))
compileOnly(intellijCore())
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)

testApi(platform(libs.junit.bom))
testImplementation(libs.junit.jupiter.api)
Expand Down
2 changes: 1 addition & 1 deletion plugins/jvm-abi-gen/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ dependencies {
embedded(project(":kotlin-metadata-jvm"))

compileOnly(intellijCore())
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)

testImplementation(libs.junit4)
testImplementation(projectTests(":compiler:tests-common"))
Expand Down
2 changes: 1 addition & 1 deletion plugins/kapt3/kapt3-compiler/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ dependencies {
compileOnly(project(":kotlin-annotation-processing-runtime"))
compileOnly(intellijCore())
compileOnly(toolsJarApi())
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)

testImplementation(intellijCore())
testRuntimeOnly(intellijResources()) { isTransitive = false }
Expand Down
2 changes: 1 addition & 1 deletion plugins/noarg/noarg.backend/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ dependencies {
compileOnly(project(":compiler:backend"))
compileOnly(project(":compiler:ir.backend.common"))
compileOnly(intellijCore())
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)
implementation(kotlinStdlib())
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ dependencies {
compileOnly(project(":compiler:ir.tree"))
compileOnly(project(":compiler:fir:tree"))
compileOnly(intellijCore())
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)
}

optInToUnsafeDuringIrConstructionAPI()
Expand Down
2 changes: 1 addition & 1 deletion plugins/scripting/scripting-compiler-impl/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ dependencies {
api(kotlinStdlib())
compileOnly(commonDependency("org.jetbrains.kotlin:kotlin-reflect")) { isTransitive = false }
compileOnly(intellijCore())
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)

// FIXME: drop after removing references to LocalFileSystem they don't exist in intellij-core
compileOnly(intellijAnalysis())
Expand Down
2 changes: 1 addition & 1 deletion prepare/compiler/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ dependencies {
fatJarContents(commonDependency("org.jetbrains.intellij.deps.jna:jna-platform")) { isTransitive = false }
fatJarContents(commonDependency("org.jetbrains.intellij.deps.fastutil:intellij-deps-fastutil"))
fatJarContents(commonDependency("org.lz4:lz4-java")) { isTransitive = false }
fatJarContents(commonDependency("org.jetbrains.intellij.deps:asm-all")) { isTransitive = false }
fatJarContents(libs.intellij.asm) { isTransitive = false }
fatJarContents(libs.guava) { isTransitive = false }
//Gson is needed for kotlin-build-statistics. Build statistics could be enabled for JPS and Gradle builds. Gson will come from inteliij or KGP.
proguardLibraries(commonDependency("com.google.code.gson:gson")) { isTransitive = false}
Expand Down
2 changes: 1 addition & 1 deletion test-instrumenter/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ plugins {
dependencies {
api(kotlinStdlib())
compileOnly(intellijCore())
compileOnly(commonDependency("org.jetbrains.intellij.deps:asm-all"))
compileOnly(libs.intellij.asm)
}

sourceSets {
Expand Down

0 comments on commit 9bfb6e5

Please sign in to comment.