File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change 40
40
#include < errno.h>
41
41
#endif
42
42
43
+ #if defined __has_include
44
+ # if __has_include (<sys/stat.h>)
45
+ # include < sys/stat.h>
46
+ # define HAVE_SYS_STAT_H
47
+ # endif
48
+ #endif
49
+
43
50
/* We can get the following standard types from sys/types for gcc, but we
44
51
* need to define the types ourselves for the other compilers that normally
45
52
* target embedded systems */
@@ -495,6 +502,8 @@ typedef struct Dir DIR;
495
502
#define S_IWOTH 0000002 // /< write permission, other
496
503
#define S_IXOTH 0000001 // /< execute/search permission, other
497
504
505
+ #ifndef HAVE_SYS_STAT_H
506
+
498
507
/* Refer to sys/stat standard
499
508
* Note: Not all fields may be supported by the underlying filesystem
500
509
*/
@@ -514,6 +523,8 @@ struct stat {
514
523
time_t st_ctime; // /< Time of last status change
515
524
};
516
525
526
+ #endif
527
+
517
528
struct statvfs {
518
529
unsigned long f_bsize; // /< Filesystem block size
519
530
unsigned long f_frsize; // /< Fragment size (block size)
You can’t perform that action at this time.
0 commit comments