json|jsonrpc-c: fix detection of json-c lib