Skip to content

Commit 030bd2d

Browse files
authored
Merge pull request #71 from Concurrency-Lab/feature/support-vs2022
Fix build to support VS2022
2 parents 26accb4 + f6c7f06 commit 030bd2d

2 files changed

Lines changed: 52 additions & 78 deletions

File tree

Lines changed: 36 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -1,88 +1,62 @@
11
<?xml version="1.0" encoding="utf-8"?>
2-
<Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
2+
<Project>
3+
<Import Sdk="Microsoft.NET.Sdk" Project="Sdk.props" />
4+
35
<PropertyGroup>
4-
<MinimumVisualStudioVersion>16.0</MinimumVisualStudioVersion>
5-
<VSToolsPath Condition="'$(VSToolsPath)' == ''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)</VSToolsPath>
6-
<FileUpgradeFlags>
7-
</FileUpgradeFlags>
8-
<UpgradeBackupLocation>
9-
</UpgradeBackupLocation>
10-
<OldToolsVersion>15.0</OldToolsVersion>
11-
</PropertyGroup>
12-
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
13-
<PropertyGroup>
14-
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
15-
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
16-
<SchemaVersion>2.0</SchemaVersion>
17-
<ProjectTypeGuids>{82b43b9b-a64c-4715-b499-d71e9ca2bd60};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
18-
<ProjectGuid>{557F9B7A-043D-40C3-A57A-8DAE20334DB1}</ProjectGuid>
19-
<OutputType>Library</OutputType>
20-
<AppDesignerFolder>Properties</AppDesignerFolder>
6+
<TargetFramework>net472</TargetFramework>
217
<RootNamespace>ParallelHelper.Plugin</RootNamespace>
228
<AssemblyName>ParallelHelper.Plugin</AssemblyName>
23-
<TargetFrameworkVersion>v4.7.2</TargetFrameworkVersion>
9+
</PropertyGroup>
10+
11+
<PropertyGroup>
2412
<GeneratePkgDefFile>false</GeneratePkgDefFile>
2513
<IncludeAssemblyInVSIXContainer>false</IncludeAssemblyInVSIXContainer>
2614
<IncludeDebugSymbolsInVSIXContainer>false</IncludeDebugSymbolsInVSIXContainer>
2715
<IncludeDebugSymbolsInLocalVSIXDeployment>false</IncludeDebugSymbolsInLocalVSIXDeployment>
2816
<CopyBuildOutputToOutputDirectory>false</CopyBuildOutputToOutputDirectory>
2917
<CopyOutputSymbolsToOutputDirectory>false</CopyOutputSymbolsToOutputDirectory>
3018
<VSSDKTargetPlatformRegRootSuffix>Exp</VSSDKTargetPlatformRegRootSuffix>
31-
<StartAction>Program</StartAction>
32-
<StartProgram Condition="'$(DevEnvDir)' != ''">$(DevEnvDir)devenv.exe</StartProgram>
33-
<StartArguments>/rootsuffix Exp</StartArguments>
34-
</PropertyGroup>
35-
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
36-
<DebugSymbols>true</DebugSymbols>
37-
<DebugType>full</DebugType>
38-
<Optimize>false</Optimize>
39-
<OutputPath>bin\Debug\</OutputPath>
40-
<DefineConstants>DEBUG;TRACE</DefineConstants>
41-
<ErrorReport>prompt</ErrorReport>
42-
<WarningLevel>4</WarningLevel>
4319
</PropertyGroup>
44-
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
45-
<DebugType>pdbonly</DebugType>
46-
<Optimize>true</Optimize>
47-
<OutputPath>bin\Release\</OutputPath>
48-
<DefineConstants>TRACE</DefineConstants>
49-
<ErrorReport>prompt</ErrorReport>
50-
<WarningLevel>4</WarningLevel>
51-
</PropertyGroup>
52-
<ItemGroup>
53-
<None Include="source.extension.vsixmanifest">
54-
<SubType>Designer</SubType>
55-
</None>
56-
</ItemGroup>
20+
5721
<ItemGroup>
5822
<Content Include="GettingStarted.txt">
59-
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
23+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
6024
<IncludeInVSIX>true</IncludeInVSIX>
6125
</Content>
6226
<Content Include="License.txt">
63-
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
27+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
6428
<IncludeInVSIX>true</IncludeInVSIX>
6529
</Content>
6630
<Content Include="ReleaseNotes.txt">
67-
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
31+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
6832
<IncludeInVSIX>true</IncludeInVSIX>
6933
</Content>
7034
</ItemGroup>
35+
36+
<ItemGroup>
37+
<PackageReference Include="Microsoft.VSSDK.BuildTools" Version="17.0.3155-preview3" PrivateAssets="all" />
38+
</ItemGroup>
39+
40+
<PropertyGroup>
41+
<StartAction>Program</StartAction>
42+
<StartProgram>$(DevEnvDir)devenv.exe</StartProgram>
43+
<StartArguments>/rootsuffix $(VSSDKTargetPlatformRegRootSuffix)</StartArguments>
44+
</PropertyGroup>
45+
46+
<Import Sdk="Microsoft.NET.Sdk" Project="Sdk.targets" />
47+
48+
<Import Project="$(VSToolsPath)\VSSDK\Microsoft.VsSDK.targets" Condition="Exists('$(VSToolsPath)\VSSDK\Microsoft.VsSDK.targets')" />
49+
50+
<ItemGroup>
51+
<ProjectReference Include="..\ParallelHelper\ParallelHelper.csproj" />
52+
</ItemGroup>
53+
7154
<ItemGroup>
72-
<ProjectReference Include="..\ParallelHelper\ParallelHelper.csproj">
73-
<Project>{1318b550-f96b-4d81-b91f-e2e35373e909}</Project>
74-
<Name>ParallelHelper</Name>
75-
<IncludeOutputGroupsInVSIX>BuiltProjectOutputGroup%3bBuiltProjectOutputGroupDependencies%3bGetCopyToOutputDirectoryItems%3bSatelliteDllsProjectOutputGroup%3b</IncludeOutputGroupsInVSIX>
76-
<IncludeOutputGroupsInVSIXLocalOnly>DebugSymbolsProjectOutputGroup%3b</IncludeOutputGroupsInVSIXLocalOnly>
77-
</ProjectReference>
55+
<!-- https://github.com/dotnet/sdk/issues/433 -->
56+
<ProjectReference Update="@(ProjectReference)" AdditionalProperties="TargetFramework=netstandard2.0" />
57+
58+
<!-- https://github.com/Microsoft/extendvs/issues/57 -->
59+
<ProjectReference Update="@(ProjectReference)" Name="%(Filename)" />
7860
</ItemGroup>
79-
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
80-
<Import Project="$(VSToolsPath)\VSSDK\Microsoft.VsSDK.targets" Condition="'$(VSToolsPath)' != ''" />
81-
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
82-
Other similar extension points exist, see Microsoft.Common.targets.
83-
<Target Name="BeforeBuild">
84-
</Target>
85-
<Target Name="AfterBuild">
86-
</Target>
87-
-->
61+
8862
</Project>

