tech-pkg archive

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

Re: chosing a C++ version/compiler (was: icu wants c++11)

On Fri, Apr 28, 2017 at 11:06:40AM +0100, Jonathan Perkin wrote:
> * On 2017-04-24 at 13:50 BST, Joerg Sonnenberger wrote:
> > On Mon, Apr 24, 2017 at 02:07:17PM +0200, Edgar Fuß wrote:
> > > Is C++n a superset of C++m for n>m?
> > 
> > Mostly. There are a couple of things that explicitly create problems for
> > m == 2003 and there is the problem of at least one semantic change that
> > can potentially result in miscompiled code (destructors are tagged as
> > not throwing by default in 2011). For m>=2011 it should be transparent.
> In that case what about something like this:
> tl;dr: introduce CXX_REQD as a similar mechanism to GCC_REQD, packages
> append to it what they need, then we distil it to the most recent
> version and use that for the build.
> todo: set GCC_REQD based on it, i.e. if CXX_REQD>= c++11 then
> automatically set GCC_REQD+=4.7 or whatever
> This is running through a bulk build at present.

This looks good to me.

Please also document it in the pkgsrc guide.

We should probably make pkglint warn about "-std=c++*" and recommend
CXX_REQD when this goes in.


Home | Main Index | Thread Index | Old Index