Fix konan klib output setup
(cherry picked from commit c75b32ed1a4b8de2801bfece680b6ef7778b6dd5)
This commit is contained in:
committed by
Vasily Levchenko
parent
67fa7c779a
commit
64445bb793
+9
-2
@@ -129,7 +129,8 @@ internal fun produceOutput(context: Context) {
|
||||
LLVMWriteBitcodeToFile(context.llvmModule!!, output)
|
||||
}
|
||||
CompilerOutputKind.LIBRARY -> {
|
||||
val output = context.config.outputFiles.outputName
|
||||
val nopack = config.getBoolean(KonanConfigKeys.NOPACK)
|
||||
val output = context.config.outputFiles.klibOutputFileName(!nopack)
|
||||
val libraryName = context.config.moduleId
|
||||
val shortLibraryName = context.config.shortModuleName
|
||||
val neededLibraries = context.librariesWithDependencies
|
||||
@@ -146,9 +147,15 @@ internal fun produceOutput(context: Context) {
|
||||
irVersion = irVersion
|
||||
)
|
||||
val target = context.config.target
|
||||
val nopack = config.getBoolean(KonanConfigKeys.NOPACK)
|
||||
val manifestProperties = context.config.manifestProperties
|
||||
|
||||
if (!nopack) {
|
||||
val suffix = context.config.outputFiles.produce.suffix(target)
|
||||
if (!output.endsWith(suffix)) {
|
||||
error("please specify correct output: packed: ${!nopack}, $output$suffix")
|
||||
}
|
||||
}
|
||||
|
||||
val library = buildLibrary(
|
||||
context.config.nativeLibraries,
|
||||
context.config.includeBinaries,
|
||||
|
||||
Reference in New Issue
Block a user