Fix --use-cc when no absolute path is provided.

Thanks to Aurelien Jacobs for testing (Closes: #748777)
This commit is contained in:
Sylvestre Ledru 2014-06-23 00:18:22 +00:00
parent a08252573b
commit 877222c218
2 changed files with 4 additions and 3 deletions

3
debian/changelog vendored
View File

@ -5,7 +5,8 @@ llvm-toolchain-3.4 (1:3.4.2-3) unstable; urgency=medium
(Closes: #751943)
* Fix FTBFS on powerpc and powerpcspe (Closes: #733890)
* Broken library symlink fixed in lldb-3.4 (Closes: #715130)
* Fix --use-cc when no absolute path is provided (Closes: #748777)
* Fix --use-cc when no absolute path is provided.
Thanks to Aurelien Jacobs for testing (Closes: #748777)
* depends-on-build-essential-package-without-using-version g++ fixed
-- Sylvestre Ledru <sylvestre@debian.org> Thu, 19 Jun 2014 19:13:16 +0200

View File

@ -25,7 +25,7 @@ Index: llvm-toolchain-3.4-3.4.2/clang/tools/scan-build/ccc-analyzer
if ($FindBin::Script =~ /c\+\+-analyzer/) {
$Compiler = $ENV{'CCC_CXX'};
- if (!defined $Compiler || ! -x $Compiler) { $Compiler = $DefaultCXXCompiler; }
+ if (!defined $Compiler || ! -x $Compiler || ! SearchInPath($Compiler)) { $Compiler = $DefaultCXXCompiler; }
+ if (!defined $Compiler || (! -x $Compiler && ! SearchInPath($Compiler))) { $Compiler = $DefaultCXXCompiler; }
$Clang = $ENV{'CLANG_CXX'};
if (!defined $Clang || ! -x $Clang) { $Clang = 'clang++'; }
@ -33,7 +33,7 @@ Index: llvm-toolchain-3.4-3.4.2/clang/tools/scan-build/ccc-analyzer
else {
$Compiler = $ENV{'CCC_CC'};
- if (!defined $Compiler || ! -x $Compiler) { $Compiler = $DefaultCCompiler; }
+ if (!defined $Compiler || ! -x $Compiler && ! SearchInPath($Compiler)) { $Compiler = $DefaultCCompiler; }
+ if (!defined $Compiler || (! -x $Compiler && ! SearchInPath($Compiler))) { $Compiler = $DefaultCCompiler; }
$Clang = $ENV{'CLANG'};
if (!defined $Clang || ! -x $Clang) { $Clang = 'clang'; }