[SSSD] [PATCHES] RHEL6 build fixes

Nikolai Kondrashov Nikolai.Kondrashov at redhat.com
Wed Jun 18 15:19:54 UTC 2014


On 06/18/2014 01:15 PM, Lukas Slebodnik wrote:
> On (17/06/14 15:09), Nikolai Kondrashov wrote:
>>From a4ab4393debdec591a45736a6f563144b0088baa Mon Sep 17 00:00:00 2001
>> From: Nikolai Kondrashov <Nikolai.Kondrashov at redhat.com>
>> Date: Tue, 17 Jun 2014 11:59:47 +0300
>> Subject: [PATCH 3/3] build: Augment systemdconfdir at configure stage
>>
>> Add "/sssd.service.d" to systemdconfdir at configure stage, instead of
>> the make stage. This way, if systemd is not used, systemdconfdir
>> variable stays empty. That in turn, works around the attempt by older
>> versions of Automake to create the installation directory even though no
>> files are installed there [1].
>>
>> This fixes installation and distcheck target on RHEL6, where an
>> "/sssd.service.d" directory creation would otherwise be attempted.
>>
>> ---
> make tried to create directory "/sssd.service.d",
> because variable "systemdconfdir" was not empty.
> It should be empty if initscript is sysv.
>
> Right approach should be different.

You imply that my version is somehow wrong, which it isn't. It is keeping
the original behavior as much as possible, while fixing the issue.

> --- a/src/conf_macros.m4
> +++ b/src/conf_macros.m4
> @@ -227,6 +227,9 @@ AC_DEFUN([WITH_SYSTEMD_CONF_DIR],
>         AC_MSG_ERROR([Could not detect systemd config directory])
>       fi
>     fi
> +  if test x"$systemdconfdir" != x; then
> +    systemdconfdir="$systemdconfdir/sssd.service.d"
> +  fi
>     AC_SUBST(systemdconfdir)
>     ])

The check for empty systemdconfdir is redundant, as that is prevented by the
previous conditions, unless I read something wrong.

> or alternative version
>
> --- a/src/conf_macros.m4
> +++ b/src/conf_macros.m4
> @@ -226,6 +226,7 @@ AC_DEFUN([WITH_SYSTEMD_CONF_DIR],
>       if test x"$systemdconfdir" = x; then
>         AC_MSG_ERROR([Could not detect systemd config directory])
>       fi
> +    systemdconfdir="$systemdconfdir/sssd.service.d"
>     fi
>     AC_SUBST(systemdconfdir)
>     ])

This version alters the interpretation of the option value (i.e.
"/sssd.service.d" is no longer appended to a non empty value), which warrants
a separate patch. I don't know enough at this moment to say if it would be
correct.

I wouldn't prefer these versions over mine so far.

Nick



More information about the sssd-devel mailing list