On Tue, Nov 07, 2017 at 01:38:51PM +0000, Richard W.M. Jones wrote:
On Tue, Nov 07, 2017 at 01:28:00PM +0000, Daniel P. Berrange wrote:
> On Tue, Nov 07, 2017 at 02:05:25PM +0100, Martin Kletzander wrote:
> > 4) The are workarounds for it in the code
>
> I don't recall what these are now ?
I shouldn't have said 'workarounds', I meant all the conditioning for
differentiation between yajl 1 and 2 and supporting both version with pkg-config
and without.
libguestfs needs to disable some warnings around yajl code:
/* GCC can't work out that the YAJL_IS_<foo> test is sufficient to
* ensure that YAJL_GET_<foo> later doesn't return NULL.
*/
#if defined(__GNUC__) && __GNUC__ >= 6 /* gcc >= 6 */
#pragma GCC diagnostic ignored "-Wnull-dereference"
#endif
However we don't need any other workarounds.
As you say yajl "just works".
It might however be a problem in future if JSON itself was changed,
eg. new types, fix the trailing comma problem, etc. We'd want a more
responsive upstream to handle that.
- - -
Martin, did you look at the dependencies of these other libraries?
If they depend on other stuff, that could make them harder to use.
Also are they all available in at least Fedora, Debian, OpenSUSE and
Arch/AUR?
Just did, all of these were successful:
docker run -it fedora dnf search jansson
docker run -it opensuse zypper search jansson
docker run -it base/archlinux pacman -Sys jansson
docker run -it ubuntu sh -c "apt update; apt search jansson"
docker run -it debian sh -c "apt update; apt search jansson"
Even:
docker run -it debian:stable sh -c "apt update; apt search jansson"
found version 2.9 which is the second latest one, I believe.
Rich.
--
Richard Jones, Virtualization Group, Red Hat
http://people.redhat.com/~rjones
Read my programming and virtualization blog:
http://rwmj.wordpress.com
virt-df lists disk usage of guests without needing to install any
software inside the virtual machine. Supports Linux and Windows.
http://people.redhat.com/~rjones/virt-df/