Fib lib name on windows

This commit is contained in:
Arnaud 2025-10-10 20:14:25 +02:00 committed by Eric
parent 226b857c01
commit 3e2e9981c6
No known key found for this signature in database

View File

@ -38,7 +38,8 @@ proc buildLibrary(name: string, srcDir = "./", params = "", `type` = "dynamic")
"-d:chronicles_log_level=TRACE " &
params & " " & srcDir & name & ".nim"
else:
exec "nim c" & " --out:build/" & name &
let lib_name = (when defined(windows): name & ".dll" else: name & ".so")
exec "nim c" & " --out:build/" & lib_name &
".a --threads:on --app:staticlib --opt:size --noMain --mm:refc --header --d:metrics " &
"--nimMainPrefix:libcodex -d:noSignalHandler " &
"-d:LeopardExtraCompilerFlags=-fPIC " &