No, #if, #endif and similar (preprocessor directives) are evaluated at compile-time. The compiler can't know on which game you'll be running your plugin.
You can let the user compiling your code to choose it by having them define what game it is (like #define GAME_TFC or #define GAME_VALVE) but that's as far as you can get, you'll have to resort to runtime checks, like what Edon has shown.