You've already forked linux-packaging-mono
34 lines
1.5 KiB
XML
34 lines
1.5 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
|
|
|
<PropertyGroup Condition="'$(ResolveMatchingContract)' == 'true'">
|
|
<AddProjectReferencesDynamicallyDependsOn>
|
|
ResolveMatchingContract;
|
|
$(AddProjectReferencesDynamicallyDependsOn);
|
|
</AddProjectReferencesDynamicallyDependsOn>
|
|
<ResolveReferencesDependsOn>
|
|
$(ResolveReferencesDependsOn);
|
|
VerifyMatchingContract
|
|
</ResolveReferencesDependsOn>
|
|
</PropertyGroup>
|
|
|
|
<Target Name="ResolveMatchingContract">
|
|
<PropertyGroup>
|
|
<ContractProject Condition="'$(ContractProject)' == ''">$(SourceDir)/$(AssemblyName)/ref/$(AssemblyName).csproj</ContractProject>
|
|
<HasMatchingContract Condition="'$(HasMatchingContract)' == '' and Exists('$(ContractProject)')">true</HasMatchingContract>
|
|
</PropertyGroup>
|
|
|
|
<ItemGroup Condition="'$(HasMatchingContract)' == 'true'">
|
|
<!-- add contract project as project reference to get target path -->
|
|
<ProjectReference Include="$(ContractProject)">
|
|
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
|
|
<OutputItemType>ResolvedMatchingContract</OutputItemType>
|
|
</ProjectReference>
|
|
</ItemGroup>
|
|
</Target>
|
|
|
|
<Target Name="VerifyMatchingContract">
|
|
<Error Condition="'$(HasMatchingContract)' == 'true' and !Exists('%(ResolvedMatchingContract.Identity)')" Text="ResolveMatchingContract could not find a matching contract '%(ResolvedMatchingContract.Identity)' not found." />
|
|
</Target>
|
|
</Project>
|