Build script improvements and license