You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$ tree -L 3 rubies/head-wasm32-unknown-emscripten-full-js
67
+
rubies/head-wasm32-unknown-emscripten-full
68
+
└── usr
69
+
└── local
70
+
├── bin
71
+
├── include
72
+
├── lib
73
+
└── share
74
+
```
75
+
76
+
## Code Formatting
77
+
78
+
This project uses multiple code formatters for each language.
79
+
To format all files, run `rake format`.
80
+
Please make sure to run this command before submitting a pull request.
81
+
26
82
## Re-bindgen from `.wit` files
27
83
28
84
If you update [`*.wit`](https://github.com/WebAssembly/component-model/blob/ed90add27ae845b2e2b9d7db38a966d9f78aa4c0/design/mvp/WIT.md), which describe the interface of a WebAssembly module, either imported or exported, you need to re-generate glue code from `*.wit`.
Copy file name to clipboardExpand all lines: README.md
+1-46Lines changed: 1 addition & 46 deletions
Original file line number
Diff line number
Diff line change
@@ -78,52 +78,6 @@ A _build_ is a combination of ruby version, _profile_, and _target_.
78
78
79
79
Note: `*` is a wildcard that represents any other profile name except for itself, applied recursively. For example, `minimal-full-js-debug` is a valid profile.
80
80
81
-
## Building from source
82
-
83
-
If you want to build Ruby for WebAssembly from source yourself, follow the below instructions.
84
-
85
-
(However, in most cases, it's easier to use prebuilt binaries instead of building them yourself)
86
-
87
-
### Dependencies
88
-
89
-
-[wasi-sdk](https://github.com/WebAssembly/wasi-sdk): Only for building for WASI target. Set `WASI_SDK_PATH` environment variable to the directory of wasi-sdk.
90
-
-[Binaryen](https://github.com/WebAssembly/binaryen): Only for building for WASI target. Install `wasm-opt` in `PATH`
91
-
-[wasi-vfs](https://github.com/kateinoigakukun/wasi-vfs): A virtual filesystem layer for WASI. Install CLI tool in `PATH`. Set `LIB_WASI_VFS_A` environment variable to the path to `libwasi_vfs.a`.
92
-
-[wasi-preset-args](https://github.com/kateinoigakukun/wasi-preset-args): A tool to preset command-line arguments to a WASI module. Install in `PATH`.
93
-
-[Emscripten](https://emscripten.org): Only for building for Emscripten target. Follow the official instructions to install.
94
-
95
-
Note: It's recommended building on a builder Docker container, which installs all dependencies and provides environment variables:
Then, you can build by `rake` command. See `rake -T` for more information.
105
-
106
-
```console
107
-
# Build only a specific combination of ruby version, profile, and target
108
-
# Output is in the `rubies` directory
109
-
$ rake build:head-wasm32-unknown-wasi-full-js
110
-
$ tree -L 3 rubies/head-wasm32-unknown-wasi-full-js
111
-
rubies/head-wasm32-unknown-wasi-full-js/
112
-
├── usr
113
-
│ └── local
114
-
│ ├── bin
115
-
│ ├── include
116
-
│ ├── lib
117
-
│ └── share
118
-
└── var
119
-
└── lib
120
-
└── gems
121
-
122
-
# Or build npm package. Output is a tarball of npm package
123
-
$ rake npm:ruby-head-wasm-wasi
124
-
$ ls packages/npm-packages/ruby-head-wasm-wasi/ruby-head-wasm-wasi-*.tgz
125
-
```
126
-
127
81
## Notable Limitations
128
82
129
83
The current WASI target build does not yet support `Thread` related APIs. Specifically, WASI does not yet have an API for creating and managing threads yet.
@@ -133,4 +87,5 @@ Also there is no support for networking. It is one of the goal of WASI to suppor
133
87
134
88
## Contributing
135
89
90
+
See [CONTRIBUTING.md](./CONTRIBUTING.md) for how to build and test, and how to contribute to this project.
136
91
Bug reports and pull requests are welcome on GitHub at https://github.com/ruby/ruby.wasm
0 commit comments