aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
Diffstat (limited to 'Library')
-rw-r--r--Library/Formula/libxml2.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/Library/Formula/libxml2.rb b/Library/Formula/libxml2.rb
index 29a846121..ad6e30eae 100644
--- a/Library/Formula/libxml2.rb
+++ b/Library/Formula/libxml2.rb
@@ -37,6 +37,11 @@ class Libxml2 < Formula
ENV.append 'CFLAGS', arch_flags
ENV.append 'LDFLAGS', arch_flags
+ unless MacOS::CLT.installed?
+ # We can hijack /opt/include to insert SDKROOT/usr/include
+ inreplace 'setup.py', '"/opt/include",', "'#{MacOS.sdk_path}/usr/include',"
+ end
+
system "python", "setup.py",
"install_lib",
"--install-dir=#{python_lib}"