mirror of https://github.com/AxioDL/jbus.git
FreeBSD fix
This commit is contained in:
parent
4699542f93
commit
b82c928e45
|
@ -1,5 +1,6 @@
|
||||||
#ifndef _WIN32
|
#ifndef _WIN32
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
#include <sys/time.h>
|
||||||
#if __APPLE__
|
#if __APPLE__
|
||||||
#include <mach/mach_time.h>
|
#include <mach/mach_time.h>
|
||||||
#endif
|
#endif
|
||||||
|
@ -27,7 +28,7 @@ u64 GetGCTicks()
|
||||||
{
|
{
|
||||||
#if __APPLE__
|
#if __APPLE__
|
||||||
return mach_absolute_time() * MachToDolphinNum / MachToDolphinDenom;
|
return mach_absolute_time() * MachToDolphinNum / MachToDolphinDenom;
|
||||||
#elif __linux__
|
#elif __linux__ || __FreeBSD__
|
||||||
struct timespec tp;
|
struct timespec tp;
|
||||||
clock_gettime(CLOCK_MONOTONIC, &tp);
|
clock_gettime(CLOCK_MONOTONIC, &tp);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue