Undefined symbols for architecture x86_64: "FRHIResource::Bypass()"

When building some new C++ classes (xcode, osx 10.10.1) I get this error:

Undefined symbols for architecture x86_64: "FRHIResource::Bypass()"

I found the class in the documentation but I couldn’t find examples of anyone else having this issue online.

I have the answer. I needed to add RHI and RenderCore to my PublicDependencyModuleNames

PublicDependencyModuleNames.AddRange(new string[] { ... "RHI", "RenderCore" });

Hi ,
How did you find that these were the dependencies you needed to add? I have a similar error popping up. It looks like this.

Undefined symbols for architecture x86_64:
"_GForeignEngineDir", referenced from:
FGenericPlatformMisc::EngineDir() in UE4-    Core.a(Module.Core.1_of_6.cpp.o)

Do you know where I could find the proper dependencies to add?

Thanks,