move obsolete code out of build