Files
kotlin-fork/libraries/tools/binary-compatibility-validator/build.gradle
T
Dmitry Petrov 75ad20f823 Build compiler, plugin & stdlib with constructor call normalization
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.
2017-10-12 10:59:57 +03:00

51 lines
1.5 KiB
Groovy

apply plugin: 'kotlin'
configurations {
testArtifacts
}
dependencies {
compile project(':kotlin-stdlib')
compile 'org.ow2.asm:asm-debug-all:5.0.4'
compile 'com.google.code.gson:gson:2.6.2'
testCompile project(':kotlin-test:kotlin-test-junit')
testArtifacts project(':kotlin-stdlib')
testArtifacts project(':kotlin-stdlib-jre7')
testArtifacts project(':kotlin-stdlib-jre8')
testArtifacts project(':kotlin-stdlib-jdk7')
testArtifacts project(':kotlin-stdlib-jdk8')
testArtifacts project(':kotlin-reflect')
// legacy
testArtifacts project(':kotlin-runtime')
testArtifacts files(project(':kotlin-stdlib').tasks.originalStdlibJar)
}
sourceSets {
test {
java {
srcDir "src/test/kotlin"
}
}
}
def testCasesDeclarationsDump = "${buildDir}/cases-declarations.json".toString()
compileTestKotlin {
kotlinOptions {
freeCompilerArgs = ["-Xdump-declarations-to=$testCasesDeclarationsDump", "-Xnormalize-constructor-calls=enable"]
}
}
test {
dependsOn cleanCompileTestKotlin
dependsOn configurations.testArtifacts
systemProperty 'overwrite.output', System.getProperty("overwrite.output", "false")
systemProperty 'kotlinVersion', project.version
systemProperty 'testCasesClassesDirs', sourceSets.test.output.classesDirs.asPath
systemProperty 'testCasesDeclarations', testCasesDeclarationsDump
jvmArgs '-ea'
ignoreFailures = System.getenv("kotlin_build_ignore_test_failures") == 'yes'
}