diff options
| author | Max Howell | 2012-08-11 12:30:51 -0400 |
|---|---|---|
| committer | Max Howell | 2012-08-29 12:41:34 -0400 |
| commit | 59736fb537e10c9a83119342fa1d5926c3f0b078 (patch) | |
| tree | 64a41c8a3f60edd8a509a75b35c22e7574655cc0 /Library/Homebrew/cmd/--env.rb | |
| parent | 4d92a605eb383bdbcf99b1166b3f2ef55f9efdfb (diff) | |
| download | homebrew-59736fb537e10c9a83119342fa1d5926c3f0b078.tar.bz2 | |
superenv: build-environments that just work
1. A minimal build environment, we don't set CFLAGS, CPPFLAGS, LDFLAGS, etc. the rationale being, the less that is set, the less variables we are introducing that can break builds.
2. A set of scripts that replace cc, ld, etc. and inject the -I, -L, etc. flags we need into the args passed to the build-tools.
Because we now have complete control over compiler instantiations we do a variety of clean-up tasks, like removing bad flags, enforcing universal builds and ensuring makefiles don't try to change the order of library and include paths from ones that work to ones that don't.
The previous ENV-system is still available when --env=std is specified.
superenv applies to Xcode >= 4.3 only currently.
Diffstat (limited to 'Library/Homebrew/cmd/--env.rb')
| -rw-r--r-- | Library/Homebrew/cmd/--env.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Library/Homebrew/cmd/--env.rb b/Library/Homebrew/cmd/--env.rb index 79323c300..b5d1253fe 100644 --- a/Library/Homebrew/cmd/--env.rb +++ b/Library/Homebrew/cmd/--env.rb @@ -1,9 +1,8 @@ -require 'extend/ENV' +require 'superenv' require 'hardware' module Homebrew extend self def __env - ENV.extend(HomebrewEnvExtension) ENV.setup_build_environment ENV.universal_binary if ARGV.build_universal? if $stdout.tty? @@ -17,10 +16,11 @@ module Homebrew extend self def build_env_keys env %w[ CC CXX LD CFLAGS CXXFLAGS CPPFLAGS LDFLAGS SDKROOT - CMAKE_PREFIX_PATH CMAKE_INBLUDE_PATH CMAKE_FRAMEWORK_PATH MAKEFLAGS + CMAKE_PREFIX_PATH CMAKE_INCLUDE_PATH CMAKE_FRAMEWORK_PATH MAKEFLAGS MACOSX_DEPLOYMENT_TARGET PKG_CONFIG_PATH HOMEBREW_BUILD_FROM_SOURCE HOMEBREW_DEBUG HOMEBREW_MAKE_JOBS HOMEBREW_VERBOSE HOMEBREW_USE_CLANG HOMEBREW_USE_GCC HOMEBREW_USE_LLVM HOMEBREW_SVN + MAKE GIT CPP ACLOCAL_PATH OBJC PATH ].select{ |key| env[key] } end |
