-
Notifications
You must be signed in to change notification settings - Fork 281
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
Update JSON for Modern C++ to version 3 #503
Conversation
https://tracker.debian.org/pkg/nlohmann-json3 |
Sure, let's upgrade the version if we can — but this PR is nowhere near complete. As long as the bundled copy is older, it doesn't make sense to support only the new version (I'm OK with supporting only the new one because there's a bundled copy). At the same tike, I'd like to avoid complicated support for both. Includes needs to be updated in code too. The reason why the builtin copy wasn't updated in a while is nlohmann/json#610 and so this PR cannot be included until:
|
sorry, the AC macro changed the defined value, so I wrongly used the embedded version instead of the system one -.-' stupid mistake! I corrected the code to now look for all of the variants, so people can choose their best version
as you wish, let me know what you prefer :)
yes, it works correctly in Debian (I was wrongly using the bundled copy because of the defines changed, but I checked again and it is fine now)
yes, it works with the latest boost in Ubuntu (we did default to 1.67 some days ago)
I think this isn't an issue wrt boost |
So, right now, the patch I submitted here works in both Debian, and Ubuntu, and uses the new json 3 version that seems to have less gcc troubles, and less boost troubles. If you want me to update the submodule I can do, but testing is still relegated to Debian/Ubuntu versions. |
I did update also the submodule to 3.1.2 tag (I'm not sure we should blindly follow devel branch...) |
Good for you, but the concern was specifically about old distros.
If it cannot be compiled on (a bit) older distros, it is an issue. If it cannot be compiled on 16.04, it is an issue for me... I cannot apply this as is. I don't like supporting both versions (as previously stated), and won't merge this without verifying it works with Boost ≤ 1.64 first (or make a conscious decision to stop supporting that). If you can't test the PR for that, that's fine, I will, but I can't promise how quickly that'll be. (It also should be a single clean commit, not a series of partials, but that's nitpicking.) |
Thanks for contributing! Unfortunately there were the following style issues with your Pull Request:
Please follow git commit message guidelines (you can use This message was auto-generated by https://gitcop.com |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
When you post compilation logs, please post only the relevant bits. I got lost, repeatedly, in this enormous wall of mostly irrelevant output. I see some errors there. I'm not sure whether you're saying it is OK or not OK. There's some mention of "this patch", did you forget to link to it or are you referring to the PR? If the latter, what is the first output about? |
testing I performed. (everything starting from version 2.1.1 released)
do the compilation, everything built correctly
so, with the above two points, I can say that on Ubuntu 16.04, with appropriate backports, everything still build correctly, with bundled new json, or with a backported system one. I can't test other OS, but to me it looks good (wrt Debian/Ubuntu). |
That's not the point. The relevant piece of information is whether this PR can be built with Boost ≤ 1.64. Of course you'll be able to build if you use the latest Boost version, but such invasive backports are not a reasonable thing to expect from people. Again, the interesting thing is whether after applying this PR the whole thing can be compiled on e.g. Ubuntu 16.04 as is (except installing non-stock dependencies). Travis build of this PR passes, so I guess it is OK. I'm deeply confused by its log, though, because it shows some issue:
But: there's location/inclusion information, there are candidates listed, but there's no actual error in the output. WTH? |
I used boost 1.61, xenial has no this boost available by default. So, I think in any case, if you want to use xenial codebase, you have to backport a boost from somewhere. |
wrt the build warning, I don't really know, I see in Debian logs too (with system json and new boost), but nobody ever complained about something not working :) |
It's not a warning — it's just notes normally accompanying warnings or errors, in a place where the combination with boost 1.61 normally produces an error, and still does in this PR with clang:
The Travis build currently uses Boost 1.61 too. To apply this PR, I'll need to
|
I'm not really sure about this point... I tried to unpack the new boost, since it seems to be not under version control, but there are modifications from you, and I'm not sure the files in the directory should just be deleted and the new version unpacked... can you please give me an hint? |
Vendor branches. Upstream boost is in the IOW, it's not really something that can be easily done in a PR… Part of why I didn't update Boost in a while is that they migrated to git, opening the way to use it as a submodule (which would be preferable, even though it won't help with polluted huge history)… but they have split it into multiple repos and migrating to that is downright scary — it means either
|
Is it an issue for Debian to bump the JSON dependency mid-cycle, i.e. in 2.2.1 as opposed to waiting to 2.3? |
Ehm, Debian is already using nlohmann-json3, so 3.1.2 right now, and 3.5 in two days (I just updated it to 3.5 and uploaded) |
484e10d
to
41acc9d
Compare
I'm aware. What I'm not aware of is your policies when changing dependencies of packages in more stable branches of the distro (if even poedit-2.2 is in stable or testing; I don't know that either). |
poedit 1.8 is in stable |
* configure.ac: search for new json.hpp version 3 * update also json.hpp copy to v3.6.1
Patch configure file to find the new json.hpp file location