pkgsrc-Users archive

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

Re: libXfont2 fail with libbsd



On Wed, Jun 17, 2020 at 11:33:01AM +0000, nia wrote:
> On Wed, Jun 17, 2020 at 11:27:45AM +0000, nia wrote:
> > On Wed, Jun 17, 2020 at 11:25:21AM +0000, nia wrote:
> > > Please post the output of configure (or configure.log)
> > > It's likely there's a way to work around this cleanly.
> > > 
> > > It's clearly supposed to fall back to embedded copies of strlcpy
> > > et al if it detects them missing. It shouldn't be relying on
> > > libbsd given that it isn't part of pkgsrc.
> > 
> > This is likely caused by linux packages polluting the build
> > environment and wouldn't happen when building in a clean sandbox
> > (as various developers do for the CentOS builds).
> 
> Please try adding this to the package makefile:
> 
> CONFIGURE_ENV.Linux+=	ac_cv_search_strlcat=no

Yes, that should do the trick and is better than test the file.

But in my opinion the best should be to add the code upstream. They
put the code to include bsd/sdtlib.h and bsd/string.h when the
system has libbsd installed. It is like they forgot to add HAVE_LIBBSD
to configure.

src/util/replace.h
======================
[...]
#include <stdlib.h>
#if defined(HAVE_LIBBSD) && defined(HAVE_REALLOCARRAY)
#include <bsd/stdlib.h>       /* for reallocarray */
#endif
[...]
#include <string.h>
#if defined(HAVE_LIBBSD) && defined(HAVE_STRLCPY)
#include <bsd/string.h>       /* for strlcpy, strlcat */
#endif
[...]
=======================

I will give it a try.

adr


Home | Main Index | Thread Index | Old Index