summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGwenolé Beauchesne <gbeauchesne@mandriva.org>2003-02-18 18:42:43 +0000
committerGwenolé Beauchesne <gbeauchesne@mandriva.org>2003-02-18 18:42:43 +0000
commitf40d43ad1a8690cf3ad71a7e4e81f6a3312c3e3c (patch)
tree93dbdd00461065c8002e359502e7b72824910010
parent51f99b62910e83326283c7dcbcfd2f9e42506692 (diff)
downloaddrakx-backup-do-not-use-f40d43ad1a8690cf3ad71a7e4e81f6a3312c3e3c.tar
drakx-backup-do-not-use-f40d43ad1a8690cf3ad71a7e4e81f6a3312c3e3c.tar.gz
drakx-backup-do-not-use-f40d43ad1a8690cf3ad71a7e4e81f6a3312c3e3c.tar.bz2
drakx-backup-do-not-use-f40d43ad1a8690cf3ad71a7e4e81f6a3312c3e3c.tar.xz
drakx-backup-do-not-use-f40d43ad1a8690cf3ad71a7e4e81f6a3312c3e3c.zip
Define u_char et al. from <rpc/types.h>. The __dietlibc_u_char mechanism
is here to ensure we are not redefining types, if we were to compile programs with -D_BSD_SOURCE (u_char et al. are defined in <sys/types.h> int that case).
-rw-r--r--mdk-stage1/dietlibc/include/rpc/types.h10
-rw-r--r--mdk-stage1/dietlibc/include/sys/types.h19
2 files changed, 21 insertions, 8 deletions
diff --git a/mdk-stage1/dietlibc/include/rpc/types.h b/mdk-stage1/dietlibc/include/rpc/types.h
index 0e4f0b0e7..d4be65e38 100644
--- a/mdk-stage1/dietlibc/include/rpc/types.h
+++ b/mdk-stage1/dietlibc/include/rpc/types.h
@@ -59,6 +59,16 @@ typedef unsigned long rpcport_t;
#ifndef makedev /* ie, we haven't already included it */
#include <sys/types.h>
#endif
+
+# ifndef __dietlibc_u_char_defined
+typedef char* caddr_t;
+typedef uint32_t u_long;
+typedef unsigned char u_char;
+typedef unsigned short u_short;
+typedef unsigned int u_int;
+# define __dietlibc_u_char_defined
+#endif
+
#include <sys/time.h>
#include <sys/param.h>
diff --git a/mdk-stage1/dietlibc/include/sys/types.h b/mdk-stage1/dietlibc/include/sys/types.h
index 6bd483e50..eadc1bb65 100644
--- a/mdk-stage1/dietlibc/include/sys/types.h
+++ b/mdk-stage1/dietlibc/include/sys/types.h
@@ -101,21 +101,24 @@ typedef unsigned short sa_family_t;
#ifdef _BSD_SOURCE
/* die, BSD, die! */
+typedef uint16_t nshort;
+typedef uint32_t ntime;
+typedef uint32_t nlong;
+typedef uint32_t ulong;
+typedef uint16_t n_short;
+typedef uint32_t n_time;
+typedef uint32_t n_long;
+# ifndef __dietlibc_u_char_defined
typedef char* caddr_t;
+typedef uint32_t u_long;
typedef unsigned char u_char;
typedef unsigned short u_short;
typedef unsigned int u_int;
+# define __dietlibc_u_char_defined
+# endif
typedef unsigned char uchar;
typedef unsigned short ushort;
typedef unsigned int uint;
-typedef uint32_t u_long;
-typedef uint32_t n_long;
-typedef uint32_t n_time;
-typedef uint16_t n_short;
-typedef uint32_t ulong;
-typedef uint32_t nlong;
-typedef uint32_t ntime;
-typedef uint16_t nshort;
#endif
#ifdef _GNU_SOURCE