As I understand it, PNaCl is designed to support C and C++. Has anyone managed to get any other languages (that compile to native code) to run in PNaCl?
2 Answers
Ruby, Lua, and a number of other languages have been ported to NaCl already. See the list of NaCl ports for full documentation. https://code.google.com/p/naclports/wiki/PortList

- 131
- 1
- 4
-
Are those Ruby and Lua interpreters written in C/C++? – J D Nov 17 '13 at 01:15
-
@JanusTroelsen: Ok, thanks. I am only interested in languages that compile to native code. – J D Jan 01 '15 at 01:18
There are a couple of different approaches for targeting other languages to PNaCl. One is compiling the language interpreter with the PNaCl toolchain. Since most interpreters/VMs are written in C and C++, this turns out to be easy in practice. naclports already has Lua, Python and Ruby running in this manner.
A more direct approach is taken by llgo - actually emitting PNaCl bitcode. There were also discussions about Mono (which does run on NaCl) on PNaCl - https://groups.google.com/forum/#!topic/native-client-discuss/Km1FOVH6yn0
The real answer is - it's still early (PNaCl was released publicly last week!); this is a ripe field for disruption because the technology is new. If someone wants to port other languages, it would be very welcome.

- 263,248
- 89
- 350
- 412