diff options
-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 | ||||
-rw-r--r-- | lib/server/Daemon.cpp | 12 |
5 files changed, 24 insertions, 7 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" diff --git a/lib/server/Daemon.cpp b/lib/server/Daemon.cpp index 668bffb5..dfd2150a 100644 --- a/lib/server/Daemon.cpp +++ b/lib/server/Daemon.cpp @@ -32,13 +32,17 @@ #include <iostream> -#include "Daemon.h" +#ifdef NEED_BOX_VERSION_H +# include "BoxVersion.h" +#endif + #include "Configuration.h" -#include "ServerException.h" -#include "Guards.h" -#include "UnixUser.h" +#include "Daemon.h" #include "FileModificationTime.h" +#include "Guards.h" #include "Logging.h" +#include "ServerException.h" +#include "UnixUser.h" #include "Utils.h" #include "MemLeakFindOn.h" |