Yes, embedded linker directives in #pragma's are nice, however they don't allow the specification of undecorated names, that's why they have limited usefulness... For example, if this
Code:
#ifdef WIN32
#pragma comment(linker, "/EXPORT:GiveFnptrsToDll=_GiveFnptrsToDll@8,@1")
#pragma comment(linker, "/SECTION:.data,RW")
#endif
works for metamod plugins, it doesn't for hook DLLs. I believe MSVC doesn't decorate GiveFnptrsToDll the same way. And that sucks a bit. Anyway, it's not a MSVC-specific problem, any C++ compiler decorates function names to resolve overload ambiguities.