Skip to content

Commit 30734db

Browse files
committed
Add matrix compiler for each action containers
1 parent 32f4ec3 commit 30734db

File tree

4 files changed

+34
-37
lines changed

4 files changed

+34
-37
lines changed

.github/workflows/build.yml

Lines changed: 11 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,6 @@
1-
name: Ubuntu-Latest GCC - Build Release
1+
name: Ubuntu-Latest - Build Release
22

3-
on:
4-
push:
5-
branches: ["main"]
6-
pull_request:
7-
branches: ["main"]
3+
on: [push, pull_request]
84

95
permissions:
106
contents: write
@@ -15,9 +11,11 @@ permissions:
1511
deployments: write
1612

1713
jobs:
18-
1914
build:
20-
runs-on: [ubuntu-latest]
15+
strategy:
16+
matrix:
17+
compiler: [gcc, clang]
18+
runs-on: ubuntu-latest
2119
steps:
2220
- name: Checkout repository ${{ github.repository }} on a branch ${{ github.ref_name }} triggered by ${{ github.event_name }}
2321
uses: actions/checkout@v4
@@ -36,29 +34,14 @@ jobs:
3634

3735
- name: 🔄 Installing Dependencies...
3836
run: |
39-
sudo apt-get update
40-
echo "📦 Installing libcriterion-dev, Ninja, GCC New Version"
41-
sudo apt-get install -y libcriterion-dev ninja-build gcc-12
42-
sudo ln -s -f /usr/bin/gcc-12 /usr/bin/gcc
37+
echo "📦 Installing libcriterion-dev, Ninja"
38+
sudo apt-get update && apt-get install -y libcriterion-dev ninja-build
4339
echo "✅ Dependencies installed!"
4440
4541
- name: Run build release task...
42+
env:
43+
CC: ${{ matrix.compiler }}
4644
run: |
4745
echo "🏗️ Setting up Meson build system..."
48-
task build fclean
46+
task build
4947
echo "🎉 Build completed with Meson!"
50-
51-
deployments:
52-
runs-on: [ubuntu-latest]
53-
needs: build
54-
steps:
55-
- name: Checkout repository ${{ github.repository }} on a branch ${{ github.ref_name }} triggered by ${{ github.event_name }}
56-
uses: actions/checkout@v4
57-
58-
- run: "echo the ${{ github.repository }} has been cloned in the container !"
59-
60-
- name: Upload artifact
61-
uses: actions/upload-artifact@v4
62-
with:
63-
name: etheria-std
64-
path: .

.github/workflows/codeQL.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ jobs:
1515
strategy:
1616
fail-fast: false
1717
matrix:
18+
compiler: [gcc, clang]
1819
include:
1920
- language: c-cpp
2021
build-mode: manual
@@ -37,10 +38,8 @@ jobs:
3738

3839
- name: 🔄 Installing Dependencies...
3940
run: |
40-
sudo apt-get update
4141
echo "📦 Installing libcriterion-dev, Ninja, GCC New Version"
42-
sudo apt-get install -y libcriterion-dev ninja-build gcc-12
43-
sudo ln -s -f /usr/bin/gcc-12 /usr/bin/gcc
42+
sudo apt-get update && apt-get install -y libcriterion-dev ninja-build
4443
echo "✅ Dependencies installed!"
4544
4645
@@ -50,6 +49,8 @@ jobs:
5049
languages: ${{ matrix.language }}
5150

5251
- name: Run build release task...
52+
env:
53+
CC: ${{ matrix.compiler }}
5354
run: |
5455
echo "🏗️ Setting up Meson build system..."
5556
task build

.github/workflows/memcpy_naive_test.yml

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@ permissions:
88
jobs:
99
build:
1010
runs-on: [ubuntu-latest]
11+
strategy:
12+
matrix:
13+
compiler: [gcc, clang]
1114
steps:
1215
- name: Checkout repository ${{ github.repository }} on a branch ${{ github.ref_name }} triggered by ${{ github.event_name }}
1316
uses: actions/checkout@v4
@@ -27,18 +30,21 @@ jobs:
2730
- name: 🔄 Installing Dependencies...
2831
run: |
2932
sudo apt-get update
30-
echo "📦 Installing libcriterion-dev, Ninja, GCC New Version"
31-
sudo apt-get install -y libcriterion-dev ninja-build gcc-12
32-
sudo ln -s -f /usr/bin/gcc-12 /usr/bin/gcc
33+
echo "📦 Installing libcriterion-dev, Ninja"
34+
sudo apt-get install -y libcriterion-dev ninja-build
3335
echo "✅ Dependencies installed!"
3436
3537
- name: Build tests
38+
env:
39+
CC: ${{ matrix.compiler }}
3640
run: |
3741
echo "🏗️ Setting up Meson build system..."
3842
task build-tests
3943
echo "🎉 Build completed with Meson!"
4044
4145
- name: Run test memcpy naive tests
46+
env:
47+
CC: ${{ matrix.compiler }}
4248
run: |
43-
echo "🏗️ Run naive memcpy tests..."
49+
echo "🏗️ Run naive memcpy tests... with $CC"
4450
task run-test-suite -- $(task list-tests | grep "test_memcpy_naive")

.github/workflows/types_test.yml

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,10 @@ permissions:
77

88
jobs:
99
build:
10-
runs-on: [ubuntu-latest]
10+
runs-on: ubuntu-latest
11+
strategy:
12+
matrix:
13+
compiler: [gcc, clang]
1114
steps:
1215
- name: Checkout repository ${{ github.repository }} on a branch ${{ github.ref_name }} triggered by ${{ github.event_name }}
1316
uses: actions/checkout@v4
@@ -33,12 +36,16 @@ jobs:
3336
echo "✅ Dependencies installed!"
3437
3538
- name: Build tests
39+
env:
40+
CC: ${{ matrix.compiler }}
3641
run: |
3742
echo "🏗️ Setting up Meson build system..."
3843
task build-tests
3944
echo "🎉 Build completed with Meson!"
4045
4146
- name: Run Types tests
47+
env:
48+
CC: ${{ matrix.compiler }}
4249
run: |
43-
echo "🏗️ Setting up Meson build system..."
50+
echo "🏗️ Setting up Meson build system... with $CC"
4451
task run-test-suite -- $(task list-tests | grep "test_types")

0 commit comments

Comments
 (0)