From ef9b96de5884d14b34abd02315c1cbc7a523c31a Mon Sep 17 00:00:00 2001 From: halx99 Date: Sun, 14 Jun 2020 15:52:15 +0800 Subject: [PATCH] ios don't support thread local storage --- cocos/platform/CCImage.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cocos/platform/CCImage.cpp b/cocos/platform/CCImage.cpp index 43e1fa794b..f44a552e0b 100644 --- a/cocos/platform/CCImage.cpp +++ b/cocos/platform/CCImage.cpp @@ -41,6 +41,9 @@ THE SOFTWARE. #define STBI_NO_HDR #define STBI_NO_TGA #define STB_IMAGE_IMPLEMENTATION +#if CC_TARGET_PLATFORM == CC_PLATFORM_IOS +#define STBI_NO_THREAD_LOCALS +#endif #include "stb/stb_image.h" extern "C"