Ask / Submit
20

SDK with newer GCC that supports c++17 standard?

Tracked by Jolla

asked 2018-11-20 17:43:20 +0300

Karry gravatar image

Hi.

As a C++ developer, I would like to use latest standard (c++17) for developing. It provides really useful improvements! But Mer SDK used as official Sailfish SDK provides GCC just in prehistoric version 4.8.3, that supports c++11 and few features from c++14. Is there any plan for providing official support for newer compiler? Or it is better to ask - is there any plan to switch system libraries (libstdc++, Qt...) to newer GCC ABI (>6)?

If I understand it correctly, GNU libstdc++ support dual ABI for compatibility with legacy applications, so everything should work after transition. Core system will be just a bit bigger...

edit retag flag offensive close delete

Comments

2

Why this question still without answer

bormac ( 2019-03-03 14:54:36 +0300 )edit
2

I would also be interested in a newer gcc. Backporting libs is a huge pain. I'm using ringus gcc6 for now, but an official package would be nice (https://talk.maemo.org/showthread.php?t=99699&page=2).

KuroNeko ( 2019-03-31 01:33:58 +0300 )edit

1 Answer

Sort by » oldest newest most voted
9

answered 2019-05-01 18:06:57 +0300

Sage gravatar image

Not fully answering your question, but with the 3.0.3 release we took a small step forward on the gcc, by updating it to version 4.9.4, which added couple of more c++14 features (still not feature complete though). This helped us to check a bit the process of updating gcc, which touches more or less the whole OS when the update is done and gave us a bit more insights how to take the next step forward.

https://together.jolla.com/question/203846/changelog-303-hossa/#203846-gcc

edit flag offensive delete publish link more

Comments

1

Definitely good progress! I am waiting for new SDK to start using c++14 :-) Did you considering howto handle ABI switch in the future? I am not even sure where it may cause troubles and if it is possible to build all c++ libraries (Qt for example) with dual ABI...

Karry ( 2019-05-01 19:13:12 +0300 )edit

I guess you mean https://gcc.gnu.org/onlinedocs/libstdc++/manual/using_dual_abi.html

That should not cause too much harm. Exact details are still pending until we are closer with the next gcc upgrade.

See also: https://developers.redhat.com/blog/2015/02/05/gcc5-and-the-c11-abi/

Sage ( 2019-05-06 16:55:15 +0300 )edit

Hi Sage! I was able to build GCC 8.3 for Sailfish OS (https://build.merproject.org/package/show/home:equeim:gcc and https://build.merproject.org/project/show/home:equeim:cross-gcc), it is configured to use old ABI by default. Currently I'm testing building my apps with it, and deploying RPM with its own libstdc++ and setting rpath for executable. Everything seems to work fine, but I'm in doubt, are there any pitfalls that I'm not aware about?

equeim ( 2019-05-09 01:28:57 +0300 )edit
Login/Signup to Answer

Question tools

Follow
7 followers

Stats

Asked: 2018-11-20 17:43:20 +0300

Seen: 375 times

Last updated: May 01