History

Add MinGW platform makefile and related source changes

V committed 12 years ago

Commit 7fa09901 parent e66b34814 files · +32 −28Browse files

Showing the changes to codec/encoder/core/src/utils.cpp (1 of 14 files). Show all

Unified · Split

codec/encoder/core/src/utils.cpp+5−6
@@ -46,6 +46,9 @@ · 45 unmodified lines
4646 #include <windows.h>
4747 #include <sys/types.h>
4848 #include <sys/timeb.h>
49+#ifndef _MSC_VER
50+#include <sys/time.h>
51+#endif
4952 #else
5053 #include <sys/time.h>
5154 #endif
@@ -147,23 +150,20 @@ void WelsLogDefault (void* pCtx, const int32_t kiLevel, const str_t* kpFmtStr, v · 95 unmodified lines
147150
148151 if (pEncCtx) {
149152 time_t l_time;
150−#if defined(_WIN32)
151−#if defined(_MSC_VER)
153+#if defined(_WIN32) && defined(_MSC_VER)
152154 #if _MSC_VER >= 1500
153155 struct tm t_now;
154156 #else//VC6
155157 struct tm* t_now;
156158 #endif//_MSC_VER >= 1500
157−#endif//_MSC_VER
158159 #else//__GNUC__
159160 struct tm* t_now;
160161 #endif//WIN32
161162
162−#if defined( _WIN32 )
163+#if defined( _WIN32 ) && defined(_MSC_VER)
163164 struct _timeb tb;
164165
165166 time (&l_time);
166−#ifdef _MSC_VER
167167 #if _MSC_VER >= 1500
168168 LOCALTIME (&t_now, &l_time);
169169 #else
@@ -172,7 +172,6 @@ void WelsLogDefault (void* pCtx, const int32_t kiLevel, const str_t* kpFmtStr, v · 2 unmodified lines
172172 return;
173173 }
174174 #endif//_MSC_VER >= 1500
175−#endif//_MSC_VER
176175 FTIME (&tb);
177176 #elif defined( __GNUC__ )
178177 struct timeval tv;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t