On second thought, remove those -eq tests altogether.

Just use the "false" clauses of the various AC_ tests if something
goes wrong; there's no need for an additional state variable to check
the results of these tests.

Also convert the Jansson version test to use AC_COMPILE_IFELSE instead
of the deprecated AC_TRY_COMPILE.