#1128736 pam-python: FTBFS with glibc 2.43 due to ISO C23 const return types

Package:
src:pam-python
Source:
src:pam-python
Submitter:
Aurelien Jarno
Date:
2026-02-22 16:17:05 UTC
Severity:
normal
Tags:
#1128736#5
Date:
2026-02-22 16:16:32 UTC
From:
To:
Dear maintainer(s),

pam-python fails to build from source with glibc 2.43, currently in
experimental. From the build log:

| pam_python.c: In function ‘load_user_module’:
| pam_python.c:2289:20: error: assignment discards ‘const’ qualifier from pointer target type [-Werror=discarded-qualifiers]
|  2289 |   user_module_name = strrchr(module_path, '/');
|       |                    ^
| making output directory... done
| loading intersphinx inventory 'python' from /usr/share/doc/python3-doc/html/objects.inv ...
| building [mo]: targets for 0 po files that are out of date
| writing output...
| building [html]: targets for 1 source files that are out of date
| updating environment: [new config] 1 added, 0 changed, 0 removed
| reading sources... [100%] pam_python
|
| looking for now-outdated files... none found
| pickling environment... done
| checking consistency... done
| preparing documents... done
| copying assets...
| copying static files...
| Writing evaluated template result to /build/reproducible-path/pam-python-1.1.0~git20220701.1d4e111/doc/html/_static/language_data.js
| Writing evaluated template result to /build/reproducible-path/pam-python-1.1.0~git20220701.1d4e111/doc/html/_static/basic.css
| Writing evaluated template result to /build/reproducible-path/pam-python-1.1.0~git20220701.1d4e111/doc/html/_static/documentation_options.js
| Writing evaluated template result to /build/reproducible-path/pam-python-1.1.0~git20220701.1d4e111/doc/html/_static/alabaster.css
| copying static files: done
| copying extra files...
| copying extra files: done
| copying assets: done
| writing output... [100%] pam_python
|
| generating indices... genindex done
| writing additional pages... search done
| dumping search index in English (code: en)... done
| dumping object inventory... done
| build succeeded.
|
| The HTML pages are in html.
| rm -f html/index.html && ln -s pam_python.html html/index.html
| make[2]: Leaving directory '/build/reproducible-path/pam-python-1.1.0~git20220701.1d4e111/doc'
| cc1: all warnings being treated as errors
| error: command '/usr/bin/aarch64-linux-gnu-gcc' failed with exit code 1
| make[2]: *** [Makefile:13: pam_python.so] Error 1
| make[2]: Leaving directory '/build/reproducible-path/pam-python-1.1.0~git20220701.1d4e111/src'
| make[1]: *** [Makefile:6: lib] Error 2
| make[1]: Leaving directory '/build/reproducible-path/pam-python-1.1.0~git20220701.1d4e111'
| dh_auto_build: error: make -j128 INSTALL="install --strip-program=true" returned exit code 2
| make: *** [debian/rules:12: binary] Error 25
| dpkg-buildpackage: error: debian/rules binary subprocess failed with exit status 2

The full build log is available here [1].

The issue is due to ISO C23 declaration of bsearch, memchr, strchr,
strpbrk, strrchr, strstr, wcschr, wcspbrk, wcsrchr, wcsstr and wmemchr,
which now returns a pointer to a const-qualified type when the input
argument is a pointer to a const-qualified type [2].

I would like to thanks Emanuele Rocca for doing the archive rebuild on
a fast arm64 server.

Regards
Aurelien

[1] https://people.debian.org/~ema/glibc-2.43-rebuilds/output-1/pam-python_arm64.build
[2] https://sourceware.org/git/?p=glibc.git;a=blob;f=NEWS;h=e271fb2e4d76903c77a302aaec1ca22ce31027d0;hb=f762ccf84f122d1354f103a151cba8bde797d521#l19