diff options
author | Romain Pokrzywka <romain@kdab.com> | 2010-05-04 15:41:35 +0200 |
---|---|---|
committer | Ralf Habacker <ralf.habacker@freenet.de> | 2010-05-05 07:57:28 +0200 |
commit | 3222b64d4a5e333ad3f95374a17fc4ecd6bc1431 (patch) | |
tree | df5457f51da2c8f750720a9e9b3da6114f4211b8 /dbus | |
parent | 2c604f887efed7b7d16ed8b5cb50e50af8332564 (diff) |
fix {u}intptr_t usage on wince with msvc
Diffstat (limited to 'dbus')
-rw-r--r-- | dbus/dbus-hash.h | 5 | ||||
-rw-r--r-- | dbus/dbus-pipe.h | 9 | ||||
-rw-r--r-- | dbus/dbus-sysdeps-util-win.c | 1 | ||||
-rw-r--r-- | dbus/dbus-sysdeps-wince-glue.h | 10 | ||||
-rw-r--r-- | dbus/dbus-sysdeps.h | 4 |
5 files changed, 21 insertions, 8 deletions
diff --git a/dbus/dbus-hash.h b/dbus/dbus-hash.h index 424a9464..d1ca246c 100644 --- a/dbus/dbus-hash.h +++ b/dbus/dbus-hash.h @@ -24,8 +24,8 @@ #ifndef DBUS_HASH_H #define DBUS_HASH_H -#ifdef HAVE_CONFIG_H -#include <config.h> +#ifdef HAVE_STDINT_H +#include <stdint.h> #endif #ifdef HAVE_INTTYPES_H @@ -34,6 +34,7 @@ #include <dbus/dbus-memory.h> #include <dbus/dbus-types.h> +#include <dbus/dbus-sysdeps.h> DBUS_BEGIN_DECLS diff --git a/dbus/dbus-pipe.h b/dbus/dbus-pipe.h index 2ec80da2..f6eac5f9 100644 --- a/dbus/dbus-pipe.h +++ b/dbus/dbus-pipe.h @@ -25,8 +25,8 @@ #ifndef DBUS_PIPE_H #define DBUS_PIPE_H -#ifdef HAVE_CONFIG_H -#include <config.h> +#ifdef HAVE_STDINT_H +#include <stdint.h> #endif #ifdef HAVE_INTTYPES_H @@ -36,10 +36,11 @@ #include <dbus/dbus-types.h> #include <dbus/dbus-errors.h> #include <dbus/dbus-string.h> +#include <dbus/dbus-sysdeps.h> -typedef struct { +struct DBusPipe { intptr_t fd_or_handle; -} DBusPipe; +}; void _dbus_pipe_init (DBusPipe *pipe, intptr_t fd); diff --git a/dbus/dbus-sysdeps-util-win.c b/dbus/dbus-sysdeps-util-win.c index 4568fa28..6c101e7d 100644 --- a/dbus/dbus-sysdeps-util-win.c +++ b/dbus/dbus-sysdeps-util-win.c @@ -34,6 +34,7 @@ #include "dbus-sysdeps-win.h" #include "dbus-sockets-win.h" #include "dbus-memory.h" +#include "dbus-pipe.h" #include <stdio.h> #include <stdlib.h> diff --git a/dbus/dbus-sysdeps-wince-glue.h b/dbus/dbus-sysdeps-wince-glue.h index 6d8e3b1e..3391be9e 100644 --- a/dbus/dbus-sysdeps-wince-glue.h +++ b/dbus/dbus-sysdeps-wince-glue.h @@ -29,7 +29,6 @@ #include <stdarg.h> /* For getaddrinfo. */ -#define _WIN32_WCE 0x0401 #include <windows.h> #undef interface @@ -107,10 +106,19 @@ void abort (void); #define _S_IREAD 0000400 /* read permission, owner */ #define _S_IWRITE 0000200 /* write permission, owner */ #define _S_IEXEC 0000100 /* execute/search permission, owner */ + #ifndef __OFF_T_DEFINED typedef long off_t; #define __OFF_T_DEFINED #endif +#ifndef _INTPTR_T_DEFINED +typedef int intptr_t; +#define _INTPTR_T_DEFINED +#endif +#ifndef _UINTPTR_T_DEFINED +typedef unsigned int uintptr_t; +#define _UINTPTR_T_DEFINED +#endif #ifndef _MAX_FNAME #define _MAX_FNAME 256 diff --git a/dbus/dbus-sysdeps.h b/dbus/dbus-sysdeps.h index e00c2f91..b183b1f5 100644 --- a/dbus/dbus-sysdeps.h +++ b/dbus/dbus-sysdeps.h @@ -28,7 +28,6 @@ #include <dbus/dbus-errors.h> #include <dbus/dbus-file.h> #include <dbus/dbus-string.h> -#include <dbus/dbus-pipe.h> /* this is perhaps bogus, but strcmp() etc. are faster if we use the * stuff straight out of string.h, so have this here for now. @@ -68,6 +67,9 @@ typedef struct DBusList DBusList; /** Object that contains a list of credentials such as UNIX or Windows user ID */ typedef struct DBusCredentials DBusCredentials; +/** A wrapper around a pipe descriptor or handle */ +typedef struct DBusPipe DBusPipe; + /** * @addtogroup DBusSysdeps * |