one of my \"favorite\" annoyance when coding in C++ is declaring some static variable in my class and then looking at compilation error about unresolved static variable (in
Well, this is just the way it works. You've only declared the static member in the .h file. The linker needs to be able to find exactly one definition of that static member in the object files it links together. You can't put the definition in the .h file, that would generate multiple definitions.
UPDATE: C++17 can solve this with an inline variable.