From a31ef2de000aa4aa2ba5fcf7d079280fcced25a6 Mon Sep 17 00:00:00 2001 From: Alistair Buxton Date: Fri, 7 Feb 2014 19:21:44 +0000 Subject: Fix wrong case on included header. Fixes compilation on case-sensitive filesystems. --- LibOVR/Src/OVR_Profile.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'LibOVR') diff --git a/LibOVR/Src/OVR_Profile.cpp b/LibOVR/Src/OVR_Profile.cpp index fdac5d7..7c2897d 100644 --- a/LibOVR/Src/OVR_Profile.cpp +++ b/LibOVR/Src/OVR_Profile.cpp @@ -39,7 +39,7 @@ limitations under the License. #include "Kernel/OVR_Array.h" #ifdef OVR_OS_WIN32 -#include +#include #else #include #include -- cgit v1.2.3 From c8bc5cf5bb5c9b4c49114638ebb7a69a17e25452 Mon Sep 17 00:00:00 2001 From: Alistair Buxton Date: Fri, 7 Feb 2014 19:36:07 +0000 Subject: Don't try to use MSVC specific code in mingw. --- LibOVR/Src/OVR_SensorFusion.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'LibOVR') diff --git a/LibOVR/Src/OVR_SensorFusion.cpp b/LibOVR/Src/OVR_SensorFusion.cpp index eac0366..a2248d1 100644 --- a/LibOVR/Src/OVR_SensorFusion.cpp +++ b/LibOVR/Src/OVR_SensorFusion.cpp @@ -561,7 +561,7 @@ bool SensorFusion::LoadMagCalibration(const char* calibrationName) tm ct; memset(&ct, 0, sizeof(tm)); -#ifdef OVR_OS_WIN32 +#if defined OVR_OS_WIN32 && !defined(__MINGW32__) struct tm nowtime; localtime_s(&nowtime, &now); ct.tm_isdst = nowtime.tm_isdst; -- cgit v1.2.3 From 3c53d74a6065c5878b0b3c3e345baf848ac90a58 Mon Sep 17 00:00:00 2001 From: Alistair Buxton Date: Fri, 7 Feb 2014 20:21:58 +0000 Subject: Don't try to set thread name on mingw. Mingw doesn't support SEH so the recommended way of setting the thread name doesn't work. This can be rewritten in a portable way but for now just disable it, as it's only a debugging feature. --- LibOVR/Src/Kernel/OVR_ThreadsWinAPI.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'LibOVR') diff --git a/LibOVR/Src/Kernel/OVR_ThreadsWinAPI.cpp b/LibOVR/Src/Kernel/OVR_ThreadsWinAPI.cpp index 8880082..30e8656 100644 --- a/LibOVR/Src/Kernel/OVR_ThreadsWinAPI.cpp +++ b/LibOVR/Src/Kernel/OVR_ThreadsWinAPI.cpp @@ -969,6 +969,7 @@ void Thread::SetThreadName( const char* name ) info.dwThreadID = reinterpret_cast(GetThreadId()); info.dwFlags = 0; +#if !defined(__MINGW32__) // FIXME: Port this to mingw. __try { #ifdef _WIN64 @@ -980,6 +981,7 @@ void Thread::SetThreadName( const char* name ) __except( GetExceptionCode()==0x406D1388 ? EXCEPTION_CONTINUE_EXECUTION : EXCEPTION_EXECUTE_HANDLER ) { } +#endif // __MINGW32__ #endif // OVR_BUILD_SHIPPING } -- cgit v1.2.3 From da90f8541ad754ef6bbcb3fada6676fc827be011 Mon Sep 17 00:00:00 2001 From: Alistair Buxton Date: Fri, 7 Feb 2014 20:45:36 +0000 Subject: Fix a string conversion error with mingw. --- LibOVR/Src/OVR_Win32_HIDDevice.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'LibOVR') diff --git a/LibOVR/Src/OVR_Win32_HIDDevice.cpp b/LibOVR/Src/OVR_Win32_HIDDevice.cpp index 81a6c8a..b93e9cc 100644 --- a/LibOVR/Src/OVR_Win32_HIDDevice.cpp +++ b/LibOVR/Src/OVR_Win32_HIDDevice.cpp @@ -292,7 +292,7 @@ bool HIDDevice::HIDInitialize(const String& path) if (!openDevice()) { - LogText("OVR::Win32::HIDDevice - Failed to open HIDDevice: ", path); + LogText("OVR::Win32::HIDDevice - Failed to open HIDDevice: ", path.ToCStr()); return false; } -- cgit v1.2.3