[f2fs-dev] [PATCH 1/3] f2fs-tools: Build f2fs-tools with _FILE_OFFSET_BITS=64

Jaegeuk Kim via Linux-f2fs-devel <[email protected]>
Newsgroups net.sourceforge.lists.linux-f2fs-devel
Message-ID <[email protected]>
From: "xiuhong.wang" <[email protected]>

After commit b15b6cc56ac7("f2fs-tools: convert to lseek() and kill
lseek64"), 32-bit Android should also be built with
_FILE_OFFSET_BITS=64.

When calling the lseek function on arm32, if the offset exceeds 32
bits, lseek fails. Therefore, the flag _FILE_OFFSET_BITS=64 is
added to support operations with offsets greater than 32 bits on
arm32.

Signed-off-by: Xiuhong Wang <[email protected]>
Signed-off-by: Zhiguo Niu <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
---
 tools/f2fs_io/Android.bp | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/tools/f2fs_io/Android.bp b/tools/f2fs_io/Android.bp
index 2cc81eb859d4..52cdb73f41d6 100644
--- a/tools/f2fs_io/Android.bp
+++ b/tools/f2fs_io/Android.bp
@@ -1,7 +1,8 @@
 cc_defaults {
     name: "f2fs-io-defaults",
     cflags: [
-        "-Wno-unused-function"
+        "-D_FILE_OFFSET_BITS=64",
+        "-Wno-unused-function",
     ],
 }
 
-- 
2.55.0.rc0.799.gd6f94ed593-goog



_______________________________________________
Linux-f2fs-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.