tech-pkg archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: pkgsrc frozen for 2017Q2
On Thu, Jun 29, 2017 at 10:23:41AM -0400, Greg Troxel wrote:
>
> It's not really that googletest is broken. It's that the combination of
>
> C++ not being a single stable language
> C++ not having a stable ABI
> people using old compilers
> how the mk/ framework is
> people not setting a global GCC_REQD
>
> is broken. So it's not clear that googletest should be "fixed".
Can you please stop with the C++ bashing? It is entirely inappropiate as
the C++ standard is only indirectly involved here. The two primary
reasons why GCC_REQD interacts badly with C++ libraries are:
(1) GCC insists on a tight coupling between the full runtime library
stack and the compiler. This is not specific to C++ and we see the
issues with C and Fortran as well, just to a smaller degree. For C it is
normally enough to have the main binary linked with the newest GCC
version to make it pick up the "best" version of libgcc_s, but symbol
versioning can add some fun here as well.
(2) GCC's STL implementation used to implement std::string with
copy-on-write semantics. That was considered a smart choice in the early
days of C++, but ultimately outlawed in C++11 due to the very bad
interactions with multi-threading and iterator invalidation. To solve
this, GCC decided to "augment" the Itanium ABI to allow both new and old
std::string to coexist. This is the only intentional ABI break for the
Itanium ABI in the last 10+ years. I.e. they could have just gone with
bumping the major version, but factually made things a lot worse. Even
then, it is difficult to blame the C++ standard for an implementation
choice of a specific implementation. This means you can't easily mix
code compiled between 4.x and 5.x, not even within the restrictions of
mixing libgcc_s versions as in (1). Within the GCC 4.x series, the ABI
is backward-compatible, so it works as long as the main program picks up
the newest libstdc++.so version...
Joerg
Home |
Main Index |
Thread Index |
Old Index