Re: [PATCH] perf auto-dep: Speed up feature tests by building themin parallel

From: Ingo Molnar
Date: Tue Oct 01 2013 - 04:38:20 EST



* Geert Uytterhoeven <geert@xxxxxxxxxxxxxx> wrote:

> On Mon, Sep 30, 2013 at 7:34 PM, Linus Torvalds
> <torvalds@xxxxxxxxxxxxxxxxxxxx> wrote:
> > On Mon, Sep 30, 2013 at 10:12 AM, Arnaldo Carvalho de Melo
> > <acme@xxxxxxxxxxxxxxxxxx> wrote:
> >>
> >> Checking why that strlcpy failed...
> >
> > I don't think glibc does strlcpy. It's not a standard C function, and
> > it's somewhat controversial (although I dislike strncpy more with the
> > crazy zero-padding, ugh).
>
> Indeed, e.g. on Ubuntu it's in libbsd, so you also need to #include
> <bsd/string.h> and link with -lbsd.

Well, the point of the feature test is not to pick up an external
definition of strlcpy(), but to keep working on systems where strcpy() has
been patched into _glibc_, where we cannot avoid linking to it. (ARCH
Linux is such a distribution for example.)

So it's a quirk in essence - and I think marking our implementation as
__weak ought to solve that.

Thanks,

Ingo
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/