Skip to content

Conversation

@mapreri
Copy link
Contributor

@mapreri mapreri commented Apr 22, 2024

Distributions are now rebuilding 32bit archs and defining
_TIME_BITS=64
_FILE_OFFSET_BITS=64
to be able to use the redefined 64-bit time and file functions from glibc.

Undefine _TIME_BITS here too, to prevent this compilation error:

In file included from /usr/include/features.h:393,
from /usr/include/arm-linux-gnueabihf/sys/types.h:25,
from libeatmydata/libeatmydata.c:22:
/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"
| ^~~~~
make[2]: *** [Makefile:1046: libeatmydata/la-libeatmydata.lo] Error 1

… defining _TIME_BITS

distributions are now rebuilding 32bit archs and defining
    _TIME_BITS=64
    _FILE_OFFSET_BITS=64
to be able to use the redefined 64-bit time and file functions from
glibc.

Undefine _TIME_BITS here too, to prevent this compilation error:

> In file included from /usr/include/features.h:393,
>                  from /usr/include/arm-linux-gnueabihf/sys/types.h:25,
>                  from libeatmydata/libeatmydata.c:22:
> /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"
>       |     ^~~~~
> make[2]: *** [Makefile:1046: libeatmydata/la-libeatmydata.lo] Error 1

Signed-off-by: Mattia Rizzolo <mattia@mapreri.org>
@mapreri mapreri changed the title Fix access to open() and open64() on 32bit also when built with a env… Fix access to open() and open64() on 32bit also when built with a env defining _TIME_BITS Apr 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant