diff options
| -rw-r--r-- | Library/Formula/python.rb | 29 |
1 files changed, 1 insertions, 28 deletions
diff --git a/Library/Formula/python.rb b/Library/Formula/python.rb index 9fa30d85e..bea83600b 100644 --- a/Library/Formula/python.rb +++ b/Library/Formula/python.rb @@ -92,11 +92,7 @@ class Python < Formula args << "--without-gcc" if ENV.compiler == :clang - if superenv? - distutils_fix_superenv(args) - else - distutils_fix_stdenv - end + distutils_fix_superenv(args) if build.universal? ENV.universal_binary @@ -236,29 +232,6 @@ class Python < Formula "do_readline = '#{Formula["readline"].opt_lib}/libhistory.dylib'" end - def distutils_fix_stdenv - # Python scans all "-I" dirs but not "-isysroot", so we add - # the needed includes with "-I" here to avoid this err: - # building dbm using ndbm - # error: /usr/include/zlib.h: No such file or directory - ENV.append "CPPFLAGS", "-I#{MacOS.sdk_path}/usr/include" unless MacOS::CLT.installed? - - # Don't use optimizations other than "-Os" here, because Python's distutils - # remembers (hint: `python-config --cflags`) and reuses them for C - # extensions which can break software (such as scipy 0.11 fails when - # "-msse4" is present.) - ENV.minimal_optimization - - # We need to enable warnings because the configure.in uses -Werror to detect - # "whether gcc supports ParseTuple" (https://github.com/Homebrew/homebrew/issues/12194) - ENV.enable_warnings - if ENV.compiler == :clang - # http://docs.python.org/devguide/setup.html#id8 suggests to disable some Warnings. - ENV.append_to_cflags "-Wno-unused-value" - ENV.append_to_cflags "-Wno-empty-body" - end - end - def sitecustomize <<-EOF.undent # This file is created by Homebrew and is executed on each python startup. |
