File tree Expand file tree Collapse file tree 2 files changed +35
-0
lines changed Expand file tree Collapse file tree 2 files changed +35
-0
lines changed Original file line number Diff line number Diff line change @@ -5137,6 +5137,20 @@ if compile_prog "" "" ; then
5137
5137
have_fsxattr=yes
5138
5138
fi
5139
5139
5140
+ # #########################################
5141
+ # check if sys/mount.h conflicts with linux/fs.h
5142
+
5143
+ have_sysmount_fs=no
5144
+ cat > $TMPC << EOF
5145
+ #include <sys/mount.h>
5146
+ int main(void) {
5147
+ return FSCONFIG_SET_FLAG;
5148
+ }
5149
+ EOF
5150
+ if compile_prog " " " " ; then
5151
+ have_sysmount_fs=yes
5152
+ fi
5153
+
5140
5154
# #########################################
5141
5155
# check if rtnetlink.h exists and is useful
5142
5156
have_rtnetlink=no
@@ -6501,6 +6515,10 @@ if test "$rdma" = "yes" ; then
6501
6515
echo " RDMA_LIBS=$rdma_libs " >> $config_host_mak
6502
6516
fi
6503
6517
6518
+ if test " $have_sysmount_fs " = " yes" ; then
6519
+ echo " CONFIG_SYS_MOUNT_FS=y" >> $config_host_mak
6520
+ fi
6521
+
6504
6522
if test " $have_rtnetlink " = " yes" ; then
6505
6523
echo " CONFIG_RTNETLINK=y" >> $config_host_mak
6506
6524
fi
Original file line number Diff line number Diff line change 98
98
#include <linux/soundcard.h>
99
99
#include <linux/kd.h>
100
100
#include <linux/mtio.h>
101
+ #ifdef CONFIG_SYS_MOUNT_FS
102
+ /*
103
+ * glibc >= 2.36 linux/mount.h conflicts with sys/mount.h,
104
+ * which in turn prevents use of linux/fs.h. So we have to
105
+ * define the constants ourselves for now.
106
+ */
107
+ #define FS_IOC_GETFLAGS _IOR('f', 1, long)
108
+ #define FS_IOC_SETFLAGS _IOW('f', 2, long)
109
+ #define FS_IOC_GETVERSION _IOR('v', 1, long)
110
+ #define FS_IOC_SETVERSION _IOW('v', 2, long)
111
+ #define FS_IOC_FIEMAP _IOWR('f', 11, struct fiemap)
112
+ #define FS_IOC32_GETFLAGS _IOR('f', 1, int)
113
+ #define FS_IOC32_SETFLAGS _IOW('f', 2, int)
114
+ #define FS_IOC32_GETVERSION _IOR('v', 1, int)
115
+ #define FS_IOC32_SETVERSION _IOW('v', 2, int)
116
+ #else
101
117
#include <linux/fs.h>
118
+ #endif
102
119
#if defined(CONFIG_FIEMAP )
103
120
#include <linux/fiemap.h>
104
121
#endif
You can’t perform that action at this time.
0 commit comments