timedated: use libsystemd-bus instead of libdbus for bus communication

Among other things this also adds a few things necessary for the change:

- Considerably more powerful error returning APIs in libsystemd-bus

- Adapter for connecting an sd_bus to an sd_event

- As I reworked the PolicyKit logic to the new library I also made it
  asynchronous, so that PolicyKit requests of one user cannot block out
  another user anymore.

- We always use the macro names for common bus error. That way it is
  harder to mistype them since the compiler will notice
This commit is contained in:
Lennart Poettering
2013-10-16 06:15:02 +02:00
parent 7a37d62501
commit 40ca29a137
31 changed files with 1541 additions and 890 deletions
+2 -3
View File
@@ -61,8 +61,7 @@
#include "fdset.h"
#include "build.h"
#include "fileio.h"
#include "bus-internal.h"
#include "bus-message.h"
#include "bus-util.h"
#ifndef TTY_GID
#define TTY_GID 5
@@ -1187,7 +1186,7 @@ static int register_machine(void) {
NULL,
"sayssusa(sv)",
arg_machine,
SD_BUS_APPEND_ID128(arg_uuid),
SD_BUS_MESSAGE_APPEND_ID128(arg_uuid),
"nspawn",
"container",
(uint32_t) 0,