Fix out-of-tree build for python