Merge pull request #43 from woodruffw-forks/ww/debugging

Don't treat -w/-W as compile-only indicators
This commit is contained in:
Ian A Mason 2021-02-18 09:22:57 -08:00 committed by GitHub
commit 44b352b488
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 2 deletions

View File

@ -271,6 +271,7 @@ func compileTimeLinkFiles(compilerExecName string, pr ParserResult, objFiles []s
func buildObjectFile(compilerExecName string, pr ParserResult, srcFile string, objFile string) (success bool) {
args := pr.CompileArgs[:]
args = append(args, srcFile, "-c", "-o", objFile)
LogDebug("buildObjectFile: %v", args)
success, err := execCmd(compilerExecName, args, "")
if !success {
LogError("Failed to build object file for %s because: %v\n", srcFile, err)

View File

@ -177,8 +177,8 @@ func Parse(argList []string) ParserResult {
"--version": {0, pr.compileOnlyCallback},
"-v": {0, pr.compileOnlyCallback},
"-w": {0, pr.compileOnlyCallback},
"-W": {0, pr.compileOnlyCallback},
"-w": {0, pr.compileUnaryCallback},
"-W": {0, pr.compileUnaryCallback},
"-emit-llvm": {0, pr.emitLLVMCallback},
"-flto": {0, pr.linkTimeOptimizationCallback},