language: cpp
compiler:
  - gcc
  - clang
before_install:
  - sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test
  - if [ "$CXX" == "clang++"  ]; then sudo add-apt-repository -y 'deb http://llvm.org/apt/precise/ llvm-toolchain-precise-3.5 main'; fi
  - sudo apt-get update -qq
install:
  - sudo apt-get install liblua5.1-dev libncurses-dev libboost-dev libz-dev
  - if [ "$CXX" == "g++"  ]; then sudo apt-get install g++-4.9; fi
  - if [ "$CXX" == "g++"  ]; then export CXX="g++-4.9"; fi
  - if [ "$CXX" == "clang++"  ]; then sudo apt-get install --allow-unauthenticated libstdc++-4.9-dev clang-3.5; fi
  - if [ "$CXX" == "clang++"  ]; then export CXX="clang++-3.5"; fi
script: cmake . && make && make install

language: cpp
compiler:
  - gcc
  - clang
before_install:
  - sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test
  - if [ "$CXX" == "clang++"  ]; then sudo add-apt-repository -y 'deb http://llvm.org/apt/precise/ llvm-toolchain-precise-3.5 main'; fi
  - sudo apt-get update -qq
install:
  - sudo apt-get install liblua5.1-dev lua5.1 libncurses-dev libboost-dev libz-dev
  - if [ "$CXX" == "g++"  ]; then sudo apt-get install g++-4.9; fi
  - if [ "$CXX" == "g++"  ]; then export CXX="g++-4.9"; fi
  - if [ "$CXX" == "clang++"  ]; then sudo apt-get install --allow-unauthenticated libstdc++-4.9-dev clang-3.5; fi
  - if [ "$CXX" == "clang++"  ]; then export CXX="clang++-3.5"; fi
script:
  - cmake . && make && make install
  - echo "os.exit()" | lua -l color_coded

Test if lua can load the library
Test if lua can load the library

In addition to compiling the library file, we can also check if lua can
load it. This may reveal linker errors such as undefined references.
