From 970d57b99778684907925c41ac9e414c279db8e7 Mon Sep 17 00:00:00 2001 From: Shawn Chain Date: Fri, 9 Nov 2018 18:00:11 +0800 Subject: [PATCH] Add compile switch for log in local time --- Common/Logger.cpp | 6 +++++- Makefile.osx | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Common/Logger.cpp b/Common/Logger.cpp index 936bf37..c64685b 100644 --- a/Common/Logger.cpp +++ b/Common/Logger.cpp @@ -18,7 +18,11 @@ #include "Logger.h" -static bool utc = false; +#if defined(LOG_LOCALTIME) && LOG_LOCAL_TIME == 1 +static const bool utc = false; +#else +static const bool utc = true; +#endif CLogger::CLogger(const wxString& directory, const wxString& name) : wxLog(), diff --git a/Makefile.osx b/Makefile.osx index ac25bae..66755cd 100644 --- a/Makefile.osx +++ b/Makefile.osx @@ -1,5 +1,5 @@ export CXX ?= $(shell wx-config --cxx) -export CFLAGS ?= -O2 -Wall $(shell wx-config --cxxflags) +export CFLAGS ?= -O2 -Wall $(shell wx-config --cxxflags) -DLOG_LOCALTIME=1 export GUILIBS ?= $(shell wx-config --libs adv,core,base) export LIBS ?= $(shell wx-config --libs base) export LDFLAGS ?=