reorganised build stuff