here at office we work with MSVC++ 7.1 and I don't manage to compile the log4cpp library (from cvs) as is since I don't find in my environment any trace of the localtime_s function:
-*- mode: grep; default-directory: "c:/Program Files/Microsoft Visual Studio .NET 2003/Vc7/include/" -*-
Grep started at Thu Apr 09 15:00:37
grep -nHr -e localtime_s .
Grep finished with no matches found at Thu Apr 09 15:00:38
am I missing something or is the symbol unduly defined?
I did not manage to find in the microsoft heystack when the localtime_s function was first introduced...
if I #undef the symbol LOG4CPP_HAVE_LOCALTIME_R then it compiles perfectly.
RCS file: /cvsroot/log4cpp/log4cpp/include/log4cpp/config-win32-stlport-boost.h,v
retrieving revision 1.7
diff -u -r1.7 config-win32-stlport-boost.h
--- include/log4cpp/config-win32-stlport-boost.h 5 Sep 2007 14:30:28 -0000 1.7
+++ include/log4cpp/config-win32-stlport-boost.h 9 Apr 2009 13:16:58 -0000
@@ -88,7 +88,7 @@
#define LOG4CPP_HAVE_SNPRINTF 1
#endif
-#if defined(_MSC_VER) && _MSC_VER >= 1300
+#if defined(_MSC_VER) && _MSC_VER >= 1400
#define LOG4CPP_HAVE_LOCALTIME_R 1
#endif
RCS file: /cvsroot/log4cpp/log4cpp/include/log4cpp/config-win32.h,v
retrieving revision 1.24
diff -u -r1.24 config-win32.h
--- include/log4cpp/config-win32.h 5 Sep 2007 14:30:28 -0000 1.24
+++ include/log4cpp/config-win32.h 9 Apr 2009 13:16:58 -0000
@@ -90,7 +90,7 @@
#define LOG4CPP_HAVE_SNPRINTF 1
#endif
-#if defined(_MSC_VER) && _MSC_VER >= 1300
+#if defined(_MSC_VER) && _MSC_VER >= 1400
#define LOG4CPP_HAVE_LOCALTIME_R 1
#endif