From ba64d0c8ab93c7f38b87567059cb2b66747d022c Mon Sep 17 00:00:00 2001 From: Timothee Cour Date: Mon, 8 Feb 2021 13:26:09 -0800 Subject: [PATCH] fix #16947: `--app:staticlib -o:lib` now first removes lib (#16948) --- compiler/extccomp.nim | 1 + 1 file changed, 1 insertion(+) diff --git a/compiler/extccomp.nim b/compiler/extccomp.nim index cf6cd8d9dc..6341cddd99 100644 --- a/compiler/extccomp.nim +++ b/compiler/extccomp.nim @@ -662,6 +662,7 @@ proc addExternalFileToCompile*(conf: ConfigRef; filename: AbsoluteFile) = proc getLinkCmd(conf: ConfigRef; output: AbsoluteFile, objfiles: string, isDllBuild: bool): string = if optGenStaticLib in conf.globalOptions: + removeFile output # fixes: bug #16947 result = CC[conf.cCompiler].buildLib % ["libfile", quoteShell(output), "objfiles", objfiles] else: