From fd978621ccbc9519afc05ad031ba2518e9a6f379 Mon Sep 17 00:00:00 2001 From: Nobuyoshi Nakada Date: Thu, 15 Apr 2021 12:49:06 +0900 Subject: [PATCH] mkconfig.rb: Update around SDKROOT c.f. https://opensource.apple.com/source/ruby/ruby-145.40.1/patches/tool_mkconfig.rb.diff * moved to "includedir" from "oldincludedir". * honor "$(prefix)/include" if exists, otherwise fallback to `xcrun`. --- tool/mkconfig.rb | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/tool/mkconfig.rb b/tool/mkconfig.rb index cd42661661..6db60724e9 100755 --- a/tool/mkconfig.rb +++ b/tool/mkconfig.rb @@ -124,7 +124,7 @@ File.foreach "config.status" do |line| if universal platform = val.sub(/universal/, %q[#{arch && universal[/(?:\A|\s)#{Regexp.quote(arch)}=(\S+)/, 1] || RUBY_PLATFORM[/\A[^-]*/]}]) end - when /^oldincludedir$/ + when /^includedir$/ val = '"$(SDKROOT)"'+val if /darwin/ =~ arch end v = " CONFIG[\"#{name}\"] #{eq} #{val}\n" @@ -269,7 +269,15 @@ print <