[Buildroot] [PATCH 01/11] package/libselinux: fix build issues caused by 3.8.1 bump

Waldemar Brodkorb wbx at openadk.org
Fri Sep 19 18:42:30 UTC 2025


Hi Thomas,
Thomas Petazzoni wrote,

> Hello Julien,
> 
> +Waldemar in Cc, uClibc-ng related issue.
> 
> On Mon, 15 Sep 2025 00:28:28 +0200
> Julien Olivain <ju.o at free.fr> wrote:
> 
> > I applied the full series to master, thanks.
> 
> Thanks!
> 
> > While reviewing, I found one corner case build failure with libselinux 
> > 3.9
> > on x86_64 uclibc. See:
> > https://gitlab.com/jolivain/buildroot/-/jobs/11350151899
> > 
> > It seems to be a followup issue related to the one fixed in this patch.
> 
> Dammit. I must say I don't quite grasp what they are trying to do in
> these matchpathcon.c checks.
> 
> It seems like:
> 
> #if (defined(_FILE_OFFSET_BITS) && _FILE_OFFSET_BITS == 64) && defined(__INO64_T_TYPE) && !defined(__INO_T_MATCHES_INO64_T)
> /* alias defined in the public header but we undefine it here */
> #undef matchpathcon_filespec_add
> 
> /* ABI backwards-compatible shim for non-LFS 32-bit systems */
> 
> static_assert(sizeof(unsigned long) == sizeof(__ino_t), "inode size mismatch");
> static_assert(sizeof(unsigned long) == sizeof(uint32_t), "inode size mismatch");
> static_assert(sizeof(ino_t) == sizeof(ino64_t), "inode size mismatch");
> static_assert(sizeof(ino64_t) == sizeof(uint64_t), "inode size mismatch");
> 
> is for 32-bit systems? And here you are building for x86-64, but it
> gets detected as a 32-bit system, or something like that. Is it due to
> the fact that we always build with _FILE_OFFSET_BITS=64 even on 64-bit
> systems, where I guess it doesn't make sense because off_t is anyway
> going to always be 64-bit.

So would the right fix to enable _FILE_OFFSET_BITS=64 only for
32-bit systems? Or do you think something in uClibc-ng is wrong?

best regards
 Waldemar
 


More information about the buildroot mailing list