Could not find required file 'setup.bin'

前端 未结 6 996
走了就别回头了
走了就别回头了 2020-11-28 10:33

I\'m unable to build a Setup Project in VS2010, for a Windows Service project. It fails with this error:

Could not find required file \'setup.bin\' in

6条回答
  •  生来不讨喜
    2020-11-28 11:01

    It's a multi step solution.

    First make sure you have the .Net SDKs installed.

    Then make sure the following registry entry exists: HKEY_LOCAL_MACHINE\Software\Wow6432Node\Microsoft\GenericBootstrapper\11.0

    It must contain a 'Path' entry with the value pointing to the location of the bootstrapper: C:\Program Files (x86)\Microsoft SDKs\Windows\v8.0A\Bootstrapper\

    The following powershell script does that for you:

    $registryPath = "Registry::HKEY_LOCAL_MACHINE\Software\Wow6432Node\Microsoft\GenericBootstrapper\11.0"
    $registryValue = "C:\Program Files (x86)\Microsoft SDKs\Windows\v8.0A\Bootstrapper\" 
    function CreateRegistryValues {
    
        if(-not (Test-Path $registryPath ) )
        {
            Push-Location
            Set-Location -Path Registry::HKEY_LOCAL_MACHINE\Software\Wow6432Node\Microsoft\GenericBootstrapper
            # First add the registry item
            New-Item -Name '11.0' -Value $registryValue
            #Then add a property on it for 'Path' and the folder in bootstrapper that contains the 'Engine' folder 
            New-ItemProperty `
                -Path  $registryPath `
                -Name 'Path' `
                -PropertyType String `
                -Value $registryValue
            Pop-Location
        }else{
            Write-Warning "You already have the registry key ($registryPath) set. `r`n No action was taken `r`n "
        }
    }
    

    Finally, you must copy the contents of the 'Engine' folder included as part of the Visual Studio tooling to the location listed in the registry value:

    C:\Program Files (x86)\Microsoft SDKs\Windows\v8.0A\Bootstrapper\" 
    

提交回复
热议问题