update the code for building