Targeting libstdc++-4.8-dev by default on linux
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 258
- Forks
- 68
- PR merge metrics
- No merged PRs in 30d
Description
Currently we target `libstdc++-5-dev` by default while libstdc++-4.8-dev is the default on ubuntu precise. We are targeting `libstdc++-5-dev` because the clang++ 3.8 compiler we default to had a runtime dependency on latest libstdc++ as it was built against libstdc++-5-dev headers. That is no longer the case after https://github.com/mapbox/mason/issues/252.
So I think we should try to target the minimum libstdc++-dev package per C++ package rather than globally upgrading. Note: we can and should still upgrade the libstdc++ runtime library to the latest. There is no reason not to. But what I'm proposing is not by-default upgrading the g++ provided headers. It turns out that these are the determining factor for the minimum GLIBCXX version a given binary needs per investigations at https://github.com/springmeyer/glibcxx-symbol-versioning
Benefits of not upgrading to libstdc++-5-dev by default are:
- For pure C packages, travis will run faster since it installs less apt packages
- For C++ packages, not all require the latest C++14 features only available in 4.9-dev or 5-dev.
- We can then ensure the default binaries will run on all linux systems as old as ubuntu precise.
- Specific packages that need libstdc++-4.9-dev (or greater) for C++14 support can opt-in per package.
TODO:
- [ ] There are currently no known packages that won't build with `libstdc++-4.8-dev`. Mapnik, for example builds fine with clang 3.9 + libstdc++-4.8-dev. As part of the testing in https://github.com/mapbox/mason/pull/253 I plan to look for any packages that don't build with `libstdc++-4.8-dev` and require `libstdc++-4.9-dev` or `libstdc++-5-dev`
- [ ] Then I'll start moving on #251
/cc @mapsam @jfirebaugh @kkaefer @tmpsantos
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the testing described in mason#253 and the package configuration that selects the default libstdc++-dev dependency. Check which packages build with libstdc++-4.8-dev and identify any that require newer headers; done means using the minimum package per C++ package while retaining the latest runtime library and supporting Ubuntu Precise.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp, linux
- Domain
- build-system, devtools, operating-systems
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100