Skip to content

.Net Core 3 preview 6 PublishTrimmed errors when using Microsoft.Management.Infrastructure package #665

@sbomer

Description

@sbomer

@theimowski in https://github.com/dotnet/coreclr/issues/25703#issue-468342557

> dotnet --version
3.0.100-preview6-012264
  1. dotnet new console
  2. dotnet add package Microsoft.Management.Infrastructure --version 1.0.0
  3. dotnet publish --framework netcoreapp3.0 --runtime win10-x64 /p:PublishTrimmed=true

Errors with Microsoft.NET.ILLink.targets(87,5): error MSB6006: "dotnet" exited with code 134.

Microsoft (R) Build Engine version 16.2.0-preview-19278-01+d635043bd for .NET Core
Copyright (C) Microsoft Corporation. All rights reserved.

  Restore completed in 414.31 ms for /Users/theimowski/sandbox/dotnet/ILLink.MMI/ILLink.MMI.csproj.
/usr/local/share/dotnet/sdk/3.0.100-preview6-012264/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.RuntimeIdentifierInference.targets(158,5): message NETSDK1057: You are using a preview version of .NET Core. See: https://aka.ms/dotnet-core-preview [/Users/theimowski/sandbox/dotnet/ILLink.MMI/ILLink.MMI.csproj]
/usr/local/share/dotnet/sdk/3.0.100-preview6-012264/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.targets(328,5): warning NETSDK1074: The application host executable will not be customized because adding resources requires that the build be performed on Windows (excluding Nano Server). [/Users/theimowski/sandbox/dotnet/ILLink.MMI/ILLink.MMI.csproj]
  ILLink.MMI -> /Users/theimowski/sandbox/dotnet/ILLink.MMI/bin/Debug/netcoreapp3.0/win10-x64/ILLink.MMI.dll
/usr/local/share/dotnet/sdk/3.0.100-preview6-012264/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.ILLink.targets(87,5): error MSB6006: "dotnet" exited with code 134. [/Users/theimowski/sandbox/dotnet/ILLink.MMI/ILLink.MMI.csproj]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions