.travis-build.sh 565 B

12345678910111213141516171819202122
  1. #!/bin/sh
  2. set -e
  3. set -x
  4. if grep -r '\s$' src *.yml *.txt *.md Doxyfile .gitignore .gitmodules .travis* dist/*.desktop \
  5. dist/*.svg dist/*.xml; then
  6. echo Trailing whitespace found, aborting
  7. exit 1
  8. fi
  9. #if OS is linux or is not set
  10. if [ "$TRAVIS_OS_NAME" = "linux" -o -z "$TRAVIS_OS_NAME" ]; then
  11. mkdir build && cd build
  12. cmake -DUSE_QT5=OFF ..
  13. make -j4
  14. elif [ "$TRAVIS_OS_NAME" = "osx" ]; then
  15. export Qt5_DIR=$(brew --prefix)/opt/qt5
  16. mkdir build && cd build
  17. cmake .. -GXcode
  18. xcodebuild -configuration Release
  19. fi