Squash
0.7.0
|
Library version information. More...
Macros | |
#define | SQUASH_VERSION_MAJOR 0 |
#define | SQUASH_VERSION_MINOR 7 |
#define | SQUASH_VERSION_REVISION 0 |
#define | SQUASH_VERSION_API "0.7" |
#define | SQUASH_VERSION_CURRENT SQUASH_VERSION(SQUASH_VERSION_MAJOR, SQUASH_VERSION_MINOR, SQUASH_VERSION_REVISION) |
#define | SQUASH_VERSION_EXTRACT_MAJOR(version) (((version) >> 16) & 0xff) |
#define | SQUASH_VERSION_EXTRACT_MINOR(version) (((version) >> 8) & 0xff) |
#define | SQUASH_VERSION_EXTRACT_REVISION(version) ((version) & 0xff) |
#define | SQUASH_VERSION(major, minor, revision) (((major) << 16) | ((minor) << 8) | (revision)) |
Functions | |
unsigned int | squash_version (void) |
Get the library version. More... | |
const char * | squash_version_api (void) |
Get the API version. More... | |
Library version information.
#define SQUASH_VERSION | ( | major, | |
minor, | |||
revision | |||
) | (((major) << 16) | ((minor) << 8) | (revision)) |
#define SQUASH_VERSION_CURRENT SQUASH_VERSION(SQUASH_VERSION_MAJOR, SQUASH_VERSION_MINOR, SQUASH_VERSION_REVISION) |
#define SQUASH_VERSION_EXTRACT_MAJOR | ( | version | ) | (((version) >> 16) & 0xff) |
Extract the major version number from an encoded version
#define SQUASH_VERSION_EXTRACT_MINOR | ( | version | ) | (((version) >> 8) & 0xff) |
Extract the minor version number from an encoded version
#define SQUASH_VERSION_EXTRACT_REVISION | ( | version | ) | ((version) & 0xff) |
Extract the revision number from an encoded version
unsigned int squash_version | ( | void | ) |
Get the library version.
This function will return the version of the library currently in use. Note that this may be different than the version you compiled against; generally you should only use this function to make sure it is greater than or equal to SQUASH_VERSION_CURRENT, or for reporting purposes.
const char* squash_version_api | ( | void | ) |
Get the API version.
Unlike the library version, the API version will only change when backwards-incompatible changes are made (i.e., it should be "1.0" for every 1.x release). Code linked against a library version not exactly equal to what it was compiled with will almost certainly fail.