Search code examples
visual-studio-2008wixarchivecabself-extracting

Add a directory to a CAB project in Visual Studio 2008


We just recently converted our help file from the CHM format to HTML. Since our installer is Wix, rather than add each new file to the installer, I set up a build of a 7-Zip SFX file that takes every document in our Webhelp folder and packages it into a self-extracting archive. Then we have a CA in Wix that extracts these to the appropriate directory.

The issue I have with this approach is that our clients who use McAfee are now getting an AV warning about Heuristic.BehavesLike.Exploit.CodeExec.FFJ being detected in the installer, which started with the first release that used this SFX archive. So now I am looking into packaging our help files inside of a CAB instead, but it looks like every time our help files are updated, we have to go into the project and add the files by hand.

Is there a way to tell Visual Studio to just add everything in a folder to a CAB file at build time?


Solution

  • I ended up following Alexey Ivanov's suggestion (first comment under the question) which also makes it so I don't have to manually clean up the extracted files at the commit phase of the uninstall.