Move from C++14 plus extensions to C++17 and refine cmake configuration #9
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR switches to C++17 and refines the cmake configuration. The motivation was to make plasp compile on MacOS (which failed badly). Like this, it should in principle even compile on Windows, too. I would have switched to C++17's variant too but this would have required to change all the match functions. I also removed extra options from the cmake configuration files. Those are of course nice for development but are guaranteed to cause friction when someone tries to package the project. They could be added back but should not be enabled by default.
I have seen (too late) that the project's development branch is quite a bit ahead of the master. In any case, it should not be hard to merge back changes into the development branch.
I have also seen that your were preparing to switch to meson. I would vote not to do this. Cmake has admittedly worst case syntax plus some other flaws but it is one of the most widely used build systems. I used it in a lot of our projects and it is quite easy to painlessly support a wide range of platforms. Also, with the recent changes the configuration does not even look that ugly.
Feel free to discard this PR if you want to take another route.
EDIT: There are also some small changes like missing includes and additional overloads to support compilation on MacOS (
size_t
is defined asunsigned long long
).