-
Notifications
You must be signed in to change notification settings - Fork 98
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Made nlohmann_json optional in the tests, exported c++14 requirement #102
Conversation
nice! I think that we should What do you think? |
Sure makes sense, haven't really looked into the test, but will do now :) |
Ok that's a little different than the ifdef idea I had in mind. I thought we could just set a compile time define with |
I mean right now it uses the cpp preprocessor, we just don't need to pass the definition via command line because |
I also think that it would be better to use definitions instead of a Instead of doing |
@SylvainCorlay Or just I'll amend the PR when I'm back home :) |
living and learning :) |
Alright added the definition ;) |
Prior to this PR
xtl
did not properly export it's compile feature requirementcxx_std_14
. This now propagates to other targets that link againstxtl
.When building from
test
and not the rootxtl
directory cmake now properly tries to find thenlohmann_json
package. In addition if it fails to findnlohmann_json
it will not compiletest_xoptional.cpp
and not link againstnlohmann_json
.Furthermore
nlohmann_json
recently adapt to the more modern namespaced targets nlohmann/json#1048 currently only on master branch. The newCMakeLists.txt
will use the correct target i.e.nlohmann_json
ornlohmann_json::nlohmann_json
.This also should fix #101 .