Translating C to JavaScript

I've got a bunch of math/dsp algorithms in C. Single functions, one function per file, no fancy linking or includes or preprocessor directives, only c99 and standard library calls (mainly memset and memmoves to handle array copying etc). Translating them is not a big problem, but it takes time. I was wondering if there was some C -> Javascript translation tool, in order to speed up the work.

Please mind I don't need a perfect translation, I will put my hand on the final result anyway. What I need is a simple tool that helps with the basic, "boring" things.

Anyone heard of such a thing?

Edit: seems that emscripten will do the trick.


Update: it seems The Times They Are a-Changin' :)

See this article: DOOM Ported to JavaScript and HTML5

Zakai compiled the DOOM source code from C to JavaScript using Emscripten and Clang and optimized it with Closure Compiler.

And here is the Project page. Have fun! :)

FYI, Emscripten does exactly that.

Need Your Help

How to change React Native cursor color?

ios react-native

I am using React Native and I would like to change the cursor color of a text input. I actually got the default blue color.

record/save audio from voice recognition intent

android speech-recognition speech-to-text

Before asking this question, I checked all stackoverflow other threads related to this issue without any success, so please, don't answer with links to other threads, :)