Name
Cabinet (CAB) Maker —
\windows\system32\makecab.exe; diantz.exe
Synopsis
Cabinet file
(.cab
) compression
utility.
To Open
Command Prompt →
makecab
Usage
makecab [/v[n]] [/d var=value] [/l dir] source [destination]
makecab [/v[n]] [/d var=value] /f directive_file
Description
A cabinet file is a compressed archive commonly used to package
application installation files. Cabinets are similar to
.zip
files, although there are added features
such as a rudimentary script system intended to install and register
application components.
There are two ways to use the Cabinet Maker. First, you can compress one or more files directly, like this:
makecab \windows\greenstone.bmp greenstone.cab
which compresses the file, greenstone.bmp
, into
the greenstone.cab
archive. The new cabinet
file, greenstone.cab
, is created automatically
in the current directory; if it already exists, it is replaced with
the new archive. Unfortunately,
wildcards (*.*)
aren’t allowed in the source, so you can only
specify one file at a time. This is where the second usage of the
Cabinet Maker comes in: instead of specifying options and files
directly, a single plain text file, called a directive file
(.ddf
) is used. The simplest directive file
lists all the files to include. A line beginning with a semicolon is
treated as a comment.
Assuming the lines:
;Example directive file c:\windows\greenstone.bmp c:\windows\rhododendron.bmp
are saved into a file called test.ddf
, the
Makecab command would then look like this:
makecab ...
Get Windows XP in a Nutshell, Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.