cmake introduction
A short example project for the CMake build system
include
config.h
Go to the documentation of this file.
1
#ifndef __cxx_test_project_config_h__
2
#define __cxx_test_project_config_h__
3
4
// If CMake defines the variable CXX_TEST_PROJECT_WITH_LAPACK
5
// then the following will be defined in the header config.h.
6
// Otherwise it will be commented and is not available in your code,
7
// i.e. #ifdef CXX_TEST_PROJECT_WITH_LAPACK will be true in the
8
// first case and false in the second.
9
#define CXX_TEST_PROJECT_WITH_LAPACK
10
11
// Here the value of the CMake variable CXX_TEST_PROJECT_VERSION
12
// will be assigned to the respective variable for the C++ preprocessor.
13
// If it is empty or doesn't exists, the value here will be empty.
14
#define CXX_TEST_PROJECT "1.0.2"
15
16
/** @brief Namespace for configuration time constants
17
*
18
* The constants are automatically defined by CMake in the configuration process.
19
*/
20
namespace
configure_time_constants
21
{
22
/// @name information on the repository version and the build system
23
/// @brief here some information from configure time (during a `cmake` run) is
24
/// made available during compile and run time.
25
/// @warning this is updated only during configure time, i.e. when `cmake` is
26
/// called. So these entries here can be quite out of date, don't rely on them
27
/// to be correct. You can touch the file `config.h.in` in the directory
28
/// `include` to invoke a rerun of `cmake` during a call to make and update
29
/// this file.
30
//@{
31
constexpr
const
char
*
git_revision
=
"5aead1bf5c1d9181cd2c52a1103b98387e34f77b"
;
///< Git revision id
32
constexpr
const
char
*
git_shortrev
=
"5aead1b"
;
///< CurrentGit shortrev
33
constexpr
const
char
*
git_branch
=
""
;
///< Current Git branch
34
35
constexpr
const
char
*
build_type
=
"Debug"
;
///< Current build type
36
//@}
37
}
38
#endif
configure_time_constants::git_revision
constexpr const char * git_revision
Git revision id.
Definition:
config.h:31
configure_time_constants::build_type
constexpr const char * build_type
Current build type.
Definition:
config.h:35
configure_time_constants::git_shortrev
constexpr const char * git_shortrev
CurrentGit shortrev.
Definition:
config.h:32
configure_time_constants::git_branch
constexpr const char * git_branch
Current Git branch.
Definition:
config.h:33
configure_time_constants
Namespace for configuration time constants.
Definition:
config.h:20
Generated on Wed Jan 5 2022 21:36:56 for cmake introduction by
1.8.14