File: version.h

package info (click to toggle)
libgit2 1.9.1%2Bds-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 60,804 kB
  • sloc: ansic: 203,436; javascript: 2,458; sh: 1,763; python: 384; perl: 99; php: 65; makefile: 33
file content (77 lines) | stat: -rw-r--r-- 2,237 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
/*
 * Copyright (C) the libgit2 contributors. All rights reserved.
 *
 * This file is part of libgit2, distributed under the GNU GPL v2 with
 * a Linking Exception. For full terms see the included COPYING file.
 */
#ifndef INCLUDE_git_version_h__
#define INCLUDE_git_version_h__

#include "common.h"

/**
 * @file git2/version.h
 * @brief The version of libgit2
 * @ingroup Git
 * @{
 */
GIT_BEGIN_DECL

/**
 * The version string for libgit2.  This string follows semantic
 * versioning (v2) guidelines.
 */
#define LIBGIT2_VERSION           "1.9.1"

/** The major version number for this version of libgit2. */
#define LIBGIT2_VERSION_MAJOR      1

/** The minor version number for this version of libgit2. */
#define LIBGIT2_VERSION_MINOR      9

/** The revision ("teeny") version number for this version of libgit2. */
#define LIBGIT2_VERSION_REVISION   1

/** The Windows DLL patch number for this version of libgit2. */
#define LIBGIT2_VERSION_PATCH      0

/**
 * The prerelease string for this version of libgit2.  For development
 * (nightly) builds, this will be "alpha".  For prereleases, this will be
 * a prerelease name like "beta" or "rc1".  For final releases, this will
 * be `NULL`.
 */
#define LIBGIT2_VERSION_PRERELEASE NULL

/**
 * The library ABI soversion for this version of libgit2. This should
 * only be changed when the library has a breaking ABI change, and so
 * may not reflect the library's API version number.
 */
#define LIBGIT2_SOVERSION         "1.9"

/**
 * An integer value representing the libgit2 version number. For example,
 * libgit2 1.6.3 is 1060300.
 */
#define LIBGIT2_VERSION_NUMBER (    \
    (LIBGIT2_VERSION_MAJOR * 1000000) + \
    (LIBGIT2_VERSION_MINOR * 10000) +   \
    (LIBGIT2_VERSION_REVISION * 100))

/**
 * Compare the libgit2 version against a given version. Evaluates to true
 * if the given major, minor, and revision values are greater than or equal
 * to the currently running libgit2 version. For example:
 *
 *  #if LIBGIT2_VERSION_CHECK(1, 6, 3)
 *  # error libgit2 version is >= 1.6.3
 *  #endif
 */
#define LIBGIT2_VERSION_CHECK(major, minor, revision) \
	(LIBGIT2_VERSION_NUMBER >= ((major)*1000000)+((minor)*10000)+((revision)*100))

/** @} */
GIT_END_DECL

#endif