Build common standard library headers and kotlin-test (common and jvm) as multiplatform projects.

This commit is contained in:
Ilya Gorbunov
2017-03-06 19:47:51 +03:00
parent 780e12f04a
commit 08fa304b6f
11 changed files with 272 additions and 121 deletions
+55
View File
@@ -0,0 +1,55 @@
description = 'Kotlin Test Common'
apply plugin: 'kotlin-platform-common'
dependencies {
compile project(':kotlin-stdlib-common')
}
sourceSets {
test {
kotlin {
srcDir 'src/test'
exclude '**'
}
}
}
// common block
compileKotlinCommon.compilerJarFile = bootstrapCompilerFile
jar {
baseName = project.name
manifest {
attributes 'Implementation-Vendor': 'JetBrains',
'Implementation-Title': "${project.description ?: project.name}", // TODO: project.description is resolved after evaluating this, therefore this attribute is repeated in the projects; seek for a solution
'Implementation-Version': version,
'Build-Jdk': System.getProperty('java.version'),
'Built-By': 'JetBrains'
}
from("${rootDir}/../dist/kotlinc/build.txt") { into("META-INF/") }
}
// TODO: use dokka instead?
javadoc {
failOnError = false
}
task sourcesJar(type: Jar, dependsOn:classes) {
classifier = 'sources'
from sourceSets.main.kotlin
}
task javadocJar(type: Jar, dependsOn:javadoc) {
classifier = 'javadoc'
from javadoc.destinationDir
}
@@ -1,9 +0,0 @@
package kotlin.jvm
@Suppress("HEADER_WITHOUT_IMPLEMENTATION")
@Target(AnnotationTarget.FILE)
internal header annotation class JvmMultifileClass
@Suppress("HEADER_WITHOUT_IMPLEMENTATION")
@Target(AnnotationTarget.FILE)
internal header annotation class JvmName(val name: String)