From: vsr Date: Fri, 20 Jan 2017 13:03:50 +0000 (+0300) Subject: Patch for MacOS (from SALOME forum) X-Git-Tag: SHAPER_2.7.0 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=de2a98b899a9157d6978f8f666d6255ff87342ae;p=plugins%2Fhexablockplugin.git Patch for MacOS (from SALOME forum) --- diff --git a/src/GUI/HEXABLOCKPluginGUI_HypothesisCreator.cxx b/src/GUI/HEXABLOCKPluginGUI_HypothesisCreator.cxx index 3e71319..887f292 100755 --- a/src/GUI/HEXABLOCKPluginGUI_HypothesisCreator.cxx +++ b/src/GUI/HEXABLOCKPluginGUI_HypothesisCreator.cxx @@ -93,15 +93,15 @@ enum { namespace { -#ifdef WIN32 +#if defined(WIN32) #include -#else +#elif !defined(__APPLE__) #include #endif int maxAvailableMemory() { -#ifdef WIN32 +#if defined(WIN32) // See http://msdn.microsoft.com/en-us/library/aa366589.aspx MEMORYSTATUSEX statex; statex.dwLength = sizeof (statex); @@ -113,7 +113,7 @@ namespace { statex.ullTotalVirtual / 1024 / 1024; return (int) ( 0.7 * totMB ); } -#else +#elif !defined(__APPLE__) struct sysinfo si; int err = sysinfo( &si ); if ( err == 0 ) {