Autodesk / Aurora

Real-time GPU path tracing with an OpenUSD Hydra render delegate
Apache License 2.0
506 stars 31 forks source link

Windows SDK not found while compiling. #1

Closed Lucas3Dspain closed 1 year ago

Lucas3Dspain commented 1 year ago

I'm trying to compile in windows 10 with visual studio 2019. I have installed the windows SDK 10.0.22621.0 but I get this error:

Severity    Code    Description Project File    Line    Suppression State
Error       CMake Error at Libraries/Aurora/CMakeLists.txt:11 (message):
    Windows SDK version  is found but version 10.0.22000.0 or later is required.
    Windows SDK version 10.0.22000.0 or later can be installed from https://developer.microsoft.com/en-us/windows/downloads/sdk-archive/    Aurora  C:\Users\LucasMorante\Desktop\_Repos\Aurora\Libraries/Aurora/CMakeLists.txt 11  

It is weird that it does not show me any windows SDK version.

    set(MINIMUM_WINDOWS_SDK_VERSION "10.0.22000.0")
    if(WINDOWS_SDK_VERSION VERSION_LESS MINIMUM_WINDOWS_SDK_VERSION)
        message(FATAL_ERROR
                "  Windows SDK version ${WINDOWS_SDK_VERSION} is found but version ${MINIMUM_WINDOWS_SDK_VERSION} or later is required.\n"
                "  Windows SDK version ${MINIMUM_WINDOWS_SDK_VERSION} or later can be installed from https://developer.microsoft.com/en-us/windows/downloads/sdk-archive/"
        )

This is the command I'm using.

python "%USERPROFILE%/Desktop/_Repos\Aurora\Scripts\installExternals.py" "%USERPROFILE%/Desktop/_Repos/Aurora_externals" --generator "Visual Studio 16 2019"

I might have something wrong in my VS configuration but I don't find what could it be. Any help is welcomed.

melMass commented 1 year ago

It clearly states the SDK you are missing 10.0.22000.0

gareth-morgan-autodesk commented 1 year ago

Hi @Lucas3Dspain do you have no Windows SDK installed at all? That would explain the error message. Aurora requires at least Windows SDK 10.0.22000.0

gareth-morgan-autodesk commented 1 year ago

We use the registry key Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows Kits\Installed Roots to find the SDK version. Which should be set by the Windows Kits installer. Does your machine not have that registry key set?

If not you can set manually by pointing the environment variables WINDOWS_SDK_PATH to point to the folder where the WIndows SDK is installed and WINDOWS_SDK_VERSION to the version number of the Windows SDK you have installed installed.

Lucas3Dspain commented 1 year ago

Hi Gareth, I do have the SDK installed and its in the registry.

regedit_FBHTNwz6gH

What is weird to me is that the error I'm getting is not getting any version. This variable is not getting any value ${WINDOWS_SDK_VERSION}

Lucas3Dspain commented 1 year ago

closed by accident

Lucas3Dspain commented 1 year ago

setting manually the environment variables WINDOWS_SDK_PATH, WINDOWS_SDK_VERSION worked!