target-helpers: Enable debug helpers only on debug builds.

Some of these helpers use debug_get_option, which works also on releases.
This commit is contained in:
José Fonseca 2012-07-06 09:50:11 +01:00
parent c445b0f76d
commit 232073b0d9
1 changed files with 7 additions and 0 deletions

View File

@ -10,6 +10,8 @@
* one or more debug driver: rbug, trace.
*/
#ifdef DEBUG
#ifdef GALLIUM_TRACE
#include "trace/tr_public.h"
#endif
@ -26,9 +28,12 @@
#include "noop/noop_public.h"
#endif
#endif /* DEBUG */
static INLINE struct pipe_screen *
debug_screen_wrap(struct pipe_screen *screen)
{
#ifdef DEBUG
#if defined(GALLIUM_RBUG)
screen = rbug_screen_create(screen);
@ -46,6 +51,8 @@ debug_screen_wrap(struct pipe_screen *screen)
screen = noop_screen_create(screen);
#endif
#endif /* DEBUG */
return screen;
}