VS 2022: Error when creating the app packages for more than one architecture

Heiko 1,211 Reputation points
2022-08-13T14:24:40.093+00:00

It is not possible to select more than one target platform in VS 2022 without encountering an error when creating the packages.

It is easy to recreate:

  • Create an empty UWP project.
  • Associate it with a store app.
  • Open the app package creation dialog.
  • Choose as architecture (x86 + x64) or (x64 + ARM) or (x86 + ARM).

The following combinations work:

ARM64 + ARM
ARM64 + x86
ARM64 + x64

See Output here

Universal Windows Platform (UWP)
Visual Studio
Visual Studio
A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.
4,604 questions
{count} votes

Accepted answer
  1. Roy Li - MSFT 31,766 Reputation points Microsoft Vendor
    2022-08-30T08:13:40.283+00:00

    Hello,

    Welcome to Microsoft Q&A!

    Make a summary about this question.

    This issue seems to be related to the environment that using now. After creating a new VM, installing the new Windows 11 and Visual Studio 2022, the problem seems to disappear.

    Thank you.


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

1 additional answer

Sort by: Most helpful
  1. Heiko 1,211 Reputation points
    2022-08-16T13:03:12.013+00:00

    I have version 6.2.14 and VS 2022 17.3.0.

    I tried 6.2.13, but get the same errors.

    I tried 6.2.12.
    Now the following work:
    (x86 + x64)
    (x86 + ARM)
    (ARM + ARM64)
    (x64 + ARM64)

    But the following doesn't work with same errors:
    (x64 + ARM)
    (x86 + x64 + ARM + ARM64)

    Package created for x86 and built a msixupload file, but failed for ARM64 without any error:
    (x86 + ARM64)

    *Build started...
    1>------ Build started: Project: TestApp1, Configuration: Release ARM64 ------
    1> TestApp1 -> D:\VS Community 2022\MyProjects\Test\TestApp1\TestApp1\bin\ARM64\Release\TestApp1.exe
    1> Processing application code
    1> Computing application closure and generating interop code
    1> Loading 44 modules...
    1> Generating code...
    1> Interop code generated.
    1> Compiling interop code
    1> Generating System.Reflection.DispatchProxy proxy code.
    1> Cleaning up unreferenced code
    1> Generating native code
    1> Generating fixups for native code
    1> TestApp1 -> D:\VS Community 2022\MyProjects\Test\TestApp1\TestApp1\bin\ARM64\Release\TestApp1_1.0.24.0_ARM64.msix
    1> TestApp1 -> obj\ARM64\Release\Symbols\TestApp1_1.0.24.0_ARM64.appxsym
    1> TestApp1 -> D:\VS Community 2022\MyProjects\Test\TestApp1\TestApp1\bin\ARM64\Release\Upload\TestApp1_1.0.24.0\TestApp1_1.0.24.0_ARM64.appxsym
    1> TestApp1 -> D:\VS Community 2022\MyProjects\Test\TestApp1\TestApp1\AppPackages\TestApp1_1.0.24.0_Test\TestApp1_1.0.24.0_x86_arm64.msixbundle
    1> TestApp1 -> D:\VS Community 2022\MyProjects\Test\TestApp1\TestApp1\AppPackages\TestApp1_1.0.24.0_x86_arm64_bundle.msixupload
    1> Your package has been successfully created.

    ==========
    Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
    A package has been successfully built for Release (x86).

    ==========
    Package: 1 succeeded, 1 failed ===========

    ==========
    App Bundle: 1 succeeded, 1 failed ===========*

    I tried 6.2.11.
    The following work:
    (x86 + x64)

    The following doesn't work, with same errors:
    (x86 + ARM)

    I tried 6.2.10.
    The following work:
    (x86 + x64)

    The following doesn't work, with same errors:
    (x86 + ARM)

    The errors occur in VS 2022 under Windows 11. I don't think it has anything to do with microsoft.netcore.universalwindowsplatform, because in the production VM with Windows 10 and VS 2017 the UWP projects have the versions 6.2.8 and 6.2.13 and there I can build the packages and bundles for (x86 + x64 + ARM) without errors.

    I reinstalled version 6.2.14 (VS2022) and set the MSBuild verbose settings to Diagnostic. Now (x86 + x64) works, but (x86 + x64 + ARM + ARM64) not and (x86 + ARM) also doesn't work.

    Here is the Build output for the ARM package (x86 + ARM).