Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use the Emscripten WASM Node Module #122

Closed
lastmjs opened this issue Apr 2, 2018 · 2 comments
Closed

Use the Emscripten WASM Node Module #122

lastmjs opened this issue Apr 2, 2018 · 2 comments

Comments

@lastmjs
Copy link
Owner

lastmjs commented Apr 2, 2018

I'm hoping Emscripten will provide a WASM build. If that were to happen, we could use Node.js easily to compile C/C++ to WASM without having to install and build the toolchain. No other really good tools for compiling C/C++ seem to be available on npm right now. The webassembly module requires the user to download binaries, only for Windows and Linux for now, which wouldn't work with Mac users of course. WASM will provide a portable solution to his, requiring no building on the user's machine

See here: emscripten-core/emscripten#5774
And here: emscripten-core/emscripten#6015

@lastmjs
Copy link
Owner Author

lastmjs commented Dec 23, 2019

Some people have started work on this. Everything is still early and experimental, but hopefully I can use one of these projects, and perhaps they will get picked up by the community and become well-supported:

@lastmjs
Copy link
Owner Author

lastmjs commented Dec 23, 2019

Also, regular compilers such as gcc or g++ will probably get a Wasm compilation target eventually. This should really help as well, for example this project seems like it allows access to gcc or g++ with a JS API in Node.js...hopefully it also installs the binaries locally in node_modules: https://www.npmjs.com/package/gnucc

The end-all-be-all would be a Wasm binary for a C compiler, which would make it extremely simple to distribute...but until then, if the compilers and toolchains at least give us binaries for the different architectures, we should be able to create scripts to load them locally

@lastmjs lastmjs closed this as completed Dec 24, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant