add core functions for header building
 cleanup