From 8a6c3c55a7b5ff2042ad6973ddd7ab73236de047 Mon Sep 17 00:00:00 2001 From: Henrik Rydberg Date: Mon, 24 Nov 2008 10:51:54 +0100 Subject: Initial version Signed-off-by: Henrik Rydberg --- hal-abi.h | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 hal-abi.h (limited to 'hal-abi.h') diff --git a/hal-abi.h b/hal-abi.h new file mode 100644 index 0000000..277580f --- /dev/null +++ b/hal-abi.h @@ -0,0 +1,28 @@ +/* + * HAL ABI + * + * The following is all hal information needed in order to compile + * a hald-addon. + */ + +/* Structure declarations */ +struct LibHalContext; +struct DBusConnection; + +/* Simple error handling */ +#define setup_logger() +#define eprintf(...) (fprintf(stderr, __VA_ARGS__), fprintf(stderr, "\n")) +#define WARNING(...) eprintf("addon-warning: " __VA_ARGS__) +#define DEBUG(...) eprintf("addon-debug: " __VA_ARGS__) +#define ERROR(...) eprintf("addon-error: " __VA_ARGS__) +#define HAL_WARNING(x) WARNING x +#define HAL_DEBUG(x) DEBUG x +#define HAL_ERROR(x) ERROR x + +/* Function declarations */ +struct LibHalContext * +libhal_ctx_init_direct(struct DBusError *error); + +struct DBusConnection * +libhal_ctx_get_dbus_connection(struct LibHalContext *ctx); + -- cgit v1.2.3