mirror of
https://github.com/stenzek/duckstation.git
synced 2026-02-04 05:04:33 +00:00
Common: Silence deprecation warnings on MacOS
This commit is contained in:
@@ -447,6 +447,11 @@ void MemMap::UnmapSharedMemory(void* baseaddr, size_t size)
|
||||
|
||||
const void* MemMap::GetBaseAddress()
|
||||
{
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
|
||||
#endif
|
||||
|
||||
u32 name_buffer_size = 0;
|
||||
_NSGetExecutablePath(nullptr, &name_buffer_size);
|
||||
if (name_buffer_size > 0) [[likely]]
|
||||
@@ -471,6 +476,10 @@ const void* MemMap::GetBaseAddress()
|
||||
}
|
||||
|
||||
return reinterpret_cast<const void*>(&GetBaseAddress);
|
||||
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
void* MemMap::AllocateJITMemoryAt(const void* addr, size_t size)
|
||||
|
||||
@@ -6,6 +6,11 @@
|
||||
#include "opengl_context.h"
|
||||
#include "opengl_loader.h"
|
||||
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
|
||||
#endif
|
||||
|
||||
#if defined(__APPLE__) && defined(__OBJC__)
|
||||
#import <AppKit/AppKit.h>
|
||||
#else
|
||||
@@ -47,3 +52,7 @@ private:
|
||||
NSOpenGLPixelFormat* m_pixel_format = nullptr;
|
||||
void* m_opengl_module_handle = nullptr;
|
||||
};
|
||||
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
|
||||
@@ -9,6 +9,10 @@
|
||||
|
||||
#include <dlfcn.h>
|
||||
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
|
||||
#endif
|
||||
|
||||
LOG_CHANNEL(GPUDevice);
|
||||
|
||||
OpenGLContextAGL::OpenGLContextAGL() : OpenGLContext()
|
||||
|
||||
Reference in New Issue
Block a user