(Xbox) Buildfixes

This commit is contained in:
twinaphex 2017-09-12 23:44:05 +02:00
parent 5c7b288873
commit 0800047258
2 changed files with 6 additions and 4 deletions

View File

@ -29,6 +29,8 @@
#include <compat/strl.h>
#include <retro_inline.h>
#include <encodings/utf.h>
static INLINE unsigned leading_ones(uint8_t c)
{
unsigned ones = 0;

View File

@ -448,7 +448,7 @@ static bool _scond_wait_win32(scond_t *cond, slock_t *lock, DWORD dwMilliseconds
struct QueueEntry myentry;
struct QueueEntry **ptr;
#if _WIN32_WINNT >= 0x0500
#if _WIN32_WINNT >= 0x0500 || defined(_XBOX)
static LARGE_INTEGER performanceCounterFrequency;
LARGE_INTEGER tsBegin;
static bool first_init = true;
@ -468,7 +468,7 @@ static bool _scond_wait_win32(scond_t *cond, slock_t *lock, DWORD dwMilliseconds
/* since this library is meant for realtime game software
* I have no problem setting this to 1 and forgetting about it. */
#if _WIN32_WINNT >= 0x0500
#if _WIN32_WINNT >= 0x0500 || defined(_XBOX)
if (first_init)
{
performanceCounterFrequency.QuadPart = 0;
@ -490,7 +490,7 @@ static bool _scond_wait_win32(scond_t *cond, slock_t *lock, DWORD dwMilliseconds
/* Now we can take a good timestamp for use in faking the timeout ourselves. */
/* But don't bother unless we need to (to save a little time) */
if (dwMilliseconds != INFINITE)
#if _WIN32_WINNT >= 0x0500
#if _WIN32_WINNT >= 0x0500 || defined(_XBOX)
QueryPerformanceCounter(&tsBegin);
#else
tsBegin = timeGetTime();
@ -536,7 +536,7 @@ static bool _scond_wait_win32(scond_t *cond, slock_t *lock, DWORD dwMilliseconds
/* Assess the remaining timeout time */
if (dwMilliseconds != INFINITE)
{
#if _WIN32_WINNT >= 0x0500
#if _WIN32_WINNT >= 0x0500 || defined(_XBOX)
LARGE_INTEGER now;
LONGLONG elapsed;