From 2e6b4b960d58eba3151518cf6cc3413955645460 Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Thu, 17 Oct 2013 11:56:33 -0700 Subject: [PATCH] Fixed compiling on Mac OS X, added a system RAM test --- src/cpuinfo/SDL_cpuinfo.c | 2 +- test/testplatform.c | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/cpuinfo/SDL_cpuinfo.c b/src/cpuinfo/SDL_cpuinfo.c index c59b51b873284..d39075f1548ab 100644 --- a/src/cpuinfo/SDL_cpuinfo.c +++ b/src/cpuinfo/SDL_cpuinfo.c @@ -621,7 +621,7 @@ SDL_GetSystemRAM(void) #ifdef HAVE_SYSCTLBYNAME if (SDL_SystemRAM <= 0) { int mib[2] = {CTL_HW, HW_MEMSIZE}; - uint64 memsize = 0; + Uint64 memsize = 0; size_t len = sizeof(memsize); if (sysctl(mib, 2, &memsize, &len, NULL, 0) == 0) { diff --git a/test/testplatform.c b/test/testplatform.c index 2f32e1f4e9c5e..a8ed39dd2a8f0 100644 --- a/test/testplatform.c +++ b/test/testplatform.c @@ -153,6 +153,7 @@ TestCPUInfo(SDL_bool verbose) SDL_Log("SSE3 %s\n", SDL_HasSSE3()? "detected" : "not detected"); SDL_Log("SSE4.1 %s\n", SDL_HasSSE41()? "detected" : "not detected"); SDL_Log("SSE4.2 %s\n", SDL_HasSSE42()? "detected" : "not detected"); + SDL_Log("System RAM %d MB\n", SDL_GetSystemRAM()); } return (0); }