From 226974bf2c595ae1c775339d3284cf864b365ca7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Sun, 24 May 2015 17:33:15 +0200 Subject: [PATCH] TextureTools: work around compiler warning. --- src/Magnum/Shaders/Implementation/CreateCompatibilityShader.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Magnum/Shaders/Implementation/CreateCompatibilityShader.h b/src/Magnum/Shaders/Implementation/CreateCompatibilityShader.h index 1cccfa369..472f3a9c1 100644 --- a/src/Magnum/Shaders/Implementation/CreateCompatibilityShader.h +++ b/src/Magnum/Shaders/Implementation/CreateCompatibilityShader.h @@ -31,7 +31,9 @@ #include "Magnum/Extensions.h" #include "Magnum/Shader.h" -#ifdef MAGNUM_BUILD_STATIC +/* Enable only when compiling Shaders library and thus work around + "static symbol not used" warning when using this file for TextureTools */ +#if defined(MAGNUM_BUILD_STATIC) && defined(MAGNUM_SHADERS_EXPORT) static void importShaderResources() { CORRADE_RESOURCE_INITIALIZE(MagnumShaders_RCS) }