Version Checking

Version Checking — Conditionally include code based on Builder version

Functions

Types and Values

Description

This module provides various macros that may be used to build code based on the version of Builder at build time.

Functions

IDE_ENCODE_VERSION()

#define             IDE_ENCODE_VERSION(major,minor,micro)

IDE_CHECK_VERSION()

#define             IDE_CHECK_VERSION(major,minor,micro)

Compile-time version checking. Evaluates to TRUE if the version of libide is greater than the required one.

Parameters

major

required major version

 

minor

required minor version

 

micro

required micro version

 

Types and Values

IDE_BUILD_TYPE

#define IDE_BUILD_TYPE "plain"

The build type of the installed build.


IDE_BUILD_CHANNEL

#define IDE_BUILD_CHANNEL "other"

The release channel of Builder. This should be a string such as "other", "flatpak-stable", or "flatpak-nightly".


IDE_MAJOR_VERSION

#define IDE_MAJOR_VERSION (3)

libide major version component (e.g. 1 if IDE_VERSION is 1.2.3)


IDE_MINOR_VERSION

#define IDE_MINOR_VERSION (30)

libide minor version component (e.g. 2 if IDE_VERSION is 1.2.3)


IDE_MICRO_VERSION

#define IDE_MICRO_VERSION (3)

libide micro version component (e.g. 3 if IDE_VERSION is 1.2.3)


IDE_VERSION

#define IDE_VERSION (3.30.3)

libide version.


IDE_VERSION_S

#define IDE_VERSION_S "3.30.3"

libide version, encoded as a string, useful for printing and concatenation.


IDE_VERSION_HEX

#define             IDE_VERSION_HEX

libide version, encoded as an hexadecimal number, useful for integer comparisons.