Strategy for custom-patched Clang version

Fernando Hueso González Fernando.Hueso at uv.es
Tue Sep 1 10:39:19 BST 2026


Hello, I am working in coordination with Andreas Tille and Stephan 
Lachnit towards adding some medical and science packages to Debian.

One of the tricky cases involves building Clang v22 with ~43 patches on 
top, as a prerequisite for building that package. These add custom clang 
features that will not be present upstream. Note that this custom 
version of Clang relies on the native system version LLVM22, so no need 
to rebuild LLVM here, only Clang.

So this is the question, which of the following strategies would align 
best from Debian side?

- Modify https://salsa.debian.org/pkg-llvm-team/llvm-toolchain/ to have 
a special build variant that applies those patches and installs the 
lib/*.a, lib/*.so, include files lib/clang/22/*.h, binaries bin/clang 
and CMake scripts into /usr/CustomClang/* in order not to interfere with 
/usr/bin.

- or Create a new repository on Salsa (science team? or this team?) that 
specifically does this clang build


Thanks in advance for help / guidance / opinions.

Regards, Fernando Hueso.




More information about the Pkg-llvm-team mailing list