forked from dotnet/wcf
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Versioning.props
86 lines (75 loc) · 4.55 KB
/
Versioning.props
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
<Project>
<PropertyGroup>
<GenerateAssemblyInfo Condition="'$(GenerateAssemblyInfo)'==''">true</GenerateAssemblyInfo>
<Ship_SvcUtilXmlSerPackages Condition="'$(Ship_SvcUtilXmlSerPackages)'==''">false</Ship_SvcUtilXmlSerPackages>
<Ship_SvcUtilPackages Condition="'$(Ship_SvcUtilPackages)'==''">false</Ship_SvcUtilPackages>
<Ship_WcfPackages Condition="'$(Ship_WcfPackages)'==''">true</Ship_WcfPackages>
</PropertyGroup>
<PropertyGroup Condition="'$(GenerateAssemblyInfo)'=='true'">
<AssemblyInfoFile Condition="'$(MSBuildProjectExtension)' == '.csproj'">$(IntermediateOutputPath)_AssemblyInfo.cs</AssemblyInfoFile>
</PropertyGroup>
<PropertyGroup>
<!-- Disable some standard properties for building our projects -->
<!-- [todo:arcade] Disabling these because our shipped assemblies didn't include these attributes, not sure if we care or not. -->
<GenerateTargetFrameworkAttribute>false</GenerateTargetFrameworkAttribute>
<GenerateAssemblyConfigurationAttribute>false</GenerateAssemblyConfigurationAttribute>
<!-- [todo:arcade] This attribute exists in our previously shipped S.P.SM assembly but not in all the Facade assemblies. For now removing accross all assemblies. -->
<GenerateNeutralResourcesLanguageAttribute>false</GenerateNeutralResourcesLanguageAttribute>
</PropertyGroup>
<!-- Assembly metadata indicating that an assembly is a framework (as opposed to user) assembly:
Test projects need to not have this because of the way "IsFrameworkAssembly" APIs work to check this. -->
<!-- [todo:arcade] Make sure all test projects set IsTestProject to true -->
<ItemGroup Condition="'$(IsTestProject)' != 'true'" >
<AssemblyMetadata Include=".NETFrameworkAssembly">
<Value></Value>
</AssemblyMetadata>
<AssemblyMetadata Include="Serviceable">
<Value>True</Value>
</AssemblyMetadata>
<AssemblyMetadata Include="PreferInbox">
<Value>True</Value>
</AssemblyMetadata>
</ItemGroup>
<!--TODO ARCADE in the CoreFx version there is a depends on, investigate if this is necessary.-->
<Target Name="_ComputeAssemblyInfoAttributes"
BeforeTargets="GetAssemblyAttributes">
<PropertyGroup>
<!-- wcf has always added a description set to assembly name so include that here -->
<Description Condition="'$(Description)' == ''">$(AssemblyName)</Description>
<!-- SDK sets product to assembly but we want it to be our product name -->
<!-- [todo:arcade] In our previous shipped WCF pkgs (4.5.0) this value is Microsoft .NET Framework on all the assemblies regardless of whether they are for desktop, uap or unix. -->
<Product>Microsoft%AE .NET Core</Product>
<!-- Use the .NET Core product branding version for informational version description -->
<!-- [todo:arcade] Currently in local builds this is producing a weird version "3.0.0-ci.19157.1" need to verify what this looks like in an official build. -->
<InformationalVersion>$(ProductVersion)</InformationalVersion>
<InformationalVersion Condition="'$(VersionSuffix)' != ''">$(InformationalVersion)-$(VersionSuffix)</InformationalVersion>
</PropertyGroup>
<ItemGroup>
<AssemblyAttribute Include="System.Reflection.AssemblyDefaultAliasAttribute">
<_Parameter1>$(AssemblyName)</_Parameter1>
</AssemblyAttribute>
<AssemblyAttribute Include="System.Reflection.AssemblyMetadata"
Condition="'$(SkipFrameworkAssemblyMetadata)' != 'true' and '@(AssemblyMetadata)' != ''">
<_Parameter1>%(AssemblyMetadata.Identity)</_Parameter1>
<_Parameter2>%(AssemblyMetadata.Value)</_Parameter2>
</AssemblyAttribute>
</ItemGroup>
</Target>
<!-- Work around https://github.com/Microsoft/msbuild/issues/3412 by writing the non-string assembly attributes manually -->
<Target Name="_WriteNonStringAssemblyInfoAttributes"
AfterTargets="CoreGenerateAssemblyInfo"
Inputs="$(MSBuildProjectFile)"
Outputs="$(AssemblyInfoFile)">
<ItemGroup Condition="'$(MSBuildProjectExtension)' == '.csproj'">
<AssemblyInfoLines Condition="'$(CLSCompliant)'=='true'" Include="[assembly:System.CLSCompliant(true)]" />
</ItemGroup>
<WriteLinesToFile File="$(AssemblyInfoFile)"
Lines="@(AssemblyInfoLines)"
Condition="'@(AssemblyInfoLines)' != ''"
Overwrite="true" />
<ItemGroup Condition="'@(AssemblyInfoLines)' != ''">
<Compile Include="$(AssemblyInfoFile)" />
<FileWrites Include="$(AssemblyInfoFile)" />
</ItemGroup>
</Target>
</Project>