Fixes to the build system, particularly around BWC testing, and to make future version bumps less painful. Original commit: elastic/x-pack-elasticsearch@a1d456f30a