[LTP] [PATCH] unlink09: Add _GNU_SOURCE feature macro to workaround the compile error
Yang Xu
xuyang2018.jy@fujitsu.com
Tue Apr 23 10:37:23 CEST 2024
In CI environment, unlink09 compiling failed on alpine/latest because loff_t
type is not declared. Add _GNU_SOURCE feature macro to enable GNU extension
to solve the problem.
Signed-off-by: Yang Xu <xuyang2018.jy@fujitsu.com>
---
testcases/kernel/syscalls/unlink/unlink09.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/testcases/kernel/syscalls/unlink/unlink09.c b/testcases/kernel/syscalls/unlink/unlink09.c
index cc4b4a07e..1472e9134 100644
--- a/testcases/kernel/syscalls/unlink/unlink09.c
+++ b/testcases/kernel/syscalls/unlink/unlink09.c
@@ -13,6 +13,8 @@
* - EROFS when target file is on a read-only filesystem.
*/
+#define _GNU_SOURCE
+
#include <sys/ioctl.h>
#include "tst_test.h"
#include "lapi/fs.h"
--
2.39.3
More information about the ltp
mailing list