Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Newer approach to reference assemblies on MacOS and Linux #3448

Merged
merged 2 commits into from
Mar 7, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion playground/MSTest1/MSTest1.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
<PackageReference Include="coverlet.collector" Version="1.2.0" />
</ItemGroup>
<ItemGroup Condition=" $(TargetFramework.StartsWith('net4')) AND '$(OS)' != 'Windows_NT' ">
<Reference Include="netstandard" />
<Reference Include="System" />
<Reference Include="System.Runtime" />
<Reference Include="System.Xml" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@
<ProjectReference Include="..\MSTest1\MSTest1.csproj" />
</ItemGroup>
<ItemGroup Condition=" $(TargetFramework.StartsWith('net4')) AND '$(OS)' != 'Windows_NT' ">
<Reference Include="netstandard" />
<Reference Include="System" />
<Reference Include="System.Runtime" />
<Reference Include="System.Xml" />
Expand Down
2 changes: 0 additions & 2 deletions scripts/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -267,8 +267,6 @@ function invoke_build()
local start=$SECONDS
log ".. .. Build: Source: $TPB_Solution"

# Workaround for https://github.com/dotnet/sdk/issues/335
export FrameworkPathOverride=$TP_PACKAGES_DIR/microsoft.targetingpack.netframework.v4.7.2/1.0.0/lib/net472/
if [ -z "$PROJECT_NAME_PATTERNS" ]
then
if [[ $TP_USE_REPO_API = 0 ]]; then
Expand Down
5 changes: 5 additions & 0 deletions scripts/build/TestPlatform.Settings.targets
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,11 @@
<!-- Package dependency versions -->
<Import Project="$(MSBuildThisFileDirectory)TestPlatform.Dependencies.props" Condition=" '$(DependencyVersionsImported)' != 'true' "/>

<!-- Allows build of .NET Framework assemblies on MacOS and Linux https://github.com/dotnet/designs/pull/33#issuecomment-489264196 -->
<ItemGroup>
<PackageReference Condition=" '$(OS)' != 'Windows_NT' " Include="Microsoft.NETFramework.ReferenceAssemblies" Version="1.0.0" PrivateAssets="All" />
nohwnd marked this conversation as resolved.
Show resolved Hide resolved
</ItemGroup>

<!-- Include PublicApi analyzers into all projects that are in our src directory, this can't use TestProject == true
because some projects in test and playground are not tests, but we don't want to analyze those for public apis, because
we don't ship them.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@
<Reference Include="System.Runtime" />
<Reference Include="System.Xml" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="netstandard" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Microsoft.Diagnostics.NETCore.Client" Version="$(MicrosoftDiagnosticsNETCoreClientVersion)" />
Expand Down
5 changes: 0 additions & 5 deletions src/package/external/external.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -60,11 +60,6 @@
<PackageReference Include="Microsoft.NETCore.ILAsm" Version="$(ILAsmPackageVersion)" />
<PackageReference Include="Microsoft.NETCore.ILDAsm" Version="$(ILAsmPackageVersion)" />
<PackageReference Include="Microsoft.DotNet.Build.Tasks.Feed" Version="$(MicrosoftDotNetBuildTasksFeedVersion)" PrivateAssets="All" />

<!-- Required for resolution of desktop dependencies in non windows environment.
We've to set to net472 since the net451 and other packages have assemblies in wrong case.
E.g. System.XML instead of System.Xml. -->
<PackageReference Include="Microsoft.TargetingPack.NETFramework.v4.7.2" Version="1.0.0" PrivateAssets="All" />
</ItemGroup>
<Import Project="$(TestPlatformRoot)scripts\build\TestPlatform.targets" />

Expand Down
1 change: 0 additions & 1 deletion src/testhost.arm64/testhost.arm64.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@
<!-- CVE-2019-0657, CVE-2019-0980 and CVE-2019-0981 mitigation -->
</ItemGroup>
<ItemGroup Condition=" $(TargetFramework.StartsWith('net4')) AND '$(OS)' != 'Windows_NT' ">
<Reference Include="netstandard" />
<Reference Include="System" />
<Reference Include="System.Runtime" />
<Reference Include="System.Xml" />
Expand Down
1 change: 0 additions & 1 deletion src/testhost.x86/testhost.x86.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@
<!-- CVE-2019-0657, CVE-2019-0980 and CVE-2019-0981 mitigation -->
</ItemGroup>
<ItemGroup Condition=" $(TargetFramework.StartsWith('net4')) AND '$(OS)' != 'Windows_NT' ">
<Reference Include="netstandard" />
<Reference Include="System" />
<Reference Include="System.Runtime" />
<Reference Include="System.Xml" />
Expand Down
1 change: 0 additions & 1 deletion src/testhost/testhost.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@
<!-- CVE-2019-0657, CVE-2019-0980 and CVE-2019-0981 mitigation -->
</ItemGroup>
<ItemGroup Condition=" $(TargetFramework.StartsWith('net4')) AND '$(OS)' != 'Windows_NT' ">
<Reference Include="netstandard" />
<Reference Include="System" />
<Reference Include="System.Runtime" />
<Reference Include="System.Xml" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@
<Reference Include="System" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Xml" />
<Reference Include="netstandard" />
</ItemGroup>
<Import Project="$(TestPlatformRoot)scripts\build\TestPlatform.targets" />
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
<Reference Include="System" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Xml" />
<Reference Include="netstandard" />
</ItemGroup>
<Import Project="$(TestPlatformRoot)scripts\build\TestPlatform.targets" />
</Project>