[Rpm-maint] [PATCH] plugins/systemd_inhibit.c: Define DBUS_TYPE_UNIX_FD if undefined.

Panu Matilainen pmatilai at laiskiainen.org
Tue Mar 5 17:15:30 UTC 2013


On 03/05/2013 04:24 PM, Mark Wielaard wrote:
> Older dbus versions (at least 1.2.24) don't define it by default.
> ---
>   plugins/systemd_inhibit.c |    4 ++++
>   1 files changed, 4 insertions(+), 0 deletions(-)
>
> diff --git a/plugins/systemd_inhibit.c b/plugins/systemd_inhibit.c
> index badcc9e..1dd66e6 100644
> --- a/plugins/systemd_inhibit.c
> +++ b/plugins/systemd_inhibit.c
> @@ -3,6 +3,10 @@
>   #include <rpm/rpmts.h>
>   #include "plugin.h"
>
> +#ifndef DBUS_TYPE_UNIX_FD
> +#define DBUS_TYPE_UNIX_FD ((int) 'h')
> +#endif
> +
>   rpmPluginHook PLUGIN_HOOKS = (
>       PLUGINHOOK_INIT |
>       PLUGINHOOK_CLEANUP |
>

Hum... dbus 1.2.24 would be RHEL-6'ish, right? In which case the whole 
plugin makes no sense at all because it actually needs to have a fairly 
recent systemd running on the system to do anything at all.

Dunno, I can certainly apply that but then again it might make more 
sense to not even try compiling it with dbus that old, as anything with 
that old dbus version is highly unlikely to be running systemd in the 
first place (which however is something that cannot be tested for during 
build)

	- Panu -


More information about the Rpm-maint mailing list