1
0
Fork 0
mirror of https://github.com/KingDuckZ/dindexer.git synced 2025-08-18 15:29:48 +00:00

Gather more build env info and show them when doing -b

This commit is contained in:
King_DuckZ 2016-03-17 09:50:52 +01:00
parent a75eee1325
commit aee6c35ede
3 changed files with 18 additions and 2 deletions

View file

@ -29,4 +29,16 @@
#define ACTION_PREFIX "@bare_name@-"
#define DB_OWNER_NAME "@DB_OWNER_NAME@"
#if defined(NDEBUG)
# define CMAKE_CXX_FLAGS "@CMAKE_CXX_FLAGS_RELEASE@"
# define CMAKE_C_FLAGS "@CMAKE_C_FLAGS_RELEASE@"
#else
# define CMAKE_CXX_FLAGS "@CMAKE_CXX_FLAGS_DEBUG@"
# define CMAKE_C_FLAGS "@CMAKE_C_FLAGS_DEBUG@"
#endif
#define CMAKE_SYSTEM "@CMAKE_SYSTEM@"
#define CMAKE_CXX_COMPILER "@CMAKE_CXX_COMPILER@"
#define CMAKE_C_COMPILER "@CMAKE_C_COMPILER@"
#define CMAKE_VERSION "@CMAKE_VERSION@"
#endif

View file

@ -35,6 +35,10 @@ void print_builtin_feats() {
#else
printf("NDEBUG = no (Debug build)\n");
#endif
printf("Built on %s (CMake %s)\n", CMAKE_SYSTEM, CMAKE_VERSION);
printf("Build flags:\n");
printf(" %s %s\n", CMAKE_CXX_COMPILER, CMAKE_CXX_FLAGS);
printf(" %s %s\n", CMAKE_C_COMPILER, CMAKE_C_FLAGS);
printf("DB_OWNER_NAME = \"%s\"\n", DB_OWNER_NAME);
}