ruby-changes:49528
From: nobu <ko1@a...>
Date: Sun, 7 Jan 2018 11:49:33 +0900 (JST)
Subject: [ruby-changes:49528] nobu:r61643 (trunk): extmk.rb: exclude recursively
nobu 2018-01-07 11:49:27 +0900 (Sun, 07 Jan 2018) New Revision: 61643 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=61643 Log: extmk.rb: exclude recursively * ext/extmk.rb: exclude extension libraries recursively. Modified files: trunk/ext/extmk.rb Index: ext/extmk.rb =================================================================== --- ext/extmk.rb (revision 61642) +++ ext/extmk.rb (revision 61643) @@ -496,13 +496,17 @@ cond = proc {|ext, *| https://github.com/ruby/ruby/blob/trunk/ext/extmk.rb#L496 } ($extension || %w[*]).each do |e| e = e.sub(/\A(?:\.\/)+/, '') - exts |= Dir.glob("#{ext_prefix}/#{e}/**/extconf.rb").collect {|d| + incl, excl = Dir.glob("#{ext_prefix}/#{e}/**/extconf.rb").collect {|d| d = File.dirname(d) d.slice!(0, ext_prefix.length + 1) d - }.find_all {|ext| + }.partition {|ext| with_config(ext, &cond) - }.sort + } + incl.sort! + excl.sort!.collect! {|d| d+"/"} + nil while incl.reject! {|d| excl << d+"/" if excl.any? {|e| d.start_with?(e)}} + exts |= incl if $LIBRUBYARG_SHARED.empty? and CONFIG["EXTSTATIC"] == "static" exts.delete_if {|d| File.fnmatch?("-*", d)} end -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/