diff options
| author | Martin Afanasjew | 2016-01-10 17:50:29 +0100 |
|---|---|---|
| committer | Martin Afanasjew | 2016-02-05 22:07:07 +0100 |
| commit | f9efa18be146dc4372ac9c7a3a60ec1ad14cbd46 (patch) | |
| tree | 281451f818e4be39dfc6b253d05fc2c958973561 /Library | |
| parent | 49990ee93fddb74cb36cec8d7b17946a853ed39c (diff) | |
| download | brew-f9efa18be146dc4372ac9c7a3a60ec1ad14cbd46.tar.bz2 | |
ENV: protect against RUBYLIB/RUBYOPT
Some things can break in hard to debug ways if users or build scripts
set these variables, causing our otherwise quite robust Ruby wrappers
to fail. In theory, we could also use `--disable-rubyopt`, but this is
not supported in Ruby 1.8 (and we still care about it).
Diffstat (limited to 'Library')
| -rwxr-xr-x | Library/ENV/4.3/cc | 2 | ||||
| -rwxr-xr-x | Library/ENV/scm/git | 2 |
2 files changed, 4 insertions, 0 deletions
diff --git a/Library/ENV/4.3/cc b/Library/ENV/4.3/cc index b48abde03..11d811508 100755 --- a/Library/ENV/4.3/cc +++ b/Library/ENV/4.3/cc @@ -1,5 +1,7 @@ #!/bin/sh # Make sure this shim uses the same Ruby interpreter that is used by Homebrew. +unset RUBYLIB +unset RUBYOPT exec "$HOMEBREW_RUBY_PATH" -x "$0" "$@" #!/usr/bin/env ruby -W0 diff --git a/Library/ENV/scm/git b/Library/ENV/scm/git index 57484a078..6124ffe5f 100755 --- a/Library/ENV/scm/git +++ b/Library/ENV/scm/git @@ -1,5 +1,7 @@ #!/bin/sh # Make sure this shim uses the same Ruby interpreter that is used by Homebrew. +unset RUBYLIB +unset RUBYOPT exec "$HOMEBREW_RUBY_PATH" -x "$0" "$@" #!/usr/bin/env ruby -W0 |
