From 7442ca6b274f1a935c31e34221fbd0a68077ddc5 Mon Sep 17 00:00:00 2001 From: Ted Kremenek Date: Wed, 2 Apr 2008 16:04:51 +0000 Subject: [PATCH] Implemented "-k" support. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@49090 91177308-0d34-0410-b5e6-96231b3b80d8 --- utils/scan-build | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/utils/scan-build b/utils/scan-build index aef4e67fb5..01e30997e6 100755 --- a/utils/scan-build +++ b/utils/scan-build @@ -148,17 +148,25 @@ sub Postprocess { sub RunBuildCommand { my $Args = shift; + my $IgnoreErrors = shift; my $Cmd = $Args->[0]; if ($Cmd eq "gcc" or $Cmd eq "cc" or $Cmd eq "llvm-gcc") { shift @$Args; unshift @$Args, "ccc-analyzer" } + elsif ($IgnoreErrors) { + if ($Cmd eq "make" or $Cmd eq "gmake") { + push @$Args, "-k"; + } + elsif ($Cmd eq "xcodebuild") { + push @$Args, "-PBXBuildsContinueAfterErrors=YES"; + } + } system(@$Args); } - ##----------------------------------------------------------------------------## # DisplayHelp - Utility function to display all help options. ##----------------------------------------------------------------------------## @@ -288,7 +296,7 @@ if ($Verbose >= 2) { # Run the build. -RunBuildCommand(\@ARGV); +RunBuildCommand(\@ARGV, $IgnoreErrors); # Postprocess the HTML directory. -- 2.40.0