Apparently, the XInput extension is using the same pkg-config file ('xi') for both the 1.x and the 2.x API, so we need to check for both the 1.x XGetExtensionVersion and the 2.x XQueryInputVersion.