[PATCH v4 1/3] configure: Use 64bit off_t

Khem Raj raj.khem at gmail.com
Thu Dec 15 19:58:40 AEDT 2022


Pass -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 via CFLAGS
this enabled large file support on 32bit architectures

Signed-off-by: Khem Raj <raj.khem at gmail.com>
---
 configure.ac | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/configure.ac b/configure.ac
index a736ff0..c2b948c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -319,6 +319,9 @@ if test "x$enable_lzma" = "xyes"; then
   CPPFLAGS="${saved_CPPFLAGS}"
 fi
 
+# Enable 64-bit off_t
+CFLAGS+=" -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"
+
 # Set up needed symbols, conditionals and compiler/linker flags
 AM_CONDITIONAL([ENABLE_LZ4], [test "x${have_lz4}" = "xyes"])
 AM_CONDITIONAL([ENABLE_LZ4HC], [test "x${have_lz4hc}" = "xyes"])
-- 
2.39.0



More information about the Linux-erofs mailing list