.travis.yml 2.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. language: c
  2. compiler:
  3. - gcc
  4. env:
  5. global:
  6. #this is the encrypted GITAUTH
  7. - secure: "nSunY54Wp5HkQCHHbKwlwpbaKyqRVIu/0EnhaoJSwhM1wqerQV/E5d/2JelO9/tZgbungAO7wk/fjutRMVc7d378RTIPwS8vHpvZfEoGhCFsLoTOlqESzsZFBup2H5t1lpQ23jRHDOxlLdJy2lz5U+zd1YnYgDXqdDFjegsIYdo="
  8. # The next declaration is the encrypted COVERITY_SCAN_TOKEN, created
  9. - secure: "ehswgymGXPM3UINhOOnfSByMnrRNTixeT2vEV+z3kXy3WHew/O1yt9GxaYGrUhJPg4+5chAQgjYmezO1x3/CUKFgeHQUmVTFWEzfy1kL1JVjO+ufYyJDnbY+x3OmyNmMYcef2J5MAuUS2C1KFvIxtLsljVK+gpe4LcylkCIF/3Y="
  10. addons:
  11. coverity_scan:
  12. project:
  13. name: acplt/open62541
  14. description: Open-source OPC UA
  15. notification_email: null@plt.rwth-aachen.de
  16. build_command_prepend: mkdir build && cd build && cmake ..
  17. build_command: make
  18. branch_pattern: coverity_scan
  19. before_install:
  20. - sudo apt-get install binutils-mingw-w64-i686 gcc-mingw-w64-i686
  21. - sudo add-apt-repository ppa:ubuntu-toolchain-r/test -y
  22. - sudo add-apt-repository ppa:kalakris/cmake -y
  23. - sudo apt-get update -qq
  24. - sudo apt-get install -qq gcc-4.8
  25. - sudo apt-get install -qq --no-install-recommends build-essential cmake python-lxml graphviz doxygen wget
  26. - wget http://security.ubuntu.com/ubuntu/pool/main/c/check/check_0.9.10-6ubuntu3_amd64.deb
  27. - sudo dpkg -i check_0.9.10-6ubuntu3_amd64.deb
  28. - wget https://launchpad.net/ubuntu/+source/liburcu/0.8.5-1ubuntu1/+build/6513813/+files/liburcu2_0.8.5-1ubuntu1_amd64.deb
  29. - wget https://launchpad.net/ubuntu/+source/liburcu/0.8.5-1ubuntu1/+build/6513813/+files/liburcu-dev_0.8.5-1ubuntu1_amd64.deb
  30. - sudo dpkg -i liburcu2_0.8.5-1ubuntu1_amd64.deb
  31. - sudo dpkg -i liburcu-dev_0.8.5-1ubuntu1_amd64.deb
  32. - sudo pip install cpp-coveralls
  33. - sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.8 20
  34. - sudo update-alternatives --config gcc
  35. script:
  36. - echo "Checking the applicability of patches"
  37. - ./tools/.checkPorts.sh
  38. - echo "Testing builds"
  39. - mkdir -p build
  40. - cd build
  41. - echo "Cross compile build for MinGW"
  42. - cmake -DCMAKE_TOOLCHAIN_FILE=../cmake/Toolchain-mingw32.cmake -DEXAMPLESERVER=ON ..
  43. - make -j
  44. - cd .. && rm build -rf && mkdir -p build && cd build
  45. - echo "Compile multithreaded version"
  46. - cmake -DMULTITHREADING=ON -DEXAMPLESERVER=ON ..
  47. - make -j
  48. - cd .. && rm build -rf && mkdir -p build && cd build
  49. - echo "Production build"
  50. - cmake -DEXAMPLESERVER=ON -DEXTENSION_STATELESS=ON -DGENERATE_DOCUMENTATION=ON ..
  51. - make -j
  52. - echo "Generate documentation"
  53. - make -j doc
  54. - echo "Debug build and unit tests (64 bit)"
  55. - make clean
  56. - cmake -DCMAKE_BUILD_TYPE=Debug -DENABLE_UNIT_TESTS=ON -DENABLE_COVERAGE=ON ..
  57. - make -j && make test
  58. - coveralls --gcov /usr/bin/gcov-4.8 -E '.*\.h' -E '.*CMakeCXXCompilerId\.cpp' -E '.*CMakeCCompilerId\.c' -r ../
  59. - cd ..
  60. after_success:
  61. - ./tools/.deployDoxygen.sh
  62. - ./tools/.coverity.sh