When you finish developing your driver or application, you can use the CAB Wizard to create cabinet (.cab) files to facilitate installation of your driver or application on devices. This file acts as a container, holding all necessary device driver or application files in one location, which ensures that these files are present at installation.
You create a .cab file by first using a text editor to create an .inf file and then using the CAB Wizard command-line tool (Cabwiz.exe) at the command prompt. For Windows Embedded CE, the CAB Wizard is typically found in <Platform Builder installation path>\CEPB\Bin.
This results in the creation of an unsigned .cab file. For more information, see Information File.
|For Windows Mobile, you can run the CAB Wizard on a development workstation that uses an Unicode file structure, and the .inf files used to create the .cab file can contain Unicode characters and refer to other files that contain Unicode characters. However, some strings and values in the .inf file can only use Unicode characters that can be converted to ANSI characters without data loss to enable backward compatibility. This includes registry keys and values, and destination filenames that are used in the .inf file. CAB files and the Registry Configuration Service Provider fail if a registry value is set outside the range of signed integers.|
For Windows Mobile, for information about signing a .cab file, see .cab File Signing Requirements.
For Windows Mobile, for information about the mechanisms that you can use to install an application using a .cab file, see Delivering Applications.
The following example shows the command-line syntax for the CAB Wizard:
"inf_file" [dest_dir] [err_file] [cpu_type [hardware_platform_label]] [platform_label [platform_label]]
Full path and filename to the CAB Wizard setup .inf file.
Note: This file must be UTF-8 encoded if it contains extended characters.
Specifies that there is an user-selected destination directory for the .cab files, using the directory called out in dest_dir.
Destination directory for the .cab files.
The default destination is the inf_file directory where the CAB Wizard setup .inf file is located.
Creates a log file using the file name that err_file specifies.
File name for a log file containing all warnings and errors that are encountered when the .cab files are compiled.
Creates a .cab file for each processor type that you specify.
An arbitrary label that you use to differentiate between different processor types in the setup .inf file. For more information, see CEDevice.
Creates a .cab file for each hardware platform label that you specify.
A hardware platform label is an arbitrary label that is used in the Win32 setup .inf file to differentiate between different hardware platform types. For more information, see CEDevice.
Creates a .cab file for each platform label that you specify in the associated .inf file. Use this parameter only if the associated .inf file contains a [CEDevice] section. Otherwise, creation of the .cab file does not succeed. For more information, see Platform and CEDevice.
The label that specifies the platform type.
A platform label is an arbitrary label that is used in the setup .inf file to differentiate between different platform types. For more information, see Platform.
Specifies that the application does not appear in the Remove Programs dialog on the target device. When used, the associated application cannot be uninstalled.
Specifies that the .cab file created is compressed.
For Windows Mobile:
Note: Do not use this parameter if you want to install the .cab file on devices using platforms earlier than Pocket PC for Windows Mobile Version 5.0.
Since the CAB Wizard can use a single .inf file and multiple application binaries to create multiple .cab files, you can use the cpu_type and hardware_platform_label parameters to help create a separate .cab file for each specific processor or platform type that you specify. For more information, see Information File.
The following code example creates a .cab file for an ARM-family processor, assuming that the setup .inf file contains the associated hardware platform label MyARMDevice:
cabwiz.exe "c:\myfile.inf" /err myfile.err /cpu MyARMDevice
The following code example creates two .cab files for the ARM-family processor and the processor associated with your Emulator, assuming that the setup .inf file contains the MyARMDevice and MyEMUL hardware platform labels:
cabwiz.exe MyFile.inf /cpu MyARMDevice MyEMUL