improve building scripts