[wix-users] Avoid removing files (of a shared msm) by uninstalling msi

Mike Henseler m.henseler at simfront.com
Thu Dec 2 06:23:50 PST 2021


Thnks, in all the literature I read, I never saw "heatwave"  before.
Including the Wix.chm


-----Original Message-----
From: Rob Mensching <rob at firegiant.com> 
Sent: December 2, 2021 9:14 AM
To: WiX Toolset Users Mailing List <wix-users at lists.wixtoolset.org>; ziegolf at gmail.com
Cc: Mike Henseler <m.henseler at simfront.com>
Subject: RE: [wix-users] Avoid removing files (of a shared msm) by uninstalling msi

And, finally, if you want a _much_ simpler solution for harvesting (in exchange for $) you might check out: https://www.firegiant.com/wix/wep-documentation/harvesting/


Free trial available: https://www.firegiant.com/products/wix-expansion-pack/

-----Original Message-----
From: wix-users <wix-users-bounces at lists.wixtoolset.org> On Behalf Of Mike Henseler via wix-users
Sent: Thursday, December 2, 2021 5:46 AM
To: ziegolf at gmail.com; WiX Toolset Users Mailing List <wix-users at lists.wixtoolset.org>
Cc: Mike Henseler <m.henseler at simfront.com>
Subject: Re: [wix-users] Avoid removing files (of a shared msm) by uninstalling msi

Thnks,
Using heat with transforms (Heat.exe -t) is a feature of WiX and the suggested method to custom modify heat generated .wxs files.
I usually generate independent heat.wxs files then link them

From: ziegolf at gmail.com <ziegolf at gmail.com>
Sent: December 2, 2021 6:31 AM
To: WiX Toolset Users Mailing List <wix-users at lists.wixtoolset.org>
Cc: Mike Henseler <m.henseler at simfront.com>
Subject: Re: [wix-users] Avoid removing files (of a shared msm) by uninstalling msi

Thanks for the hints to solve my problem.
@Rob
this is it!
It works like a charm while using the same (!) build of my msm in all my msi's

@Mike
your idea seems to be a good way for me to create some special hacks ...
Additional information
I'm not working with an extra wxs file for harvesting my files.
I use this way and modified it for my use case https://github.com/DavidEGrayson/wix-example-harvest-directory

Have a nice day
OZ


Am Mi., 1. Dez. 2021 um 18:35 Uhr schrieb Mike Henseler via wix-users <wix-users at lists.wixtoolset.org<mailto:wix-users at lists.wixtoolset.org>>:

try applying this transform (.xsl) against the .wxs that you want to create by heat(harvest).
Works for me but you may need to refine it for your needs.

Note: this is not to be confused with a msi/mst transform

<xsl:stylesheet version="1.0"
            xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
            xmlns:msxsl="urn:schemas-microsoft-com:xslt"
            xmlns:wix="http://schemas.microsoft.com/wix/2006/wi" >

    <xsl:output method="xml" indent="yes" />


    <xsl:template match="@*|node()">
        <xsl:copy>
            <xsl:apply-templates select="@*|node()"/>
        </xsl:copy>
    </xsl:template>

    <xsl:template match="wix:Component">
    <xsl:copy>
      <xsl:attribute name="SharedDllRefCount">yes</xsl:attribute>
      <xsl:apply-templates select="@*|node()"/>
    </xsl:copy>
  </xsl:template>

</xsl:stylesheet>


-----Original Message-----
From: wix-users <wix-users-bounces at lists.wixtoolset.org<mailto:wix-users-bounces at lists.wixtoolset.org>> On Behalf Of Mike Henseler via wix-users
Sent: December 1, 2021 10:16 AM
To: WiX Toolset Users Mailing List <wix-users at lists.wixtoolset.org<mailto:wix-users at lists.wixtoolset.org>>
Cc: Mike Henseler <m.henseler at simfront.com<mailto:m.henseler at simfront.com>>
Subject: Re: [wix-users] Avoid removing files (of a shared msm) by uninstalling msi

https://stackoverflow.com/questions/8034798/wix-installer-using-xslt-with-heat-exe-to-update-attributes


