Emscripten

From Wikipedia, the free encyclopedia
Jump to navigation Jump to search
Emscripten
Emscripten logo.svg
Original author(s)Alon Zakai
Stable release
2.0.12 / 11 January 2021; 10 days ago (2021-01-11)[1]
Repository Edit this at Wikidata
Written inC, C++, JavaScript[2]
TypeCompiler
LicenseMIT License
Websiteemscripten.org Edit this on Wikidata

Emscripten is an LLVM-based compiler that compiles C and C++ source code to either WebAssembly[3] or a subset of JavaScript known as asm.js,[4] primarily for execution in web browsers.

Emscripten allows applications and libraries written in C or C++ to be compiled ahead of time and run efficiently in web browsers, typically at speeds comparable to or faster than interpreted or dynamically compiled JavaScript.

Usage[edit]

Emscripten has been used to port Unreal Engine 3, SQLite, MeshLab,[5] Bullet physics,[6] AutoCAD,[7] a subset of the Qt application framework,[8] and more.

Game engines[edit]

The Unity, Godot and Unreal game engines provide an export option to HTML5, utilizing Emscripten.[9][10][11]

Frameworks & toolkits[edit]

openFrameworks exports native C++ applications to HTML5 via Emscripten.[12] emscripten-qt allows you to compile applications written for the Qt application framework into JavaScript.[8]

Software archiving[edit]

In December 2014, the Internet Archive launched a DOSBox emulator compiled in Emscripten to provide browser-based access to thousands of archived MS-DOS and PC programs.[13][14][15]

See also[edit]

References[edit]

  1. ^ "Releases". emscripten-core/emscripten. GitHub. Retrieved 2021-01-21.
  2. ^ "emscripten-core/emscripten: Emscripten: An LLVM-to-JavaScript Compiler". C: 40.0%; C++: 34.4%; JavaScript: 17.4%.
  3. ^ https://github.com/kripken/emscripten/wiki/WebAssembly
  4. ^ Walton, Zach (2012-04-04). "Easily Port C++ To HTML5/JavaScript With Emscripten". WebProNews. iEntry Network. Archived from the original on 2013-07-30. Retrieved 2012-04-25.
  5. ^ http://www.meshlabjs.net - Homepage of the experimental, client based, javascript, version of MeshLab that runs inside a browser
  6. ^ "Porting Examples and Demos". Emscripten GitHub wiki. Retrieved 2016-03-01.
  7. ^ "The Future of AutoCAD". Through the Interface. Retrieved 2018-05-09.
  8. ^ a b "Qt for WebAssembly".
  9. ^ "Unity game engine heading to the browser without plug-ins". Ars Technica. Retrieved 2016-03-01.
  10. ^ "The future of scripting in Unity – Unity Blog". Unity Technologies Blog. Retrieved 2016-03-01.
  11. ^ "Tappy Chicken". www.unrealengine.com. Retrieved 2016-03-01.
  12. ^ "openFrameworks setup for Emscripten". openFrameworks. Retrieved 2016-03-04.
  13. ^ Ohlheiser, Abby (2015-01-05). "You can now play nearly 2,400 MS-DOS video games in your browser". Washington Post. Retrieved 2015-01-08.
  14. ^ Each New Boot a Miracle by Jason Scott (December 23, 2014)
  15. ^ "Internet Archive Search: "collection:softwarelibrary_msdos"". archive.org. Retrieved 2016-03-01.

External links[edit]