language:
  - cpp

sudo: false

compiler:
  - clang
  - gcc

os:
  - linux
  - osx

branches:
  only:
    - master
    - dev

addons:
  apt:
    sources:
      - ubuntu-toolchain-r-test
    packages:
      - g++-4.9

install:
  - echo "BUILDER = $BUILDER"
  - echo "BOARD = $BOARD"
  - echo "CONF = $CONF"
  - pip install --user lutin

env:
  matrix:
    - CONF=debug BOARD=Linux
    #- CONF=debug BOARD=Windows
    #- CONF=debug BOARD=Android
    - CONF=release BOARD=Linux
    #- CONF=release BOARD=Windows
    #- CONF=release BOARD=Android
  exclude:
    - compiler: clang
      env: BOARD=Windows
    - compiler: clang
      env: BOARD=Android

before_script:
  - cd ..
  - mkdir bin
  - curl https://storage.googleapis.com/git-repo-downloads/repo > bin/repo
  - chmod a+x bin/repo
  - git config --global user.email "travis@travis.com"
  - git config --global user.name "Travis"
  - git config --global color.ui "auto"
  - git config --global core.editor "vi"
  - mkdir framework
  - cd framework
  - ../bin/repo init -u https://github.com/HeeroYui/manifest.git
  - ../bin/repo sync -j8
  - cd ..
  - pwd
  - ls -l
  - if [ "$CXX" == "clang++" ]; then BUILDER=clang; else BUILDER=gcc; fi
  - if [ "$CXX" == "g++" ]; then COMPILATOR_OPTION="--compilator-version=4.9"; else COMPILATOR_OPTION=""; fi

script: 
  - lutin -C -P -t $BOARD -c $BUILDER $COMPILATOR_OPTION -m $CONF -p edn

notifications:
  email:
    - yui.heero@gmail.com
