开发者

How is writing the MSBuild for a Silverlight project different?

I have the Import:

    <Import Project="$(MSBuildExtensionsPath)\Microsoft\Silverlight\v4.0\Microsoft.Silverlight.CSharp.tar ets" />

and a bunch 开发者_StackOverflow社区of Silverlight specific PropertyGroups such as:

  <TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
  <SchemaVersion>2.0</SchemaVersion>
  <NoStdLib>true</NoStdLib>
  <NoStdCfg>true</NoStdCfg>
  -----etc.

How do I write targets that use the above?

EDIT

I also have these references:

<ItemGroup>
<Reference Include="mscorlib" />
<Reference Include="system" />
<Reference Include="System.Windows" />
</ItemGroup>


Simply pass all properties to MSBuild task:

<Target Name="....">
   <MSBuild Projects="$(ProjectsToBuild)" 
            Properties="TargetFrameworkVersion=$(TargetFrameworkVersion); ... "/>
</Target>
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