One more question, is it possible to add a file filter when harvesting a directory? For example, what if I only want to harvest files with ".xtc" extension? Thanks.
> From: dan.mad...@quanser.com > To: wix-users@lists.sourceforge.net > Date: Mon, 21 Nov 2011 09:55:14 -0500 > Subject: Re: [WiX-users] add reference to C++ project > > Hello Huifei Rao, > > If you search for heat.exe in the WiX documentation (Start menu/All > Programs/Windows Installer XML Toolset 3.5/WiX Documentation) it gives some > examples of using heat for various purposes, such as harvesting a directory: > > Harvest a directory: > > heat dir ".\My Files" -gg -sfrag -template:fragment -out directory.wxs > > This will harvest the sub folder "My Files" as a single fragment to the > file directory.wxs. It will generate guids for all the files as they are > found. > > I've noticed that some others in this newsgroup have taken the route of > copying the files they want to harvest to another directory in the structure > they want (in a Post Build step in Visual Studio for example) and then > harvesting that directory using a command such as the one above in order to > generate a WxS file they can include in their installer project. I don't know > if such an approach would be suitable for your particular situation, but you > may wish to consider it. > > BTW, I'm a novice at WiX (although I have used it successfully for several > installers that target both 32-bit and 64-bit platforms from the same WxS > source files) so there may be better ways to do things. Also, when it comes > to upgrading to VS2010 at some point, I have discovered that when I included > too many WxS files in one project that VS2010 would croak while building the > solution. It appeared to be a bug in VS2010 rather than WiX, but, anyways, I > tend to use WiX include files that I then include in a single WxS file to get > around the problems with VS2010 (within a single project, but I have multiple > merge module projects for sharing installer components with third parties). > > Daniel Madill > > -----Original Message----- > From: rhf417 [mailto:rhf...@hotmail.com] > Sent: November-18-11 10:20 PM > To: General discussion for Windows Installer XML toolset. > Subject: Re: [WiX-users] add reference to C++ project > > To Daniel Madill: I did not actually name my project with '+' sign inside. > > Unfortunately, there is no chance for me to upgrade to VS2010 in the near > future. Is there any example on how to use heat to harvest the output > directory for the C++ project? Thanks. > > Huifei Rao > > -------------------------------------------------- > From: "Daniel Madill" <dan.mad...@quanser.com> > Sent: Friday, November 18, 2011 5:01 PM > To: "General discussion for Windows Installer XML toolset." > <wix-users@lists.sourceforge.net> > Subject: Re: [WiX-users] add reference to C++ project > > > I hadn't noticed the "VS2008" when I posted last. References to C++ > > projects work fine for me in VS2010 with WiX 3.5. I haven't tried VS2008. > > My mistake. Sorry about that. > > > > Daniel Madill > > > > -----Original Message----- > > From: Castro, Edwin G. (Hillsboro) [mailto:edwin.cas...@fiserv.com] > > Sent: November-18-11 4:40 PM > > To: General discussion for Windows Installer XML toolset. > > Subject: Re: [WiX-users] add reference to C++ project > > > > You still cannot add VS2008 C++ projects as references to WiX projects. > > > > You'll need to either author the WXS manually or use heat to harvest the > > output directory for the C++ project. You can automate heat execution by > > customizing the WiX project file (it is all MSBuild anyway). It may be > > easier to author the WXS manually if you don't have much MSBuild > > experience or cannot find another way to automate heat. Of course, you > > could use heat to generate a WXS to add to your WiX project... > > > > Edwin G. Castro > > Software Developer - Staff > > Digital Channels > > Fiserv > > Office: 503-746-0643 > > Fax: 503-617-0291 > > www.fiserv.com > > Please consider the environment before printing this e-mail > > > >> -----Original Message----- > >> From: RaoHuiFei [mailto:rhf...@hotmail.com] > >> Sent: Friday, November 18, 2011 1:33 PM > >> To: wix-users@lists.sourceforge.net > >> Subject: [WiX-users] add reference to C++ project > >> > >> > >> I have a VS2008 solution which contains a couple of C++ projects and C# > >> projects. Within this solution, a WiX3.5 setup project is created to > >> generate a > >> MSI installation package. All the outputs of my C++ projects and C# > >> projects > >> need to be added into the installation package. I follow the instruction > >> of > >> (http://wix.sourceforge.net/manual-wix3/votive_project_references.htm). > >> It > >> works fine with C# projects. However, it does not work with C++ project: > >> - After I add reference to a C++ project, its "Full Path" property will > >> show > >> "Object reference not set to an instance of an object" > >> - If I add a component as shown below, I will get "error CNDL0150: > >> Undefined > >> preprocessor variable '$(var.myC++Project.TargetFileName)'" > >> <Component Id="myC++Project" Guid="CF8AEB23-7573-4A68-AA48- > >> E1BD7FF7A0F1"> > >> <File Id="myC++Project" Name="$(var.myC++Project.TargetFileName)" > >> Source="$(var.myC++Project.TargetPath)" DiskId="1" /> > >> </Component> > >> > >> > >> I googled this issue and found some 2-years-ago posts saying that > >> referencing > >> C++ project with WiX was not supported at that time and will probably be > >> supported in the future. However, it look like it is still not supported > >> now. How > >> could I add references to C++ projects with WiX? Thanks. > >> > >> > >> > >> > >> ------------------------------------------------------------------------------ > >> All the data continuously generated in your IT infrastructure contains a > >> definitive record of customers, application performance, security > >> threats, > >> fraudulent activity, and more. Splunk takes this data and makes sense of > >> it. IT > >> sense. And common sense. > >> http://p.sf.net/sfu/splunk-novd2d > >> _______________________________________________ > >> WiX-users mailing list > >> WiX-users@lists.sourceforge.net > >> https://lists.sourceforge.net/lists/listinfo/wix-users > > ------------------------------------------------------------------------------ > > All the data continuously generated in your IT infrastructure > > contains a definitive record of customers, application performance, > > security threats, fraudulent activity, and more. Splunk takes this > > data and makes sense of it. IT sense. And common sense. > > http://p.sf.net/sfu/splunk-novd2d > > _______________________________________________ > > WiX-users mailing list > > WiX-users@lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/wix-users > > ------------------------------------------------------------------------------ > > All the data continuously generated in your IT infrastructure > > contains a definitive record of customers, application performance, > > security threats, fraudulent activity, and more. Splunk takes this > > data and makes sense of it. IT sense. And common sense. > > http://p.sf.net/sfu/splunk-novd2d > > _______________________________________________ > > WiX-users mailing list > > WiX-users@lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/wix-users > > > > ------------------------------------------------------------------------------ > All the data continuously generated in your IT infrastructure > contains a definitive record of customers, application performance, > security threats, fraudulent activity, and more. Splunk takes this > data and makes sense of it. IT sense. And common sense. > http://p.sf.net/sfu/splunk-novd2d > _______________________________________________ > WiX-users mailing list > WiX-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wix-users > ------------------------------------------------------------------------------ > All the data continuously generated in your IT infrastructure > contains a definitive record of customers, application performance, > security threats, fraudulent activity, and more. Splunk takes this > data and makes sense of it. IT sense. And common sense. > http://p.sf.net/sfu/splunk-novd2d > _______________________________________________ > WiX-users mailing list > WiX-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wix-users ------------------------------------------------------------------------------ All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-novd2d _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users