I need to convert the function "path::combine(path1, path2)". Please help me if you have some idea. Thank you!
Use the CombinePath Task:
<Project DefaultTargets="DefaultTarget" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<MyBasePath>.\a\b</MyBasePath>
<MySecondPath>c\d</MySecondPath>
</PropertyGroup>
<Target Name="Combine">
<PropertyGroup>
<MySecondPath Condition="$(MySecondPath)==''">.\</MySecondPath>
</PropertyGroup>
<CombinePath BasePath="$(MyBasePath)" Paths="$(MySecondPath)">
<Output TaskParameter="CombinedPaths" PropertyName="CombineOutput" />
</CombinePath>
</Target>
<Target Name="DefaultTarget" DependsOnTargets="Combine">
<Message Text="Result from Combine is $(CombineOutput)" />
</Target>
</Project>