diff options
| author | Kyungdahm Yun | 2013-01-18 00:01:37 +0900 |
|---|---|---|
| committer | Adam Vandenberg | 2013-01-17 14:33:12 -0800 |
| commit | 902d22290b1dfd13742da3d72199641ac4b4f0b4 (patch) | |
| tree | d594e6f15cdc64db59e3bd79bdcce20d6ba6042f /Library | |
| parent | fbf91baf904f1b1e41cf0dc863c9518d489a947f (diff) | |
| download | homebrew-902d22290b1dfd13742da3d72199641ac4b4f0b4.tar.bz2 | |
Fix PYTHONFRAMEWORKDIR for Xcode with CLT
PYTHONFRAMEWORKDIR is now replaced even if CLT is installed.
Closes #17144.
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
Diffstat (limited to 'Library')
| -rw-r--r-- | Library/Formula/python.rb | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/Library/Formula/python.rb b/Library/Formula/python.rb index 39e39f4c8..a56b5d067 100644 --- a/Library/Formula/python.rb +++ b/Library/Formula/python.rb @@ -164,15 +164,16 @@ class Python < Formula install-lib=#{site_packages} EOF - unless MacOS::CLT.installed? - makefile = prefix/'Frameworks/Python.framework/Versions/2.7/lib/python2.7/config/Makefile' - inreplace makefile do |s| + makefile = prefix/'Frameworks/Python.framework/Versions/2.7/lib/python2.7/config/Makefile' + inreplace makefile do |s| + unless MacOS::CLT.installed? s.gsub!(/^CC=.*$/, "CC=xcrun clang") s.gsub!(/^CXX=.*$/, "CXX=xcrun clang++") s.gsub!(/^AR=.*$/, "AR=xcrun ar") s.gsub!(/^RANLIB=.*$/, "RANLIB=xcrun ranlib") - s.gsub!(/^PYTHONFRAMEWORKDIR=\tPython\.framework/, "PYTHONFRAMEWORKDIR= #{opt_prefix}/Frameworks/Python.framework") end + # Should be fixed regardless of CLT (for `python-config --ldflags`) + s.gsub!(/^PYTHONFRAMEWORKDIR=\tPython\.framework/, "PYTHONFRAMEWORKDIR= #{opt_prefix}/Frameworks/Python.framework") end end |
