[Previous] [Contents] [Index] [Next]

flashcmp

Compress files for a flash filesystem


Note: This utility is now deprecated. Use inflator and deflate instead.

Syntax:

flashcmp [options] [srcfile ...]

Options:

-a
Append a suffix to the compressed file. By default, flashcmp replaces the source file with a compressed file of the same name so if anything goes wrong with the compression, you might lose your source file. If you specify the -a option, flashcmp creates a new compressed file named after the source file, with a suffix of .lzo, .ucl, or .zip, according to the compression algorithm used.

With other compression utilities, it's logical to append a suffix to the file by default; but in the case of the flash filesystem we normally don't want a suffix appended because the filesystem decompresses automatically (the user shouldn't even know that the file is compressed). The flashcmp utility inserts a signature in the file that lets mkefs distinguish a compressed file from a regular file.

-b size[K|M]
Maximum buffer size before compression. The suffixes K and M aren't case-sensitive. The default is 4096 bytes.

The compression engine operates on a buffer of the given size and the flash filesystem must allocate a buffer of equal size to decompress. Large buffers can improve compression ratios, but in a RAM-constrained system, a large buffer size may not be desirable.

-d
Decompress srcfile. By default, flashcmp compresses srcfile.
-ln
This option is used only with ZIP compression. The n variable represents the compression level (0-9) to be used. The default is 5.
-t type
Type of compression algorithm to use; type can be one of:
lzo
For LZO compression (fast compression, very fast decompression, typical 30% reduction of executables).
ucl
For UCL compression (slow compression, fast decompression, typical 45% reduction of executables).
zip
For ZIP compression (not supported after QNX Neutrino 6.0.1).

The default compression type is lzo.

-v
Operate verbosely.

Description:


Note: QNX Neutrino flash filesystem version 3 no longer provides built-in decompression. The flash filesystem's decompression functionality has moved into the inflator resource manager. You should now use the deflate utility to compress files. The flashcmp utility is now used for backward compatibility.

The flashcmp utility compresses files for a flash filesystem. It's intended to be used in conjunction with the filter attribute for mkefs. It can also be used to precompress files intended for a flash filesystem. For example:

cat file | flashcmp > file.lzo

Or:

flashcmp file

Author:

The LZO and UCL algorithms used in this utility are copyright 2000, Markus F.X.J. Oberhumer.

See also:

deflate, inflator, mkefs


[Previous] [Contents] [Index] [Next]