You should look if configure uses python as default. So if it is on or off by default. Perhaps only one of the both options would need to be explicitly set.
So if `--without-python` is the default, then `if build.with? 'python' then args << "--with-python"` ... or the other way around