Skip to content

Commit 0476c87

Browse files
committed
Updated workflow
1 parent 8644c6e commit 0476c87

1 file changed

Lines changed: 52 additions & 95 deletions

File tree

.github/workflows/build.yml

Lines changed: 52 additions & 95 deletions
Original file line numberDiff line numberDiff line change
@@ -10,103 +10,60 @@ env:
1010
BUILD_TYPE: Release
1111

1212
jobs:
13-
# NOTES:
14-
# * JsonCpp 1.9.6 is needed but it is not available on Ubuntu 24.04 yet
15-
# * StormByte is not available on ubuntu so it is always bundled
16-
build_GCC_all_ON:
13+
build:
1714
runs-on: ubuntu-24.04
1815

19-
steps:
20-
- name: Checkout repository and submodules
21-
uses: actions/checkout@v3
22-
with:
23-
submodules: recursive
24-
25-
- name: Update repository
26-
run: sudo apt update
27-
28-
- name: Install dependencies
29-
run: sudo apt install -y libsqlite3-dev ffmpeg clang cmake
30-
31-
- name: Pretending hdr10plus_tool is installed
32-
run: sudo touch /usr/bin/hdr10plus_tool && sudo chmod +x /usr/bin/hdr10plus_tool
33-
34-
- name: Configure CMake All ON
35-
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_C_COMPILER=/usr/bin/gcc -DCMAKE_CXX_COMPILER=/usr/bin/g++ -DENABLE_FDK_AAC=ON -DENABLE_H264=ON -DENABLE_H265=ON -DENABLE_LAME=ON -DENABLE_LIBOPUS=ON -DENABLE_LIBVORBIS=ON -DENABLE_LIBVPX=ON -DENABLE_XVID=ON -DWITH_SYSTEM_JSONCPP=OFF -DWITH_SYSTEM_STORMBYTE=OFF -DWITH_SYSTEM_SQLITE=ON
36-
37-
- name: Build
38-
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
39-
40-
build_GCC_all_OFF:
41-
runs-on: ubuntu-24.04
16+
strategy:
17+
matrix:
18+
compiler: [gcc, clang]
19+
enable_flags: [ON, OFF]
20+
external_jsoncpp: [OFF] # Until 1.6.0 version is stable on ubuntu it can not be used here
21+
stdlib: [stdc++, libc++]
22+
exclude:
23+
- compiler: gcc
24+
stdlib: libc++
4225

