Bug 354444

Summary: Let user set the C++ standard version globally
Product: [Applications] kdevelop Reporter: Markus Trippelsdorf <octoploid>
Component: Language Support: CPP (Clang-based)Assignee: kdevelop-bugs-null
Status: CONFIRMED ---    
Severity: wishlist CC: damir_porobic, mail
Priority: NOR Keywords: junior-jobs
Version First Reported In: git master   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Markus Trippelsdorf 2015-10-27 09:23:19 UTC
Currently -std=c++11 is hardcoded in languages/plugins/custom-definesandincludes/compilerprovider/settingsmanager.cpp:67.
It would be nice if this could be changed by the user globally in
Configure -> Kdevelop -> Language Support -> Clang Language Support.

Reproducible: Always
Comment 1 Milian Wolff 2015-11-01 16:50:32 UTC
In KDevelop 5 with the clang language backend you can change the language version on a per-project basis already. Changing the default globally could be added but is very low priority for me.
Comment 2 Damir Porobic 2017-02-08 17:02:00 UTC
I'm looking into this.
Comment 3 Sven Brauch 2017-02-10 21:57:11 UTC
Shouldn't this be set automatically by the project manager? e.g. cmake knows about the C++ standard required by the project via CMAKE_CXX_STANDARD.
Comment 4 Damir Porobic 2017-02-11 19:45:02 UTC
As far as I understander this was about setting manually the C++ default standard like under "Configure Project kdevelop" but only a default that would be used by all future projects, not only a particular. Is using  CMAKE_CXX_STANDARD something that would work for the requester? Not sure if this is what he meant with this wish.
I was planning to implement it under /kdevplatform/shell/settings/languagepreferences but this seems to be wrong.
Comment 5 Sven Brauch 2017-02-11 22:29:33 UTC
Yes, I think that's what it meant, but is it what should be done? In the end you want kdevelop to use the same standard your compiler runs with as well for each project -- and that information you can get from the build system (and you have to set it there anyways).
Comment 6 Damir Porobic 2017-02-14 08:23:53 UTC
In that case we're not going to progress with this one I guess?
Comment 7 Sven Brauch 2017-02-14 20:53:23 UTC
I'd suggest to implement a feature which queries the C++ standard from the project manager. That will make it work for at least cmake projects automatically.