pkgsrc-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: CVS commit: pkgsrc/www/libecap
On Wed, Jun 22, 2016 at 05:38:31PM +0100, Patrick Welche wrote:
> On Wed, Jun 22, 2016 at 05:02:39PM +0100, Patrick Welche wrote:
> > On Tue, Jun 21, 2016 at 05:57:07PM +0000, Joerg Sonnenberger wrote:
> > > +--- src/libecap/common/memory.h.orig 2016-06-20 16:15:17.012240492 +0000
> > > ++++ src/libecap/common/memory.h
> > > +@@ -4,14 +4,24 @@
> > > + #define LIBECAP__COMMON_MEMORY_H
> > > +
> > > + #include <libecap/common/libecap.h>
> > > ++#include <ciso646>
> > > ++
> > > ++#if __cplusplus >= 201103L || defined(_LIBCPP_VERSION)
> > > ++#include <functional>
> > ^^^^^^^^^^
> > If I change this to <memory>, things no longer break for me on
> > -current with gcc 5.4.0 and -std=c++14, -std=c++11, and no -std flag.
>
> But then squid3 fails to build. It seems that it needs the tr1 version:
>
> http://bugs.squid-cache.org/show_bug.cgi?id=4376#c4
Can of worms: as you can see I can fix squid either with
const shared_ptr<libecap::adapter::Service>theService;
1) return static_cast<bool>(theService);
2) return theService != nullptr;
Any style preference between 1) and 2)?
But then there is another issue: with your patch, on gcc with no -std
flag, libecap will contain:
000000000000d34a T libecap::RegisterHost(std::tr1::shared_ptr<libecap::host::Host> const&)
squid3 will then compile with -std=c++11 and look for the function without
tr1 which doesn't exist in libecap and fail to link.
We can add -std=c++11 to libecap, which makes your patch even simpler:
just remove the tr1.
So what do you suggest?
Cheers,
Patrick
Home |
Main Index |
Thread Index |
Old Index