How do I fix my source compile when missing nvapi.h?

Hello,
I am really exhausted, I have been trying to build from source all night long,
So I started with the 4.1 branch and got some errors, I thought I messed up the requirements or something so I decided to try the Master branch.

I went about it like I should (i guess?) :

  1. made folder “UnrealEngine-master”
  2. installed DirectX Redist files
  3. put all the requirements 1-3 in there
  4. generated project files
  5. built from Visual Studio 2013 RC

And I got some build errors (shown below),

So I tried the latest-preview build with vc express:

  1. made folder “UnrealEngine-latest-preview”
  2. put all requirements including Optional files
  3. put Lua source folder into the script plugin (except luac.c)
  4. generated files
  5. built with VS 2013 EXPRESS

For whatever reason I end up with the exact same errors no matter what branch I select:
Has the compiler gone haywire? and where is the mysterious NVAPI.h (not in the required zip files!) `?

C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.MakeFile.Targets(38,5): error MSB3073: The command “…..\Build\BatchFiles\Build.bat UE4Editor Win64 Development” exited with code -1.


c:\users\aeoeaa\documents\github\unrealengine-latest-preview\engine\source\runtime\opengldrv\private\Windows/OpenGLWindows.h(356): error C2146: syntax error : missing ‘;’ before identifier ‘glBufferStorage’


c:\users\aeoeaa\documents\github\unrealengine-latest-preview\engine\source\runtime\opengldrv\private\Windows/OpenGLWindows.h(356): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int


c:\users\aeoeaa\documents\github\unrealengine-latest-preview\engine\source\runtime\opengldrv\private\Windows/OpenGLWindows.h(467): error C2064: term does not evaluate to a function taking 4 arguments


C:\Users\aeoeaa\Documents\GitHub\UnrealEngine-latest-preview\Engine\Source\Runtime\OpenGLDrv\Private\Windows\OpenGLWindows.cpp(14): error C2146: syntax error : missing ‘;’ before identifier ‘glBufferStorage’


C:\Users\aeoeaa\Documents\GitHub\UnrealEngine-latest-preview\Engine\Source\Runtime\OpenGLDrv\Private\Windows\OpenGLWindows.cpp(14): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int


C:\Users\aeoeaa\Documents\GitHub\UnrealEngine-latest-preview\Engine\Source\Runtime\OpenGLDrv\Private\Windows\OpenGLWindows.cpp(14): error C2086: ‘int glBufferStorage’ : redefinition

c:\users\aeoeaa\documents\github\unrealengine-latest-preview\engine\source\runtime\opengldrv\private\Windows/OpenGLWindows.h(356) : see declaration of ‘glBufferStorage’


C:\Users\aeoeaa\Documents\GitHub\UnrealEngine-latest-preview\Engine\Source\Runtime\OpenGLDrv\Private\Windows\OpenGLWindows.cpp(738): error C2146: syntax error : missing ‘;’ before identifier ‘wglGetProcAddress’


C:\Users\aeoeaa\Documents\GitHub\UnrealEngine-latest-preview\Engine\Source\Runtime\Windows\D3D11RHI\Private\D3D11Commands.cpp(20): fatal error C1083: Cannot open include file: ‘nvapi.h’: No such file or directory


Hey real,

Would you be able to provide us with a DxDiag for your system?

Thanks,

-Steve

Hello Steve, of course:
link text

I read somewhere that a few people had problems building the source because they had other versions of Visual Studio installed, but also that the bug was fixed?
I have VS 2010, 2012, 2013 RC and 2013 Express for Windows Desktop; installed. Do you think that might be causing problems?

And thanks for your time! much appreciated.

Hey real,

We haven’t seen this issue happening internally when we download and compile the github versions. One user was experiencing a similar (if not the exact issue) as well and posted their solution here: 4.1 github release prereqs - C++ - Epic Developer Community Forums

We’ll still look into this internally, but if you want to try that workaround in the meantime to see if that fixes your problem, you can just update us on if that works for you or not.

-Steve

Hello again, and thanks for all the help!

Yes, that solution worked just fine, I also had to move nvapi64.lib into thirdparty/nvapi/amd64/