Commit graph

2170 commits

Author SHA1 Message Date
Frank Osterfeld
25ceeeb679 Cleanup of nonce code
Remove the write_file function and use the existing
_dbus_string_save_to_file, improve error handling

Cherry picked from commit 0f7b026d01be7e0fd444cdb56e5f9b7a5137a062 in
the dbus4win repository. Edited to apply and fix whitespace issues by
tml@iki.fi.
2009-12-01 08:43:37 +01:00
Frank Osterfeld
5e2a99c12c The current state of the nonce-tcp implementation
Merged and cleaned up patch from my [Frank Osterfeld's] local work
branch.

Cherry-picked from commit e2801eca57b2d9e09afd662ed5ef6fc83be73afc and
edited by tml@iki.fi to make it apply, and fixing whitespace issues.
2009-12-01 08:43:36 +01:00
Nguyễn Thái Ngọc Duy
366ffe4478 bus/Makefile.am: make dbus-daemon and friends bin_PROGRAMS on Windows
On Linux, dbus-daemon and dbus-daemon-launch-helper are treated specially
because they need permission adjustment.

On Windows, all executables are stubs, created by libtool. The real
executables are in .libs. We need to use libtool to install them
properly. So let's make them bin_PROGRAMS on Windows.
(cherry picked from commit 7fb35992d67433ac3ba82e9e2e786e123323456d)
2009-12-01 08:38:06 +01:00
Frank Osterfeld
6900afeb7d -util.c doesn't belong into the lib (cherry picked from commit 6191f6dda62e43765d5f48d677f7a2349e616a63) 2009-12-01 08:38:05 +01:00
Nguyễn Thái Ngọc Duy
a990f2507e Move some functions from dbus-sysdeps-util-win.c to dbus-sysdeps-win.c
These are used by dbus-sysdeps-win.c and it is not linked together
with dbus-sysdeps-util-win.c
(cherry picked from commit 24b612adbf8045b8b00af15f8d44eb38f964641f)
2009-12-01 08:38:04 +01:00
Nguyễn Thái Ngọc Duy
612e1b38f4 use WINDRES instead of RC to compile rc file
This is the way used by GTK+ and other packages. I don't know much about "RC" though.
(cherry picked from commit d5b993ebc1411b15e4563d05fbd92cf8b29cbb4c)
2009-12-01 08:38:03 +01:00
Nguyễn Thái Ngọc Duy
4c02c62621 remove dbus-uuidgen from Windows build (cherry picked from commit 73873e002ac9ba6159388b2c7b4190c30961ec68) 2009-12-01 08:38:02 +01:00
Nguyễn Thái Ngọc Duy
fe365b416c configure.in: do not define DBUS_UNIX unconditionally (cherry picked from commit 5c072b8c4d912dfe34b72c2b7bbcb4ea359c98d7) 2009-12-01 08:38:01 +01:00
Marc Mutz
ae776f576a bus/Makefile.am: conditional compilation for W32, use EXEEXT in install hooks (cherry picked from commit 551a9c446b782167aa8b0a74a41a1b7ffb42c6eb) 2009-12-01 08:36:31 +01:00
Marc Mutz
6bb37dc542 tools/Makefile.am: conditional compilation for W32 (cherry picked from commit 8b2f7581ef46b6e9bd29b8399657c039cb49f030) 2009-12-01 08:36:30 +01:00
Marc Mutz
a871d0f42e Makefile.am's: reorder libraries so static libs come first (fixes linking on W32) (cherry picked from commit f88bd88d6b4b318f9401fae595343c8b1bacf654) 2009-12-01 08:36:29 +01:00
Marc Mutz
5a0a3b4451 configure.in: don't look for X11 on W32 (cherry picked from commit 73730866ec198ac4c24dc69c9f62b4a3a2f05bf1) 2009-12-01 08:36:28 +01:00
Marc Mutz
558d3e10a1 configure.in: add W32 extra libs (cherry picked from commit 909f2b23596247aaef4c5945853eebf607f7d329) 2009-12-01 08:36:27 +01:00
Marc Mutz
83387d2ae0 WIN32: add versioninfo, and export symbols
* dbus/versioninfo.rc.in: (new file) copied and modified from libgpg-error
 * configure.in: enable libtool's W32 support, extract version information
    for use in versioninfo.rc.in, define DBUS_WIN, define DBUS_UNIX only on
    unix (adapted from libgpg-error)
 * dbus/Makefile.am: switch sources depending on platform,
    compile versioninfo.rc, add dbus-1.def (not used since buildsystem creates
    its own .def file apparently)
(cherry picked from commit cfa717ddb7b9258a862d87cd5b3bdbe582ce106c)
2009-12-01 08:36:26 +01:00
Ralf Habacker
8ab7f05a19 fixed DBUS_VA_COPY for msvc 2009-11-30 16:01:19 +01:00
Ralf Habacker
fd049c3455 use dbus provided wait function 2009-11-30 16:00:20 +01:00
Ralf Habacker
3b253a5d27 keep in sync with source 2009-11-30 14:08:30 +01:00
Frank Osterfeld
01d2b26bed _dbus_get_install_root assumes that dbus-daemon is in a bin/ subdirectory. That's not a common directory structure on windows, so weaken the assumption: $somepath/bin/dbus-daemon.exe -> $somepath $somepath/dbus-daemon.exe, where somepath doesn't end in /bin/: -> $somepath i.e., use dbus-daemon.exe's directory as root if that directory is not a "bin" directory (cherry picked from commit 2d2055b2fa7f92c144e9a182a9a091ebe5215d7d) 2009-11-30 13:43:20 +01:00
Frank Osterfeld
be3d150691 define _DEBUG for debug builds (cherry picked from commit 3e261c022623306d4dba0cb11fa342abff61aee9) 2009-11-30 13:43:19 +01:00
Frank Osterfeld
08f8057d1f do not run test binaries as unit tests if they aren't unit tests (cherry picked from commit 5281f5b113bd97152d1c9eac050432bda3274748) 2009-11-30 13:43:18 +01:00
Tor Lillqvist
7d931da812 dbus/dbus-sysdeps-win.c: _dbus_windows_user_is_process_owner belongs to -util-win.c (cherry picked from commit 952caf475334b7c38084d4a992abef3f4e0d4cfb) 2009-11-30 13:43:17 +01:00
Tor Lillqvist
07c63490d2 dbus/dbus-sysdeps-util-win.c: use GetFileAttributes instead of CreateFile in _dbus_file_exists (cherry picked from commit 3ba582b91361785c3eb0121e8b9e85d046eea75f) 2009-11-30 13:43:16 +01:00
Tor Lillqvist
fb11d1f9f3 dbus/dbus-sysdeps-win.c: tighter "scoping" for alternate _dbus_poll implementations (cherry picked from commit 6828a25073c16fb5af55c4aaf16a08eb90e4676d) 2009-11-30 13:43:15 +01:00
Ralf Habacker
f128dc3cb5 keep def file in sync with source 2009-11-30 13:30:12 +01:00
Ralf Habacker
e6f2be5f19 removed duplicated implementation 2009-11-30 13:24:42 +01:00
Tor Lillqvist
c366d25cf1 dbus/dbus-sysdeps-util-win.c: remove unused str*_s definitions (cherry picked from commit 373214317c33031547f3788cffed8a832142fc43) 2009-11-30 13:21:37 +01:00
Tor Lillqvist
8836d6c5bf dbus/dbus-sysdeps-*win.c: remove #undef open, which has no effect (cherry picked from commit 737e3782cd16424a6f1b941b64867178bb5634be) 2009-11-30 13:21:36 +01:00
Tor Lillqvist
ab7d00f2ed dbus/dbus-sysdeps-win.h: move declarations into .c (used nowhere else) (cherry picked from commit 0ea30b511e5b099c43bfdf2cbff0f3935917e057) 2009-11-30 13:21:35 +01:00
Tor Lillqvist
6f4bf6cc31 dbus/dbus-sysdeps-win.c: add _dbus_win_error_string, and use after MoveFileEx instead of _dbus_error_from_errno (cherry picked from commit 1d0b2dacf52faffbeba09af2b309683ccc71547a) 2009-11-30 13:21:34 +01:00
Tor Lillqvist
f28b7bb5a5 dbus/dbus-sysdeps-win.c: use MoveFileEx, not unlink+rename, in _dbus_string_save_to_file (cherry picked from commit c31bb3c262db1e6e42ec1bc9a6e8063c625a7cb2) 2009-11-30 13:21:33 +01:00
Tor Lillqvist
9ea9cd1bdd dbus/dbus-sysdeps-win.c: use GetTempPath, not getenv, in _dbus_get_tmpdir (cherry picked from commit c2366c5410149e896cb56c3d17bb995308e18292) 2009-11-30 13:21:32 +01:00
Tor Lillqvist
3b8aa7dc7c dbus/dbus-sysdeps-win.c: _dbus_getpid() returns dbus_pid_t (cherry picked from commit 40a01bf6d2c6d216093d309ca4c48602a585960b) 2009-11-30 13:21:31 +01:00
Tor Lillqvist
2df200caf9 dbus/dbus-sysdeps-win.c: set an error when _close fails in _dbus_pipe_close (cherry picked from commit 6671b4a20da468bad6842815a1161a98251b66fc) 2009-11-30 13:21:30 +01:00
Tor Lillqvist
22d12f61fa dbus/dbus-sysdeps-win.c: Use CryptoApi to get random numbers (cherry picked from commit 5f7ae46398818200b3fdcdfe80b78bee31a3e89b) 2009-11-30 13:21:30 +01:00
Tor Lillqvist
67a9fd2082 dbus/dbus-sysdeps-*win.c: remove DBusFile abstraction (cherry picked from commit 2895660b0e683d71dd51911819c0f31aff8517c3) 2009-11-30 13:21:28 +01:00
Tor Lillqvist
a549878e2d dbus/dbus-sysdeps-win.c: #define socklen_t -> typedef (cherry picked from commit eb104f4573fcbcbf3a87d673a023b5db4a249867) 2009-11-30 13:14:20 +01:00
Tor Lillqvist
8d61e82f91 dbus/dbus-sysdeps-win.h: add _dbus_win_get_dll-module (cherry picked from commit da5e8e14029cb64a65fe482e232be1d786a8ee19) 2009-11-30 13:14:19 +01:00
Tor Lillqvist
b9eae52cc0 dbus/dbus-spawn-win.c: implement missing _dbus_babysitter_get_child_exit_status (cherry picked from commit 7a9863b9847380dbb8400f895934d7f282ebdbf2) 2009-11-30 13:14:18 +01:00
Tor Lillqvist
8a7f49a51e dbus/dbus-internals.c: "#define inline" is only needed on MSVC, not mingw (cherry picked from commit 314e91e3ee2566477918a51dbddd9eb141b33a23) 2009-11-30 13:14:18 +01:00
Ralf Habacker
807fd7e731 _dbus_verbose_real: (optionally) use OutputDebugString() (cherry picked from commit fd6d354c47b4b8dc24ce32e31171568a8704e7d1) 2009-11-30 13:11:26 +01:00
Ralf Habacker
b94b853cd7 added DBUS_USE_OUTPUT_DEBUG_STRING option 2009-11-30 13:10:38 +01:00
Tor Lillqvist
230caac475 dbus/dbus-internals.h: 2x const char foo[] -> const char foo * (cherry picked from commit 62eaf8c91160abdeab6a46bb7bff737e13a390cf) 2009-11-30 12:21:28 +01:00
Tor Lillqvist
8c5456c337 dbus/dbus-transport.c: _dbus_credentials_get_windows_sid might return NULL (cherry picked from commit 8d8d5fa1babc8f51f1d1bb95b8116850978c60d9) 2009-11-30 12:21:27 +01:00
Tor Lillqvist
ef86bcedc8 dbus/dbus-transport.c: fix {our,auth}_identity mismatch (cherry picked from commit e15f1cde3b5893357f640e360f64c0a1ae37f93b) 2009-11-30 12:21:26 +01:00
Ralf Habacker
85efbce5d6 completed notes 2009-11-30 12:14:24 +01:00
Tor Lillqvist
b5c8483f44 tools/dbus-launch-win.c: TODO++ (cherry picked from commit 0f5dbec6407975d6a93fbb2cbcd58ab192961cf8) 2009-11-30 12:04:59 +01:00
Tor Lillqvist
2ca591df21 dbus/dbus-connection.c: use dbus_message_type_to_string instead of printing the naked message type (cherry picked from commit 33d858e83e3cb1f55ed257ffef930b8f49c3ffc7) 2009-11-30 12:04:58 +01:00
Ole André Vadla Ravnås
29e8f9917a Fix broken Windows implementation of _dbus_printf_string_upper_bound().
Pass the correct buffer size when trying again, and keep trying with
larger buffer sizes, doubling the size each time.
(cherry picked from commit 95832a94607eea609de994467b7d64e36af72e6b)
2009-11-30 12:04:58 +01:00
Ole André Vadla Ravnås
91f5972fa1 Use CreateDirectory() instead of complicating things.
This is Windows sysdeps after all, and _dbus_mkdir() wasn't used anywhere else.
(cherry picked from commit 0bbe3787ce1e9e992f2bcbbdfcab1dcdb0b41f24)
2009-11-30 12:00:20 +01:00
Ole André Vadla Ravnås
f2b62600dc Remove a misleading comment.
errno.h is present and needed on Windows. (It's not present on Windows CE though.)
(cherry picked from commit cef676c0c7ea8ad352e1ecf1c3643edb1abd7ad6)
2009-11-30 12:00:19 +01:00