language: java
dist: trusty
jdk:
- oraclejdk8
before_install:
- sudo apt-key update
- sudo apt-get update -qq
- sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test
- sudo apt-get update; sudo apt-get install -y gcc-4.8 g++-4.8
- sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.8 20
- sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-4.8 20
- sudo update-alternatives --config gcc
- sudo update-alternatives --config g++
- mkdir $HOME/usr
- export PATH="$HOME/usr/bin:$PATH"
- wget https://cmake.org/files/v3.7/cmake-3.7.2-Linux-x86_64.sh
- chmod +x cmake-3.7.2-Linux-x86_64.sh
- "./cmake-3.7.2-Linux-x86_64.sh --prefix=$HOME/usr --exclude-subdir --skip-license"
install:
- sudo apt-get -y update
- sudo apt-get -y install mono-runtime mono-mcs
- sudo wget http://master.dl.sourceforge.net/project/d-apt/files/d-apt.list -O /etc/apt/sources.list.d/d-apt.list
- sudo sh -c 'curl https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key
  add -'
- sudo sh -c 'curl https://storage.googleapis.com/download.dartlang.org/linux/debian/dart_stable.list
  > /etc/apt/sources.list.d/dart_stable.list'
- sudo apt-get update && sudo apt-get -y --allow-unauthenticated install --reinstall
  d-apt-keyring && sudo apt-get update
#- sudo apt-get -y install dmd-bin dart
- sudo apt-get -y install dart
- wget http://haxe.org/website-content/downloads/3.4.2/downloads/haxe-3.4.2-linux64.tar.gz
- wget http://nekovm.org/media/neko-2.1.0-linux64.tar.gz
- tar xzf haxe-3.4.2-linux64.tar.gz
- tar xzf neko-2.1.0-linux64.tar.gz
- nvm install 8 || true
- nvm use 8 || true
before_script:
- export HAXE_STD_PATH=$PWD/haxe-3.4.2/std
- export HAXELIB_PATH=$PWD/haxe-3.4.2/lib
- export LD_LIBRARY_PATH=$PWD/neko-2.1.0-linux64
- export NEKOPATH=$PWD/neko-2.1.0-linux64
- export HAXEPATH=$PWD/haxe-3.4.2
- export PATH=$HAXEPATH:$NEKOPATH:$PATH
- haxelib --quiet --always setup $HAXELIB_PATH
- haxelib --quiet --always install hxcpp > /dev/null
- ls -la $PWD
- ls -la $PWD/haxe-3.4.2
- g++ --version || true
- which java || true
- java -version || true
- which haxe || true
- haxe -version || true
- which neko || true
- neko -version || true
- which nvm || true
- nvm --version || true
- which node || true
- node --version || true
#- dmd --version || true
- "./gradlew --version"
script:
- "./gradlew -s -i check install"
- pushd jtransc-main-run/example
- "./run"
- popd
- pushd jtransc-main-run/example-gradle
- "../../gradlew runPlainJs && node build/jtransc-js/program.js"
- popd
- pushd jtransc-main-run/example-gradle-multi
- "./gradlew runPlainJs && node build/jtransc-js/program.js"
- popd
- pushd jtransc-maven-plugin/example
- mvn package
- node target/jtransc-js/program.js
- popd
#after_success:
#  - bash <(curl -s https://codecov.io/bash)
notifications:
  webhooks:
    urls:
    - secure: jTXtftO3t28zsQyTs7ZkKAms3qYvP4BuhWP2PjDJlM7cMRtRc3tJX/S9useSOnlu9CgKb3tEWuUIlHYdbQWitf4Z1SgBZa6Lskjkiac+gsN88rC3XqoHsrfGdGO/q0My+8MzvOU85ljjrEd07GmhKf6tsYI7c/thY3AQ2Pb6SRZP8tk9jnW2BTKgLrpU0IxuvnGCXBLLtrF8rbw6r1uRqODeE9yy1P6t3HTFR1abzmmMkuBsMGgyw3KE86n+hjH6L0xj+SIRhWyihzVqTTjIkDkqXdkOCd6IJIdAE0lRpUSBPi14oLAEWllDEhvUTieKeUUfzHDLXJjF36ZcEJCGCFuyJRCVmVGLVhcIASxhKZmovQGw7xxM70tLyeCYV+KMDiG9qsJPwr64Vhoo7lhve/buyVFuytIW88RIY42WBFEHWcry9Kj4m0XIDTGgwUtU3pOF64aRWkSLe6gvsKbW2dhxlNY0KQ2Swht5wdyU0AII4f5T7FOiEjo3Yus4Nc+C+qALkl2X2Hd03wf50ztDjCnejlghmWVtGV8r7peOkCBSip8DMHaWSv42in02IYc5qGAmFPTVSGVHRG6nCviiX4mv0PTF5yu2DfTHfOpyX+CltRRHH/O1SIRUVSq2YC6AEKBadB6Y4CMKsOoOyGIV8p1TL6VnI52BtcgGXF+ZrmQ=
    on_success: change
    on_failure: always
    on_start: never
