@joebigelow / wix / commits / 6d1c4cc8

Small Microsoft.Common.targets integration improvements

Rob Mensching committed Jan 13, 2022 at 13:14 UTC 6d1c4cc83214b65032251c67239b02da59a3e635
2 files changed +21 -20
src/wix/WixToolset.Sdk/tools/wix.props
+6
@@ -15,6 +15,12 @@
15
16 <Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
17
18 + <PropertyGroup>
19 + <Configurations Condition=" '$(Configurations)' == '' ">Debug;Release</Configurations>
20 + <Platforms Condition=" '$(Platforms)' == '' ">x86,x64,ARM64,AnyCPU</Platforms>
21 + <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
22 + </PropertyGroup>
23 +
24 <PropertyGroup>
25 <ProjectTypeGuids>B7DD6F7E-DEF8-4E67-B5B7-07EF123DB6F0</ProjectTypeGuids>
26 <AddAdditionalExplicitAssemblyReferences>false</AddAdditionalExplicitAssemblyReferences>
src/wix/WixToolset.Sdk/tools/wix.targets
+15 -20
@@ -43,6 +43,10 @@
43 <EmbeddedResource Include="**/*.wxl" Exclude="$(DefaultItemExcludes);$(DefaultExcludesInProjectFolder)" Condition=" '$(EnableDefaultEmbeddedResourceItems)' == 'true' " />
44 </ItemGroup>
45
46 + <ItemGroup>
47 + <AvailableItemName Include="BindPath;WixLibrary;WixExtension" />
48 + </ItemGroup>
49 +
50 <!--
51 ***********************************************************************************************
52 ***********************************************************************************************
@@ -56,15 +60,18 @@
60 <Language>wix</Language>
61 <TargetRuntime>wix</TargetRuntime>
62
63 + <!-- Ensure BaseOutputPath for Microsoft.Common.targets -->
64 + <BaseOutputPath Condition="'$(BaseOutputPath)' == ''">bin\</BaseOutputPath>
65 + <BaseOutputPath Condition="!HasTrailingSlash('$(BaseOutputPath)')">$(BaseOutputPath)\</BaseOutputPath>
66 +
67 <!-- Use OutputName to set the AssemblyName for Microsoft.Common.targets -->
68 <OutputName Condition=" '$(OutputName)'=='' ">$(MSBuildProjectName)</OutputName>
69 <AssemblyName>$(OutputName)</AssemblyName>
70
71 <!-- Default OutputType to a known WiX Toolset type. -->
72 <OutputType Condition=" '$(OutputType)' == '' ">Package</OutputType>
65 - <AvailablePlatforms>x86,x64,ARM,ARM64,AnyCPU</AvailablePlatforms>
73 + <AvailablePlatforms>x86,x64,ARM64,AnyCPU</AvailablePlatforms>
74
67 - <!-- Default WixPdbType to a known WiX Toolset type. -->
75 <WixPdbType Condition=" '$(WixPdbType)' == '' ">full</WixPdbType>
76 </PropertyGroup>
77
@@ -86,28 +93,21 @@
93 <TargetExt Condition=" '$(OutputType)' == 'IntermediatePostLink' ">.wixipl</TargetExt>
94 </PropertyGroup>
95
89 -<!--
90 - <PropertyGroup>
91 - <DefaultContentType Condition="$(DefaultContentType) == ''">Default</DefaultContentType>
92 - </PropertyGroup>
93 --->
94 -
96 <Import Project="$(MSBuildToolsPath)\Microsoft.Common.targets" />
97
97 - <!-- This will override some targets that get defined in Microsoft.Common so this needs to be imported after -->
98 - <Import Condition="Exists('$(DisableNetFrameworkResolutionTargets)') and '$(SkipImportDisableNetFrameworkResolutionTargets)' != 'true'" Project="$(DisableNetFrameworkResolutionTargets)" />
99 - <!-- being Import that mimics the above line where DisableNetFrameworkResolutionTargets == Microsoft.NET.DisableStandardFrameworkResolution.targets -->
98 + <!--
99 + This will override some targets that get defined in Microsoft.Common just like Microsoft.NET.DisableStandardFrameworkResolution.targets
100 + so this needs to be imported after
101 + -->
102 <Target Name="GetReferenceAssemblyPaths" />
103 <Target Name="GetFrameworkPaths" />
102 -
104 <PropertyGroup>
105 <_TargetFrameworkDirectories />
106 <FrameworkPathOverride />
107 <TargetFrameworkDirectory />
107 -
108 <NoStdLib>true</NoStdLib>
109 </PropertyGroup>
110 - <!-- end DisableNetFrameworkResolutionTargets == Microsoft.NET.DisableStandardFrameworkResolution.targets -->
110 + <!-- end Microsoft.NET.DisableStandardFrameworkResolution.targets -->
111
112 <PropertyGroup>
113 <!-- We don't target any frameworks, so clear what the Microsoft.Common.targets set -->
@@ -182,9 +182,8 @@
182 <WixExtension Include="$(WixExtension)" Condition=" '$(WixExtension)' != '' " />
183 </ItemGroup>
184
185 - <!-- Defaut Compiler properties. -->
185 + <!-- Default Compiler properties. -->
186 <PropertyGroup>
187 - <!-- TODO: This probably doesn't work any longer since Platform won't be defined until Microsoft.Common.targets is included -->
187 <InstallerPlatform Condition=" '$(InstallerPlatform)' == '' and '$(Platform)' != 'AnyCPU' and '$(Platform)' != 'Any CPU' ">$(Platform)</InstallerPlatform>
188 </PropertyGroup>
189
@@ -192,10 +191,6 @@
191 <ItemGroup>
192 <BindInputPaths Include="$(BindInputPaths)" Condition=" '$(BindInputPaths)' != '' " />
193 <LinkerBindInputPaths Include="$(LinkerBindInputPaths)" Condition=" '$(LinkerBindInputPaths)' != '' " />
195 - </ItemGroup>
196 -
197 - <!-- Default Lit and Light "properties" -->
198 - <ItemGroup>
194 <LinkerBindInputPaths Condition=" '@(LinkerBindInputPaths)' == '' " Include="@(BindInputPaths)" />
195 </ItemGroup>
196