HomePhabricator

[CMAKE] Enable Large File Support on platforms that don't enable it by default

Description

[CMAKE] Enable Large File Support on platforms that don't enable it by default

Summary:
This targets all 32-bit platforms and windows.

The test for off_t == off64_t from D4167 is updated to accommodate OSX
not providing the off64_t type and renamed to be more meaningful as a
check for LFS.

The -D_FILE_OFFSET_BITS=64 is added to enable LFS, which is the
correct flag for all our currently supported platforms. Other flags can
be added later for other platforms as needed. Note that mingw also
requires a linker flag for win32.

Depends on D4167.

Test Plan:
Build with cmake on all 32 bits platforms + windows.
Run the gitian builds (sanity check).
Check the binaries run in all cases.

Reviewers: #bitcoin_abc, deadalnix

Reviewed By: #bitcoin_abc, deadalnix

Differential Revision: https://reviews.bitcoinabc.org/D4182

Details

Provenance
FabienAuthored on Sep 30 2019, 15:15
FabienPushed on Oct 1 2019, 13:54
Reviewer
Restricted Project
Differential Revision
D4182: [CMAKE] Enable Large File Support on platforms that don't enable it by default
Parents
rABC98415c84aa38: Add support for Glibc version 2.28
Branches
Unknown
Tags
Unknown