diff options
Diffstat (limited to 'mcs/tools/xbuild/targets/Microsoft.WebApplication.targets')
-rw-r--r-- | mcs/tools/xbuild/targets/Microsoft.WebApplication.targets | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/mcs/tools/xbuild/targets/Microsoft.WebApplication.targets b/mcs/tools/xbuild/targets/Microsoft.WebApplication.targets new file mode 100644 index 0000000000..0f61904250 --- /dev/null +++ b/mcs/tools/xbuild/targets/Microsoft.WebApplication.targets @@ -0,0 +1,31 @@ +<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <PropertyGroup> + <WebApplicationOutputDir Condition="'$(OutDir)' != '$(OutputPath)'">$(OutDir)_PublishedWebsites\$(MSBuildProjectName)</WebApplicationOutputDir> + + <PrepareForRunDependsOn> + $(PrepareForRunDependsOn); + _CopyWebApplication + </PrepareForRunDependsOn> + </PropertyGroup> + + <!-- OutDir has been overridden, so copy all the relevant files to that --> + <Target Name="_CopyWebApplication" Condition="'$(OutDir)' != '$(OutputPath)'"> + <MakeDir Directories="$(WebApplicationOutputDir)\bin"/> + <Copy SourceFiles="@(IntermediateAssembly)" DestinationFolder="$(WebApplicationOutputDir)\bin" SkipUnchangedFiles="true"/> + <Copy + SourceFiles="$(IntermediateOutputPath)$(AssemblyName)$(TargetExt).mdb" + Condition="Exists('$(IntermediateOutputPath)$(AssemblyName)$(TargetExt).mdb')" + DestinationFolder="$(WebApplicationOutputDir)\bin" + SkipUnchangedFiles="true" /> + + <Copy + SourceFiles = "@(IntermediateSatelliteAssemblies)" + DestinationFiles = "@(IntermediateSatelliteAssemblies->'$(WebApplicationOutputDir)\bin\%(Culture)\$(AssemblyName).resources.dll')" + Condition = "'@(IntermediateSatelliteAssemblies)' != ''" + SkipUnchangedFiles="true" /> + + <!-- Copy the referenced assemblies --> + <Copy SourceFiles="@(ReferenceCopyLocalPaths)" DestinationFolder="$(WebApplicationOutputDir)\bin" SkipUnchangedFiles="true" /> + <Copy SourceFiles="@(Content)" DestinationFolder="$(WebApplicationOutputDir)\%(Content.RelativeDir)" /> + </Target> +</Project> |