Skip Navigation Links
Skip Navigation LinksHome > ZipArchive > How to Use > API Documentation
The ZipArchive Library
_features.h File Reference
#include "_platform.h"

Macros

#define _ZIP_AES   1
#define _ZIP_BZIP2   1
#define _ZIP_BZIP2_INTERNAL   1
#define _ZIP_FILE_IMPLEMENTATION   ZIP_ZFI_DEFAULT
#define _ZIP_SEEK   1
#define _ZIP_STRICT_U16   1
#define _ZIP_UNICODE   1
#define _ZIP_UNICODE_CUSTOM   0
#define _ZIP_UNICODE_NORMALIZE   0
#define _ZIP_USE_HWAES   1
#define _ZIP_USE_HWCRC   1
#define _ZIP_USE_LOCKING   0
#define _ZIP_ZIP64   1
#define _ZIP_ZSTD   1
#define _ZIP_ZSTD_INTERNAL   1
#define ZIP_ZFI_DEFAULT   0
#define ZIP_ZFI_STL   1
#define ZIP_ZFI_WIN   2
#define ZSTD_MULTITHREAD
#define ZSTD_STATIC_LINKING_ONLY

Detailed Description

Contains the definitions that enable or disable certain features in the ZipArchive Library.

Macro Definition Documentation

◆ _ZIP_AES

#define _ZIP_AES   1

Define it as 1, if you use AES. Define it as 0 otherwise.

See also
Encryption Methods: How to Best Protect Your Data

◆ _ZIP_BZIP2

#define _ZIP_BZIP2   1

Define it as 1, if you use the BZIP2 algorithm for compression. Define it as 0 otherwise.

See also
Compressing Data

◆ _ZIP_BZIP2_INTERNAL

#define _ZIP_BZIP2_INTERNAL   1

Define it, if you want to use the bzip2 sources that come with the ZipArchive Library. When building with CMake, this is controlled by the ZIP_USE_BZIP2_INTERNAL option (ON=internal sources, OFF=system library).

See also
Compressing Data

◆ _ZIP_FILE_IMPLEMENTATION

#define _ZIP_FILE_IMPLEMENTATION   ZIP_ZFI_DEFAULT

Active implementation of CZipFile class.

See also
Compilation of the ZipArchive Library and Integration with Applications

◆ _ZIP_SEEK

#define _ZIP_SEEK   1

Define it as 1, if you want to create seekable data. Define it as 0 otherwise.

See also
Creating Seekable Compressed Data

◆ _ZIP_STRICT_U16

#define _ZIP_STRICT_U16   1

Define it as 0 to have the index and volume numbers types defined as WORD. Define it as 1 to define them as int. Makes sense only if _ZIP_ZIP64 is 0.

◆ _ZIP_UNICODE

#define _ZIP_UNICODE   1

Define it as 1, if you want to use Unicode support for filenames and comments (WinZip compatible). This functionality is available in the Full Version only. Under Windows, this functionality requires Unicode compilation. Define it as 0 otherwise.

See also
Unicode Support: Using Non-English Characters in Filenames, Comments and Passwords

◆ _ZIP_UNICODE_CUSTOM

#define _ZIP_UNICODE_CUSTOM   0

Define it as 1, if you want to use custom Unicode support for filenames and comments provided by the ZipArchive Library. This functionality is available only under Windows and is deprecated. Requires Unicode compilation. Define it as 0 otherwise.

See also
Unicode Support: Using Non-English Characters in Filenames, Comments and Passwords

◆ _ZIP_UNICODE_NORMALIZE

#define _ZIP_UNICODE_NORMALIZE   0

Define it as 1, if you use Unicode and under Windows you decompress archives from systems that use different Unicode Normalization form for filenames (like macOS). This functionality is available only under Windows and requires Unicode compilation. Define it as 0 otherwise.

See also
Unicode Support: Using Non-English Characters in Filenames, Comments and Passwords

◆ _ZIP_USE_HWAES

#define _ZIP_USE_HWAES   1

Define it as 1 to enable hardware AES acceleration (Intel AES-NI or ARM Crypto Extensions). Hardware acceleration is automatically detected at runtime and used when available. Define it as 0 to use software-only AES implementation.

See also
Encryption Methods: How to Best Protect Your Data

◆ _ZIP_USE_HWCRC

#define _ZIP_USE_HWCRC   1

Define it as 1 to enable hardware CRC-32 acceleration (Intel PCLMULQDQ or ARM CRC32 instructions). Hardware acceleration is automatically detected at runtime and used when available. Define it as 0 to use software-only CRC-32 implementation.

◆ _ZIP_USE_LOCKING

#define _ZIP_USE_LOCKING   0

Define it as 1, if you use the AES encryption in a multithreaded environment or archive sharing (CZipArchive::OpenFrom). Define it as 0 otherwise.

See also
Encryption Methods: How to Best Protect Your Data
Extracting Data and Testing Archives

◆ _ZIP_ZIP64

#define _ZIP_ZIP64   1

Define it as 1, if you use ZIP64. Define it as 0 otherwise.

See also
Zip64 Format: Crossing the Limits of File Sizes and Number of Files and Segments

◆ _ZIP_ZSTD

#define _ZIP_ZSTD   1

Define it as 1, if you want to use zstd compression algorithm. Define it as 0 otherwise.

◆ _ZIP_ZSTD_INTERNAL

#define _ZIP_ZSTD_INTERNAL   1

Define it, if you want to use the zstd sources that come with the ZipArchive Library. When building with CMake, this is controlled by the ZIP_USE_ZSTD_INTERNAL option (ON=internal sources, OFF=system library). If not using CMake, change the definition below to 0 to use internal zstd sources.

See also
Compressing Data

◆ ZIP_ZFI_DEFAULT

#define ZIP_ZFI_DEFAULT   0

Default implementation of CZipFile class.

See also
Compilation of the ZipArchive Library and Integration with Applications

◆ ZIP_ZFI_STL

#define ZIP_ZFI_STL   1

STL implementation of CZipFile class.

See also
Compilation of the ZipArchive Library and Integration with Applications

◆ ZIP_ZFI_WIN

#define ZIP_ZFI_WIN   2

Windows API implementation of CZipFile class.

See also
Compilation of the ZipArchive Library and Integration with Applications

◆ ZSTD_MULTITHREAD

#define ZSTD_MULTITHREAD

Enables multithreading support for zstd compression.

◆ ZSTD_STATIC_LINKING_ONLY

#define ZSTD_STATIC_LINKING_ONLY

Enables static linking for zstd library.

Back To Top Up