-----Original Message-----
From: wix-users <wix-users-bounces at lists.wixtoolset.org<mailto:wix-users-bounces at lists.wixtoolset.org>> On Behalf Of Mike Henseler via wix-users
Sent: December 1, 2021 10:02 AM
To: WiX Toolset Users Mailing List <wix-users at lists.wixtoolset.org<mailto:wix-users at lists.wixtoolset.org>>
Cc: Mike Henseler <m.henseler at simfront.com<mailto:m.henseler at simfront.com>>
Subject: Re: [wix-users] Avoid removing files (of a shared msm) by uninstalling msi

You will probably have to create an xml transform, to update the xml created by the heat tool.
I don't have time right now to explain or try your scenario, but wanted to make the suggestion.

-----Original Message-----
From: wix-users <wix-users-bounces at lists.wixtoolset.org<mailto:wix-users-bounces at lists.wixtoolset.org>> On Behalf Of Rob Mensching via wix-users
Sent: December 1, 2021 9:38 AM
To: WiX Toolset Users Mailing List <wix-users at lists.wixtoolset.org<mailto:wix-users at lists.wixtoolset.org>>
Cc: Rob Mensching <rob at firegiant.com<mailto:rob at firegiant.com>>
Subject: Re: [wix-users] Avoid removing files (of a shared msm) by uninstalling msi

Make sure your Component/@Guid is stable. The Windows Installer reference counts Components by their Guid: https://robmensching.com/blog/posts/2003/10/18/component-rules-101/


-----Original Message-----
From: wix-users <wix-users-bounces at lists.wixtoolset.org<mailto:wix-users-bounces at lists.wixtoolset.org>> On Behalf Of ;-) via wix-users
Sent: Wednesday, December 1, 2021 3:52 AM
To: wix-users at lists.wixtoolset.org<mailto:wix-users at lists.wixtoolset.org>
Cc: ziegolf at gmail.com<mailto:ziegolf at gmail.com>
Subject: [wix-users] Avoid removing files (of a shared msm) by uninstalling msi

Hello Wix-users,

I will try my first post in this mailing list.

I am working with Wix3.11, Visual Studio 2019 and the Wixproj-Templates of VS2019.
I created a merge module with harvesting (!) its files.
I created a msi to install the merge module. Everything works fine.

I want to use the merge module with different msi's.
Now: the files of the merge module will be uninstalled when uninstalling the first msi (containing this msm)

My question:
In other case I work with Component at SharedDllRefCount="yes".
It is working fine with single files.
But here I am harvesting the source files.
Is it possible to set the value SharedDllRefCount="yes"
during harvesting to each component?
If yes (=possible),
how is the notation of coding it in Wixproj-Templates? (snippet)

What would be a practice to avoid uninstall the files in my use case?
until I uninstall the last msi (containing this msm).
I is not possible to put the files
of the msm into an own msi (because of the development history...)


Any idea?
Thanks in advance
Have a nice day

OZ

BTW - how does the search in the list's archive work?
I get diplayed the number of hits of a keyword in my browser, but no links are shown. How to get the results?

Avoid removing files (of a shared msm) by uninstalling msi

____________________________________________________________________
WiX Toolset Users Mailing List provided by FireGiant http://www.firegiant.com/

____________________________________________________________________
WiX Toolset Users Mailing List provided by FireGiant http://www.firegiant.com/


***** This email was sent outside of your organization *****

____________________________________________________________________
WiX Toolset Users Mailing List provided by FireGiant http://www.firegiant.com/


***** This email was sent outside of your organization *****

____________________________________________________________________
WiX Toolset Users Mailing List provided by FireGiant http://www.firegiant.com/


***** This email was sent outside of your organization *****

____________________________________________________________________
WiX Toolset Users Mailing List provided by FireGiant http://www.firegiant.com/

***** This email was sent outside of your organization *****

____________________________________________________________________
WiX Toolset Users Mailing List provided by FireGiant http://www.firegiant.com/


***** This email was sent outside of your organization *****



More information about the wix-users mailing list