diff --git a/kotlin-native/build-tools/src/main/kotlin/org/jetbrains/kotlin/bitcode/CompileToBitcode.kt b/kotlin-native/build-tools/src/main/kotlin/org/jetbrains/kotlin/bitcode/CompileToBitcode.kt index 812b8f96712..4867b4e1d9e 100644 --- a/kotlin-native/build-tools/src/main/kotlin/org/jetbrains/kotlin/bitcode/CompileToBitcode.kt +++ b/kotlin-native/build-tools/src/main/kotlin/org/jetbrains/kotlin/bitcode/CompileToBitcode.kt @@ -167,9 +167,9 @@ open class CompileToBitcode @Inject constructor( val llvmDir = project.findProperty("llvmDir") executable = "$llvmDir/bin/llvm-link" args = listOf("-o", outFile.absolutePath) + linkerArgs + - project.fileTree(objDir) { - include("**/*.bc") - }.files.map { it.absolutePath } + inputFiles.map { + bitcodeFileForInputFile(it).absolutePath + } } } }