From 1fe29a83336112873ce1b1fb3f032f4d718702b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Tue, 31 May 2022 19:48:37 +0200 Subject: [PATCH] DebugTools: fix WebGL 2 build on Emscripten < 2.0.17. Eheh. But given that nobody complained for so long, it means nobody uses those ancient versions anymore. Or nobody uses DebugTools, that's more like it. --- src/Magnum/DebugTools/BufferData.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Magnum/DebugTools/BufferData.cpp b/src/Magnum/DebugTools/BufferData.cpp index b5ba55bd8..9b5a55662 100644 --- a/src/Magnum/DebugTools/BufferData.cpp +++ b/src/Magnum/DebugTools/BufferData.cpp @@ -24,6 +24,9 @@ DEALINGS IN THE SOFTWARE. */ +/* Don't compile this file on Emscripten < 2.0.17. Because it's easier to do + that here than through CMake. */ +#if !defined(__EMSCRIPTEN_major__) || __EMSCRIPTEN_major__*10000 + __EMSCRIPTEN_minor__*100 + __EMSCRIPTEN_tiny__ >= 20017 #include "BufferData.h" #include @@ -34,7 +37,6 @@ #include #endif -#if !(defined(MAGNUM_TARGET_WEBGL) && (defined(MAGNUM_TARGET_GLES2) || __EMSCRIPTEN_major__*10000 + __EMSCRIPTEN_minor__*100 + __EMSCRIPTEN_tiny__ < 20017)) namespace Magnum { namespace DebugTools { #if defined(MAGNUM_BUILD_DEPRECATED) && !defined(MAGNUM_TARGET_WEBGL)