[EXT] [PATCH] examples/fips_validation: fix link to libjansson
Akhil Goyal
gakhil at marvell.com
Tue Jun 21 12:22:35 CEST 2022
> > When compiling this example out of DPDK, linking the executable fails
> > with:
> >
> > ## Building fips_validation
> > /usr/bin/ld: /tmp/ccQjeHBg.o: in function `fips_test_init':
> > fips_validation.c:(.text+0x7ab): undefined reference to `json_loadf'
> > /usr/bin/ld: /tmp/ccQjeHBg.o: in function
> > `fips_test_parse_one_json_vector_set':
> > fips_validation.c:(.text+0xc2e): undefined reference to `json_object_get'
> > /usr/bin/ld: fips_validation.c:(.text+0xc36): undefined reference to
> > `json_string_value'
> > /usr/bin/ld: /tmp/ccQjeHBg.o: in function
> > `fips_test_parse_one_json_group':
> > fips_validation.c:(.text+0xd00): undefined reference to `json_object_get'
> > /usr/bin/ld: fips_validation.c:(.text+0xd14): undefined reference to
> > `json_integer_value'
> > ...
> >
> > Code in an example can't rely on RTE_HAS_JANSSON, because it only
> > indicates that the jansson library was available at the time of dpdk
> > compilation.
> >
> > Prefer a local build flag (like what is done in vm_power_manager).
> > And add linking to libjansson, if available.
> >
> > Fixes: f556293fd58e ("examples/fips_validation: add JSON info to header")
> >
> > Signed-off-by: David Marchand <david.marchand at redhat.com>
>
> Acked-by: Gowrishankar Muthukrishnan <gmuthukrishn at marvell.com>
Applied to dpdk-next-crypto
Thanks.
More information about the dev
mailing list