summaryrefslogtreecommitdiff
path: root/libnm-util/nm-version.h
diff options
context:
space:
mode:
authorThomas Haller <thaller@redhat.com>2018-01-16 16:01:49 +0100
committerThomas Haller <thaller@redhat.com>2018-01-23 10:54:11 +0100
commit4da1480cfd50fcc44ddc934db56a02f696e1bc52 (patch)
treea33fadf5cbc8cb46e41c17f2e01ed11ff068a511 /libnm-util/nm-version.h
parent165fe65eef720dcc494c9afa2d787325e0a08053 (diff)
version: rename macro NM_VERSION_CUR_STABLE to NM_API_VERSION
NM_API_VERSION is a better name. It's not the current stable version, but the version number of the API which the current NM_VERSION provides. In practice, NM_API_VERSION is either identical to NM_VERSION (in case of a release) or NM_VERSION is a development version leading up the the upcoming NM_API_VERSION. For example, with the new name the check #if NM_VERSION != NM_API_VERSION # warning this is an development version #endif makes more sense.
Diffstat (limited to 'libnm-util/nm-version.h')
-rw-r--r--libnm-util/nm-version.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/libnm-util/nm-version.h b/libnm-util/nm-version.h
index 5f3bd022a1..f56c3944dd 100644
--- a/libnm-util/nm-version.h
+++ b/libnm-util/nm-version.h
@@ -29,17 +29,17 @@
#if !defined (NM_VERSION_MIN_REQUIRED) || (NM_VERSION_MIN_REQUIRED == 0)
# undef NM_VERSION_MIN_REQUIRED
-# define NM_VERSION_MIN_REQUIRED (NM_VERSION_CUR_STABLE)
+# define NM_VERSION_MIN_REQUIRED (NM_API_VERSION)
#endif
#if !defined (NM_VERSION_MAX_ALLOWED) || (NM_VERSION_MAX_ALLOWED == 0)
# undef NM_VERSION_MAX_ALLOWED
-# define NM_VERSION_MAX_ALLOWED (NM_VERSION_CUR_STABLE)
+# define NM_VERSION_MAX_ALLOWED (NM_API_VERSION)
#endif
/* sanity checks */
-#if NM_VERSION_MIN_REQUIRED > NM_VERSION_CUR_STABLE
-#error "NM_VERSION_MIN_REQUIRED must be <= NM_VERSION_CUR_STABLE"
+#if NM_VERSION_MIN_REQUIRED > NM_API_VERSION
+#error "NM_VERSION_MIN_REQUIRED must be <= NM_API_VERSION"
#endif
#if NM_VERSION_MAX_ALLOWED < NM_VERSION_MIN_REQUIRED
#error "NM_VERSION_MAX_ALLOWED must be >= NM_VERSION_MIN_REQUIRED"