regular_ci.yml 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146
  1. name: Dinit Regular CI
  2. on:
  3. push:
  4. branches:
  5. - master
  6. paths:
  7. - '**'
  8. - '!.*'
  9. - '!README.md'
  10. - '!NEWS'
  11. - '!BUILD*'
  12. - '!CONTRIBUTORS'
  13. - '!TODO'
  14. - '!LICENSE'
  15. - '!build/includes/README'
  16. - '!doc/CODE-STYLE'
  17. - '!doc/COMPARISON'
  18. - '!doc/CONTRIBUTING'
  19. - '!doc/DESIGN'
  20. - '!doc/getting_started.md'
  21. - '!doc/manpages/README'
  22. - '!doc/manpages/generate-html.sh'
  23. - '!doc/manpages/DINIT-AS-INIT.md'
  24. - '!doc/linux/**'
  25. pull_request:
  26. branches:
  27. - master
  28. paths:
  29. - '**'
  30. - '!.*'
  31. - '!README.md'
  32. - '!NEWS'
  33. - '!BUILD*'
  34. - '!CONTRIBUTORS'
  35. - '!TODO'
  36. - '!LICENSE'
  37. - '!build/includes/README'
  38. - '!doc/CODE-STYLE'
  39. - '!doc/COMPARISON'
  40. - '!doc/CONTRIBUTING'
  41. - '!doc/DESIGN'
  42. - '!doc/getting_started.md'
  43. - '!doc/manpages/README'
  44. - '!doc/manpages/generate-html.sh'
  45. - '!doc/manpages/DINIT-AS-INIT.md'
  46. - '!doc/linux/**'
  47. workflow_dispatch:
  48. jobs:
  49. Debian-bullseye_build:
  50. runs-on: ubuntu-latest
  51. container:
  52. image: debian:bullseye
  53. strategy:
  54. matrix:
  55. include:
  56. - arch: 'amd64'
  57. - arch: 'i386'
  58. steps:
  59. - uses: actions/checkout@v3
  60. - name: Add i386 repos
  61. if: ${{ matrix.arch == 'i386' }}
  62. run: dpkg --add-architecture i386
  63. - name: Getting depends (amd64)
  64. if: ${{ matrix.arch == 'amd64' }}
  65. run: |
  66. apt-get update
  67. apt-get install g++ make m4 file -y
  68. - name: Getting depends (i386)
  69. if: ${{ matrix.arch == 'i386' }}
  70. run: |
  71. apt-get update
  72. apt-get install gcc:i386 make:i386 m4:i386 g++:i386 file -y
  73. - name: Print g++ architecture
  74. run: g++ -dumpmachine
  75. - name: Build
  76. run: make
  77. - name: Print dinit executive file architecture
  78. run: file ./src/dinit
  79. - name: Unit tests
  80. run: make check
  81. - name: Integration tests
  82. run: make check-igr
  83. MacOS-latest_build:
  84. runs-on: macos-latest
  85. strategy:
  86. matrix:
  87. include:
  88. - arch: 'amd64'
  89. steps:
  90. - uses: actions/checkout@v3
  91. # on MacOS, g++ symlinked to clang++
  92. # We must verify that
  93. - name: Verify g++ (it is g++ or clang++?)
  94. run: g++ --version
  95. - name: Print g++ architecture
  96. run: g++ -dumpmachine
  97. - name: Build
  98. run: make
  99. - name: Print dinit executive file architecture
  100. run: file ./src/dinit
  101. - name: Unit tests
  102. run: make check
  103. - name: Integration tests
  104. run: make check-igr
  105. Alpine-latest_build:
  106. runs-on: ubuntu-latest
  107. strategy:
  108. matrix:
  109. include:
  110. - arch: 'armv6'
  111. - arch: 'armv7'
  112. - arch: 'aarch64'
  113. steps:
  114. - uses: actions/checkout@v3
  115. - uses: uraimo/run-on-arch-action@v2.3.0
  116. name: Getting depends & build & unit tests & integration tests
  117. with:
  118. arch: ${{ matrix.arch }}
  119. distro: alpine_latest
  120. run: |
  121. apk add ncurses
  122. echo "$(tput bold) !---- ${{ matrix.arch }} BUILD ----!$(tput sgr0)"
  123. echo "$(tput bold) ----Getting depends---- :$(tput sgr0) apk update && apk add make g++ m4 file"
  124. apk update
  125. apk add make g++ m4 file
  126. echo "$(tput bold) ----Print g++ arch---- :$(tput sgr0) g++ -dumpmachine"
  127. g++ -dumpmachine
  128. echo "$(tput bold) ----Build---- :$(tput sgr0) make"
  129. make
  130. echo "$(tput bold) ----Print dinit executive file architecture---- :$(tput sgr0) file ./src/dinit"
  131. file ./src/dinit
  132. echo "$(tput bold) ----Unit tests---- :$(tput sgr0) make check"
  133. make check
  134. echo "$(tput bold) ----Integration tests---- :$(tput sgr0) make check-igr"
  135. make check-igr