Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Installing Emscripten on Ubuntu

I am trying to install Emscripten on Ubuntu, but the official installation guide for Emscripten doesn't offer any instructions for installing Emscripten on Linux. The only advice that the installation guide has to offer is:

If you are on Linux, things should be very simple for you and there is no need for any additional guide.

I have read the README.md file in the Emscripten repository as well, and it doesn't offer any instructions for Ubuntu either. What steps will I need to follow in order to set up Emscripten on Ubuntu?

like image 799
Anderson Green Avatar asked Feb 15 '13 20:02

Anderson Green


2 Answers

For Ubuntu 12.04 it is also very easy.

  1. go to http://llvm.org/releases/download.html and download LLVM 3.2 (Clang Binaries for Ubuntu-12.04/x86) LLVM is integrated
  2. extract it to a place you like eg. ~/opt/dev/llvm
  3. add this to your .profile PATH="$PATH:/home/[your_profile]/opt/dev/llvm/clang3.2/bin"
  4. make sure you have nodejs installed
  5. follow the instructions for the emscripten installation

thats all

if you get /usr/include/features.h:324:10: fatal error: 'bits/predefs.h' file not found simply install sudo apt-get install libc6-dev-i386

like image 78
dustin.b Avatar answered Sep 28 '22 17:09

dustin.b


For getting started with clang 3.2 I assume you are running Ubuntu 12.10. 13.04 already has clang 3.2 packaged, so I would recommend using these package(s).

There are two ways of getting them:

  1. Installing/Upgrading selected packages of Ubuntu 13.04 (minor intrusive)

    • Add deb http://archive.ubuntu.com/ubuntu/ raring main restricted universe multiverse to your sources.
    • Update your package info (e.g. sudo apt-get update)
    • Install only the needed package and dependencies (e.g. sudo apt-get install clang-3.2)
    • Disable the source entry, added before.
  2. Upgrade/Install Ubuntu to 13.04+

EDIT:

Update to current situation.

like image 43
abergmeier Avatar answered Sep 28 '22 16:09

abergmeier