Skip to content

Targeting pack support for .NET Core 3.0 #9744

Closed

Description

@dsplaisted

For .NET Core 3.0, we expect to separate targeting packs, which contain the assets needed at build time when targeting .NET Core 3.0 (for example, reference assemblies and intellisense documentation) from "runtime packs", which will include the platform-specific runtime components for .NET Core 3.

This issue tracks the work required in order to support targeting packs. This may include:

Finer-grained issues for these tasks will be filed as necessary

Activity

  1. dasMulli commented on Sep 17, 2018

    @dasMulli
    Contributor

    🙏 dotnet targeting-pack install net472 ❤️

  2. dasMulli commented on Sep 17, 2018

    @dasMulli
    Contributor

    Same as for https://github.com/dotnet/cli/issues/10007, please consider:

    • Clean-up story
    • Location and permission configuration. This may be important for build scripts that may not have superuser / elevated permissions and would need to use a custom folder (dotnet targeting-pack install net472 -o ./targeting-packs; dotnet build foo/foo.csproj --targeting-packs ./targeting-pakcs)
  3. nguerrera commented on Oct 2, 2018

    @nguerrera
    Contributor

    More design details will follow, but at a very high level we are looking at having the experience be that if you do not have the targeting pack globally installed / bundled with SDK, then nuget restore would pull it down to nuget cache via NuGet/Home#7339

  4. dasMulli commented on Nov 29, 2018

    @dasMulli
    Contributor

    Ideally, this shouldn't break usages of

    MetadataReference[] _ref = 
        DependencyContext.Default.CompileLibraries
        .First(cl => cl.Name == "Microsoft.NETCore.App")
        .ResolveReferencePaths()
        .Select(asm => MetadataReference.CreateFromFile(asm))
        .ToArray();

    when using PreserveCompilationContext=true

    It should only need an update to the dependency model NuGet package.

  5. pozitron01 commented on Nov 19, 2019

    @pozitron01

    Hello,
    I hop I am not mess up this topic but I do not find any reference for targeting-pack commands...

    dotnet targeting-pack install net472

    This does not work to me.

    My Dockerfile:

    FROM mcr.microsoft.com/dotnet/core/sdk:3.0
    
    WORKDIR /installer
    # Targeting pack install
    RUN wget -c https://download.visualstudio.microsoft.com/download/pr/cb26477c-ca65-4fa7-86cc-de0131303875/b844b61ec6ddab5d82dabc6c5efd419b/dotnet-targeting-pack-3.0.0-preview8-28405-07-x64.deb
    RUN wget -c https://download.visualstudio.microsoft.com/download/pr/90cf071f-8412-45b1-9237-ade8d9d5b871/adcdf7d67cb0554f6a53af3d3b303e9d/aspnetcore-targeting-pack-3.0.0-preview8.19405.7.deb
    
    RUN dpkg -i dotnet-targeting-pack-3.0.0-preview8-28405-07-x64.deb
    RUN dpkg -i aspnetcore-targeting-pack-3.0.0-preview8.19405.7.deb
    
    WORKDIR /usr/src
    

    When i run the above command i got the following message:

    root@4aa0901c2878:/usr/src# dotnet targeting-pack install net471
    Specify which project file to use because this '/usr/src' contains more than one project file.
    

    I have tried to point a specific .csproj file with no luck. :(

    Can anybody help me with this?

    Or can anybody explain me how to build (for run stylecop really) a multiple .csproj project in a CI pipeline?

    Thank you

  6. transferred this issue fromdotnet/clion Jan 31, 2020
  7. added this to the 3.0.1xx milestone on Jan 31, 2020
  8. removed
    EpicGroups multiple user stories. Can be grouped under a theme.
    on Aug 12, 2026
  9. added theissue type on Aug 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions