diff --git a/README.md b/README.md index 153da38f..82772151 100644 --- a/README.md +++ b/README.md @@ -180,7 +180,7 @@ dependencies { sourceSets { main { component { - target "ios_arm64", "ios_arm32", "ios_x64", "macos_x64", "linux_x64", "mingw_x64" + targets = ["ios_arm64", "ios_arm32", "ios_x64", "macos_x64", "linux_x64", "mingw_x64"] outputKinds = [EXECUTABLE] } } diff --git a/atomicfu-js/build.gradle b/atomicfu-js/build.gradle index bff1e85e..ceb1d6b3 100644 --- a/atomicfu-js/build.gradle +++ b/atomicfu-js/build.gradle @@ -4,12 +4,17 @@ apply from: file("$rootProject.projectDir/gradle/node-js.gradle") apply from: file("$rootProject.projectDir/gradle/test-mocha-js.gradle") apply from: file("$rootProject.projectDir/gradle/publish-npm-js.gradle") +configurations { + transformer +} + dependencies { compile "org.jetbrains.kotlin:kotlin-stdlib-js:$kotlin_version" expectedBy project(":atomicfu-common") testCompile "org.jetbrains.kotlin:kotlin-test-js:$kotlin_version" - testCompile project(":atomicfu-transformer") + + transformer project(":atomicfu-transformer") } tasks.withType(compileKotlin2Js.getClass()) { @@ -40,10 +45,10 @@ repositories.whenObjectAdded { def orifinalFile = "$buildDir/classes/kotlin/test/atomicfu-js_test.js" def transformedFile = "$buildDir/classes/kotlin/test/atomicfu-js_testTransformed.js" -task transformJS (type: JavaExec, dependsOn: compileKotlin2Js) { +task transformJS (type: JavaExec, dependsOn: [compileKotlin2Js, tasks.findByPath(":atomicfu-transformer:assemble")]) { main = "kotlinx.atomicfu.transformer.AtomicFUTransformerJSKt" args = [orifinalFile, transformedFile, true] - classpath = sourceSets.test.runtimeClasspath + classpath = project.files(configurations.transformer.asCollection()) inputs.file(orifinalFile) outputs.file(transformedFile) } diff --git a/atomicfu-native/build.gradle b/atomicfu-native/build.gradle index 7e0f26fd..814d075d 100644 --- a/atomicfu-native/build.gradle +++ b/atomicfu-native/build.gradle @@ -5,7 +5,7 @@ apply from: project.rootProject.file('gradle/maven-central.gradle') sourceSets { main { component { - target "ios_arm64", "ios_arm32", "ios_x64", "macos_x64", "linux_x64", "mingw_x64" + targets = ["ios_arm64", "ios_arm32", "ios_x64", "macos_x64", "linux_x64", "mingw_x64"] outputKinds = [KLIBRARY] pom { withXml(configureMavenCentralMetadata) @@ -18,10 +18,11 @@ dependencies { expectedBy project(':atomicfu-common') } + if (project.hasProperty("teamcity")) { afterEvaluate { - runTestDebug { + tasks.withType(Class.forName("org.gradle.nativeplatform.test.tasks.RunTestExecutable_Decorated")) { args '--ktest_logger=TEAMCITY' } } -} \ No newline at end of file +} diff --git a/gradle.properties b/gradle.properties index e874776c..b2d04de8 100644 --- a/gradle.properties +++ b/gradle.properties @@ -2,7 +2,7 @@ version = 0.11.5-SNAPSHOT group = org.jetbrains.kotlinx kotlin_version = 1.2.61 -kotlin_native_version = 0.8.2 +kotlin_native_version = 0.9 asm_version = 5.2 slf4j_version = 1.8.0-alpha2 junit_version = 4.12