.travis.yml 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153
  1. # Declare python as our language. This way we get our chosen Python version,
  2. # and pip is available. Gcc and clang are available anyway.
  3. language: python
  4. python: 3.5
  5. sudo: false
  6. cache: ccache
  7. jobs:
  8. include:
  9. - name: basic checks and reference configurations
  10. addons:
  11. apt:
  12. packages:
  13. - gnutls-bin
  14. - doxygen
  15. - graphviz
  16. - gcc-arm-none-eabi
  17. - libnewlib-arm-none-eabi
  18. - gcc-arm-linux-gnueabi
  19. - libc6-dev-armel-cross
  20. script:
  21. - tests/scripts/all.sh -k 'check_*'
  22. - tests/scripts/all.sh -k test_default_out_of_box
  23. - tests/scripts/all.sh -k test_ref_configs
  24. - tests/scripts/all.sh -k build_arm_linux_gnueabi_gcc_arm5vte build_arm_none_eabi_gcc_m0plus
  25. - name: full configuration
  26. os: linux
  27. dist: focal
  28. addons:
  29. apt:
  30. packages:
  31. - clang-10
  32. - gnutls-bin
  33. script:
  34. # Do a manual build+test sequence rather than using all.sh,
  35. # because there's no all.sh component that does what we want,
  36. # which is a build with Clang >= 10 and ASan, running all the SSL
  37. # testing.
  38. # - The clang executable in the default PATH is Clang 7 on
  39. # Travis's focal instances, but we want Clang >= 10.
  40. # - Running all the SSL testing requires a specific set of
  41. # OpenSSL and GnuTLS versions and we don't want to bother
  42. # with those on Travis.
  43. # So we explicitly select clang-10 as the compiler, and we
  44. # have ad hoc restrictions on SSL testing based on what is
  45. # passing at the time of writing. We will remove these limitations
  46. # gradually.
  47. - make generated_files
  48. - make CC=clang-10 CFLAGS='-Werror -Wall -Wextra -fsanitize=address,undefined -fno-sanitize-recover=all -O2' LDFLAGS='-Werror -Wall -Wextra -fsanitize=address,undefined -fno-sanitize-recover=all'
  49. - make test
  50. - programs/test/selftest
  51. - tests/scripts/test_psa_constant_names.py
  52. - tests/ssl-opt.sh
  53. # Modern OpenSSL does not support null ciphers.
  54. - tests/compat.sh -p OpenSSL -e 'NULL'
  55. - tests/scripts/travis-log-failure.sh
  56. # GnuTLS supports CAMELLIA but compat.sh doesn't properly enable it.
  57. - tests/compat.sh -p GnuTLS -e 'CAMELLIA'
  58. - tests/scripts/travis-log-failure.sh
  59. - tests/context-info.sh
  60. - name: Windows
  61. os: windows
  62. # The language 'python' is currently unsupported on the
  63. # Windows Build Environment. And 'generic' causes the job to get stuck
  64. # on "Booting virtual machine".
  65. language: c
  66. before_install:
  67. - choco install python --version=3.5.4
  68. env:
  69. # Add the directory where the Choco packages go
  70. - PATH=/c/Python35:/c/Python35/Scripts:$PATH
  71. - PYTHON=python.exe
  72. script:
  73. - type perl; perl --version
  74. - type python; python --version
  75. - scripts/make_generated_files.bat
  76. # Logs appear out of sequence on Windows. Give time to catch up.
  77. - sleep 5
  78. - scripts/windows_msbuild.bat v141 # Visual Studio 2017
  79. - visualc/VS2013/x64/Release/selftest.exe
  80. - name: full configuration on arm64
  81. os: linux
  82. dist: focal
  83. arch: arm64
  84. addons:
  85. apt:
  86. packages:
  87. - gcc
  88. script:
  89. # Do a manual build+test sequence rather than using all.sh.
  90. #
  91. # On Arm64 host of Travis CI, the time of `test_full_cmake_*` exceeds
  92. # limitation of Travis CI. Base on `test_full_cmake_*`, we removed
  93. # `ssl-opt.sh` and GnuTLS compat.sh here to meet the time limitation.
  94. - scripts/config.py full
  95. - make generated_files
  96. - make CFLAGS='-O3 -Werror -fsanitize=address,undefined -fno-sanitize-recover=all' LDFLAGS='-Werror -fsanitize=address,undefined -fno-sanitize-recover=all'
  97. - make test
  98. - programs/test/selftest
  99. - tests/scripts/test_psa_constant_names.py
  100. # Modern OpenSSL does not support fixed ECDH or null ciphers.
  101. - tests/compat.sh -p OpenSSL -e 'NULL\|ECDH_'
  102. - tests/scripts/travis-log-failure.sh
  103. - tests/context-info.sh
  104. - name: full configuration(GnuTLS compat tests) on arm64
  105. os: linux
  106. dist: focal
  107. arch: arm64
  108. addons:
  109. apt:
  110. packages:
  111. - clang
  112. - gnutls-bin
  113. script:
  114. # Do a manual build+test sequence rather than using all.sh.
  115. #
  116. # On Arm64 host of Travis CI, the time of `test_full_cmake_*` exceeds
  117. # limitation of Travis CI. Base on `test_full_cmake_*`, we removed
  118. # `ssl-opt.sh` and OpenSSl compat.sh here to meet the time limitation.
  119. - scripts/config.py full
  120. - make generated_files
  121. - make CC=clang CFLAGS='-O3 -Werror -fsanitize=address,undefined -fno-sanitize-recover=all' LDFLAGS='-Werror -fsanitize=address,undefined -fno-sanitize-recover=all'
  122. # GnuTLS supports CAMELLIA but compat.sh doesn't properly enable it.
  123. - tests/compat.sh -p GnuTLS -e 'CAMELLIA'
  124. - tests/scripts/travis-log-failure.sh
  125. - tests/context-info.sh
  126. after_failure:
  127. - tests/scripts/travis-log-failure.sh
  128. env:
  129. global:
  130. - SEED=1
  131. - secure: "JECCru6HASpKZ0OLfHh8f/KXhKkdrCwjquZghd/qbA4ksxsWImjR7KEPERcaPndXEilzhDbKwuFvJiQX2duVgTGoq745YGhLZIjzo1i8tySkceCVd48P8WceYGz+F/bmY7r+m6fFNuxDSoGGSVeA4Lnjvmm8PFUP45YodDV9no4="
  132. install:
  133. - $PYTHON scripts/min_requirements.py
  134. addons:
  135. apt:
  136. packages:
  137. - gnutls-bin
  138. coverity_scan:
  139. project:
  140. name: "ARMmbed/mbedtls"
  141. notification_email: support-mbedtls@arm.com
  142. build_command_prepend:
  143. build_command: make
  144. branch_pattern: coverity_scan