How to merge dependency into .Appx to avoid -DependencyPath argument

2.5k Views Asked by At

I have a large win32 program consisting of a mixture of native and managed code. I would like to put it into a single .Appx file for simple installation on Windows 10. I don't want to put it in the Windows Store - I simply want to replace the old installer with an .Appx file.

Using the DesktopAppConverter I have converted the program to an .Appx. My problem is that the DesktopAppConverter adds a dependency on 'Microsoft.VCLibs.140.00.UWPDesktop' which means that I have to distribute both my .appx and Microsoft.VCLibs.x64.14.00.Desktop.appx. So the user can no longer just click my .appx file but has to run this from PowerShell:

Add-AppxPackage .\MyApp.appx -DependencyPath .\Microsoft.VCLibs.x64.14.00.Desktop.appx

Is there a way that I can "merge" the dependency into a single .appx that the user can just double click to install?

1

There are 1 best solutions below

1
On

Microsoft documents support for appx bundles, you could try that.

Another option, more risky, would be to assume that such a dependency is already present on the machine (it is quite common so it might be installed by other packages from the store). In this case you can edit your appx package and remove the dependency from it.

Advanced Installer can import appx packages and provide an easy to use GUI to edit their content, with just a few clicks you can remove/add your dependencies.

Disclaimer: I am part of the team building Advanced Installer over the last 14 years.