mirror of
https://github.com/Homebrew/brew.git
synced 2025-07-14 16:09:03 +08:00
Move extra stdenv setup to extended callback
This commit is contained in:
parent
eebc04ec9b
commit
d09e23c8b1
@ -14,7 +14,6 @@ module EnvActivation
|
||||
extend(Superenv)
|
||||
else
|
||||
extend(HomebrewEnvExtension)
|
||||
prepend 'PATH', "#{HOMEBREW_PREFIX}/bin", ':' unless ORIGINAL_PATHS.include? HOMEBREW_PREFIX/'bin'
|
||||
end
|
||||
end
|
||||
end
|
||||
@ -27,6 +26,12 @@ module HomebrewEnvExtension
|
||||
FC_FLAG_VARS = %w{FCFLAGS FFLAGS}
|
||||
DEFAULT_FLAGS = '-march=core2 -msse4'
|
||||
|
||||
def self.extended(base)
|
||||
unless ORIGINAL_PATHS.include? HOMEBREW_PREFIX/'bin'
|
||||
base.prepend_path 'PATH', "#{HOMEBREW_PREFIX}/bin"
|
||||
end
|
||||
end
|
||||
|
||||
def setup_build_environment
|
||||
# Clear CDPATH to avoid make issues that depend on changing directories
|
||||
delete('CDPATH')
|
||||
|
Loading…
x
Reference in New Issue
Block a user