
language: cpp

env:
  - CONFIG=Release


install:
  - if [ "${TRAVIS_OS_NAME}" = "linux" ]; then
         wget --no-check-certificate http://www.cmake.org/files/v3.3/cmake-3.3.2-Linux-i386.tar.gz
      && tar -xzf cmake-3.3.2-Linux-i386.tar.gz
      && sudo cp -fR cmake-3.3.2-Linux-i386/* /usr
      && sudo apt-add-repository -y ppa:ubuntu-toolchain-r/test
      && sudo apt-add-repository -y ppa:beineri/opt-qt542
      && sudo apt-get -qq update
      && sudo apt-get -qq install g++-4.8 libc6-i386    qt54svg qt54tools  qt54serialport
      && export CXX="g++-4.8"
      && export CC="gcc-4.8"
      ;
    fi

script:
  -    mkdir build
    && cd build
    && if [ "${TRAVIS_OS_NAME}" = "linux" ]; then
         cmake -DCMAKE_BUILD_TYPE=$CONFIG -DENABLE_TRAVIS_CI=ON -DCMAKE_PREFIX_PATH=/opt/qt54/lib/cmake ..
         ;
       fi
    && make -j 3
    && cd ..
