setuptools install script, refactoring