25 #ifndef DBUS_SYSDEPS_H
26 #define DBUS_SYSDEPS_H
34 #include <dbus/dbus-errors.h>
35 #include <dbus/dbus-file.h>
36 #include <dbus/dbus-string.h>
55 #include "dbus-sysdeps-wince-glue.h"
61 #define _DBUS_PATH_SEPARATOR ";"
63 #define _DBUS_PATH_SEPARATOR ":"
101 #define DBUS_PID_UNSET ((dbus_pid_t) -1)
103 #define DBUS_UID_UNSET ((dbus_uid_t) -1)
105 #define DBUS_GID_UNSET ((dbus_gid_t) -1)
108 #define DBUS_PID_FORMAT "%lu"
110 #define DBUS_UID_FORMAT "%lu"
112 #define DBUS_GID_FORMAT "%lu"
149 int _dbus_write_socket_with_unix_fds (
int fd,
155 int _dbus_write_socket_with_unix_fds_two (
int fd,
171 int _dbus_connect_tcp_socket_with_nonce (
const char *host,
174 const char *noncefile,
201 dbus_gid_t **group_ids,
211 dbus_bool_t _dbus_daemon_is_session_bus_address_published (
const char *scope);
213 dbus_bool_t _dbus_daemon_publish_session_bus_address (
const char* address,
const char* shm_name);
215 void _dbus_daemon_unpublish_session_bus_address (
void);
240 #if DBUS_HAVE_ATOMIC_INT_COND
241 # define DBUS_HAVE_ATOMIC_INT 1
243 # undef DBUS_HAVE_ATOMIC_INT
254 #define _DBUS_POLLIN 0x0001
256 #define _DBUS_POLLPRI 0x0004
258 #define _DBUS_POLLOUT 0x0002
260 #define _DBUS_POLLERR 0x4000
262 #define _DBUS_POLLHUP 0x2000
264 #define _DBUS_POLLNVAL 0x8000
265 #elif defined(__HAIKU__)
267 #define _DBUS_POLLIN 0x0001
269 #define _DBUS_POLLOUT 0x0002
271 #define _DBUS_POLLERR 0x0004
273 #define _DBUS_POLLPRI 0x0020
275 #define _DBUS_POLLHUP 0x0080
277 #define _DBUS_POLLNVAL 0x1000
280 #define _DBUS_POLLIN 0x0001
282 #define _DBUS_POLLPRI 0x0002
284 #define _DBUS_POLLOUT 0x0004
286 #define _DBUS_POLLERR 0x0008
288 #define _DBUS_POLLHUP 0x0010
290 #define _DBUS_POLLNVAL 0x0020
305 int timeout_milliseconds);
375 void _dbus_exit (
int code) _DBUS_GNUC_NORETURN;
417 dbus_pid_t pid_to_write,
434 void _dbus_init_system_log (
void);
437 DBUS_SYSTEM_LOG_INFO,
438 DBUS_SYSTEM_LOG_SECURITY,
439 DBUS_SYSTEM_LOG_FATAL
440 } DBusSystemLogSeverity;
442 void _dbus_system_log (DBusSystemLogSeverity severity,
const char *msg, ...) _DBUS_GNUC_PRINTF (2, 3);
443 void _dbus_system_logv (DBusSystemLogSeverity severity, const
char *msg, va_list args);
448 #if !defined (DBUS_VA_COPY)
449 # if defined (__GNUC__) && defined (__PPC__) && (defined (_CALL_SYSV) || defined (_WIN32))
450 # define DBUS_VA_COPY(ap1, ap2) (*(ap1) = *(ap2))
451 # elif defined (DBUS_VA_COPY_AS_ARRAY)
452 # define DBUS_VA_COPY(ap1, ap2) memcpy ((ap1), (ap2), sizeof (va_list))
454 # define DBUS_VA_COPY(ap1, ap2) ((ap1) = (ap2))
463 #define _DBUS_BYTE_OF_PRIMITIVE(p, i) \
464 (((const char*)&(p))[(i)])
470 #define _DBUS_DOUBLES_BITWISE_EQUAL(a, b) \
471 (_DBUS_BYTE_OF_PRIMITIVE (a, 0) == _DBUS_BYTE_OF_PRIMITIVE (b, 0) && \
472 _DBUS_BYTE_OF_PRIMITIVE (a, 1) == _DBUS_BYTE_OF_PRIMITIVE (b, 1) && \
473 _DBUS_BYTE_OF_PRIMITIVE (a, 2) == _DBUS_BYTE_OF_PRIMITIVE (b, 2) && \
474 _DBUS_BYTE_OF_PRIMITIVE (a, 3) == _DBUS_BYTE_OF_PRIMITIVE (b, 3) && \
475 _DBUS_BYTE_OF_PRIMITIVE (a, 4) == _DBUS_BYTE_OF_PRIMITIVE (b, 4) && \
476 _DBUS_BYTE_OF_PRIMITIVE (a, 5) == _DBUS_BYTE_OF_PRIMITIVE (b, 5) && \
477 _DBUS_BYTE_OF_PRIMITIVE (a, 6) == _DBUS_BYTE_OF_PRIMITIVE (b, 6) && \
478 _DBUS_BYTE_OF_PRIMITIVE (a, 7) == _DBUS_BYTE_OF_PRIMITIVE (b, 7))
531 _dbus_replace_install_prefix (
const char *configure_time_path);
539 #include "dbus-sysdeps-win.h"