upgrade build to also work with 2.11
Merge commit '14666891d7c1f075a7bdd4dead40e3557940c7ee' into 0.5.x