Add /NOIMPLIB /NOEXP on MSVC linker by default when building an executable

This commit is contained in:
gingerBill
2023-01-14 13:42:29 +00:00
parent 9aa9429135
commit b0619980b2
+6
View File
@@ -322,6 +322,12 @@ gb_internal i32 linker_stage(lbGenerator *gen) {
}
}
switch (build_context.build_mode) {
case BuildMode_Executable:
link_settings = gb_string_append_fmt(link_settings, " /NOIMPLIB /NOEXP");
break;
}
result = system_exec_command_line_app("msvc-link",
"\"%.*slink.exe\" %s %.*s -OUT:\"%.*s\" %s "
"/nologo /incremental:no /opt:ref /subsystem:%s "