qmake fix to improve build stability of qtwayland

This fixes qtwayland (and possibly other modules) build when its api changes and an old version is installed already.