.travis.yml 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121
  1. language: cpp
  2. # OS config, depends on actual 'os' in build matrix
  3. dist: xenial
  4. sudo: false
  5. env:
  6. global:
  7. - SCONS_CACHE=$HOME/.scons_cache/$TRAVIS_BRANCH
  8. - SCONS_CACHE_LIMIT=1024
  9. - OPTIONS="debug_symbols=no verbose=yes progress=no"
  10. - secure: "uch9QszCgsl1qVbuzY41P7S2hWL2IiNFV4SbAYRCdi0oJ9MIu+pVyrQdpf3+jG4rH6j4Rffl+sN17Zz4dIDDioFL1JwqyCqyCyswR8uACC0Rr8gr4Mi3+HIRbv+2s2P4cIQq41JM8FJe84k9jLEMGCGh69w+ibCWoWs74CokYVA="
  11. cache:
  12. directories:
  13. - $SCONS_CACHE
  14. matrix:
  15. include:
  16. - env: STATIC_CHECKS=yes
  17. os: linux
  18. compiler: gcc
  19. addons:
  20. apt:
  21. sources:
  22. - llvm-toolchain-xenial-6.0
  23. packages:
  24. - clang-format-6.0
  25. - env: PLATFORM=x11 TOOLS=yes TARGET=debug CACHE_NAME=${PLATFORM}-tools-mono-gcc-8 MATRIX_EVAL="CC=gcc-8 && CXX=g++-8" EXTRA_ARGS="module_mono_enabled=yes mono_glue=no warnings=extra werror=yes"
  26. os: linux
  27. compiler: gcc-8
  28. addons:
  29. apt:
  30. sources:
  31. - mono
  32. - ubuntu-toolchain-r-test
  33. packages:
  34. - &gcc8_deps [gcc-8, g++-8]
  35. - &linux_deps [libasound2-dev, libfreetype6-dev, libgl1-mesa-dev, libglu1-mesa-dev, libx11-dev, libxcursor-dev, libxi-dev, libxinerama-dev, libxrandr-dev]
  36. - &linux_mono_deps [mono-devel, msbuild, nuget]
  37. coverity_scan:
  38. project:
  39. name: "godotengine/godot"
  40. description: "Godot Engine Coverity scans"
  41. notification_email: coverity@godotengine.org
  42. build_command_prepend: ""
  43. build_command: "scons p=x11 -j2 $OPTIONS"
  44. branch_pattern: coverity_scan
  45. - env: PLATFORM=x11 TOOLS=no TARGET=release CACHE_NAME=${PLATFORM}-clang EXTRA_ARGS="warnings=extra werror=yes"
  46. os: linux
  47. compiler: clang
  48. addons:
  49. apt:
  50. packages:
  51. - *linux_deps
  52. - env: PLATFORM=android TOOLS=no TARGET=release_debug CACHE_NAME=${PLATFORM}-clang EXTRA_ARGS="warnings=extra werror=yes"
  53. os: linux
  54. compiler: clang
  55. - env: PLATFORM=osx TOOLS=yes TARGET=debug CACHE_NAME=${PLATFORM}-tools-clang
  56. os: osx
  57. compiler: clang
  58. - env: PLATFORM=iphone TOOLS=no TARGET=debug CACHE_NAME=${PLATFORM}-clang
  59. os: osx
  60. compiler: clang
  61. - env: PLATFORM=server TOOLS=yes TARGET=release_debug CACHE_NAME=${PLATFORM}-tools-gcc-8 MATRIX_EVAL="CC=gcc-8 && CXX=g++-8" EXTRA_ARGS="warnings=extra werror=yes"
  62. os: linux
  63. compiler: gcc-8
  64. addons:
  65. apt:
  66. sources:
  67. - ubuntu-toolchain-r-test
  68. packages:
  69. - *gcc8_deps
  70. - *linux_deps
  71. - env: PLATFORM=x11 TOOLS=no TARGET=release_debug CACHE_NAME=${PLATFORM}-gcc-5
  72. os: linux
  73. compiler: gcc
  74. addons:
  75. apt:
  76. packages:
  77. - *linux_deps
  78. before_install:
  79. - eval "${MATRIX_EVAL}"
  80. - if [ "$STATIC_CHECKS" = "yes" ]; then
  81. unset SCONS_CACHE;
  82. fi
  83. install:
  84. - pip install --user scons;
  85. - if [ "$TRAVIS_OS_NAME" = "linux" ] && [ "$PLATFORM" = "android" ]; then
  86. misc/travis/android-tools-linux.sh;
  87. fi
  88. - if [ "$TRAVIS_OS_NAME" = "osx" ]; then
  89. export PATH=${PATH}:/Users/travis/Library/Python/2.7/bin;
  90. fi
  91. - if [ "$TRAVIS_OS_NAME" = "osx" ] && [ "$PLATFORM" = "android" ]; then
  92. misc/travis/android-tools-osx.sh;
  93. fi
  94. before_script:
  95. - if [ "$PLATFORM" = "android" ]; then
  96. export ANDROID_HOME=$TRAVIS_BUILD_DIR/godot-dev/build-tools/android-sdk;
  97. export ANDROID_NDK_ROOT=$TRAVIS_BUILD_DIR/godot-dev/build-tools/android-ndk;
  98. fi
  99. script:
  100. - if [ "$STATIC_CHECKS" = "yes" ]; then
  101. sh ./misc/travis/clang-format.sh;
  102. else
  103. scons -j2 CC=$CC CXX=$CXX platform=$PLATFORM tools=$TOOLS target=$TARGET $OPTIONS $EXTRA_ARGS;
  104. fi