Version macros

Version macros — Check the version at compile time

Functions

Types and Values

Includes

#include <emeus.h>

Description

Emeus allows checking the version of the API at compile time; this can be used to write code that can be used when built against a specific version of the library.

Functions

EMEUS_CHECK_VERSION()

#define             EMEUS_CHECK_VERSION(major,minor,micro)

Compile time check for a specific version of Emeus.

This macro evaluates to TRUE if the version of Emeus is greater than or equal to major .minor .micro .

Parameters

major

the major version, or 1 in 1.2.3

 

minor

the minor version, or 2 in 1.2.3

 

micro

the micro version, or 3 in 1.2.3

 

Since: 1.0

Types and Values

EMEUS_VERSION_MIN_REQUIRED

# define EMEUS_VERSION_MIN_REQUIRED     (EMEUS_VERSION_CUR_STABLE)

Defines the lower bound of the API of Emeus that can be used.

This macro can only be defined prior to including emeus.h.

The allowed values for this macro are one of the encoded Emeus version symbols, like EMEUS_VERSION_1_0.

If this pre-processor symbol is defined, Emeus will only emit compiler warnings when attempting to use functions that have been deprecated in newer versions of the library; for instance, if EMEUS_VERSION_MIN_REQUIRED is defined to be EMEUS_VERSION_1_4, you'll be able to use API that has been deprecated in version 1.0 and 1.2 without any warning; any API deprecated in 1.4 and above will emit a compiler warning.

See also: EMEUS_VERSION_MAX_ALLOWED

Since: 1.0


EMEUS_VERSION_MAX_ALLOWED

#  define EMEUS_VERSION_MAX_ALLOWED     EMEUS_VERSION_MIN_REQUIRED

Defines the upper bound of the API of Emeus that can be used.

This macro can only be defined prior to including emeus.h.

The allowed values for this macro are one of the encoded Emeus version symbols, like EMEUS_VERSION_1_0.

If this pre-processor symbol is define, Emeus will emit a compiler warning when attempting to use functions that have been introduced in newer versions of the library; for instance, if EMEUS_VERSION_MAX_ALLOWED is defined to be EMEUS_VERSION_1_2, you'll be able to use API that has been introduced in version 1.0 and 1.2 without any warning; any API introduced in 1.4 and above will emit a compiler warning.

See also: EMEUS_VERSION_MIN_REQUIRED

Since: 1.0


EMEUS_VERSION_1_0

#define EMEUS_VERSION_1_0       (G_ENCODE_VERSION (1, 0))

A pre-processor symbol that expands to the 1.0 version of Emeus.

You should use this macro with EMEUS_VERSION_MIN_REQUIRED and EMEUS_VERSION_MAX_ALLOWED.

Since: 1.0