1

I'm trying to use $(WindowsSDK_ExecutablePath_x64) in my C++ project post build events to copy some files. However, it contains two paths instead of one. I can't seem to be able to find how to use the first path (not the .Net one):

C:\Program Files (x86)\Windows Kits\10\bin\10.0.19041.0\x64;C:\Program Files (x86)\Microsoft SDKs\Windows\v10.0A\bin\NETFX 4.8 Tools\x64

I'd like to do something like copy /Y $(WindowsSDK_ExecutablePath_x64)\bin\file.ext destination in my post build events. How can I do this? I'm using VS 2019 and have the latest Windows SDK installed.

Jeaninez - MSFT
  • 3,210
  • 1
  • 5
  • 20
rashmatash
  • 1,699
  • 13
  • 23
  • `WindowsSDK_ExecutablePath_x64` is the path to the build systems. Just like the PATH environment variable. Also copying part of the tool-chain seems strange to me. What are you trying to achieve? Feeling like an XY-problem. – Richard Critten Jul 12 '21 at 16:36
  • I need to copy dxcompiler.dll and dxil.dll to the executable if it's not already there or a new version is available. setting a path is not enough since I need to redistribute those files. – rashmatash Jul 12 '21 at 19:57

1 Answers1

0

I ended up using the following:

$(WindowsSdkDir)bin\$(TargetPlatformVersion)\x64\dxil.dll

rashmatash
  • 1,699
  • 13
  • 23