Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion src/native/minipal/configure.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ include(CheckFunctionExists)
include(CheckIncludeFiles)
include(CheckSymbolExists)

check_include_files("windows.h" HAVE_WINDOWS_H)
check_include_files("windows.h;bcrypt.h" HAVE_BCRYPT_H)
check_include_files("sys/auxv.h;asm/hwcap.h" HAVE_AUXV_HWCAP_H)
check_include_files("asm/hwprobe.h" HAVE_HWPROBE_H)
Expand Down
1 change: 0 additions & 1 deletion src/native/minipal/minipalconfig.h.in
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
#cmakedefine01 HAVE_CLOCK_GETTIME_NSEC_NP
#cmakedefine01 BIGENDIAN
#cmakedefine01 HAVE_BCRYPT_H
#cmakedefine01 HAVE_WINDOWS_H
#cmakedefine01 HAVE_FSYNC

#endif
12 changes: 6 additions & 6 deletions src/native/minipal/time.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
#include <minipal/time.h>
#include "minipalconfig.h"

#if HAVE_WINDOWS_H
#if HOST_WINDOWS

#include <Windows.h>

Expand All @@ -23,7 +23,7 @@ int64_t minipal_hires_tick_frequency()
return ts.QuadPart;
}

#else // HAVE_WINDOWS_H
#else // HOST_WINDOWS

#include "minipalconfig.h"

Expand Down Expand Up @@ -77,17 +77,17 @@ int64_t minipal_hires_ticks(void)
#endif
}

#endif // !HAVE_WINDOWS_H
#endif // HOST_WINDOWS

void minipal_microdelay(uint32_t usecs, uint32_t* usecsSinceYield)
{
#if HAVE_WINDOWS_H
#if HOST_WINDOWS
if (usecs > 1000)
{
SleepEx(usecs / 1000, FALSE);
if (usecsSinceYield)
{
usecsSinceYield = 0;
*usecsSinceYield = 0;
}

return;
Expand All @@ -107,7 +107,7 @@ void minipal_microdelay(uint32_t usecs, uint32_t* usecsSinceYield)

if (usecsSinceYield)
{
usecsSinceYield = 0;
*usecsSinceYield = 0;
}

return;
Expand Down
Loading