Dune Core Modules (2.4.1)

version.hh
Go to the documentation of this file.
1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
2// vi: set et ts=4 sw=2 sts=2:
3#ifndef DUNE_VERSION_HH
4#define DUNE_VERSION_HH
5
26#define DUNE_VERSION_JOIN(module,type) module ## _VERSION_ ## type
27
42#define DUNE_VERSION_EQUAL(module,major,minor) \
43 ((DUNE_VERSION_JOIN(module,MAJOR) == major) && \
44 (DUNE_VERSION_JOIN(module,MINOR) == minor))
45
60#define DUNE_VERSION_EQUAL_REV(module,major,minor,revision) \
61 ( DUNE_VERSION_EQUAL(module,major,minor) && \
62 (DUNE_VERSION_JOIN(module,REVISION) == revision))
63
78#define DUNE_VERSION_NEWER(module,major,minor) \
79 ((DUNE_VERSION_JOIN(module,MAJOR) > major) \
80 || ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN(module,MINOR) >= minor)))
81
96#define DUNE_VERSION_NEWER_REV(module,major,minor,revision) \
97 ((DUNE_VERSION_JOIN(module,MAJOR) > major) \
98 || ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN(module,MINOR) > minor)) \
99 || ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN(module,MINOR) == minor) \
100 && (DUNE_VERSION_JOIN(module,REVISION) >= revision)))
101
116#define DUNE_VERSION_ID(major,minor,revision) \
117 ((unsigned int)((major << 24) + (minor << 16) + revision))
118
133#define DUNE_MODULE_VERSION_ID(module) \
134 DUNE_VERSION_ID( DUNE_VERSION_JOIN(module,MAJOR), DUNE_VERSION_JOIN(module,MINOR), DUNE_VERSION_JOIN(module,REVISION) )
135
136#endif
Creative Commons License   |  Legal Statements / Impressum  |  Hosted by TU Dresden  |  generated with Hugo v0.111.3 (Nov 24, 23:30, 2024)