What is Project Centennial? In short, a tool for app developers to quickly convert x86/x64 applications (.msi or .exe) into Universal Apps (.appx). The apps could then be distributed via Windows Store or Windows Store for Business. For more information, take a look here:
Earlier today the tool to make this conversion was released in preview (download it here) and I’ve done my first test with it during the day. This post will cover the process in a few quick steps and give you a good start in converting apps. You can also review the official site from Microsoft covering the tool: Desktop to UWP app
Note, most (if not all) apps you convert today will probably be un-supported and if you use an app someone else have developed you are probably breaking some kind of agreement. So use this in test and development environments or on your apps developed in house. Lets get started!
A few things to be aware of:
- You need to be running the latest Windows 10 release (14316)
- You need to enable Containers (and it requires Windows Enterprise)
- You need to install Windows 10 SDK
- 64 bit (x64) processor
- Hardware-assisted virtualization
- Second Level Address Translation (SLAT)
Begin by downloading the preview together with the base-image in .WIM format. I recommend that you extract the tool in a folder on your C:\ drive but you could place it where it suits you. Place the base-image in the same folder.
Enable Containers either via the GUI (add remove features) or Powershell:
Enable-WindowsOptionalFeature -FeatureName Containers -Online
And install the Windows 10 Standalone SDK.
Open an administrative Powershell windows and set the execution policy to Bypass.
Next step is to extract the base-image and setup the tool. Default, it will place the image in: C:\ProgramData\Microsoft\Windows\Images\BaseImage-14316
Run the following line (only required the first time you run the tool on a computer):
.\DesktopAppConverter.ps1 -setup -Baseimage .\baseimage-14316.wim
Make sure you have navigated to the root of the DesktopAppConverter Folder before running the above.
When the command has finished, you are ready to start converting apps. In this example, I’ll use 7zip in MSI-format.
I use the same .ps1 script as before, but points it to the expanded (extracted) base image. This will be the base (containerized) when creating the app-package. Point out the default folder and fill in the rest of the required attributes.
When pointing out the msi, I recommend that you place it into a separate folder. The script will copy everything in the folder were the file is placed, and this could cause complications. I wasn’t a good idea to use my download folder for example. 🙂
Other things to be aware of:
- The version needs to be in the following format X.X.X.X
- The destination needs to be an empty folder or the script will create it for you.
- The Publisher needs the CN= first, and this will also be important to remember when setting up the certificates later on.
- Point out the correct executable.
- PackageName should not include a number.
- You also have a couple of optional attributes that you could use, but I will not cover them in details.