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 (Including Clang 19 )
29
29
env :
30
30
DEBIAN_FRONTEND : noninteractive
31
31
run : |
@@ -34,21 +34,29 @@ 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 and install Clang 19
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 python3-clang
43
+ # Ensure Clang 19 is the default
44
+ update-alternatives --install /usr/bin/clang clang /usr/lib/llvm-19/bin/clang 100
45
+ update-alternatives --install /usr/bin/clang++ clang++ /usr/lib/llvm-19/bin/clang++ 100
38
46
pipx install --system-site-packages mcdc-checker
39
47
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
48
- name : Verify Clang Installation
46
49
run : |
47
50
echo "Checking clang binary..."
48
51
which clang || { echo "clang not found in PATH"; exit 1; }
49
52
echo "clang version:"
50
53
clang --version
51
54
55
+ - name : Verify Clang Python Bindings
56
+ run : |
57
+ echo "Testing Clang Python bindings..."
58
+ python3 -c "import clang.cindex; print('Clang bindings are working')"
59
+
52
60
- name : Build with Coverage Flags
53
61
run : |
54
62
export CFLAGS="-fprofile-arcs -ftest-coverage -g"
0 commit comments