diff options
author | Eelco Dolstra <eelco.dolstra@logicblox.com> | 2005-12-15 13:37:36 +0000 |
---|---|---|
committer | Eelco Dolstra <eelco.dolstra@logicblox.com> | 2005-12-15 13:37:36 +0000 |
commit | ded942b341d65b8aceeeab6a699554e95d35c1b4 (patch) | |
tree | c6a63fb535bcf255f53b075946c17d196d4fdeb6 /pkgs/build-support | |
parent | a3746c77012669192cf2334a370344d3bb1e20ac (diff) |
* Make sure that `gcc -v' (i.e., with no other arguments) does the
right thing. This is necessary to make libtool detect g++ properly. (Fixes the `libtool: compile: unable to infer tagged configuration' error on FreeBSD when building Berkeley DB 4.4.) svn path=/nixpkgs/trunk/; revision=4370
Diffstat (limited to 'pkgs/build-support')
-rw-r--r-- | pkgs/build-support/gcc-wrapper/gcc-wrapper.sh | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/pkgs/build-support/gcc-wrapper/gcc-wrapper.sh b/pkgs/build-support/gcc-wrapper/gcc-wrapper.sh index d514b57e28a0c..51916ccdd4a1c 100644 --- a/pkgs/build-support/gcc-wrapper/gcc-wrapper.sh +++ b/pkgs/build-support/gcc-wrapper/gcc-wrapper.sh @@ -92,6 +92,15 @@ if test "$dontLink" != "1"; then fi fi +# As a very special hack, if the arguments are just `-v', then don't +# add anything. This is to prevent `gcc -v' (which normally prints +# out the version number and returns exit code 0) from printing out +# `No input files specified' and returning exit code 1. +if test "$*" = "-v"; then + extraAfter=() + extraBefore=() +fi + # Optionally print debug info. if test "$NIX_DEBUG" = "1"; then echo "original flags to @gccProg@:" >&2 |