diff options
author | Vladimír Čunát <vcunat@gmail.com> | 2016-01-29 11:53:50 +0100 |
---|---|---|
committer | Vladimír Čunát <vcunat@gmail.com> | 2016-02-03 17:15:11 +0100 |
commit | 89036ef76ab09af6ba324c896f0db00ae1ebaab0 (patch) | |
tree | 2378a464309985299fd43583b0f5696c4875411e /pkgs/stdenv/generic/setup.sh | |
parent | 80270e201981bd8fedc51935dfe46e8885e72b31 (diff) | |
download | nixlib-89036ef76ab09af6ba324c896f0db00ae1ebaab0.tar nixlib-89036ef76ab09af6ba324c896f0db00ae1ebaab0.tar.gz nixlib-89036ef76ab09af6ba324c896f0db00ae1ebaab0.tar.bz2 nixlib-89036ef76ab09af6ba324c896f0db00ae1ebaab0.tar.lz nixlib-89036ef76ab09af6ba324c896f0db00ae1ebaab0.tar.xz nixlib-89036ef76ab09af6ba324c896f0db00ae1ebaab0.tar.zst nixlib-89036ef76ab09af6ba324c896f0db00ae1ebaab0.zip |
stdenv: accept wider range of $configureScript options
Fixes #12632. I think it's better to quote this variable in general, because it is common and even documented to pass space-separated commands in there. The greps should just fail in that case and `if` won't proceed which seems fine for such cases, and it's certainly better than passing additional unintended parameters to grep (which was happening all the time before).
Diffstat (limited to 'pkgs/stdenv/generic/setup.sh')
-rw-r--r-- | pkgs/stdenv/generic/setup.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pkgs/stdenv/generic/setup.sh b/pkgs/stdenv/generic/setup.sh index dc6c765353f7..7d25472993c5 100644 --- a/pkgs/stdenv/generic/setup.sh +++ b/pkgs/stdenv/generic/setup.sh @@ -644,14 +644,14 @@ configurePhase() { # Add --disable-dependency-tracking to speed up some builds. if [ -z "$dontAddDisableDepTrack" ]; then - if grep -q dependency-tracking $configureScript; then + if grep -q dependency-tracking "$configureScript"; then configureFlags="--disable-dependency-tracking $configureFlags" fi fi # By default, disable static builds. if [ -z "$dontDisableStatic" ]; then - if grep -q enable-static $configureScript; then + if grep -q enable-static "$configureScript"; then configureFlags="--disable-static $configureFlags" fi fi |