Fix scope of the Qt version check.