-
-
Notifications
You must be signed in to change notification settings - Fork 2
/
EF.msbuild
128 lines (106 loc) · 6.38 KB
/
EF.msbuild
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" DefaultTargets="Clean;Test;Package" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration Condition="'$(Configuration)' == ''">Release</Configuration>
<Platform>AnyCPU</Platform>
<SolutionDir Condition="$(SolutionDir) == '' Or $(SolutionDir) == '*Undefined*'">$(MSBuildThisFileDirectory)</SolutionDir>
<BuildProperties>Platform=$(Platform);SolutionDir=$(SolutionDir)</BuildProperties>
<BuildProperties Condition="'$(InternalsInvisible)' != ''">$(BuildProperties);InternalsInvisible=$(InternalsInvisible)</BuildProperties>
<BuildProperties Condition="'$(RunCodeAnalysis)' != ''">$(BuildProperties);RunCodeAnalysis=$(RunCodeAnalysis)</BuildProperties>
<BuildProperties Condition="'$(StyleCopEnabled)' != ''">$(BuildProperties);StyleCopEnabled=$(StyleCopEnabled)</BuildProperties>
<SkipStrongNamesXml>tools\SkipStrongNames.xml</SkipStrongNamesXml>
</PropertyGroup>
<ItemGroup>
<ProjectToBuild Include="src\EntityFramework\EntityFramework.csproj" />
<ProjectToBuild Include="src\EntityFramework.PowerShell\EntityFramework.PowerShell.csproj" />
<ProjectToBuild Include="src\EntityFramework.PowerShell.Utility\EntityFramework.PowerShell.Utility.csproj" />
<ProjectToBuild Include="src\EntityFramework.SqlServer\EntityFramework.SqlServer.csproj" />
<ProjectToBuild Include="src\EntityFramework.SqlServerCompact\EntityFramework.SqlServerCompact.csproj" />
<ProjectToBuild Include="src\EntityFramework.SqlServerCompact\EntityFramework.SqlServerCompact.Legacy.csproj" />
<ProjectToBuild Include="src\Migrate\Migrate.csproj" />
</ItemGroup>
<ItemGroup>
<NonCoreProjectToBuild Include="test\EntityFramework\FunctionalTests\FunctionalTests.csproj" />
<NonCoreProjectToBuild Include="test\EntityFramework\FunctionalTests.Transitional\FunctionalTests.Transitional.csproj" />
<NonCoreProjectToBuild Include="test\EntityFramework\FunctionalTests.ProviderAgnostic\FunctionalTests.ProviderAgnostic.csproj" />
<NonCoreProjectToBuild Include="test\EntityFramework\UnitTests\UnitTests.csproj" />
<NonCoreProjectToBuild Include="test\EntityFramework\VBTests\VBTests.vbproj" />
</ItemGroup>
<ItemGroup>
<ProjectToBuild Include="@(NonCoreProjectToBuild)" Condition="'$(BuildCoreOnly)' != 'true'" />
</ItemGroup>
<ItemGroup>
<XunitAssembly Include="test\EntityFramework\UnitTests\bin\$(Configuration)\EntityFramework.UnitTests.dll" />
<XunitAssembly Include="test\EntityFramework\FunctionalTests\bin\$(Configuration)\EntityFramework.FunctionalTests.dll" />
<XunitAssembly Include="test\EntityFramework\FunctionalTests.Transitional\bin\$(Configuration)\EntityFramework.FunctionalTests.Transitional.dll" />
<XunitAssembly Condition="'$(Configuration)' == '$(Configuration45)'"
Include="test\EntityFramework\VBTests\bin\$(Configuration)\EntityFramework.VBTests.dll" />
</ItemGroup>
<ItemGroup>
<ProviderAgnosticXunitAssembly Include="test\EntityFramework\FunctionalTests.ProviderAgnostic\bin\$(Configuration)\EntityFramework.FunctionalTests.ProviderAgnostic.dll" />
</ItemGroup>
<ItemGroup>
<XunitAssembly Include="@(ProviderAgnosticXunitAssembly)" />
</ItemGroup>
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), build.cmd))\tools\EntityFramework.settings.targets"/>
<Import Project="$(SolutionDir)\.nuget\nuget.targets" />
<Target Name="Clean" DependsOnTargets="CleanPackages">
<MSBuild Targets="Clean"
Projects="@(ProjectToBuild)"
Properties="Configuration=%(BuildConfiguration.Identity);$(BuildProperties)"
BuildInParallel="true" />
</Target>
<Target Name="RestorePackages" DependsOnTargets="CheckPrerequisites">
<PropertyGroup>
<RequireRestoreConsent>false</RequireRestoreConsent>
</PropertyGroup>
<Message Text="Restoring NuGet packages..." Importance="High" />
<Exec Command="$(NuGetCommand) restore EntityFramework.sln"
LogStandardErrorAsError="true" />
</Target>
<Target Name="Build" DependsOnTargets="RestorePackages">
<MSBuild Targets="Build"
Projects="@(ProjectToBuild)"
Properties="Configuration=%(BuildConfiguration.Identity);$(BuildProperties)"
BuildInParallel="true" />
</Target>
<Target Name="Rebuild" DependsOnTargets="Clean;Build" />
<!-- Rebuild core projects w/o internals visible and w/o running code quality tools. -->
<Target Name="RebuildLean">
<MSBuild Targets="Rebuild"
Projects="$(MSBuildThisFileFullPath)"
Properties="Configuration=$(Configuration);$(BuildProperties);BuildCoreOnly=true;InternalsInvisible=true;RunCodeAnalysis=false;StyleCopEnabled=false" />
</Target>
<Import Project="tools\SkipStrongNames.targets" />
<UsingTask TaskName="Xunit.Runner.MSBuild.xunit"
AssemblyFile="packages\xunit.1.9.2\lib\net20\xunit.runner.msbuild.dll" />
<Target Name="Test" DependsOnTargets="CheckSkipStrongNames;Build">
<xunit Assemblies="@(XunitAssembly)" Xml="$(OutputPath)TestResults.xml" />
</Target>
<Target Name="ProviderAgnosticTests" DependsOnTargets="CheckSkipStrongNames;Build">
<xunit Assemblies="@(ProviderAgnosticXunitAssembly)" />
</Target>
<Target Name="Package" DependsOnTargets="RebuildLean;BuildPackages" />
<Target Name="BuildPackages">
<MSBuild Targets="Build"
Projects="$(RepositoryRoot)src\NuGet\NuGet.proj"
Properties="Configuration=$(Configuration);RunCodeAnalysis=false;StyleCopEnabled=false"
Condition="'$(Configuration)' == '$(Configuration45)'" />
<CallTarget Targets="MoveNuGetSymbols" />
</Target>
<Target Name="CleanPackages" DependsOnTargets="RemoveNuGetSymbols">
<MSBuild Targets="Clean"
Projects="$(RepositoryRoot)src\NuGet\NuGet.proj"
Properties="Configuration=$(Configuration);RunCodeAnalysis=false;StyleCopEnabled=false"
Condition="'$(Configuration)' == '$(Configuration45)'" />
</Target>
<Target Name="MoveNuGetSymbols">
<ItemGroup>
<SymbolNuPkg Include="$(AssemblyPath)**\*symbols.nupkg" />
</ItemGroup>
<Move SourceFiles="@(SymbolNuPkg)" DestinationFolder="$(NuGetSymbolsOutputPath)" />
</Target>
<Target Name="RemoveNuGetSymbols">
<RemoveDir Directories="$(NuGetSymbolsOutputPath)" Condition="Exists($(NuGetSymbolsOutputPath))"/>
</Target>
</Project>