MSIX packaging utilities for CMake
npm install cmake-msixFunctions to simplify the creation of MSIX packages for distributing Windows applications.
#### find_make_appx
Locates the MakeAppx.exe tool from the Windows SDK, required for building MSIX packages.
``cmake`
find_make_appx(
##### MakeAppx.exe
An output variable where the path to the executable will be stored.
#### add_app_manifest
Generates the core AppxManifest.xml file, which defines essential metadata for the MSIX package.
`cmake`
add_appx_manifest(
[DESTINATION
NAME
VERSION
PUBLISHER
[DISPLAY_NAME
PUBLISHER_DISPLAY_NAME
DESCRIPTION
[UNVIRTUALIZED_PATHS
)
#####
The name of the CMake target to create.
##### DESTINATION AppxManifest.xml
The output file path for the . Defaults to "AppxManifest.xml" in the build directory.
##### NAME
The name of the application.
##### VERSION
The semantic version of the application.
##### PUBLISHER
The publisher of the application.
##### DISPLAY_NAME "${NAME}"
The name displayed to users. Defaults to .
##### PUBLISHER_DISPLAY_NAME
The publisher's display name.
##### DESCRIPTION
A description of the application.
##### UNVIRTUALIZED_PATHS
A list of paths that should remain unvirtualized within the MSIX package.
#### add_appx_mapping
Creates a Mapping.txt file that specifies the file structure within the MSIX package.
`cmake`
add_appx_mapping(
[DESTINATION
[ICON
[TARGET
[EXECUTABLE
[RESOURCES [FILE|DIR
)
#####
The name of the CMake target to create.
##### DESTINATION Mapping.txt
The output file path for the . Defaults to "Mapping.txt" in the build directory.
##### ICON
Path to the application icon.
##### TARGET
An existing CMake target representing the core executable of your application.
##### EXECUTABLE TARGET
Direct path to the application executable. Use if not providing .
##### RESOURCES [FILE|DIR
A list of additional files or directories to include.
###### FILE
Copies a file from to within the MSIX package.
###### DIR
Copies an entire directory from to within the MSIX package.
#### add_msix_package
The central function to generate the final MSIX package.
`cmake`
add_msix_package(
DESTINATION
[MANIFEST
[MAPPING
[DEPENDS
)
#####
The name of the CMake target to create.
##### DESTINATION
The output path and filename for the MSIX package.
##### MANIFEST AppxManifest.xml
Path to the file. Defaults to "AppxManifest.xml" in the build directory.
##### MAPPING "Mapping.txt"
Path to the Mapping.txt file. Defaults to in the build directory.
##### DEPENDS
A list of CMake targets on which the package build depends.
Apache-2.0