diff options
author | Chris Wilson <chris+github@qwirx.com> | 2011-10-25 22:03:07 +0000 |
---|---|---|
committer | Chris Wilson <chris+github@qwirx.com> | 2011-10-25 22:03:07 +0000 |
commit | b63f27c0923a6758e5e5dbe2bc42e06a93049443 (patch) | |
tree | abfd888c993c466584e31fdf15fec69f72d099e7 /lib/common | |
parent | be9a51e36a54deab6f8e785af5b3052058a1d070 (diff) |
Avoid recompiling everything on MSVC when BoxVersion.h changes.
Diffstat (limited to 'lib/common')
-rw-r--r-- | lib/common/BannerText.h | 6 | ||||
-rw-r--r-- | lib/common/BoxPlatform.h | 2 | ||||
-rw-r--r-- | lib/common/MainHelper.h | 5 | ||||
-rw-r--r-- | lib/common/Utils.cpp | 6 |
4 files changed, 16 insertions, 3 deletions
diff --git a/lib/common/BannerText.h b/lib/common/BannerText.h index e40224da..f0772c9c 100644 --- a/lib/common/BannerText.h +++ b/lib/common/BannerText.h @@ -10,9 +10,13 @@ #ifndef BANNERTEXT__H #define BANNERTEXT__H +#ifdef NEED_BOX_VERSION_H +# include "BoxVersion.h" +#endif + #define BANNER_TEXT(UtilityName) \ "Box " UtilityName " v" BOX_VERSION ", (c) Ben Summers and " \ - "contributors 2003-2010" + "contributors 2003-2011" #endif // BANNERTEXT__H diff --git a/lib/common/BoxPlatform.h b/lib/common/BoxPlatform.h index df77c310..53a967e8 100644 --- a/lib/common/BoxPlatform.h +++ b/lib/common/BoxPlatform.h @@ -23,7 +23,7 @@ #ifdef _MSC_VER #include "BoxConfig-MSVC.h" -#include "BoxVersion.h" +#define NEED_BOX_VERSION_H #else #include "BoxConfig.h" #endif diff --git a/lib/common/MainHelper.h b/lib/common/MainHelper.h index 3c973624..3c6e9ff0 100644 --- a/lib/common/MainHelper.h +++ b/lib/common/MainHelper.h @@ -12,6 +12,10 @@ #include <stdio.h> +#ifdef NEED_BOX_VERSION_H +# include "BoxVersion.h" +#endif + #include "BoxException.h" #include "Logging.h" @@ -21,6 +25,7 @@ MEMLEAKFINDER_INIT \ MEMLEAKFINDER_START \ try { + #define MAINHELPER_END \ } catch(std::exception &e) { \ BOX_FATAL(e.what()); \ diff --git a/lib/common/Utils.cpp b/lib/common/Utils.cpp index 4f44ce0a..51bc3040 100644 --- a/lib/common/Utils.cpp +++ b/lib/common/Utils.cpp @@ -28,9 +28,13 @@ #include <dlfcn.h> #endif -#include "Utils.h" +#ifdef NEED_BOX_VERSION_H +# include "BoxVersion.h" +#endif + #include "CommonException.h" #include "Logging.h" +#include "Utils.h" #include "MemLeakFindOn.h" |