build: allow the waf build to work with python 3.0 and 3.1