Skip to content

Commit 424fda6

Browse files
apply given patches for ruby sources
1 parent c847e77 commit 424fda6

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

Rakefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ BUILD_SOURCES = {
1313
type: "github",
1414
repo: "ruby/ruby",
1515
rev: "master",
16-
patches: []
16+
patches: Dir["./patches/*.patch"].map{|p| File.expand_path(p) }
1717
}
1818
}
1919

lib/ruby_wasm/build_system/product/ruby_source.rb

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,9 @@ def fetch
3434
else
3535
raise "unknown source type: #{@params[:type]}"
3636
end
37+
(@params[:patches] || []).each do |patch_path|
38+
system "patch -p1 < #{patch_path}", chdir: src_dir
39+
end
3740
end
3841

3942
def build

0 commit comments

Comments
 (0)