CI-unixish-docker.yml: perform make and CMake builds in parallel (#4415)

* CI-unixish-docker.yml: perform make and CMake builds in parallel

* CI-unixish-docker.yml: cleanups

* CI-unixish-docker.yml: only install necessary packages
This commit is contained in:
Oliver Stöneberg 2022-08-29 12:27:23 +02:00 committed by GitHub
parent eab60668fd
commit 6c72a27c2c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 31 additions and 6 deletions

View File

@ -8,7 +8,7 @@ permissions:
contents: read contents: read
jobs: jobs:
build: build_cmake:
strategy: strategy:
matrix: matrix:
@ -26,15 +26,13 @@ jobs:
- name: Install missing software on CentOS 7 - name: Install missing software on CentOS 7
if: matrix.image == 'centos:7' if: matrix.image == 'centos:7'
run: | run: |
yum install -y cmake gcc-c++ make which python3 yum install -y cmake gcc-c++ make pcre-devel
yum install -y pcre-devel
- name: Install missing software on ubuntu - name: Install missing software on ubuntu
if: matrix.image != 'centos:7' if: matrix.image != 'centos:7'
run: | run: |
apt-get update apt-get update
apt-get install -y cmake g++ make python3 libxml2-utils apt-get install -y cmake g++ make libxml2-utils libpcre3-dev
apt-get install -y libpcre3-dev
# required so a default Qt installation is configured # required so a default Qt installation is configured
- name: Install missing software on ubuntu 18.04 - name: Install missing software on ubuntu 18.04
@ -61,9 +59,34 @@ jobs:
cmake --build . --target check -- -j$(nproc) cmake --build . --target check -- -j$(nproc)
cd .. cd ..
build_make:
strategy:
matrix:
image: ["centos:7", "ubuntu:14.04", "ubuntu:16.04", "ubuntu:18.04"]
fail-fast: false # Prefer quick result
runs-on: ubuntu-22.04
container:
image: ${{ matrix.image }}
steps:
- uses: actions/checkout@v2
- name: Install missing software on CentOS 7
if: matrix.image == 'centos:7'
run: |
yum install -y gcc-c++ make which python3 pcre-devel
- name: Install missing software on ubuntu
if: matrix.image != 'centos:7'
run: |
apt-get update
apt-get install -y g++ make python3 libxml2-utils libpcre3-dev
- name: Build cppcheck - name: Build cppcheck
run: | run: |
make clean
make -j$(nproc) HAVE_RULES=yes make -j$(nproc) HAVE_RULES=yes
- name: Build test - name: Build test
@ -74,10 +97,12 @@ jobs:
run: | run: |
make -j$(nproc) check HAVE_RULES=yes make -j$(nproc) check HAVE_RULES=yes
# requires python3
- name: Run extra tests - name: Run extra tests
run: | run: |
tools/generate_and_run_more_tests.sh tools/generate_and_run_more_tests.sh
# requires which
- name: Validate - name: Validate
run: | run: |
make -j$(nproc) checkCWEEntries validateXML make -j$(nproc) checkCWEEntries validateXML