esp-nimble-cpp 2.4.0
Loading...
Searching...
No Matches
NimBLECppVersion.h
1/*
2 * Copyright 2020-2025 Ryan Powell <ryan@nable-embedded.io> and
3 * esp-nimble-cpp, NimBLE-Arduino contributors.
4 *
5 * Licensed under the Apache License, Version 2.0 (the "License");
6 * you may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
16 */
17
18#ifndef NIMBLE_CPP_VERSION_H_
19#define NIMBLE_CPP_VERSION_H_
20
22#define NIMBLE_CPP_VERSION_MAJOR 2
23
25#define NIMBLE_CPP_VERSION_MINOR 4
26
28#define NIMBLE_CPP_VERSION_PATCH 0
29
42#define NIMBLE_CPP_VERSION_VAL(major, minor, patch) (((major) << 16) | ((minor) << 8) | (patch))
43
48#define NIMBLE_CPP_VERSION \
49 NIMBLE_CPP_VERSION_VAL(NIMBLE_CPP_VERSION_MAJOR, NIMBLE_CPP_VERSION_MINOR, NIMBLE_CPP_VERSION_PATCH)
50
52#define NIMBLE_CPP_VERSION_STRINGIFY_IMPL(x) #x
53#define NIMBLE_CPP_VERSION_STRINGIFY(x) NIMBLE_CPP_VERSION_STRINGIFY_IMPL(x)
60#ifndef NIMBLE_CPP_VERSION_PRERELEASE
61# define NIMBLE_CPP_VERSION_PRERELEASE ""
62#endif
63
68#ifndef NIMBLE_CPP_VERSION_BUILD_METADATA
69# define NIMBLE_CPP_VERSION_BUILD_METADATA ""
70#endif
71
73#define NIMBLE_CPP_VERSION_STR \
74 "NimBLE-CPP " \
75 NIMBLE_CPP_VERSION_STRINGIFY(NIMBLE_CPP_VERSION_MAJOR) "." \
76 NIMBLE_CPP_VERSION_STRINGIFY(NIMBLE_CPP_VERSION_MINOR) "." \
77 NIMBLE_CPP_VERSION_STRINGIFY(NIMBLE_CPP_VERSION_PATCH) \
78 NIMBLE_CPP_VERSION_PRERELEASE NIMBLE_CPP_VERSION_BUILD_METADATA
79
80#endif // NIMBLE_CPP_VERSION_H_