name: Ubuntu armv7 (GCC 11)

on:
  push:
    branches:
      - master
  pull_request:
    branches:
      - master

jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: uraimo/run-on-arch-action@v3
        name: Test
        id: runcmd
        with:
          arch: armv7
          githubToken: ${{ github.token }}
          distro: ubuntu24.04
          install: |
            apt-get update -q -y
            apt-get install -y cmake make g++
          run: |
            cmake -B build -DSIMDUTF_FAST_TESTS=On
            cmake --build build -j=$(nproc)
            ctest --output-on-failure --test-dir build -j=$(nproc)
            cmake -DCMAKE_CXX_FLAGS="-fstack-protector-strong -fno-strict-aliasing" -B buildprotected -DSIMDUTF_FAST_TESTS=On
            cmake --build buildprotected -j=$(nproc)
            ctest --output-on-failure --test-dir buildprotected -j=$(nproc)
