config.sh: check_pkg: do return instead of exit

Fixes json detection case when:
1. the system has "json" package, but too old a version
2. the system has an up-to-date "json-c" version
3. config.sh exits immediately after the first step