[wix-users] [Ext] Visual Studio Build Issue for Heat Command

Derek Wetherall derek.wetherall at gmail.com
Tue Nov 26 05:38:09 PST 2019


The fragment is added to the project when you first set up the project
(doesn't matter what it is initially) and is then  regenerated by the heat
command in the pre-build step. It is then used by the wix project.


On Tue, 26 Nov 2019 at 12:07, Ven H via wix-users <
wix-users at lists.wixtoolset.org> wrote:

> In your reply, you have mentioned "The resulting  fragment is included in
> my project" - Is this a manual step? Also, if pre-build event does this,
> this means build will continue. At that point, the Heat output should
> already be part of the Visual Studio. Is that the case with you?
>
> On Tue, Nov 26, 2019 at 2:26 PM Derek Wetherall via wix-users <
> wix-users at lists.wixtoolset.org> wrote:
>
> > I run the heat from a Pre-Build event in the visual studio solution
> > creating a fragment with the -sfrag command. The resulting  fragment is
> > included in my project. And referred to by a ComnponentGroupRef  in the
> > product.wxs.
> > e.g.
> > "heat.exe" dir "$(ProjectDir)..\mydir" -cg BinDir -gg -g1 -scom -sreg
> > -sfrag  -dr foo   -var "var.fooDir" -out
> > "$(ProjectDir)Fragments\fooFragment.wxs"
> >
> > And
> >
> > <Feature Id="MyFeature" Title="$(var.ProductName) " Level="300">
> >       <ComponentGroupRef Id="fooDir" />
> >     </Feature>
> >
> >
> >
> > Schlumberger-Private
> >
> > -----Original Message-----
> > From: wix-users <wix-users-bounces at lists.wixtoolset.org> On Behalf Of
> Ven
> > H via wix-users
> > Sent: 26 November 2019 06:35
> > To: WiX Toolset Users Mailing List <wix-users at lists.wixtoolset.org>
> > Cc: Ven H <venh.123 at gmail.com>
> > Subject: [Ext] [wix-users] Visual Studio Build Issue for Heat Command
> >
> > Hi,
> >
> > I have a WiX Setup Project in Visual Studio 2017. I have a requirement to
> > run Heat command on a folder and include the generated wxs file into the
> > project before starting to build (i.e., before running the Candle & Light
> > commands). But, I am not sure how to achieve this. I tried different
> things
> > and also searched on the internet. I am forced to run the build process
> > twice. I have tweaked the .wixproj file to include the HeatDirectory task
> > to run the heat command. But it makes me run the build twice. First, it
> > runs the Heat command and generates the wxs. Then I have to manually
> > include this wxs into the project and run the build again to generate the
> > MSI correctly. Is there a better way to do this? Please advise. Also, I
> > need to have a build task after build (not Post Build Event) to upload
> this
> > MSI to a remote server.
> >
> > ____________________________________________________________________
> > WiX Toolset Users Mailing List provided by FireGiant
> >
> https://urldefense.com/v3/__http://www.firegiant.com/__;!kI-RaYHuUlXHMWI!0oP1d-WjwdLCL6j5SilD2H36cisLNXMHaW3ah3Xdh1_tgw-Mu6aurkb1mdGGfA$
> >
> > ____________________________________________________________________
> > WiX Toolset Users Mailing List provided by FireGiant
> > http://www.firegiant.com/
> >
>
> ____________________________________________________________________
> WiX Toolset Users Mailing List provided by FireGiant
> http://www.firegiant.com/
>



More information about the wix-users mailing list