From 6b1139e82c0a96c267752b437a3b14f6787535ec Mon Sep 17 00:00:00 2001 From: alaviss Date: Tue, 14 Apr 2020 18:47:40 +0000 Subject: [PATCH] sys/mnttab.h: include sys/stat.h for stat64 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Musl libc defined `stat64` as a macro, which causes the build to fail upon compiling os/linux/getmntany.c due to conflicts between the forward declaration and the implementation. This commit fixes that by including in "sys/mnttab.h" directly. Reviewed-by: Brian Behlendorf Signed-off-by: Hiếu Lê Closes #10195 --- lib/libspl/include/os/linux/sys/mnttab.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/libspl/include/os/linux/sys/mnttab.h b/lib/libspl/include/os/linux/sys/mnttab.h index 7b30bf1d5478..093218d6853b 100644 --- a/lib/libspl/include/os/linux/sys/mnttab.h +++ b/lib/libspl/include/os/linux/sys/mnttab.h @@ -32,6 +32,7 @@ #include #include +#include #include #ifdef MNTTAB @@ -67,7 +68,6 @@ struct extmnttab { uint_t mnt_minor; }; -struct stat64; struct statfs; extern int getmntany(FILE *fp, struct mnttab *mp, struct mnttab *mpref);