src/jdk.jpackage/windows/classes/jdk/jpackage/internal/resources/template.wxs
author herrick
Mon, 18 Mar 2019 09:09:36 -0400
branchJDK-8200758-branch
changeset 57269 d28d38406872
parent 57256 d7c27451f759
permissions -rw-r--r--
8220264: msi installer does not remove some files if app installed into non-default location Submitten-by: almatvee Reviewed-by: herrick
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
57254
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
     1
<?xml version="1.0" encoding="utf-8"?>
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
     2
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
     3
     xmlns:util="http://schemas.microsoft.com/wix/UtilExtension">
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
     4
    <Product Id="PRODUCT_GUID" Name="APPLICATION_NAME"
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
     5
             Language="1033" Version="APPLICATION_VERSION"
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
     6
             Manufacturer="APPLICATION_VENDOR"
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
     7
             UpgradeCode="PRODUCT_UPGRADE_GUID">
57255
f686bda3b831 8215574: Investigate and document usage of --category, --copyright, --vendor and --description
herrick
parents: 57254
diff changeset
     8
        <Package Description="APPLICATION_DESCRIPTION"
f686bda3b831 8215574: Investigate and document usage of --category, --copyright, --vendor and --description
herrick
parents: 57254
diff changeset
     9
                 Manufacturer="APPLICATION_VENDOR"
57254
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    10
                 InstallerVersion="200" Compressed="yes"
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    11
                 InstallScope="INSTALL_SCOPE" Platform="PLATFORM"/>
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    12
        <Media Id="1" Cabinet="simple.cab" EmbedCab="yes" />
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    13
        UPGRADE_BLOCK
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    14
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    15
        <!-- We use RemoveFolderEx to ensure application folder is fully
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    16
             removed on uninstall. Including files created outside of MSI
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    17
             after application had been installed (e.g. on AU or user state).
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    18
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    19
             Hovewer, RemoveFolderEx is only available in WiX 3.6,
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    20
             we will comment it out if we running older WiX.
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    21
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    22
             RemoveFolderEx requires that we "remember" the path for uninstall.
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    23
             Read the path value and set the APPLICATIONFOLDER property with the value.
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    24
        -->
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    25
        <Property Id="APPLICATIONFOLDER">
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    26
            <RegistrySearch Key="SOFTWARE\APPLICATION_VENDOR\APPLICATION_NAME"
57269
d28d38406872 8220264: msi installer does not remove some files if app installed into non-default location
herrick
parents: 57256
diff changeset
    27
                            Root="REGISTRY_ROOT" Type="raw" Win64="WIN64"
57254
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    28
                            Id="APPLICATIONFOLDER_REGSEARCH" Name="Path" />
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    29
        </Property>
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    30
        <DirectoryRef Id="APPLICATIONFOLDER">
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    31
            <Component Id="CleanupMainApplicationFolder" Guid="*" Win64="WIN64">
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    32
                <RegistryValue Root="REGISTRY_ROOT"
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    33
                               Key="SOFTWARE\APPLICATION_VENDOR\APPLICATION_NAME"
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    34
                               Name="Path" Type="string" Value="[APPLICATIONFOLDER]"
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    35
                               KeyPath="yes" />
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    36
                <!-- We need to use APPLICATIONFOLDER variable here or RemoveFolderEx
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    37
                     will not remove on "install". But only if WiX 3.6 is used. -->
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    38
                WIX36_ONLY_START
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    39
                  <util:RemoveFolderEx On="uninstall" Property="APPLICATIONFOLDER" />
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    40
                WIX36_ONLY_END
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    41
            </Component>
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    42
        </DirectoryRef>
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    43
        <?include bundle.wxi ?>
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    44
        CA_BLOCK
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    45
        <UI>
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    46
            INVALID_INSTALL_DIR_DLG_BLOCK
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    47
            UI_BLOCK
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    48
        </UI>
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    49
        <Icon Id="DesktopIcon.exe" SourceFile="APPLICATION_ICON" />
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    50
        <Icon Id="StartMenuIcon.exe" SourceFile="APPLICATION_ICON" />
57256
d7c27451f759 8219678: CLI changes in jpackage
herrick
parents: 57255
diff changeset
    51
        ADD_LAUNCHER_ICONS
57254
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    52
    </Product>
c1b92a014e89 8214566: --win-dir-chooser does not prompt if destination folder is not empty
herrick
parents: 57181
diff changeset
    53
</Wix>