From 32f8f40a4aa13fb16eaf0a0f1b9f6fa1ed72633c Mon Sep 17 00:00:00 2001 From: JohnHolmesII Date: Tue, 14 May 2019 21:33:01 -0700 Subject: [PATCH] Disable warnings for stb_image.cpp. Should this file be moved to 3rdparty? --- rpcs3/stb_image.cpp | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/rpcs3/stb_image.cpp b/rpcs3/stb_image.cpp index 0cc9a34afe..feeee513ba 100644 --- a/rpcs3/stb_image.cpp +++ b/rpcs3/stb_image.cpp @@ -1,4 +1,28 @@ #include "stdafx.h" // Defines STB_IMAGE_IMPLEMENTATION *once* for stb_image.h includes (Should this be placed somewhere else?) #define STB_IMAGE_IMPLEMENTATION + +// This header generates lots of errors, so we ignore those (not rpcs3 code) +#if defined(__clang__) +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Weverything" #include +#pragma clang diagnostic pop + +#elif defined(__GNUC__) || defined(__GNUG__) +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wall" +#pragma GCC diagnostic ignored "-Wextra" +#include +#pragma GCC diagnostic pop + +#elif defined(_MSC_VER) +// TODO Turn off warnings for MSVC. Using the normal push warning levels simply +// creates a new warning about warnings being supressed (ie fuck msvc) +// #pragma warning( push, 4 ) +#include +// #pragma warning( pop ) + +#else +#include +#endif