Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
**/*~
**/*.tmproj
_build
_build
ml-proto/ocaml
11 changes: 11 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
language: c++

sudo: off

install: ./ml-proto/travis/install-ocaml.sh

script: ./ml-proto/travis/build-test.sh

os:
- linux
- osx
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
[![Build Status](https://travis-ci.org/WebAssembly/spec.svg?branch=master)](https://travis-ci.org/WebAssembly/spec)

# spec

This repository holds the official specifications and reference implementations
Expand Down
24 changes: 24 additions & 0 deletions ml-proto/travis/build-test.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
#!/bin/bash

set -e
set -x

# Move to a location relative to the script so it runs
# from anywhere.
cd $(dirname ${BASH_SOURCE[0]})/..

export PATH=$PWD/ocaml/install/bin:$PATH

cd src

make clean
rm -f lexer.ml
rm -f parser.ml
rm -f parser.mli

ocamlbuild -libs bigarray main.native
make

cd ..

./runtests.py
18 changes: 18 additions & 0 deletions ml-proto/travis/install-ocaml.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#!/bin/bash

set -e

# Move to a location relative to the script so it runs
# from anywhere.
cd $(dirname ${BASH_SOURCE[0]})/..

rm -rf ocaml
mkdir ocaml
cd ocaml
curl http://caml.inria.fr/pub/distrib/ocaml-4.02/ocaml-4.02.2.tar.gz -O
tar xfz ocaml-4.02.2.tar.gz
cd ocaml-4.02.2
./configure -prefix $PWD/../install
make world.opt
mkdir ../install
make install