4326
steps:
44-
- name: Checkout repository and submodules
45-
uses: actions/checkout@v3
46-
with:
47-
submodules: recursive
48-
49-
- name: Update repository
50-
run: sudo apt update
51-
52-
- name: Install dependencies
53-
run: sudo apt install -y ffmpeg clang cmake
54-
55-
- name: Pretending hdr10plus_tool is installed
56-
run: sudo touch /usr/bin/hdr10plus_tool && sudo chmod +x /usr/bin/hdr10plus_tool
57-
58-
- name: Configure CMake All OFF
59-
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_C_COMPILER=/usr/bin/gcc -DCMAKE_CXX_COMPILER=/usr/bin/g++ -DENABLE_FDK_AAC=OFF -DENABLE_H264=OFF -DENABLE_H265=OFF -DENABLE_LAME=OFF -DENABLE_LIBOPUS=OFF -DENABLE_LIBVORBIS=OFF -DENABLE_LIBVPX=OFF -DENABLE_XVID=OFF -DWITH_SYSTEM_JSONCPP=OFF -DWITH_SYSTEM_STORMBYTE=OFF -DWITH_SYSTEM_SQLITE=OFF
60-
61-
- name: Build
62-
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
63-
64-
build_Clang_all_ON:
65-
runs-on: ubuntu-24.04
66-
67-
steps:
68-
- name: Checkout repository and submodules
69-
uses: actions/checkout@v3
70-
with:
71-
submodules: recursive
72-
73-
- name: Update repository
74-
run: sudo apt update
75-
76-
- name: Install dependencies
77-
run: sudo apt install -y libsqlite3-dev ffmpeg clang cmake
78-
79-
- name: Pretending hdr10plus_tool is installed
80-
run: sudo touch /usr/bin/hdr10plus_tool && sudo chmod +x /usr/bin/hdr10plus_tool
81-
82-
- name: Configure CMake All ON
83-
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_C_COMPILER=/usr/bin/clang -DCMAKE_CXX_COMPILER=/usr/bin/clang++ -DENABLE_FDK_AAC=ON -DENABLE_H264=ON -DENABLE_H265=ON -DENABLE_LAME=ON -DENABLE_LIBOPUS=ON -DENABLE_LIBVORBIS=ON -DENABLE_LIBVPX=ON -DENABLE_XVID=ON -DWITH_SYSTEM_JSONCPP=OFF -DWITH_SYSTEM_STORMBYTE=OFF -DWITH_SYSTEM_SQLITE=ON
84-
85-
- name: Build with Clang
86-
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
87-
88-
build_Clang_all_OFF:
89-
runs-on: ubuntu-24.04
90-
91-
steps:
92-
- name: Checkout repository and submodules
93-
uses: actions/checkout@v3
94-
with:
95-
submodules: recursive
96-
97-
- name: Update repository
98-
run: sudo apt update
99-
100-
- name: Install dependencies
101-
run: sudo apt install -y ffmpeg clang cmake
102-
103-
- name: Pretending hdr10plus_tool is installed
104-
run: sudo touch /usr/bin/hdr10plus_tool && sudo chmod +x /usr/bin/hdr10plus_tool
105-
106-
- name: Configure CMake All OFF
107-
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_C_COMPILER=/usr/bin/clang -DCMAKE_CXX_COMPILER=/usr/bin/clang++ -DENABLE_FDK_AAC=OFF -DENABLE_H264=OFF -DENABLE_H265=OFF -DENABLE_LAME=OFF -DENABLE_LIBOPUS=OFF -DENABLE_LIBVORBIS=OFF -DENABLE_LIBVPX=OFF -DENABLE_XVID=OFF -DWITH_SYSTEM_JSONCPP=OFF -DWITH_SYSTEM_STORMBYTE=OFF -DWITH_SYSTEM_SQLITE=OFF
108-
109-
- name: Build with Clang
110-
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
27+
- name: Checkout repository and submodules
28+
uses: actions/checkout@v3
29+
with:
30+
submodules: recursive
31+
32+
- name: Update repository
33+
run: sudo apt update
34+
35+
- name: Install dependencies
36+
run: |
37+
sudo apt install -y libsqlite3-dev ffmpeg cmake clang
38+
if [[ "${{ matrix.compiler }}" == "clang" && "${{ matrix.stdlib }}" == "libc++" ]]; then
39+
sudo apt install -y libc++-dev
40+
fi
41+
if [[ "${{ matrix.external_jsoncpp }}" == "ON" ]]; then
42+
sudo apt install -y libjsoncpp-dev
43+
fi
44+
45+
- name: Pretending hdr10plus_tool is installed
46+
run: sudo touch /usr/bin/hdr10plus_tool && sudo chmod +x /usr/bin/hdr10plus_tool
47+
48+
- name: Configure CMake
49+
run: |
50+
cmake -B ${{github.workspace}}/build \
51+
-DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} \
52+
-DCMAKE_C_COMPILER=/usr/bin/${{ matrix.compiler }} \
53+
-DCMAKE_CXX_COMPILER=$([[ ${{ matrix.compiler }} == 'gcc' ]] && echo '/usr/bin/g++' || echo '/usr/bin/clang++') \
54+
-DCMAKE_CXX_FLAGS="${{ matrix.stdlib == 'libc++' && matrix.compiler == 'clang' && '-stdlib=libc++' || '' }}" \
55+
-DWITH_SYSTEM_JSONCPP=${{ matrix.external_jsoncpp }} \
56+
-DWITH_SYSTEM_STORMBYTE=OFF \
57+
-DWITH_SYSTEM_SQLITE=${{ matrix.enable_flags }} \
58+
-DENABLE_FDK_AAC=${{ matrix.enable_flags }} \
59+
-DENABLE_H264=${{ matrix.enable_flags }} \
60+
-DENABLE_H265=${{ matrix.enable_flags }} \
61+
-DENABLE_LAME=${{ matrix.enable_flags }} \
62+
-DENABLE_LIBOPUS=${{ matrix.enable_flags }} \
63+
-DENABLE_LIBVORBIS=${{ matrix.enable_flags }} \
64+
-DENABLE_LIBVPX=${{ matrix.enable_flags }} \
65+
-DENABLE_XVID=${{ matrix.enable_flags }}
66+
67+
- name: Build
68+
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
11169

112-

0 commit comments

Comments
 (0)