https://kotlinlang.org logo
Title
t

thevery

06/15/2018, 2:20 PM
ok, 0.1.6 fixes issue but now I have the following:
exception: java.lang.IllegalStateException: Could not find "http_client_native"
config:
library('nativelib') {
        enableMultiplatform true

        dependencies {
            artifactnativelib "io.ktor.common.client:http_client_native:$kotlin_http_client_version"
        }
    }

    program('nativetest') {
        srcDir 'src/test/kotlin'
        commonSourceSet 'test'
        libraries {
            artifact 'nativelib'
        }
        extraOpts '-tr'
        dependencies {
            artifactnativetest "io.ktor.common.client:http_client_native:$kotlin_http_client_version"
        }
    }
library
is ok, but
program
if failing
i

ilya.matveev

06/15/2018, 2:35 PM
It's a known issue with names of published artifacts and the fix for it is already waiting for tests: https://github.com/JetBrains/kotlin-native/pull/1697. But a new ktor build with correct naming needs to be published.
t

thevery

06/15/2018, 2:44 PM
Thank you! Is there any workaround for this issue (except rebuilding from sources)?
e

e5l

06/15/2018, 2:55 PM
You could add library sources to program sourceSet and exclude transitive dependencies for now.
t

thevery

06/15/2018, 3:42 PM
There is no explicit sources in library and it is not quite clear how to add both test sources and main sources. Maybe you can provide some sample based on snippet above?
e

e5l

06/21/2018, 7:12 AM
http-client-common
0.1.11
version released with new gradle dsl, coroutines and bug fixes https://github.com/e5l/http-client-common
👍 1