generating building script