Skip to content

Commit 9f2c0a3

Browse files
committed
packaging/WiX: Add check for required WiX extensions
1 parent 087b4b1 commit 9f2c0a3

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

packaging/WiX/wix_setup.cmake

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,3 +45,22 @@ ELSE ()
4545
ENDIF ($ENV{WIX_DIR})
4646
ENDIF ()
4747

48+
49+
# Check WIX extensions, our MSI build requires UI and Util from WixToolset.
50+
51+
message(STATUS "==Installed WiX extensions")
52+
execute_process(
53+
COMMAND ${WIX_EXECUTABLE} extension list
54+
OUTPUT_VARIABLE wix_extension
55+
)
56+
message(STATUS "==========================")
57+
58+
if(
59+
NOT wix_extensions MATCHES "WixToolset.UI.wixext"
60+
OR NOT wix_extensions MATCHES "WixToolset.Util.wixext"
61+
)
62+
message(SEND_ERROR
63+
"Required WiX extensions not detected (WixToolset.UI/Util)"
64+
)
65+
endif()
66+

0 commit comments

Comments
 (0)