25
25
- name : Configure Safe Directory
26
26
run : git config --global --add safe.directory $GITHUB_WORKSPACE
27
27
28
- - name : Install Dependencies (Including Clang and Python Bindings)
28
+ - name : Install Dependencies
29
29
env :
30
30
DEBIAN_FRONTEND : noninteractive
31
31
run : |
@@ -34,21 +34,28 @@ jobs:
34
34
apt-get install -y \
35
35
lcov libcurl4-openssl-dev libmariadb-dev libmariadb-dev-compat \
36
36
python3 python3-pip python3-venv gcovr bc pipx wget \
37
- software-properties-common clang libclang-dev python3-clang
37
+ software-properties-common
38
+ # Add the official LLVM repository for the latest Clang
39
+ wget https://apt.llvm.org/llvm.sh
40
+ chmod +x llvm.sh
41
+ ./llvm.sh 19
42
+ apt-get install -y clang-19 libclang-19-dev
43
+ update-alternatives --install /usr/bin/clang clang /usr/lib/llvm-19/bin/clang 100
44
+ update-alternatives --install /usr/bin/clang++ clang++ /usr/lib/llvm-19/bin/clang++ 100
38
45
pipx install --system-site-packages mcdc-checker
39
46
40
- - name : Verify Clang Python Bindings
41
- run : |
42
- echo "Testing Clang Python bindings..."
43
- python3 -c "import clang.cindex; print('Clang bindings are working')"
44
-
45
47
- name : Verify Clang Installation
46
48
run : |
47
49
echo "Checking clang binary..."
48
50
which clang || { echo "clang not found in PATH"; exit 1; }
49
51
echo "clang version:"
50
52
clang --version
51
53
54
+ - name : Verify Clang Python Bindings
55
+ run : |
56
+ echo "Testing Clang Python bindings..."
57
+ python3 -c "import clang.cindex; print('Clang bindings are working')"
58
+
52
59
- name : Build with Coverage Flags
53
60
run : |
54
61
export CFLAGS="-fprofile-arcs -ftest-coverage -g"
0 commit comments