From 1683e6633d023703c897c12c7cc2d5ae0548ffc7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jaakko=20Ker=C3=A4nen?= Date: Sun, 5 Mar 2017 13:48:26 +0200 Subject: [PATCH] Fixed|MSVC|Debug: Build failure --- doomsday/sdk/libgui/src/graphics/glbuffer.cpp | 5 ++++- doomsday/sdk/libgui/src/graphics/gldrawqueue.cpp | 1 + doomsday/sdk/libgui/src/graphics/glstate.cpp | 5 ++++- 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/doomsday/sdk/libgui/src/graphics/glbuffer.cpp b/doomsday/sdk/libgui/src/graphics/glbuffer.cpp index f16903ac3f..931cccafab 100644 --- a/doomsday/sdk/libgui/src/graphics/glbuffer.cpp +++ b/doomsday/sdk/libgui/src/graphics/glbuffer.cpp @@ -24,6 +24,10 @@ namespace de { +#ifdef DENG2_DEBUG +extern int GLDrawQueue_queuedElems; +#endif + using namespace internal; using namespace gl; @@ -402,7 +406,6 @@ void GLBuffer::draw(DrawRanges const *ranges) const ++drawCounter; #ifdef DENG2_DEBUG - extern int GLDrawQueue_queuedElems; DENG2_ASSERT(GLDrawQueue_queuedElems == 0); #endif diff --git a/doomsday/sdk/libgui/src/graphics/gldrawqueue.cpp b/doomsday/sdk/libgui/src/graphics/gldrawqueue.cpp index dbbcd1ccb6..45e174e565 100644 --- a/doomsday/sdk/libgui/src/graphics/gldrawqueue.cpp +++ b/doomsday/sdk/libgui/src/graphics/gldrawqueue.cpp @@ -27,6 +27,7 @@ namespace de { #ifdef DENG2_DEBUG +extern int GLDrawQueue_queuedElems; int GLDrawQueue_queuedElems = 0; #endif diff --git a/doomsday/sdk/libgui/src/graphics/glstate.cpp b/doomsday/sdk/libgui/src/graphics/glstate.cpp index ba1be52ad6..831570510c 100644 --- a/doomsday/sdk/libgui/src/graphics/glstate.cpp +++ b/doomsday/sdk/libgui/src/graphics/glstate.cpp @@ -28,6 +28,10 @@ namespace de { +#ifdef DENG2_DEBUG +extern int GLDrawQueue_queuedElems; +#endif + namespace internal { enum Property { @@ -648,7 +652,6 @@ void GLState::apply() const LIBGUI_ASSERT_GL_OK(); #ifdef DENG2_DEBUG - extern int GLDrawQueue_queuedElems; DENG2_ASSERT(GLDrawQueue_queuedElems == 0); #endif