Misc cleanup

This commit is contained in:
SiliconExarch 2021-08-29 22:13:59 +01:00
parent 3f55406f4f
commit 607290edad
4 changed files with 13 additions and 6 deletions

View file

@ -279,7 +279,7 @@ PFNGLDEPTHBOUNDSEXTPROC qglDepthBoundsEXT;
// DG: couldn't find any extension for this, it's supported in GL2.0 and newer, incl OpenGL ES2.0
// SE: only the ATI implementation is provided on Mac OS X 10.4 and 10.5
#if (defined(__MAC_OS_X_VERSION_MIN_REQUIRED) && __MAC_OS_X_VERSION_MIN_REQUIRED <= 1050)
#if OSX_TIGER || OSX_LEOPARD
PFNGLSTENCILOPSEPARATEATIPROC qglStencilOpSeparate;
#else
PFNGLSTENCILOPSEPARATEPROC qglStencilOpSeparate;
@ -403,12 +403,12 @@ static void R_CheckPortableExtensions( void ) {
if ( glConfig.twoSidedStencilAvailable )
qglActiveStencilFaceEXT = (PFNGLACTIVESTENCILFACEEXTPROC)GLimp_ExtensionPointer( "glActiveStencilFaceEXT" );
#if (defined(__MAC_OS_X_VERSION_MIN_REQUIRED) && __MAC_OS_X_VERSION_MIN_REQUIRED <= 1050)
#if OSX_TIGER || OSX_LEOPARD
if( glConfig.glVersion >= 2.0) {
common->Printf( "... got GL2.0+ glStencilOpSeparate()\n" );
common->Printf( "... got GL2.0+ glStencilOpSeparateATI()\n" );
qglStencilOpSeparate = (PFNGLSTENCILOPSEPARATEATIPROC)GLimp_ExtensionPointer( "glStencilOpSeparateATI" );
} else {
common->Printf( "... don't have GL2.0+ glStencilOpSeparate()\n" );
common->Printf( "... don't have GL2.0+ glStencilOpSeparateATI()\n" );
qglStencilOpSeparate = NULL;
}
#else

View file

@ -97,7 +97,7 @@ extern PFNGLACTIVESTENCILFACEEXTPROC qglActiveStencilFaceEXT;
// DG: couldn't find any extension for this, it's supported in GL2.0 and newer, incl OpenGL ES2.0
// SE: only the ATI implementation is provided on Mac OS X 10.4 and 10.5
#if (defined(__MAC_OS_X_VERSION_MIN_REQUIRED) && __MAC_OS_X_VERSION_MIN_REQUIRED <= 1050)
#if OSX_TIGER || OSX_LEOPARD
extern PFNGLSTENCILOPSEPARATEATIPROC qglStencilOpSeparate;
#else
extern PFNGLSTENCILOPSEPARATEPROC qglStencilOpSeparate;

View file

@ -202,6 +202,13 @@ If you have questions concerning this license or the applicable additional terms
#ifdef __APPLE__
#include <Availability.h>
#ifdef __MAC_OS_X_VERSION_MIN_REQUIRED
#if __MAC_OS_X_VERSION_MIN_REQUIRED == 1040
#define OSX_TIGER 1
#elif __MAC_OS_X_VERSION_MIN_REQUIRED < 1060
#define OSX_LEOPARD 1
#endif
#endif
#endif
#define ID_TIME_T time_t

View file

@ -401,7 +401,7 @@ int Sys_GetDriveFreeSpace( const char *path ) {
static const int crashSigs[] = { SIGILL, SIGABRT, SIGFPE, SIGSEGV };
static const char* crashSigNames[] = { "SIGILL", "SIGABRT", "SIGFPE", "SIGSEGV" };
#if ( defined(__linux__) && defined(__GLIBC__) ) || defined(__FreeBSD__) || (defined(__APPLE__) && !(__MAC_OS_X_VERSION_MIN_REQUIRED <= 1040))
#if ( defined(__linux__) && defined(__GLIBC__) ) || defined(__FreeBSD__) || (defined(__APPLE__) && !OSX_TIGER)
#define D3_HAVE_BACKTRACE
#include <execinfo.h>
#endif