From 797f97f41582d73a1c8e3126efc7f0afa6d52656 Mon Sep 17 00:00:00 2001 From: syntheticpp Date: Mon, 26 Jan 2009 19:45:54 +0000 Subject: [PATCH] Cygwin fixes: build with mingw 3.4.4 and 4.3.2 git-svn-id: svn://svn.code.sf.net/p/loki-lib/code/trunk@950 7ec92016-0320-0410-acc4-a06ded1c099a --- include/loki/CachedFactory.h | 2 +- src/LevelMutex.cpp | 6 ++++++ src/Makefile | 1 + 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/include/loki/CachedFactory.h b/include/loki/CachedFactory.h index 391f5bf..81d5f29 100644 --- a/include/loki/CachedFactory.h +++ b/include/loki/CachedFactory.h @@ -37,7 +37,7 @@ #define D( x ) ; #endif -#ifdef _MSC_VER +#if defined(_MSC_VER) || defined(__CYGWIN__) #include #endif diff --git a/src/LevelMutex.cpp b/src/LevelMutex.cpp index 9165382..696485e 100644 --- a/src/LevelMutex.cpp +++ b/src/LevelMutex.cpp @@ -20,6 +20,8 @@ // ---------------------------------------------------------------------------- +#if !defined(__CYGWIN__) || (defined(__CYGWIN__) && __GNUC__ > 3) + #include #include @@ -1148,3 +1150,7 @@ bool MultiMutexLocker::Unlock( void ) // ---------------------------------------------------------------------------- } // end namespace Loki + + +#endif + diff --git a/src/Makefile b/src/Makefile index 7b9dc18..b272929 100644 --- a/src/Makefile +++ b/src/Makefile @@ -31,6 +31,7 @@ ifeq ($(OS), GNU) SHARED_LIB_VERSIONED := libloki.so.$(VERSION) override LDFLAGS += --shared -Wl,-soname=$(SHARED_LIB_VERSIONED) -fPIC LDLIBS := -lpthread +else ifeq ($(OS), HP-UX) SHARED_LIB_BASE := libloki.so SHARED_LIB_VERSIONED := libloki.so.$(VERSION)