EricWF added a comment. GCC 4.0 seems to have attributes on namespaces and we should require GCC >= 4.7. I can't seem to find any documentation about when Clang supports visibility attributes on namespaces but it I think it works for all clang versions. http://reviews.llvm.org/D8652