[PATCH v4] When using the Mozilla NSS library for cryptography, include the NSPR header files
Mike Frysinger
vapier@gentoo.org
Sat Jun 11 14:11:00 GMT 2016
On 11 Jun 2016 11:06, Florian Weimer wrote:
> On 06/11/2016 10:02 AM, Mike Frysinger wrote:
> >> Isn't using pkg-config in a GNU project a bit tricky?
> >
> > i don't see why it would be. it's pretty much defacto now for any
> > reasonable library. GNOME, a GNU project, is heavily invested in
> > it.
>
> glibc doesn't provide pkg-config data, either. :-/
>
> (You'd need it for statically linking libcrypt when using NSS. Might
> also help with the libpthread.a situation.)
true. i wouldn't be against adding it since on our side, the overhead
is low -- we just generate text files at configure time and install
them and that's it.
> >> You can link
> >> against NSS, but then you also get libdl and libpthread, which we do not
> >> want as dependencies of libgcrypt.
> >
> > i'm not sure what you're saying here. `pkg-config --libs nss` doesn't
> > pull in any of those libs.
>
> I get this:
>
> -lssl3 -lsmime3 -lnss3 -lnssutil3 -lplds4 -lplc4 -lnspr4 -lpthread -ldl
depending on how nss is built, it might be a bug in your distro's .pc
file. if nss is providing shared libs, then nspr/pthread/dl should be
listed in Libs.private instead of Libs.
that said ...
> And if freebl needs nspr headers, it may pull in libnspr as well, which
> depends on libpthread.
but that issue exists regardless of where we source the data right ? if
we ask nss-config/nspr-config (or nss.pc/nspr.pc) and it ends up linking
against pthread/dl even at runtime, we've lost.
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://sourceware.org/pipermail/libc-alpha/attachments/20160611/26023c0d/attachment.sig>
More information about the Libc-alpha
mailing list