Re: cifs-utils: make fails if keyutils isn't installed

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2012/1/9 Jeff Layton <jlayton@xxxxxxxxx>:
> On Mon, 9 Jan 2012 14:00:15 -0200
> Frédéric L. W. Meunier  <fredlwm@xxxxxxxxxxx> wrote:
>
>> I moved from cifs-utils 5.0 to 5.2. I didn't have keyutils installed and
>> the compilation failed because configure checks for its presence, but
>> doesn't abort if it's missing, and make tries to link to it.
>>
>> ...
>> checking keyutils.h usability... no
>> checking keyutils.h presence... no
>> checking for keyutils.h... no
>> configure: WARNING: keyutils.h not found, consider installing
>> keyutils-libs-devel. Disabling cifs.upcall.
>> configure: WARNING: keyutils.h not found, consider installing
>> keyutils-libs-devel. Disabling cifs.idmap.
>> ...
>>
>> Makefile.in:
>>
>> @CONFIG_CIFSACL_TRUE@getcifsacl_LDADD = -lkeyutils $(WINB_LDADD)
>> @CONFIG_CIFSACL_TRUE@setcifsacl_LDADD = -lkeyutils $(WINB_LDADD)
>>
>> Apparently, getcifsacl and setcifsacl don't use keyutils at all, but
>> cifs-utils links to it ?
>
> Good catch. Does this patch fix it?
>
> ----------------------[snip]--------------------
>
> [PATCH] get/setcifsacl: don't link in -lkeyutils
>
> These binaries don't use keys API at all. There's no need to link in
> the keys library.
>
> Reported-by: Frédéric L. W. Meunier  <fredlwm@xxxxxxxxxxx>
> Signed-off-by: Jeff Layton <jlayton@xxxxxxxxx>
> ---
>  Makefile.am |    4 ++--
>  1 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/Makefile.am b/Makefile.am
> index cb20442..038cd0e 100644
> --- a/Makefile.am
> +++ b/Makefile.am
> @@ -55,12 +55,12 @@ endif
>  if CONFIG_CIFSACL
>  bin_PROGRAMS += getcifsacl
>  getcifsacl_SOURCES = getcifsacl.c
> -getcifsacl_LDADD = -lkeyutils $(WINB_LDADD)
> +getcifsacl_LDADD = $(WINB_LDADD)
>  man_MANS += getcifsacl.1
>
>  bin_PROGRAMS += setcifsacl
>  setcifsacl_SOURCES = setcifsacl.c
> -setcifsacl_LDADD = -lkeyutils $(WINB_LDADD)
> +setcifsacl_LDADD = $(WINB_LDADD)
>  man_MANS += setcifsacl.1
>
>  endif
> --
> 1.7.7.4
>

Should have never listed keyutils library on the link line in
the first place.

Acked-by: Shirish Pargaonkar <shirishpargaonkar@xxxxxxxxx>
--
To unsubscribe from this list: send the line "unsubscribe linux-cifs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux