Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/newlib
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2016-04-15 14:44:21 +0300
committerCorinna Vinschen <corinna@vinschen.de>2016-04-15 15:51:40 +0300
commitc5d5030aea7585b86a4fe6e3dec068b0e720e8a2 (patch)
tree60144668fa00f5910ae13482a44874c409ab3658 /newlib
parent57d2718c0ea15f3dc3f5dddce4c0915a901374db (diff)
Provide POSIX defined blksize_t in <sys/types.h>
Signed-off-by: Sebastian Huber <sebastian.huber@embedded-brains.de>
Diffstat (limited to 'newlib')
-rw-r--r--newlib/libc/include/sys/_types.h4
-rw-r--r--newlib/libc/include/sys/stat.h2
-rw-r--r--newlib/libc/include/sys/types.h5
-rw-r--r--newlib/libc/sys/rtems/include/machine/_types.h5
4 files changed, 13 insertions, 3 deletions
diff --git a/newlib/libc/include/sys/_types.h b/newlib/libc/include/sys/_types.h
index 13362ad09..0d48f04ad 100644
--- a/newlib/libc/include/sys/_types.h
+++ b/newlib/libc/include/sys/_types.h
@@ -26,6 +26,10 @@
typedef long __blkcnt_t;
#endif
+#ifndef __machine_blksize_t_defined
+typedef long __blksize_t;
+#endif
+
#ifndef __machine_off_t_defined
typedef long _off_t;
#endif
diff --git a/newlib/libc/include/sys/stat.h b/newlib/libc/include/sys/stat.h
index a75c1c24f..94a90c0dd 100644
--- a/newlib/libc/include/sys/stat.h
+++ b/newlib/libc/include/sys/stat.h
@@ -53,7 +53,7 @@ struct stat
long st_spare2;
time_t st_ctime;
long st_spare3;
- long st_blksize;
+ blksize_t st_blksize;
blkcnt_t st_blocks;
long st_spare4[2];
#endif
diff --git a/newlib/libc/include/sys/types.h b/newlib/libc/include/sys/types.h
index ac8252ee6..24d90cd34 100644
--- a/newlib/libc/include/sys/types.h
+++ b/newlib/libc/include/sys/types.h
@@ -101,6 +101,11 @@ typedef __blkcnt_t blkcnt_t;
#define _BLKCNT_T_DECLARED
#endif
+#ifndef _BLKSIZE_T_DECLARED
+typedef __blksize_t blksize_t;
+#define _BLKSIZE_T_DECLARED
+#endif
+
#if !defined(__clock_t_defined) && !defined(_CLOCK_T_DECLARED)
typedef _CLOCK_T_ clock_t;
#define __clock_t_defined
diff --git a/newlib/libc/sys/rtems/include/machine/_types.h b/newlib/libc/sys/rtems/include/machine/_types.h
index 3dbcb3db5..ed0920692 100644
--- a/newlib/libc/sys/rtems/include/machine/_types.h
+++ b/newlib/libc/sys/rtems/include/machine/_types.h
@@ -3,11 +3,12 @@
#include <machine/_default_types.h>
-typedef __int32_t blksize_t;
-
typedef __int32_t __blkcnt_t;
#define __machine_blkcnt_t_defined
+typedef __int32_t __blksize_t;
+#define __machine_blksize_t_defined
+
typedef __uint64_t __dev_t;
#define __machine_dev_t_defined