Skip to content

WinUI 3 (1.8.250906003): Build Warning: MSB8027, Linker Warning: LNK4042 #10772

@AdrianWenz

Description

@AdrianWenz

Describe the bug

After upgrading to WinUI 3 (1.8.250906003) via the Microsoft® Visual Studio NuGet interface, I get the following build/linker warnings when building the solution:

warning MSB8027: Two or more files with the name of DeploymentManagerAutoInitializer.cpp will produce outputs to the same location. This can lead to an incorrect build result.
warning MSB8027: Two or more files with the name of WindowsAppRuntimeAutoInitializer.cpp will produce outputs to the same location. This can lead to an incorrect build result.
DeploymentManagerAutoInitializer.cpp
DeploymentManagerAutoInitializer.cpp
WindowsAppRuntimeAutoInitializer.cpp
WindowsAppRuntimeAutoInitializer.cpp
warning LNK4042: object specified more than once; extras ignored
warning LNK4042: object specified more than once; extras ignored
XamlMetaDataProvider.cpp
XamlTypeInfo.g.cpp
warning LNK4042: object specified more than once; extras ignored
warning LNK4042: object specified more than once; extras ignored

packages.config.txt

Why is this important?

Building the solution results in the above build/linker warnings or occasionally even fails to build due to file access denials related to the above-mentioned files ('DeploymentManagerAutoInitializer.cpp' and 'WindowsAppRuntimeAutoInitializer.cpp').

Steps to reproduce the bug

  1. Upgrade from the previous version to 1.8.250906003 via the Microsoft® Visual Studio NuGet interface.
  2. Recompile the solution.

Actual behavior

No response

Expected behavior

No response

Screenshots

No response

NuGet package version

None

Windows version

No response

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingneeds-triageIssue needs to be triaged by the area owners

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions