diff --git a/pack/Microsoft.Azure.Functions.PythonWorker.targets b/pack/Microsoft.Azure.Functions.PythonWorker.targets index ba674972..887dc8d5 100644 --- a/pack/Microsoft.Azure.Functions.PythonWorker.targets +++ b/pack/Microsoft.Azure.Functions.PythonWorker.targets @@ -1,25 +1,43 @@ - - - - - - - + + <_PythonWorkerToolsDir>$([System.IO.Path]::GetFullPath('$(MSBuildThisFileDirectory)../tools')) + + + <_PythonSupportedRuntime Include="win-x86" WorkerPath="WINDOWS/X86" /> + <_PythonSupportedRuntime Include="win-x64" WorkerPath="WINDOWS/X64" /> + <_PythonSupportedRuntime Include="linux-x64" WorkerPath="LINUX/X64" /> + <_PythonSupportedRuntime Include="osx-x64" WorkerPath="OSX/X64" /> + <_PythonSupportedRuntime Include="osx-arm64" WorkerPath="OSX/Arm64" /> + + + - + - - + + + + <_PythonWorkerFiles Include="$(_PythonWorkerToolsDir)/**" CopyToOutputDirectory="PreserveNewest" CopyToPublishDirectory="PreserveNewest" /> + - - + + + + <_PythonWorkersRuntimeFolder>@(_PythonSupportedRuntime->WithMetadataValue('Identity', '$(RuntimeIdentifier)')->Metadata('WorkerPath')) + + + + <_PythonWorkerFiles Include="$(_PythonWorkerToolsDir)/*" CopyToOutputDirectory="PreserveNewest" CopyToPublishDirectory="PreserveNewest" /> + <_PythonWorkerFiles Include="$(_PythonWorkerToolsDir)/**/$(_PythonWorkersRuntimeFolder)/**" CopyToOutputDirectory="PreserveNewest" CopyToPublishDirectory="PreserveNewest" /> + + + + +