| 1 | 7-Zip for installers 9.38\r |
| 2 | -------------------------\r |
| 3 | \r |
| 4 | 7-Zip is a file archiver for Windows NT/2000/2003/2008/XP/Vista/7/8/10. \r |
| 5 | \r |
| 6 | 7-Zip for installers is part of LZMA SDK.\r |
| 7 | LZMA SDK is written and placed in the public domain by Igor Pavlov.\r |
| 8 | \r |
| 9 | It's allowed to join 7-Zip SFX module with another software.\r |
| 10 | It's allowed to change resources of 7-Zip's SFX modules.\r |
| 11 | \r |
| 12 | \r |
| 13 | HOW to use\r |
| 14 | -----------\r |
| 15 | \r |
| 16 | 7zr.exe is reduced version of 7za.exe of 7-Zip.\r |
| 17 | 7zr.exe supports only format with these codecs: LZMA, LZMA2, BCJ, BCJ2, ARM, Copy.\r |
| 18 | \r |
| 19 | Example of compressing command for installation packages:\r |
| 20 | \r |
| 21 | 7zr a archive.7z files\r |
| 22 | \r |
| 23 | 7zSD.sfx is SFX module for installers. 7zSD.sfx uses msvcrt.dll.\r |
| 24 | \r |
| 25 | SFX modules for installers allow to create installation program. \r |
| 26 | Such module extracts archive to temp folder and then runs specified program and removes \r |
| 27 | temp files after program finishing. Self-extract archive for installers must be created \r |
| 28 | as joining 3 files: SFX_Module, Installer_Config, 7z_Archive. \r |
| 29 | Installer_Config is optional file. You can use the following command to create installer \r |
| 30 | self-extract archive:\r |
| 31 | \r |
| 32 | copy /b 7zSD.sfx + config.txt + archive.7z archive.exe\r |
| 33 | \r |
| 34 | The smallest installation package size can be achieved, if installation files was \r |
| 35 | uncompressed before including to 7z archive.\r |
| 36 | \r |
| 37 | -y switch for installer module (at runtime) specifies quiet mode for extracting.\r |
| 38 | \r |
| 39 | Installer Config file format\r |
| 40 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~\r |
| 41 | Config file contains commands for Installer. File begins from string \r |
| 42 | ;!@Install@!UTF-8! and ends with ;!@InstallEnd@!. File must be written \r |
| 43 | in UTF-8 encoding. File contains string pairs: \r |
| 44 | \r |
| 45 | ID_String="Value"\r |
| 46 | \r |
| 47 | ID_String Description \r |
| 48 | \r |
| 49 | Title Title for messages \r |
| 50 | BeginPrompt Begin Prompt message \r |
| 51 | Progress Value can be "yes" or "no". Default value is "yes". \r |
| 52 | RunProgram Command for executing. Default value is "setup.exe". \r |
| 53 | Substring %%T will be replaced with path to temporary \r |
| 54 | folder, where files were extracted \r |
| 55 | Directory Directory prefix for "RunProgram". Default value is ".\\" \r |
| 56 | ExecuteFile Name of file for executing \r |
| 57 | ExecuteParameters Parameters for "ExecuteFile" \r |
| 58 | \r |
| 59 | \r |
| 60 | You can omit any string pair.\r |
| 61 | \r |
| 62 | There are two ways to run program: RunProgram and ExecuteFile. \r |
| 63 | Use RunProgram, if you want to run some program from .7z archive. \r |
| 64 | Use ExecuteFile, if you want to open some document from .7z archive or \r |
| 65 | if you want to execute some command from Windows.\r |
| 66 | \r |
| 67 | If you use RunProgram and if you specify empty directory prefix: Directory="", \r |
| 68 | the system searches for the executable file in the following sequence:\r |
| 69 | \r |
| 70 | 1. The directory from which the application (installer) loaded. \r |
| 71 | 2. The temporary folder, where files were extracted. \r |
| 72 | 3. The Windows system directory. \r |
| 73 | \r |
| 74 | \r |
| 75 | Config file Examples\r |
| 76 | ~~~~~~~~~~~~~~~~~~~~\r |
| 77 | \r |
| 78 | ;!@Install@!UTF-8!\r |
| 79 | Title="7-Zip 4.00"\r |
| 80 | BeginPrompt="Do you want to install the 7-Zip 4.00?"\r |
| 81 | RunProgram="setup.exe"\r |
| 82 | ;!@InstallEnd@!\r |
| 83 | \r |
| 84 | \r |
| 85 | \r |
| 86 | ;!@Install@!UTF-8!\r |
| 87 | Title="7-Zip 4.00"\r |
| 88 | BeginPrompt="Do you want to install the 7-Zip 4.00?"\r |
| 89 | ExecuteFile="7zip.msi"\r |
| 90 | ;!@InstallEnd@!\r |
| 91 | \r |
| 92 | \r |
| 93 | \r |
| 94 | ;!@Install@!UTF-8!\r |
| 95 | Title="7-Zip 4.01 Update"\r |
| 96 | BeginPrompt="Do you want to install the 7-Zip 4.01 Update?"\r |
| 97 | ExecuteFile="msiexec.exe"\r |
| 98 | ExecuteParameters="/i 7zip.msi REINSTALL=ALL REINSTALLMODE=vomus"\r |
| 99 | ;!@InstallEnd@!\r |
| 100 | \r |
| 101 | \r |
| 102 | \r |
| 103 | Small SFX modules for installers\r |
| 104 | --------------------------------\r |
| 105 | \r |
| 106 | 7zS2.sfx - small SFX module (GUI version)\r |
| 107 | 7zS2con.sfx - small SFX module (Console version)\r |
| 108 | \r |
| 109 | Small SFX modules support this codecs: LZMA, LZMA2, BCJ, BCJ2, ARM, COPY\r |
| 110 | \r |
| 111 | Small SFX module is similar to common SFX module for installers.\r |
| 112 | The difference (what's new in small version):\r |
| 113 | - Smaller size (30 KB vs 100 KB)\r |
| 114 |