Permalink
Browse files

updated build howto

  • Loading branch information...
1 parent 09b964f commit e20b5a3f5fe2021874639f9ee8d6fd5e0ca144ff @mnaamani committed Dec 16, 2012
Showing with 20 additions and 15 deletions.
  1. +20 −15 BUILDING
View
@@ -1,26 +1,31 @@
Building the libotr4.js
-Setup Emscripten, LLVM+clang
+1. [Setup Emscripten + LLVM clang compilers](https://github.com/kripken/emscripten/wiki/Tutorial)
+
+2. [Setup crypto-emscripten build script](https://github.com/mnaamani/crypto-emscripten).
+This will be used to compile libgpg-error,libgcrypt and libotr into bitcode.
+
+In the root directory of crypto-emscripten folder, edit **build-libs.sh** and set *LIBOTR_VERSION* to *4.0.0*.
- https://github.com/kripken/emscripten/wiki/Tutorial
+Then run the build script.
-Build libgpg-error,libgcrypt and libotr using crypto-emscripten tool:
-edit the ./build-libs script to specify version 4.0.0 of libotr
+ ./build-libs.sh
+ export CRYPTO_EMSCRIPTEN=`pwd`
- cd $HOME
- git clone https://github.com/mnaamani/crypto-emscripten/
- cd crypto-emscripten/
- ./build-libs
+3. Get the source of otr4-em and make the module.
-Edit Makefile with location of where you installed emscripten, and crypto-emscripten, eg.
+ git clone https://github.com/mnaamani/otr4-em.git
+ cd otr4-em/
- EMCC = PATH_TO_EMSCRIPTEN/emcc
- CRYPTO_BUILD = $(HOME)/crypto-emscripten/build
+Either run:
+
+ make -e #this will use the environement variable exported in step 2 to locate crypto-emscripten
+
+..or
+
+ make CRYPTO_EMSCRIPTEN=/path/to/crypto-emscripten
-build libotr4.js:
-
- make module
-test it:
+4. Run a test
node test

0 comments on commit e20b5a3

Please sign in to comment.