summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGregory Nutt <gnutt@nuttx.org>2015-02-25 14:01:14 -0600
committerGregory Nutt <gnutt@nuttx.org>2015-02-25 14:01:14 -0600
commit30ede997c3fc8764c5a84987028cc8b3b351bf48 (patch)
treebc2d1591dace41533cebbf5404f7b966b9f628e3
parent552e511b1d45bc0c2107a664a8a41c52ad8054ee (diff)
downloadnuttx-30ede997c3fc8764c5a84987028cc8b3b351bf48.tar.gz
nuttx-30ede997c3fc8764c5a84987028cc8b3b351bf48.tar.bz2
nuttx-30ede997c3fc8764c5a84987028cc8b3b351bf48.zip
Add BSD and SYSV types to sys/types to simplify porting. From Max Neklyudov
-rw-r--r--nuttx/include/sys/types.h20
1 files changed, 18 insertions, 2 deletions
diff --git a/nuttx/include/sys/types.h b/nuttx/include/sys/types.h
index 102bde622..cc8aee15d 100644
--- a/nuttx/include/sys/types.h
+++ b/nuttx/include/sys/types.h
@@ -1,7 +1,7 @@
/****************************************************************************
* include/sys/types.h
*
- * Copyright (C) 2007-2009, 2011-2012, 2014 Gregory Nutt. All rights reserved.
+ * Copyright (C) 2007-2009, 2011-2012, 2014-2015 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org>
*
* Redistribution and use in source and binary forms, with or without
@@ -240,11 +240,27 @@ typedef uint32_t clock_t;
typedef uint32_t useconds_t;
typedef int32_t suseconds_t;
+/* BSD types provided only to support porting to NuttX. */
+
+typedef unsigned char u_char;
+typedef unsigned short u_short;
+typedef unsigned int u_int;
+typedef unsigned long u_long;
+
+/* SYSV types provided only to support porting to NuttX. */
+
+typedef unsigned char unchar;
+typedef unsigned short ushort;
+typedef unsigned int uint;
+typedef unsigned long ulong;
+typedef signed char s_char;
+typedef char *caddr_t;
+
/* Task entry point */
typedef CODE int (*main_t)(int argc, char *argv[]);
-#endif
+#endif /* __ASSEMBLY__ */
/****************************************************************************
* Global Function Prototypes