Skip to content

GitLab

  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • C Clazy
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 1
    • Issues 1
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 1
    • Merge requests 1
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Releases
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • SDK
  • Clazy
  • Merge requests
  • !56

Don't hard code std=c++14 in CXX_FLAGS

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Heiko Becker requested to merge work/dont-hard-code-c++14 into 1.10 Dec 16, 2021
  • Overview 0
  • Commits 1
  • Changes 1

I got the following build error

"src/checks/level2/missing-qobject-macro.cpp:93:43: error: 'std::filesystem' has not been declared".

I'm pretty sure that my compiler (gcc 11.2.0) supports it and cmake seems to agree and defines -DHAS_STD_FILESYSTEM. It turns out that the manual addition of "-std=c++14" to CMAKE_CXX_FLAGS overwrote "CMAKE_CXX_STANDARD 17" here. Seems generally nicer to only have that in one place and it also fixes the previously mentioned build error.

Assignee
Assign to
Reviewer
Request review from
Time tracking
Source branch: work/dont-hard-code-c++14