configure: Make the libXi soname check depend on the header check.