Only execute JSONcpp library check when building submit client
and throw errors when required libraries are not found.

Cherry-picked from master bf0e30de12, closes #143.