diff --git a/base/i2-base.h b/base/i2-base.h index 29ee50d59..1f0508268 100644 --- a/base/i2-base.h +++ b/base/i2-base.h @@ -61,14 +61,9 @@ # include "config.h" #endif /* _MSC_VER */ -#define PLATFORM_WINDOWS 1 -#define PLATFORM_UNIX 2 - #ifdef _WIN32 -# define I2_PLATFORM PLATFORM_WINDOWS # include "win32.h" #else -# define I2_PLATFORM PLATFORM_UNIX # include "unix.h" #endif diff --git a/base/unix.cpp b/base/unix.cpp index 3b074442f..83c2a864f 100644 --- a/base/unix.cpp +++ b/base/unix.cpp @@ -17,9 +17,9 @@ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. * ******************************************************************************/ +#ifndef _WIN32 #include "i2-base.h" -#if I2_PLATFORM == PLATFORM_UNIX #include using namespace icinga; @@ -44,4 +44,4 @@ void closesocket(SOCKET fd) close(fd); } -#endif /* I2_PLATFORM == PLATFORM_UNIX */ +#endif /* _WIN32 */ diff --git a/base/win32.cpp b/base/win32.cpp index 5f1a66a28..9ccc89c4c 100644 --- a/base/win32.cpp +++ b/base/win32.cpp @@ -17,12 +17,11 @@ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. * ******************************************************************************/ +#ifdef _WIN32 #include "i2-base.h" -#if I2_PLATFORM == PLATFORM_WINDOWS - using namespace icinga; /* nothing here (yet) */ -#endif /* I2_PLATFORM == PLATFORM_WINDOWS */ +#endif /* _WIN32 */