lens_default: fix PRIb64 length modifier on LP64 musl

On LP64 targets built against musl, -Werror=format aborts the build in lens_default.c:

error: format '%llb' expects argument of type 'long long unsigned int',
but argument 3 has type 'uint64_t' {aka 'long unsigned int'}

The PRIb64 fallback hardcodes __PRI64_PREFIX as "ll", which is only correct where uint64_t is unsigned long long (ILP32). glibc never hits the fallback (it defines __PRI64_PREFIX itself, wordsize-aware, in <inttypes.h>). musl exposes the same modifier as __PRI64 but not __PRI64_PREFIX, so the "ll" default is used and is wrong on 64-bit.

This reuses musl's __PRI64 when __PRI64_PREFIX is absent, keeping "ll" as a last resort for libcs that expose neither. glibc builds are unaffected (the block is skipped entirely).

Fix confirmed against ltrace 0.8.1 on a musl x86_64 (LP64) Yocto target.

Merge request reports

Loading