mount tracefs for alpine image #52
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build and Test on Linux Mac and Windows | |
| on: | |
| push: | |
| branches: [ master ] | |
| tags: "v*" | |
| env: | |
| BUILD_TYPE: Debug | |
| jobs: | |
| build: | |
| name: Test on ${{ matrix.config.os }} with ${{ matrix.config.cc }} | |
| runs-on: ${{ matrix.config.os }} | |
| env: | |
| CC: ${{ matrix.config.cc }} | |
| timeout-minutes: 5 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| config: | |
| - {os: ubuntu-24.04, cc: "gcc", cxx: "g++"} | |
| - {os: ubuntu-24.04, cc: "clang", cxx: "clang++"} | |
| - {os: windows-latest, cc: "cl", cxx: "cl"} | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Prints | |
| shell: bash | |
| run: | | |
| echo ${{ matrix.config.cc }} | |
| echo ${{ matrix.config.os }} | |
| ${{ matrix.config.cc }} --version 2>&1 || ${{ matrix.config.cc }} 2>&1 || true | |
| - name: Info | |
| run: echo ${{ github.ref }} | |
| - name: Configure CMake | |
| run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} | |
| - name: Build | |
| run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} | |
| - name: Test | |
| working-directory: ${{github.workspace}}/build | |
| run: ctest -C ${{env.BUILD_TYPE}} --output-on-failure | |
| coverage: | |
| name: Coverage on ubuntu-24.04 with gcc | |
| runs-on: ubuntu-24.04 | |
| needs: build | |
| env: | |
| CC: gcc | |
| CXX: g++ | |
| timeout-minutes: 5 | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Install dependencies | |
| run: sudo apt install libtbb-dev lcov | |
| - name: Configure CMake | |
| run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DWITH_COVERAGE=ON | |
| - name: Build | |
| run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} | |
| - name: Test | |
| working-directory: ${{github.workspace}}/build | |
| run: ctest -C ${{env.BUILD_TYPE}} --output-on-failure | |
| - name: Generate Coverage | |
| run: lcov -c --directory ${{github.workspace}}/build --output-file ${{github.workspace}}/build/coverage.info | |
| - name: Coveralls | |
| uses: coverallsapp/github-action@v2 | |
| with: | |
| github-token: ${{ secrets.GITHUB_TOKEN }} | |
| path-to-lcov: ${{github.workspace}}/build/coverage.info | |
| musl: | |
| name: Test on Alpine Linux (musl) | |
| runs-on: ubuntu-24.04 | |
| container: | |
| image: alpine:latest | |
| options: --volume /sys/kernel/tracing:/sys/kernel/tracing:ro | |
| timeout-minutes: 5 | |
| steps: | |
| - name: Install dependencies | |
| run: apk add --no-cache git cmake g++ make linux-headers | |
| - uses: actions/checkout@v6 | |
| - name: Prints | |
| run: g++ --version | |
| - name: Configure CMake | |
| run: cmake -B build -DCMAKE_BUILD_TYPE=Debug | |
| - name: Build | |
| run: cmake --build build | |
| - name: Test | |
| working-directory: build | |
| run: ctest --output-on-failure |