diff options
author | Andreas Baumann <abaumann@yahoo.com> | 2012-09-06 10:25:57 +0200 |
---|---|---|
committer | Andreas Baumann <abaumann@yahoo.com> | 2012-09-06 10:25:57 +0200 |
commit | f5c586f7231f7e033c5528bcefea357e4e64441c (patch) | |
tree | 4d039e54c77bdb84a1cb79b56db7b62bccdd43d8 /tests | |
parent | a29c464aa72d46cc956ac2752a2518526c499716 (diff) | |
download | crawler-f5c586f7231f7e033c5528bcefea357e4e64441c.tar.gz crawler-f5c586f7231f7e033c5528bcefea357e4e64441c.tar.bz2 |
first properly working logger on Windows (singleton dll issue)
Diffstat (limited to 'tests')
-rwxr-xr-x | tests/modules/testmod/Makefile.W32 | 2 | ||||
-rwxr-xr-x | tests/utils/Makefile.W32 | 6 | ||||
-rwxr-xr-x[-rw-r--r--] | tests/utils/test3.cpp | 4 |
3 files changed, 10 insertions, 2 deletions
diff --git a/tests/modules/testmod/Makefile.W32 b/tests/modules/testmod/Makefile.W32 index e01c220..77d16cb 100755 --- a/tests/modules/testmod/Makefile.W32 +++ b/tests/modules/testmod/Makefile.W32 @@ -10,6 +10,8 @@ INCLUDE_CXXFLAGS = \ INCLUDE_DIRS = \ /I. \ /I$(TOPDIR)\src \ + /I$(TOPDIR)\include\module \ + /I$(TOPDIR)\include\util \ /I.. INCLUDE_LDFLAGS = \ diff --git a/tests/utils/Makefile.W32 b/tests/utils/Makefile.W32 index 6f18d9c..03ea7ae 100755 --- a/tests/utils/Makefile.W32 +++ b/tests/utils/Makefile.W32 @@ -5,11 +5,13 @@ SUBDIRS = !INCLUDE $(TOPDIR)\makefiles\nmake\platform.mk INCLUDE_CXXFLAGS = \ - /D_WIN32_WINNT=0x504 + /D_WIN32_WINNT=0x504 \ + /DNODLL INCLUDE_DIRS = \ /I. \ - /I$(TOPDIR)\src + /I$(TOPDIR)\src \ + /I$(TOPDIR)\include\util INCLUDE_LDFLAGS = \ diff --git a/tests/utils/test3.cpp b/tests/utils/test3.cpp index 489276b..2a9a37f 100644..100755 --- a/tests/utils/test3.cpp +++ b/tests/utils/test3.cpp @@ -8,6 +8,8 @@ using namespace std; class Logger : public Singleton< Logger > { public: + DECLARE_SINGLETON( Logger ) + void log( string s ) { cout << s << endl; @@ -28,6 +30,8 @@ class Logger : public Singleton< Logger > } }; +DEFINE_SINGLETON( Logger ) + /* this works, and two loggers can coexist, but they have different type class DerivedLogger : public Logger { |