75ad20f823
Required as a workaround for Proguard bug https://sourceforge.net/p/proguard/bugs/664/ When processing bytecode generated by Kotlin compiler for constructor call with stack spilling during arguments evaluation, ProGuard performs an equivalent transformation for the bytecode, but emits invalid stack frame information. In JVM 1.6, such invalid stack frames are ignored and re-evaluated by JVM during bytecode verification. In JVM 1.8, such invalid stack frames cause VerifyError.
45 lines
698 B
Groovy
45 lines
698 B
Groovy
description 'Kotlin Script Runtime'
|
|
|
|
apply plugin: 'kotlin'
|
|
|
|
configureJvm6Project(project)
|
|
configurePublishing(project)
|
|
|
|
dependencies {
|
|
compileOnly project(':kotlin-stdlib')
|
|
}
|
|
|
|
configurations {
|
|
mainJar
|
|
}
|
|
|
|
sourceSets {
|
|
main {
|
|
kotlin {
|
|
srcDir "${rootDir}/core/script.runtime/src"
|
|
}
|
|
}
|
|
}
|
|
|
|
jar {
|
|
manifestAttributes(manifest, project, 'Main')
|
|
}
|
|
|
|
artifacts {
|
|
archives sourcesJar
|
|
archives javadocJar
|
|
mainJar jar
|
|
}
|
|
|
|
dist {
|
|
from (jar, sourcesJar)
|
|
}
|
|
|
|
compileKotlin {
|
|
kotlinOptions.freeCompilerArgs = [
|
|
"-Xallow-kotlin-package",
|
|
"-Xnormalize-constructor-calls=enable",
|
|
"-module-name", project.name
|
|
]
|
|
}
|