-
Notifications
You must be signed in to change notification settings - Fork 10
Expand file tree
/
Copy pathmruby.patch
More file actions
31 lines (31 loc) · 858 Bytes
/
Copy pathmruby.patch
File metadata and controls
31 lines (31 loc) · 858 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
diff --git a/build_config/emscripten.rb b/build_config/emscripten.rb
new file mode 100644
index 000000000..e016f7887
--- /dev/null
+++ b/build_config/emscripten.rb
@@ -0,0 +1,9 @@
+
+MRuby::CrossBuild.new('emscripten') do |conf|
+ toolchain :clang
+ conf.gembox 'wasm'
+ conf.cc.command = 'emcc'
+ conf.cc.flags = %W(-Os)
+ conf.linker.command = 'emcc'
+ conf.archiver.command = 'emar'
+end
diff --git a/mrbgems/wasm.gembox b/mrbgems/wasm.gembox
new file mode 100644
index 000000000..f4eb831e1
--- /dev/null
+++ b/mrbgems/wasm.gembox
@@ -0,0 +1,10 @@
+MRuby::GemBox.new do |conf|
+ conf.gembox "stdlib"
+ conf.gembox "stdlib-io"
+ conf.gembox "stdlib-ext"
+ conf.gembox "metaprog"
+ conf.gembox "math"
+
+ # Add third party json support
+ conf.gem :github => "mattn/mruby-json", :checksum_hash => "054699892b0d681110e7348440cddb70a3fd671e"
+end