eaarl-io  1.0.1+71abbd4
EAARL Input/Output Library (Public API)
Macros
version.h File Reference

Version information for the library. More...

Go to the source code of this file.

Macros

#define EAARLIO_VERSION_MAJOR   1
 Current major version. More...
 
#define EAARLIO_VERSION_MINOR   0
 Current minor version. More...
 
#define EAARLIO_VERSION_PATCH   1
 Current patch version. More...
 
#define EAARLIO_VERSION_PRERELEASE
 Current prerelease version. More...
 
#define EAARLIO_VERSION_GIT   "71abbd4"
 Git commit hash for the current build. More...
 
#define EAARLIO_VERSION   "1.0.1+71abbd4"
 Current version as string. More...
 

Detailed Description

Version information for the library.

The eaarlio library follows Semantic Versioning 2.0.0 for its version numbers. This means that a version number consists of three to five components. Release versions are numbered as MAJOR.MINOR.PATCH and pre-release versions are numbered as MAJOR.MINOR.PATCH-PRERELEASE. If git is found at build time and repository data is present, then the commit hash is additionally appended as "+GIT".

The full version string is available in EAARLIO_VERSION. However, each component is also separately defined to make it easier to do version checking.

Macro Definition Documentation

◆ EAARLIO_VERSION

#define EAARLIO_VERSION   "1.0.1+71abbd4"

Current version as string.

This is always defined as a string representing the full version. For releases, it will be "MAJOR.MINOR.PATCH". For pre-releases, it will be "MAJOR.MINOR.PATCH-PRERELEASE". If git was detected during compilation, then the commit hash is additionally included after a plus sign: "MAJOR.MINOR.PATCH+GIT" or "MAJOR.MINOR.PATCH-PRERELEASE+GIT".

Examples:
eaarlio_yaml.c.

◆ EAARLIO_VERSION_GIT

#define EAARLIO_VERSION_GIT   "71abbd4"

Git commit hash for the current build.

This is left undefined if git could not be found at compile time or if no .git repository directory is found in the source directory. If defined, it provides the commit hash of the repository at build time.

In Doxygen, this symbol will be shown without a value when it is not defined.

◆ EAARLIO_VERSION_MAJOR

#define EAARLIO_VERSION_MAJOR   1

Current major version.

This will always be defined as an integer. It increments when an incompatible API change is made.

◆ EAARLIO_VERSION_MINOR

#define EAARLIO_VERSION_MINOR   0

Current minor version.

This will always be defined as an integer. It increments when new functionality is added that is backwards-compatible. It resets to 0 when EAARLIO_VERSION_MAJOR is incremented.

◆ EAARLIO_VERSION_PATCH

#define EAARLIO_VERSION_PATCH   1

Current patch version.

This will always be defined as in integer. It increments when backwards-compatible bug fixes are made. It resets to 0 when EAARLIO_VERSION_MAJOR or EAARLIO_VERSION_MINOR are incremented.

◆ EAARLIO_VERSION_PRERELEASE

#define EAARLIO_VERSION_PRERELEASE

Current prerelease version.

This is left undefined for release versions. For pre-release versions, it is always defined as a string. Example values are "rc1" or "beta".

In Doxygen, this symbol will be shown without a value when it is not defined.

You can check if you are using a prerelease by using:

#ifdef EAARLIO_VERSION_PRERELEASE
// This is a prerelease version
#endif