MAKEMSI quickly and reliably creates MSI files in a non-programmatic way
Have your say! Join the MAKEMSI discussion list or view archive! Suggest improvements. No question too simple or too complex.
[Bottom][Contents][Prev]: Binary[Next]: Compile Options
Have your say! Join the MAKEMSI discussion list or view archive! Suggest improvements. No question too simple or too complex.
\->Source Code->Commands->Cabinet

The "Cabinet" Command

This command will be used for these main reasons:

Compiled cab files are now cached by default for better build performance.

The main cabinet (compile) related options are:

;---------------------------------------------------------------------------------
;--- GLOBAL DEFAULT options when option not specified on the "Cabinet" command ---
;---------------------------------------------------------------------------------
#define? CABINET_ALIAS_DEFAULT                 [DEFAULT]             ;;If no or empty alias provided
#define? CABINET_ALIAS_FREQUENTLY_CHANGES      [FrequentlyChanges]   ;;
#define? CABINET_CACHE                         Y                     ;;Y/N cache results
#define? CABINET_CABDDF_Compression            ON                    ;;ON/OFF - Want to compress files?
#define? CABINET_CABDDF_CompressionType        <$COMPRESS_MEDIUM>
#define? CABINET_CABDDF_CompressionLevel       7                     ;;Valid 1-7
#define? CABINET_CABDDF_CompressionMemory      21                    ;;Valid 10-21
#define? CABINET_CABDDF_ClusterSize            4096                  ;;Safe for CD-ROM, floppies (512) etc
#define? CABINET_CAB_FILE_NAME_FORMAT          MM_*                  ;;Name of generated 8.3 formatted CAB filename (without extension). MM01.cab, MM01_2.cab etc.

This command provides default cabinet options for any files nested between this command and the associated "/cabinet" command.

The command takes these parameters:

Define Some Cabinets

;--- Put graphics in their own cabinet file (potentially using their own compression settings) ---
<$Cabinet "{DEFAULT.Graphics}" Default4=".jpg|.bmp|.gif">
<$Cabinet "{DEFAULT.EXE}"      Default4=".exe">

;--- Add some files into specific cabinets ----------------------------------
<$Cabinet "FILES.1">
    <$Files "D:\tmp\1.txt"  DestDir="[INSTALLDIR]">
<$/Cabinet>
<$Cabinet "FILES.2">
    <$Files "D:\tmp\2.txt"  DestDir="[INSTALLDIR]">
<$/Cabinet>

;--- These will default, see "Default4" definitions above -------------------
<$Files "D:\tmp\SomeExe.exe"  DestDir="[INSTALLDIR]">
<$Files "D:\tmp\SomeGif.gif"  DestDir="[INSTALLDIR]">
<$Files "D:\tmp\SomeBmp.bmp"  DestDir="[INSTALLDIR]">


Microsoft awarded me an MVP (Most Valuable Professional award) in 2004, 2005, 2006, 2007, 2008 & 2009 for the Windows SDK (Windows Installer) area.Please email me any feedback, additional information or corrections.
See this page online (look for updates)

[Top][Contents][Prev]: Binary[Next]: Compile Options


MAKEMSI© is (C)opyright Dennis Bareis 2003-2008 (All rights reserved).
Saturday May 28 2022 at 3:11pm
Visit MAKEMSI's Home Page
Microsoft awarded me an MVP (Most Valuable Professional award) in 2004, 2005, 2006, 2007, 2008 & 2009 for the Windows SDK (Windows Installer) area.