#1154048 mupdf: FTBFS with LLVM 23 as default: libclang AST change in its wrapper generator

Package:
src:mupdf
Source:
src:mupdf
Submitter:
Sylvestre Ledru
Date:
2026-11-15 12:21:03 UTC
Severity:
normal
Tags:
#1154048#5
Date:
2026-11-15 11:02:36 UTC
From:
To:
Hello,

We are going to switch the default LLVM version to 23 (transition bug
#1154024). llvm-defaults 0.75~exp1, in experimental, already points to
23.

mupdf fails to build in unstable with it, and builds without it:

AssertionError: fz_pixmap has fz_keep_pixmap() but have not found
size/location of .refs member. type_.spelling='fz_pixmap'
base_type_cursor.spelling='fz_pixmap': include/mupdf/fitz/color.h:50

The assertion comes from scripts/wrap/parse.py:342: the C++/Python
bindings generator (using python3-clang) doesn't find the .refs member
of fz_pixmap in the AST produced by libclang 23.

To reproduce, with sbuild:

  sbuild -d unstable \
    --extra-repository='deb http://deb.debian.org/debian experimental main' \
    --build-dep-resolver=aptitude \
    --add-depends='clang (>= 1:23~), llvm-dev (>= 1:23~), libclang-dev (>= 1:23~)' \
    <package>

The --add-depends forces the llvm-defaults packages from experimental
(the default apt resolver won't pick them, aptitude does), everything
else comes from unstable.

The severity will be raised to serious once llvm-defaults 23 is in
unstable.

Cheers,
Sylvestre