It seems to me that the error message is self-explanatory "gmock/h" is not "gmock.h" and is very unlikely to be a file. Find where your code references "gmock/h" and fix the typo.
I assumed that the "gmock/h" was a typo in the post, not a typo in the code, since the OP said the code builds under the CMake toolchain. If it was a code typo, it wouldn't build in either place.