-
Notifications
You must be signed in to change notification settings - Fork 44
Open
Description
I have a project looking like this:
<Project Sdk="MSBuild.Sdk.Extras">
<PropertyGroup>
<ExtrasBuildEachRuntimeIdentifier>true</ExtrasBuildEachRuntimeIdentifier>
<IsPackable>true</IsPackable>
<NoWarn>$(NoWarn);NU5131</NoWarn>
<RuntimeIdentifiers>@(SupportedRuntimes)</RuntimeIdentifiers>
<TargetFrameworks>net6.0</TargetFrameworks>
</PropertyGroup>
<ItemGroup>
<ReferenceAssemblyProjectReference Include="../ref/runtime.ref.csproj" />
</ItemGroup>
</Project>
It builds/packs fine on its own.
I reference it from another project like this:
<ProjectReference Include="../runtime/src/runtime.src.csproj"
SkipGetTargetFrameworkProperties="true"
ReferenceOutputAssembly="false" />
However, running dotnet pack
from this project results in:
runtime.src.csproj : error MSB4057: The target "GetCopyToPublishDirectoryItems" does not exist in the project.
A workaround I'm using for now is adding this at the bottom of the first project:
<Target Name="GetCopyToPublishDirectoryItems" />
Metadata
Metadata
Assignees
Labels
No labels