diff options
| author | dinkypumpkin | 2014-03-25 08:15:31 +0000 |
|---|---|---|
| committer | Mike McQuaid | 2014-03-25 08:15:35 +0000 |
| commit | a201069224987d7ea6f3c2d69f2671ba92dc8a28 (patch) | |
| tree | 9c0a27cc2811832e39764bfc2ef9fb39f6206cc3 /Library | |
| parent | c4f9665311298731bb22ee700e970e19ec66c9cd (diff) | |
| download | homebrew-a201069224987d7ea6f3c2d69f2671ba92dc8a28.tar.bz2 | |
cc: don't add linker arguments if only -v passed.
Supports configure scripts (e.g., mplayer) that use "gcc -v" to
identify compiler.
Closes #27793.
Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
Diffstat (limited to 'Library')
| -rwxr-xr-x | Library/ENV/4.3/cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/Library/ENV/4.3/cc b/Library/ENV/4.3/cc index b4cc177b4..67bb0df07 100755 --- a/Library/ENV/4.3/cc +++ b/Library/ENV/4.3/cc @@ -73,6 +73,12 @@ class Cmd end end def args + if @args.length == 1 and @args[0] == '-v' + # Don't add linker arguments if -v passed as sole option. This stops gcc + # -v with no other arguments from outputting a linker error. Some + # software uses gcc -v (wrongly) to sniff the GCC version. + return @args.dup + end if !cccfg?("O") || tool == "ld" || configure? args = @args.dup else |
