Path to SignTool.exe or “Windows Kits” directory when using Visual Studio 2012

前端 未结 7 1792
-上瘾入骨i
-上瘾入骨i 2021-01-30 09:04

How do you get the path to SignTool.exe when using Visual Studio 2012?

In Visual Studio 2010, you could use



        
7条回答
  •  迷失自我
    2021-01-30 09:31

    Since for me, today (20/07/2020), all previous suggestions failed, although most of them worked in the past, I have decided to publish a more comprehensive approach, which also addresses later Windows 10 SDKs locations, while still using older ones as fallbacks.

    
    
        
    
        $([MSBuild]::GetRegistryValueFromView('HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows Kits\Installed Roots', 'KitsRoot10', null, RegistryView.Registry32, RegistryView.Default))
        $([MSBuild]::GetRegistryValueFromView('HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows Kits\Installed Roots', 'KitsRoot81', null, RegistryView.Registry32, RegistryView.Default))
        $([MSBuild]::GetRegistryValueFromView('HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows Kits\Installed Roots', 'KitsRoot', null, RegistryView.Registry32, RegistryView.Default))
    
        
    
        
        $(WindowsKitsRoot)bin\10.0.18362.0\x64\
        $(WindowsKitsRoot)bin\10.0.17763.0\x64\
        $(WindowsKitsRoot)bin\10.0.17134.0\x64\
        $(WindowsKitsRoot)bin\10.0.16299.0\x64\
        $(WindowsKitsRoot)bin\10.0.15063.0\x64\
        $(WindowsKitsRoot)bin\10.0.14393.0\x64\
        $(WindowsKitsRoot)bin\x64\
        $(WindowsKitsRoot)bin\$(Platform)\
    
        
    
        $(SignToolFolder)SignTool.exe
    
    
    
    
    
    
    
    
        
        
        
    
    

提交回复
热议问题