diff --git a/checkin_notes b/checkin_notes index 963019252d..f5ab5e90f4 100755 --- a/checkin_notes +++ b/checkin_notes @@ -9702,3 +9702,10 @@ Bruce 29 July 2005 sched/ sched_send.C +Charlie 29 July 2005 + Mac: #define __WXDEBUG__ only in our code (not in wxWidgets headers) + in Development version only to allow testing of wizard. See comments + in MacGUI.pch for details. + + mac/ + MacGUI.pch diff --git a/clientgui/mac/MacGUI.pch b/clientgui/mac/MacGUI.pch index 7b4680fc49..36b31cddc4 100644 --- a/clientgui/mac/MacGUI.pch +++ b/clientgui/mac/MacGUI.pch @@ -34,4 +34,25 @@ #include "config.h" +// We want to define __WXDEBUG__ to enable certain test code within our project, +// but only for Development builds. Unfortunately, XCode allows us to modify +// compiler or linker flags by build style only on a project-wide basis. If we +// do that, then the compiler & linker flags override these settings for all +// targets in the project. But our different targets need different settings. +// XCode does not provide any way to do this on a per-target basis. +// This means that we can neither add -D__WXDEBUG to the compiler flags for only +// Development Builds of the BOINC Manager, but we also cannot link in the debug +// build of wxWidgets for only Development Builds of the BOINC Manager. +// So we use a couple of ugly hacks here: +// (1) We take advantage that __OPTIMIZE__ is defined only for Deployment builds. +// (2) We define __WXDEBUG__ AFTER including stdwx.h, so as not to require the +// debug build of the wxWidgets library. + +// __OPTIMIZE__ is defined in Deployment builds, not in Development builds +#ifndef __OPTIMIZE__ +// Define this AFTER including stdwx.h so we don't have to link wih debug Wx libs +#define __WXDEBUG__ +#endif + + #endif