curl-users
Re: [PATCH] save URL to extended file attributes
Date: Fri, 5 Nov 2010 12:44:36 +0100
On Fri November 5 2010 12:30:45 Stefan Tomanek wrote:
> Dies schrieb Kamil Dudka (kdudka_at_redhat.com):
> > I don't think it was. It looks rather as a mixture to me -- inclusion of
> > a header provided by libattr, but the library wasn't linked, so it
> > actually couldn't use anything of its implementation.
>
> Actually, the linking of libattr is not needed - the function setxattr is
Yep, that explains why it was working.
> already defined by glibc, and the inclusion of <attr/xattr.h> can be
> changed to <sys/xattr.h> without trouble.
Sounds like a good idea, as included headers should match the used libraries.
> > > /usr/include/sys/xattr.h is the Linux system header
> >
> > On my boxes (RHEL, Fedora, Gentoo Linux) the header is provided by glibc.
>
> stefan_at_exa:~$ dpkg -S /usr/include/sys/xattr.h
> libc6-dev: /usr/include/sys/xattr.h
>
> > > Even more reason to do a configure test for this, as I expect that lots
> > > of people won't have libattr present.
>
> And from what I see, it's not even needed, I'll do some more tests and
> reformulate the patch.
Then we need to check for the presence of <sys/xattr.h> and the implementation
of setxattr(). There might be also a compile-time option to disable the
feature, even if both are available.
Kamil
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-users
FAQ: http://curl.haxx.se/docs/faq.html
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2010-11-05