Skip to content

Instantly share code, notes, and snippets.

@mhutch
Last active August 23, 2016 02:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mhutch/45d2efe1a57a54666d244f725b00bc60 to your computer and use it in GitHub Desktop.
Save mhutch/45d2efe1a57a54666d244f725b00bc60 to your computer and use it in GitHub Desktop.
diff --git a/mcs/tools/xbuild/data/14.0/Microsoft.Common.targets b/mcs/tools/xbuild/data/14.0/Microsoft.Common.targets
index 433cffe..89afe65 100644
--- a/mcs/tools/xbuild/data/14.0/Microsoft.Common.targets
+++ b/mcs/tools/xbuild/data/14.0/Microsoft.Common.targets
@@ -265,11 +265,10 @@
<FileWrites Include="$(TargetFrameworkMonikerAssemblyAttributesPath)" />
</ItemGroup>
- <Target Name="GenerateTargetFrameworkMonikerAttribute"
+ <Target Name="_GenerateTargetFrameworkMonikerAttribute"
DependsOnTargets="PrepareForBuild;GetReferenceAssemblyPaths"
Inputs="$(MSBuildToolsPath)\Microsoft.Common.targets"
- Outputs="$(TargetFrameworkMonikerAssemblyAttributesPath)"
- Condition="'$(GenerateTargetFrameworkAttribute)' == 'true'">
+ Outputs="$(TargetFrameworkMonikerAssemblyAttributesPath)">
<WriteLinesToFile
File="$(TargetFrameworkMonikerAssemblyAttributesPath)"
@@ -278,6 +277,11 @@
ContinueOnError="true"
Condition="'@(Compile)' != '' and '$(TargetFrameworkMonikerAssemblyAttributeText)' != ''"
/>
+ </Target>
+
+ <Target Name="GenerateTargetFrameworkMonikerAttribute"
+ DependsOnTargets="_GenerateTargetFrameworkMonikerAttribute"
+ Condition="'$(GenerateTargetFrameworkAttribute)' == 'true'">
<ItemGroup Condition="'@(Compile)' != '' and '$(TargetFrameworkMonikerAssemblyAttributeText)' != ''">
<Compile Include="$(TargetFrameworkMonikerAssemblyAttributesPath)"/>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment