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
diff options
context:
space:
mode:
authorJeff Johnston <jjohnstn@redhat.com>2005-02-24 21:29:31 +0300
committerJeff Johnston <jjohnstn@redhat.com>2005-02-24 21:29:31 +0300
commitf2f8a9a2298b14b59a6e6e2a675cc117e2cbe157 (patch)
treef7c9dcb76a6ed3799579fbb41807a377099cd6c8 /newlib/libc/include
parent45df57e8d8801f5b01c3e45a2c427b55845dac19 (diff)
2005-02-24 Ralf Corsepious <ralf.corsepius@rtems.org>
* libc/include/sys/types.h [__rtems__]: Include new header file machine/_types.h. * libc/include/machine/types.h: Ditto. * libc/sys/rtems/machine/_types.h: New file.
Diffstat (limited to 'newlib/libc/include')
-rw-r--r--newlib/libc/include/machine/types.h19
-rw-r--r--newlib/libc/include/sys/types.h34
2 files changed, 35 insertions, 18 deletions
diff --git a/newlib/libc/include/machine/types.h b/newlib/libc/include/machine/types.h
index b573336b7..40a75faa5 100644
--- a/newlib/libc/include/machine/types.h
+++ b/newlib/libc/include/machine/types.h
@@ -6,25 +6,8 @@
* closely match the types defined in the BSD machine/types.h.
* This is needed to let the RTEMS/BSD TCP/IP stack compile.
*/
-
#if defined(__rtems__)
-typedef signed long long int64_t;
-#if defined( __h8300__)
-typedef signed long int32_t;
-#else
-typedef signed int int32_t;
-#endif
-typedef signed short int16_t;
-typedef signed char int8_t;
-
-typedef unsigned long long u_int64_t;
-#if defined( __h8300__)
-typedef unsigned long u_int32_t;
-#else
-typedef unsigned int u_int32_t;
-#endif
-typedef unsigned short u_int16_t;
-typedef unsigned char u_int8_t;
+#include <machine/_types.h>
#endif
#define _CLOCK_T_ unsigned long /* clock() */
diff --git a/newlib/libc/include/sys/types.h b/newlib/libc/include/sys/types.h
index 238af1f50..944149589 100644
--- a/newlib/libc/include/sys/types.h
+++ b/newlib/libc/include/sys/types.h
@@ -21,6 +21,8 @@
#ifndef __INTTYPES_DEFINED__
#define __INTTYPES_DEFINED__
+
+#if !defined (__rtems__)
typedef short int __int16_t;
typedef unsigned short int __uint16_t;
@@ -39,6 +41,38 @@ typedef unsigned long int __uint64_t;
__extension__ typedef long long __int64_t;
__extension__ typedef unsigned long long __uint64_t;
#endif
+#else /* __rtems__ */
+
+/*
+ * The following section is RTEMS specific and is needed to more
+ * closely match the types defined in the BSD sys/types.h.
+ * This is needed to let the RTEMS/BSD TCP/IP stack compile.
+ */
+
+#include <machine/_types.h>
+
+/* deprecated */
+#if ___int8_t_defined
+typedef __uint8_t u_int8_t;
+#endif
+#if ___int16_t_defined
+typedef __uint16_t u_int16_t;
+#endif
+#if ___int32_t_defined
+typedef __uint32_t u_int32_t;
+#endif
+
+#if ___int64_t_defined
+typedef __uint64_t u_int64_t;
+
+/* deprecated */
+typedef __uint64_t u_quad_t;
+typedef __int64_t quad_t;
+typedef quad_t * qaddr_t;
+#endif
+
+#endif
+
#endif /* ! __INTTYPES_DEFINED */
#ifndef __need_inttypes