Now bundled gems are extracted under .bundle/gems

This commit is contained in:
Nobuyoshi Nakada 2020-06-19 14:02:46 +09:00
parent 0d38a51ec4
commit 1e7c0ccb0d
No known key found for this signature in database
GPG Key ID: 7CD2805BFA3770C6
2 changed files with 2 additions and 2 deletions

View File

@ -16,7 +16,7 @@ srcdir ||= File.dirname(File.dirname(__FILE__))
exts = {} exts = {}
[ [
["exts", "ext", "--extstatic $(EXTSTATIC)"], ["exts", "ext", "--extstatic $(EXTSTATIC)"],
["gems", "gems", "--no-extstatic"], ["gems", ".bundle/gems", "--no-extstatic"],
].each do |t, d, o| ].each do |t, d, o|
exts[t] = [o, Dir.glob("#{srcdir}/#{d}/*/").map {|n| n[(srcdir.size+1)..-2]}] exts[t] = [o, Dir.glob("#{srcdir}/#{d}/*/").map {|n| n[(srcdir.size+1)..-2]}]
end end

View File

@ -17,7 +17,7 @@ opt = OptionParser.new do |o|
o.order!(ARGV) o.order!(ARGV)
end end
contpat = /(?>(?>[^\\\n]|\\.)*\\\n)*(?>[^\\\n]|\\.)*/ contpat = /(?>(?>[^\\\n]|\\.)*\\\n)*(?>[^\\\n]|\\.)*/
Dir.glob("{ext,gems}/*/exts.mk") do |e| Dir.glob("{ext,.bundle/gems}/*/exts.mk") do |e|
gem = /\Agems(?=\/)/ =~ e gem = /\Agems(?=\/)/ =~ e
s = File.read(e) s = File.read(e)
s.scan(/^(extensions|SUBMAKEOPTS|EXT[A-Z]+|MFLAGS|NOTE_[A-Z]+)[ \t]*=[ \t]*(#{contpat})$/o) do |n, v| s.scan(/^(extensions|SUBMAKEOPTS|EXT[A-Z]+|MFLAGS|NOTE_[A-Z]+)[ \t]*=[ \t]*(#{contpat})$/o) do |n, v|