mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-04-20 11:36:13 +00:00
Fix broken OS X build with isnan and MAP_ANONYMOUS
This commit is contained in:
parent
634a1f3162
commit
a4f73bc705
2 changed files with 13 additions and 2 deletions
|
@ -4,11 +4,13 @@
|
|||
#include "Emu/System.h"
|
||||
#include "Emu/Cell/PPUThread.h"
|
||||
#include "Emu/SysCalls/Modules.h"
|
||||
|
||||
#include "Emu/Cell/PPUDecoder.h"
|
||||
#include "Emu/Cell/PPUInterpreter.h"
|
||||
#include "Emu/Cell/PPUDisAsm.h"
|
||||
|
||||
#include <thread>
|
||||
#include <cmath>
|
||||
|
||||
extern gcmInfo gcm_info;
|
||||
|
||||
PPUThread& GetCurrentPPUThread()
|
||||
|
@ -190,7 +192,7 @@ bool FPRdouble::IsINF(PPCdouble d)
|
|||
|
||||
bool FPRdouble::IsNaN(PPCdouble d)
|
||||
{
|
||||
return isnan(d) ? 1 : 0;
|
||||
return std::isnan((double)d) ? 1 : 0;
|
||||
}
|
||||
|
||||
bool FPRdouble::IsQNaN(PPCdouble d)
|
||||
|
|
|
@ -8,6 +8,15 @@
|
|||
#include "Emu/SysCalls/Callback.h"
|
||||
#include <vector>
|
||||
|
||||
/* OS X uses MAP_ANON instead of MAP_ANONYMOUS */
|
||||
#ifndef MAP_ANONYMOUS
|
||||
#ifdef MAP_ANON
|
||||
#define MAP_ANONYMOUS MAP_ANON
|
||||
#else
|
||||
#define MAP_ANONYMOUS 0
|
||||
#endif
|
||||
#endif
|
||||
|
||||
using std::nullptr_t;
|
||||
|
||||
#define safe_delete(x) do {delete (x);(x)=nullptr;} while(0)
|
||||
|
|
Loading…
Add table
Reference in a new issue