[commit: ghc] ghc-8.0: Unset GREP_OPTIONS in build system (ac0732f)

git at git.haskell.org git at git.haskell.org
Thu Feb 11 15:30:15 UTC 2016


Repository : ssh://git@git.haskell.org/ghc

On branch  : ghc-8.0
Link       : http://ghc.haskell.org/trac/ghc/changeset/ac0732ff36280b99f53a30ee6ecf0ce2e5eee60a/ghc

>---------------------------------------------------------------

commit ac0732ff36280b99f53a30ee6ecf0ce2e5eee60a
Author: Ben Gamari <bgamari.foss at gmail.com>
Date:   Tue Feb 9 11:06:27 2016 +0100

    Unset GREP_OPTIONS in build system
    
    Test Plan: GREP_OPTIONS=--blah ./validate
    
    Reviewers: austin, thomie
    
    Reviewed By: thomie
    
    Differential Revision: https://phabricator.haskell.org/D1887
    
    GHC Trac Issues: #11530
    
    (cherry picked from commit bfec4a6aade005b6dbd170645d4f2d062cee1d92)


>---------------------------------------------------------------

ac0732ff36280b99f53a30ee6ecf0ce2e5eee60a
 Makefile | 7 +++++++
 boot     | 3 +++
 ghc.mk   | 2 +-
 3 files changed, 11 insertions(+), 1 deletion(-)

diff --git a/Makefile b/Makefile
index 6be584f..82ab2f7 100644
--- a/Makefile
+++ b/Makefile
@@ -18,6 +18,13 @@
 MAKEFLAGS += --no-builtin-rules
 .SUFFIXES:
 
+
+# -----------------------------------------------------------------------------
+# Sanitize environment
+
+# See Trac #11530
+export GREP_OPTIONS :=
+
 ifneq "$(filter maintainer-clean distclean clean clean_% help,$(MAKECMDGOALS))" ""
 -include mk/config.mk
 else
diff --git a/boot b/boot
index 18d43aa..45f5bf0 100755
--- a/boot
+++ b/boot
@@ -11,6 +11,9 @@ my %required_tag;
 my $validate;
 my $curdir;
 
+# See Trac #11530
+$ENV{GREP_OPTIONS} = '';
+
 $required_tag{"-"} = 1;
 $validate = 0;
 
diff --git a/ghc.mk b/ghc.mk
index cbac891..5e4ecc6 100644
--- a/ghc.mk
+++ b/ghc.mk
@@ -92,7 +92,7 @@ $(error Your make does not support abspath. You need GNU make >= 3.81)
 endif
 ##################################################
 
-
+# -----------------------------------------------------------------------------
 # Catch make if it runs away into an infinite loop
 ifeq      "$(MAKE_RESTARTS)" ""
 else ifeq "$(MAKE_RESTARTS)" "1"



More information about the ghc-commits mailing list