With a recent glibc, as found on Ubuntu 26.04, with the default locale,
sort and comm do not always agree on the ordering of all characters,
notably punctuation characters, and comm will thus fail when reading the
output of sort, producing a warning, and prevent the minidebug section
from being created.
Just force them to use the C locale, where this is not a problem.
# implementations lack the long ones, and undefined symbols are told by their
# type in awk instead of --defined-only, which these implementations lack too.
define make_minidebug
- $(call qinfo, MINIDBG)cp -f $@ $@.noxz; \
+ $(call qinfo, MINIDBG)LC_ALL=C; export LC_ALL; cp -f $@ $@.noxz; \
if ! ( \
$(NM) -D -P $@ | awk '$$2 != "U" && $$2 != "w" { print $$1 }' | sort > $@.dsyms && \
$(NM) -P $@ | awk '$$2 == "T" || $$2 == "t" { print $$1 }' | sort > $@.fsyms && \