On 2024-03-01 10:28, Emanuele Rocca wrote:
> /usr/include/features-time64.h:26:5: error: #error "_TIME_BITS=64 is allowed
> only with _FILE_OFFSET_BITS=64"
> 26 | # error "_TIME_BITS=64 is allowed only with _FILE_OFFSET_BITS=64"
> | ^~~~~
The build logs show that the time64 flags -D_FILE_OFFSET_BITS=64
-D_TIME_BITS=64 are used as expected throughout the build process, with
the exception of v4l2convert.c.o which uses -D_FILE_OFFSET_BITS=32:
[94/286] cc -Ilib/libv4l2/v4l2convert.so.p -Ilib/libv4l2 -I../lib/libv4l2
-I../lib/include -I../include -fdiagnostics-color=always -Wall -Winvalid-pch
-std=gnu99 -Wpointer-arith -D_GNU_SOURCE -DPROMOTED_MODE_T=int -DENABLE_NLS
-include /<<PKGBUILDDIR>>/obj-arm-linux-gnueabihf/config.h -g -O2
-Werror=implicit-function-declaration -ffile-prefix-map=/<<PKGBUILDDIR>>=.
-fstack-protector-strong -fstack-clash-protection -Wformat
-Werror=format-security -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
-D_TIME_BITS=64 -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -U_FILE_OFFSET_BITS
-D_FILE_OFFSET_BITS=32 -D_LARGEFILE64_SOURCE -MD -MQ
lib/libv4l2/v4l2convert.so.p/v4l2convert.c.o -MF
lib/libv4l2/v4l2convert.so.p/v4l2convert.c.o.d -o
lib/libv4l2/v4l2convert.so.p/v4l2convert.c.o -c ../lib/libv4l2/v4l2convert.c
This seems intentional, see meson.build:
v4l2_wrapper_args = [
# As the library needs to provide both 32-bit and 64-bit versions
# of file operations, disable transparent large file support (fixes
# 'Error: symbol `open64/mmap64' is already defined' compile failure
# otherwise)
'-U_FILE_OFFSET_BITS',
'-D_FILE_OFFSET_BITS=32',
'-D_LARGEFILE64_SOURCE',
]
https://sources.debian.org/src/v4l-utils/1.26.1-3.1/meson.build/#L51