Move some namespaces definitions into header file