Fixed NuGet references

pull/363/head
David Hall 2022-12-21 20:31:52 -07:00
parent a3cf995800
commit b2e972c77e
4 changed files with 25 additions and 8 deletions

View File

@ -18,9 +18,10 @@ DynamicMgmtObject, ManagementExtensions
<PackageReference Include="System.ValueTuple" Version="4.5.0" />
</ItemGroup>
<ItemGroup Condition=" '$(TargetFramework)' != 'net45' ">
<PackageReference Include="System.Management" Version="7.0.0" />
<PackageReference Include="System.Management" Version="6.0.0" Condition=" '$(TargetFramework)' == 'netcoreapp3.1' " />
<PackageReference Include="System.Management" Version="7.0.0" Condition=" '$(TargetFramework)' != 'netcoreapp3.1' " />
</ItemGroup>
<ItemGroup>
<ItemGroup Condition=" '$(TargetFramework)' == 'net45' ">
<Reference Include="System.Management" />
</ItemGroup>
</Project>

View File

@ -25,7 +25,8 @@ AccountLogonRights, DesiredAccess, SystemPrivilege
</When>
<Otherwise>
<ItemGroup>
<PackageReference Include="System.DirectoryServices" Version="7.0.0" />
<PackageReference Include="System.DirectoryServices" Version="6.0.0" Condition=" '$(TargetFramework)' == 'netcoreapp3.1' " />
<PackageReference Include="System.DirectoryServices" Version="7.0.0" Condition=" '$(TargetFramework)' != 'netcoreapp3.1' " />
</ItemGroup>
</Otherwise>
</Choose>

View File

@ -2,9 +2,19 @@
<PropertyGroup>
<AssemblyName>UnitTest.PInvoke.NTDSApi</AssemblyName>
</PropertyGroup>
<ItemGroup>
<Reference Include="System.DirectoryServices" />
</ItemGroup>
<Choose>
<When Condition=" $(TargetFramework.StartsWith('net4')) ">
<ItemGroup>
<Reference Include="System.DirectoryServices" />
</ItemGroup>
</When>
<Otherwise>
<ItemGroup>
<PackageReference Include="System.DirectoryServices" Version="6.0.0" Condition=" '$(TargetFramework)' == 'netcoreapp3.1' " />
<PackageReference Include="System.DirectoryServices" Version="7.0.0" Condition=" '$(TargetFramework)' != 'netcoreapp3.1' " />
</ItemGroup>
</Otherwise>
</Choose>
<ItemGroup>
<ProjectReference Include="..\..\..\PInvoke\NetApi32\Vanara.PInvoke.NetApi32.csproj" />
<ProjectReference Include="..\..\..\PInvoke\NTDSApi\Vanara.PInvoke.NTDSApi.csproj" />

View File

@ -19,8 +19,13 @@ CompactionMode, DeviceType, Subtype
</PropertyGroup>
<ItemGroup>
<PackageReference Include="System.IO.FileSystem.AccessControl" Version="5.0.0" Condition=" $(TargetFramework.StartsWith('netstandard')) Or $(TargetFramework.StartsWith('netcore')) Or $(TargetFramework.StartsWith('net5')) " />
<PackageReference Include="System.Management" Version="5.0.0" Condition=" '$(TargetFramework)' == 'net45' " />
<PackageReference Include="System.Management" Version="7.0.0" Condition=" '$(TargetFramework)' != 'net45' " />
</ItemGroup>
<ItemGroup Condition=" '$(TargetFramework)' != 'net45' ">
<PackageReference Include="System.Management" Version="6.0.0" Condition=" '$(TargetFramework)' == 'netcoreapp3.1' " />
<PackageReference Include="System.Management" Version="7.0.0" Condition=" '$(TargetFramework)' != 'netcoreapp3.1' " />
</ItemGroup>
<ItemGroup Condition=" '$(TargetFramework)' == 'net45' ">
<Reference Include="System.Management" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\Management\Vanara.Management.csproj" />