Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'm try to make a compressed deploy-able application.

Currently I'm taking a set of files that I've published from my IDE (Visual Studio 2008 - WPF published application) and compressing them in a 7-Zip SFX archive.

My users have asked if they can "one click install" from the 7-Zip exe. There is a parameter list when I'm creating the archive. Is there a way to set some sort of combination of parameters to invoke the installer executable that is extracted?

Unfortunately the 7-Zip documentation doesn't seem to cover this scenario. I've seen several paid applications that do something similar to this, but I'm trying to keep the tool that I'm writing free of licensed code so that we can use it internally.

share|improve this question

2 Answers 2

up vote 17 down vote accepted

SFX modules for installers

SFX modules for installers are included in an external package (7z_extra). You can download these modules from www.7-zip.org. SFX modules for installers (7zS.sfx and 7zSD.sfx) allow you to create your own installation program. Such a module extracts the archive to the user's temp folder, and runs a specified program, and removes the temp files after the program finishes. A self-extracting archive for installers must be created as joining 3 files: SFX_Module, Installer_Config, 7z_Archive. In addition, an optional file, Installer_Config, is allowed. You can use the following command to create an installer self-extracting archive:

copy /b 7zS.sfx + config.txt + archive.7z archive.exe

An optimally small installation package size can be achieved, if the installation files are uncompressed before including them in the 7z archive.

-y switch for installer module specifies quiet mode extraction.

Source

share|improve this answer
    
yes. I have tried it. A bit uncomfortable coz everything is command line, but you will find good documentation for it. And I get the best compression available for free. –  Ganesh R. Sep 17 '09 at 17:47
4  
After reading this answer I found this: msfn.org/board/lofiversion/index.php/t39048.html It's basically the longer version of what is posted here. It also explains (briefly) on how to make the config.txt. –  Mike G Sep 17 '09 at 19:44
    
@MikeG -- That link is much more thorough. It explained how to make the decompression portion completely transparent. Very nice -- Thanks! –  namuol Jan 3 '13 at 11:07

You should also look at NSIS. With it, you can create an installer that is compressed with the same method that 7-Zip uses (LZMA), so it should be roughly the same size, and you have full control over the installation process.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.