Skip to content

Commit

Permalink
Record debug mode
Browse files Browse the repository at this point in the history
  • Loading branch information
gassmoeller committed Feb 16, 2024
1 parent 2d07a63 commit b099ac7
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions include/world_builder/config.h.in
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@
#define WORLD_BUILDER_VERSION_PATCH @WORLD_BUILDER_VERSION_PATCH@
#define WORLD_BUILDER_VERSION_LABEL @WORLD_BUILDER_VERSION_LABEL@

#ifndef NDEBUG
#define WORLD_BUILDER_DEBUG_MODE 1
#endif

/**
* Returns true if the used World Builder version is greater or equal than the
* version specified by the three arguments. The internal implementation
Expand Down Expand Up @@ -55,6 +59,13 @@ namespace WorldBuilder
const std::string GIT_BRANCH = "@GIT_BRANCH@";
const std::string GIT_DATE = "@GIT_DATE@";
const std::string GIT_COMMIT_SUBJECT = "@GIT_COMMIT_SUBJECT@";

const bool DEBUG_MODE =
#ifdef NDEBUG
false;
#else
true;
#endif
}

namespace Data
Expand Down

0 comments on commit b099ac7

Please sign in to comment.