'gm' uses undefined class 'Logic::GameManager'
The key words in that compiler error message are "uses" and "undefined." It's important to understand the information provided by declarations, and definitions. You might want to google for something like "C++ declaration vs. definition."
To better understand declarations and definitions, you need to think like a compiler.
Consider the line in your source code:
Logic::GameManager gm;
N.B., implicit in that line of code is a call to the public constructor (void) for GameManager. That's what the compiler considers a "use" of the class. See the following for reasons why it's complaining that the class is undefined.
Although it isn't really how compilers and linkers work, the process of compiling and linking can be thought of as follows:
When the compiler reaches that line, it attempts to generate object code that would look something like "call [public constructor Logic::GameManager()]" The bracketed [] phrase contains information which the linker will later use (after all modules have been compiled) to locate the named function in all the object code modules, and write the actual address for the function call at that point in the code. The compiler must provide sufficient information for the linker to resolve that address.
When just the first header is included, the compiler "knows" only that a namespace X containing a class Y should be found during the linking phase. That's insufficient information for the compiler to determine:
1. Whether a public constructor exists. E.g., the constructor GameManager() may be private. The public constructor hasn't been defined.
2. What the location (offset) is for the GameManager constructor function. As Stewya implies, the compiler has no information regarding where function calls will be located with regard to actual memory addresses in the final code, because the class structure hasn't been defined.
By including the second header:
1. The compiler can determine that a public constructor exists. I.e., the header information implies that somewhere in the object code there will be that function.
2. And the location within the code for the class where the constructor can be determined.
EDIT: Note that a pointer to an object is not considered a use of that object. That is:
Logic::GameManager *gm;
would be fine. The compiler "knows" how to reserve space for a pointer. That doesn't require knowing anything more about GameManager than it's a class.
However, the following, similar to the instantiation shown above, comprises a use of the class.
gm = new Logic::GameManager; // "uses" the public (void) constructor
// or
gm->Init(); // calls the address of a function in the instance