[lsb-discuss] LSB, GCC versions C++11 and libstdc++

Dallman, John john.dallman at siemens.com
Wed Feb 27 16:11:06 UTC 2013

> You've asked some good questions and I hope someone will set out to
> document those and some of the stuff I've just noted.

It does seem important for LSB to have working C++11 support quite soon. I'm
getting worried that if LSB doesn't reflect reasonably up-to-date technology,
the distributors will lose interest in it, at which point it is history.

On the application developer side, LSB is already a less-than-universal tool,
for reasons we don't need to thrash over again, but if it ends up impeding
adoption of C++11, it will likely get discarded from operations that currently
use it.

RHEL7 is due out in 2H2013, as the first of the traditional enterprise distros
to have GCC 4.7, and it's going to be important for LSB 5.0 to support that.
I'd presume that SLES12, currently road-mapped for 2H2014, would also be
supported? The others that are currently of interest to me are SLES11sp3, which
has GCC 4.7.2 run-times and a GCC 4.7.2 as an additional compiler, and RHEL6,
if there's a way to have it run C++11 code.


John Dallman
Open Tools - CTO

Siemens Industry Sector
Siemens Industry Software Limited
Parker's House 46 Regent Street
Cambridge  CB2 1DP, United Kingdom
Tel.      :+44 (1223) 371 554
Fax      :+44 (1223) 361 315
john.dallman at siemens.com

-----Original Message-----
From: lsb-discuss-bounces at lists.linux-foundation.org [mailto:lsb-discuss-bounces at lists.linux-foundation.org] On Behalf Of Mats Wichmann
Sent: 27 February 2013 14:49
To: lsb-discuss at lists.linux-foundation.org
Subject: Re: [lsb-discuss] LSB, GCC versions C++11 and libstdc++

On 02/27/2013 03:39 AM, Dallman, John wrote:
>> There are two issues with gcc 4.7 support.  The first is compatibility
>> with the compiler itself; the second is the addition of new features
>> supported in the 4.7 version of the standard library.
>> As Mats has mentioned, support for those new libstdc++ features is a
>> fairly major project.  It's on our list for LSB 5.0, but could be
>> postponed, depending on other issues.
> So, to make sure I understand this properly:
> If you don't use C++11 features (this is most reliably avoided by using an
> explicit option for an older C++ standard, such as "-std=c++98") then you can
> build LSB-compliant applications to LSB 4.0 or LSB 3.1 standards using GCC
> 4.7.2 or later. Such applications will work on any Linux that's compliant
> with the LSB version you used.
> If you do use C++11 features, you can't build LSB-compliant applications at
> present. This will become possible with the LSB version that supports C++11,
> which will also require GCC 4.7.2 or later C++ run-times. That LSB version
> is currently planned to be LSB 5.0, but the C++11 support could be postponed.
> Is that correct?

It seems pretty accurate.  There's some stuff LSB has to capture and
write about here, because the LSB headers will not have the extensive
feature test macro setup that the glibc headers do, that would allow you
to select between one compilation environment or another.  The idea
originally was that LSB would be "exactly one thing", so you don't pick
and choose from among USE_BSD, USE_GNU, various POSIX levels, various
ISO-C levels, various ISO-C++ levels, etc; you would target exactly what
that version of LSB describes.  Of course a lot of years (12+) and a lot
of versions of LSB (which map onto different sets of external stuff) and
a lot of versions of GCC have gone by, and I'm not sure how a developer
would figure all of it out.  You've asked some good questions and I hope
someone will set out to document those and some of the stuff I've just

lsb-discuss mailing list
lsb-discuss at lists.linux-foundation.org
Siemens Industry Software Limited is a limited company registered in England and Wales.
Registered number: 3476850.
Registered office: Faraday House, Sir William Siemens Square, Frimley, Surrey, GU16 8QD.

More information about the lsb-discuss mailing list