src/ParallelHelper.Plugin/source.extension.vsixmanifest

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -11,24 +11,24 @@
1111
<Tags>C#; Parallel; Asynchronous; Concurrency; Bugs; Best Practices; TPL; Task; QC; Static Analysis; async; await</Tags>
1212
</Metadata>
1313
<Installation>
14-
<InstallationTarget Id="Microsoft.VisualStudio.Community" Version="[16.3,17.0)" >
15-
<ProductArchitecture>x86</ProductArchitecture>
14+
<InstallationTarget Id="Microsoft.VisualStudio.Community" Version="[16.3,)">
15+
<ProductArchitecture>x86</ProductArchitecture>
1616
</InstallationTarget>
17-
<InstallationTarget Id="Microsoft.VisualStudio.Pro" Version="[16.3,17.0)" >
18-
<ProductArchitecture>x86</ProductArchitecture>
17+
<InstallationTarget Id="Microsoft.VisualStudio.Community" Version="[16.3,)">
18+
<ProductArchitecture>amd64</ProductArchitecture>
1919
</InstallationTarget>
20-
<InstallationTarget Id="Microsoft.VisualStudio.Enterprise" Version="[16.3,17.0)" >
21-
<ProductArchitecture>x86</ProductArchitecture>
20+
<InstallationTarget Id="Microsoft.VisualStudio.Pro" Version="[16.3,)">
21+
<ProductArchitecture>x86</ProductArchitecture>
22+
</InstallationTarget>
23+
<InstallationTarget Id="Microsoft.VisualStudio.Pro" Version="[16.3,)">
24+
<ProductArchitecture>amd64</ProductArchitecture>
25+
</InstallationTarget>
26+
<InstallationTarget Id="Microsoft.VisualStudio.Enterprise" Version="[16.3,)">
27+
<ProductArchitecture>x86</ProductArchitecture>
28+
</InstallationTarget>
29+
<InstallationTarget Id="Microsoft.VisualStudio.Enterprise" Version="[16.3,)">
30+
<ProductArchitecture>amd64</ProductArchitecture>
2231
</InstallationTarget>
23-
<InstallationTarget Id="Microsoft.VisualStudio.Community" Version="[17.0,18.0)">
24-
<ProductArchitecture>amd64</ProductArchitecture>
25-
</InstallationTarget>
26-
<InstallationTarget Id="Microsoft.VisualStudio.Pro" Version="[17.0,18.0)">
27-
<ProductArchitecture>amd64</ProductArchitecture>
28-
</InstallationTarget>
29-
<InstallationTarget Id="Microsoft.VisualStudio.Enterprise" Version="[17.0,18.0)">
30-
<ProductArchitecture>amd64</ProductArchitecture>
31-
</InstallationTarget>
3232
</Installation>
3333
<Dependencies>
3434
<Dependency Id="Microsoft.Framework.NDP" DisplayName="Microsoft .NET Framework" d:Source="Manual" Version="[4.7.2,)" />
@@ -37,6 +37,6 @@
3737
<Asset Type="Microsoft.VisualStudio.Analyzer" d:Source="Project" d:ProjectName="ParallelHelper" Path="|ParallelHelper|" />
3838
</Assets>
3939
<Prerequisites>
40-
<Prerequisite Id="Microsoft.VisualStudio.Component.CoreEditor" Version="[15.0,18.0)" DisplayName="Visual Studio core editor" />
40+
<Prerequisite Id="Microsoft.VisualStudio.Component.CoreEditor" Version="[15.0,)" DisplayName="Visual Studio core editor" />
4141
</Prerequisites>
4242
</PackageManifest>

0 commit comments

Comments
 (0)