Buildfix. Checking _POSIX_VERSION is not recommended anyway.

This commit is contained in:
Henrik Rydgård 2020-07-15 13:53:20 +02:00
parent 8c38d7305e
commit f5fd27c3b6
2 changed files with 3 additions and 9 deletions

View file

@ -21,10 +21,6 @@
#include "Common/MachineContext.h"
#ifndef _WIN32
#include <unistd.h> // Needed for _POSIX_VERSION
#endif
static BadAccessHandler g_badAccessHandler;
#ifdef MACHINE_CONTEXT_SUPPORTED
@ -225,7 +221,7 @@ void InstallExceptionHandler(BadAccessHandler badAccessHandler) {
void UninstallExceptionHandler() {
}
#elif defined(_POSIX_VERSION)
#else
static struct sigaction old_sa_segv;
static struct sigaction old_sa_bus;
@ -330,10 +326,6 @@ void UninstallExceptionHandler() {
g_badAccessHandler = nullptr;
}
#else // Unsupported platform. Could also #error
#error Shouldn't get here
#endif
#else // !MACHINE_CONTEXT_SUPPORTED

View file

@ -315,6 +315,7 @@ typedef mcontext_t SContext;
#if PPSSPP_ARCH(AMD64)
#include <cstdint>
#include <stddef.h>
#define CTX_PC CTX_RIP
static inline uint64_t *ContextRN(SContext* ctx, int n) {
static const uint8_t offsets[] = {
@ -330,6 +331,7 @@ static inline uint64_t *ContextRN(SContext* ctx, int n) {
#elif PPSSPP_ARCH(X86)
#include <cstdint>
#include <stddef.h>
#define CTX_PC CTX_RIP
static inline uint32_t *ContextRN(SContext* ctx, int n) {