From a87c5e697f95da65f0e4d48f3b4906d3c5de60d3 Mon Sep 17 00:00:00 2001 From: Mark Young Date: Tue, 9 Feb 2016 15:30:34 -0700 Subject: windowssdk: Fix 32-bit install issue with Powershell script. Fix the install Powershell script which populates the ExplicitLayers registry entries. There were 2 problems: 1) it was using newer Powershell commands that failed on Windows 7, 2) it was trying to populate the 32-bit data on a 32-bit system with the 64-bit Bin folder. --- .../ConfigLayersAndVulkanDLL.ps1 | 28 +++++++++++++++------- 1 file changed, 20 insertions(+), 8 deletions(-) (limited to 'windowsRuntimeInstaller/ConfigLayersAndVulkanDLL.ps1') diff --git a/windowsRuntimeInstaller/ConfigLayersAndVulkanDLL.ps1 b/windowsRuntimeInstaller/ConfigLayersAndVulkanDLL.ps1 index 7d90f620..bf29c6c3 100644 --- a/windowsRuntimeInstaller/ConfigLayersAndVulkanDLL.ps1 +++ b/windowsRuntimeInstaller/ConfigLayersAndVulkanDLL.ps1 @@ -265,18 +265,30 @@ if ($ossize -eq 64) { # Create layer registry entries associated with Vulkan SDK from which $mrVulkanDll is from if ($mrVulkanDllInstallDir -ne "") { - New-Item -Force -ErrorAction SilentlyContinue -Path HKLM:\SOFTWARE\Khronos\Vulkan\ExplicitLayers | out-null - Get-ChildItem $mrVulkanDllInstallDir\Bin -Filter VkLayer*json | - ForEach-Object { - New-ItemProperty -Path HKLM:\SOFTWARE\Khronos\Vulkan\ExplicitLayers -Name $mrVulkanDllInstallDir\Bin\$_ -PropertyType DWord -Value 0 | out-null - } - - # Create registry entires for the WOW6432Node registry only if we're targeting a 64-bit OS if ($ossize -eq 64) { - New-Item -Force -ErrorAction Ignore -Path HKLM:\SOFTWARE\WOW6432Node\Khronos\Vulkan\ExplicitLayers | out-null + + # Create registry entires in normal registry location for 64-bit items on a 64-bit OS + New-Item -Force -ErrorAction SilentlyContinue -Path HKLM:\SOFTWARE\Khronos\Vulkan\ExplicitLayers | out-null + Get-ChildItem $mrVulkanDllInstallDir\Bin -Filter VkLayer*json | + ForEach-Object { + New-ItemProperty -Path HKLM:\SOFTWARE\Khronos\Vulkan\ExplicitLayers -Name $mrVulkanDllInstallDir\Bin\$_ -PropertyType DWord -Value 0 | out-null + } + + # Create registry entires for the WOW6432Node registry location for 32-bit items on a 64-bit OS + New-Item -Force -ErrorAction SilentlyContinue -Path HKLM:\SOFTWARE\WOW6432Node\Khronos\Vulkan\ExplicitLayers | out-null Get-ChildItem $mrVulkanDllInstallDir\Bin32 -Filter VkLayer*json | ForEach-Object { New-ItemProperty -Path HKLM:\SOFTWARE\WOW6432Node\Khronos\Vulkan\ExplicitLayers -Name $mrVulkanDllInstallDir\Bin32\$_ -PropertyType DWord -Value 0 | out-null } + + } else { + + # Create registry entires in normal registry location for 32-bit items on a 32-bit OS + New-Item -Force -ErrorAction SilentlyContinue -Path HKLM:\SOFTWARE\Khronos\Vulkan\ExplicitLayers | out-null + Get-ChildItem $mrVulkanDllInstallDir\Bin32 -Filter VkLayer*json | + ForEach-Object { + New-ItemProperty -Path HKLM:\SOFTWARE\Khronos\Vulkan\ExplicitLayers -Name $mrVulkanDllInstallDir\Bin32\$_ -PropertyType DWord -Value 0 | out-null + } + } } -- cgit v1.2.3