Skip to content

GitLab

  • Menu
Projects Groups Snippets
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in / Register
  • crown-core crown-core
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 75
    • Issues 75
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
    • Requirements
  • Merge requests 1
    • Merge requests 1
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Crown
  • crown-corecrown-core
  • Issues
  • #134

Closed
Open
Created Mar 07, 2018 by Volodymyr Shamray@vshamrayReporter

Add Modern C++ support into build system

We need to be able to write and compile Modern C++ - at least C++14, but preferably C++17

Rationale

There has been almost 7 years since C++11 is an official standard (and even more since our compiler, gcc, supports it), yet the current Crown codebase is stuck with pre-Modern version of the language. C++14 fixes some important holes in C++11 and actually makes it usable for wide circle of developers. C++17 adds a few small but useful improvements into the language, is now supported by all major compilers.

@vshamray has spent last 3 years writing commercial software in Modern C++ and finds it rather harmful for his productivity as a developer to be forced to use a pre-Modern dialect. It basically means that 33% of Crown software developers work below their capacity. Due to that fact it is effectively a blocker for any Governance improvements. Obviously, it is something to address ASAP.

Current state

There are several problems to be solved:

  1. std=c++17 flag needs to be added to compiler flags (trivial)
  2. Boost needs to be updated to a newer version (at least 1.57, preferably 1.66) or BOOST_NO_CXX11_SCOPED_ENUMS define should be used. Given that we're changing the build system there's no reason not to update Boost anyway (easy)
  3. Even if 1 and 2 are done MacOS build still doesn't compile, not even with C++11. The problem seems to be that with Modern C++ compiler flag Qt starts to depend on modern standard library features, but the standard library that is used to compile MacOS version doesn't have any of C++11 features (difficult, needs research)

Useful link

Bitcoin C++11 discussion and commits
https://github.com/bitcoin/bitcoin/issues/6211

Edited Oct 04, 2018 by Artem B
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking