moved warning avoidance over to c files

This commit is contained in:
AdenKoperczak 2024-09-19 14:37:35 -04:00
parent 2cd0a16028
commit 797f26e461
6 changed files with 41 additions and 3 deletions

View file

@ -599,11 +599,11 @@ target_include_directories(supercell-wx PUBLIC ${scwx-qt_SOURCE_DIR}/source)
target_compile_options(scwx-qt PRIVATE
$<$<CXX_COMPILER_ID:MSVC>:/W4 /WX>
$<$<NOT:$<CXX_COMPILER_ID:MSVC>>:-Wall -Wextra -Wpedantic -Werror -Wno-error=delete-non-abstract-non-virtual-dtor>
$<$<NOT:$<CXX_COMPILER_ID:MSVC>>:-Wall -Wextra -Wpedantic -Werror>
)
target_compile_options(supercell-wx PRIVATE
$<$<CXX_COMPILER_ID:MSVC>:/W4 /WX>
$<$<NOT:$<CXX_COMPILER_ID:MSVC>>:-Wall -Wextra -Wpedantic -Werror -Wno-error=delete-non-abstract-non-virtual-dtor>
$<$<NOT:$<CXX_COMPILER_ID:MSVC>>:-Wall -Wextra -Wpedantic -Werror>
)
if (MSVC)

View file

@ -1,7 +1,16 @@
#pragma once
#if defined(__clang__)
# pragma clang diagnostic push
# pragma clang diagnostic ignored "-Wdelete-non-abstract-non-virtual-dtor"
#endif
#include <QOpenGLFunctions_3_3_Core>
#if defined(__clang__)
# pragma clang diagnostic pop
#endif
#define SCWX_GL_CHECK_ERROR() \
{ \
GLenum err; \

View file

@ -1,6 +1,16 @@
#pragma once
#if defined(__clang__)
# pragma clang diagnostic push
# pragma clang diagnostic ignored "-Wdelete-non-abstract-non-virtual-dtor"
#endif
#include <scwx/awips/phenomenon.hpp>
#if defined(__clang__)
# pragma clang diagnostic pop
#endif
#include <scwx/qt/map/draw_layer.hpp>
#include <scwx/qt/types/text_event_key.hpp>

View file

@ -1,8 +1,17 @@
#if defined(__clang__)
# pragma clang diagnostic push
# pragma clang diagnostic ignored "-Wdelete-non-abstract-non-virtual-dtor"
#endif
#include <scwx/qt/settings/text_settings.hpp>
#include <scwx/qt/types/text_types.hpp>
#include <boost/algorithm/string.hpp>
#if defined(__clang__)
# pragma clang diagnostic pop
#endif
namespace scwx
{
namespace qt

View file

@ -10,8 +10,18 @@
#include <sstream>
#include <boost/algorithm/string.hpp>
#if defined(__clang__)
# pragma clang diagnostic push
# pragma clang diagnostic ignored "-Wunused-parameter"
#endif
#include <boost/gil.hpp>
#if defined(__clang__)
# pragma clang diagnostic pop
#endif
#include <hsluv.h>
namespace scwx

View file

@ -260,7 +260,7 @@ target_include_directories(wxdata INTERFACE ${scwx-data_SOURCE_DIR}/include)
target_compile_options(wxdata PRIVATE
$<$<CXX_COMPILER_ID:MSVC>:/W4 /WX>
$<$<NOT:$<CXX_COMPILER_ID:MSVC>>:-Wall -Wextra -Wpedantic -Werror -Wno-error=unused-parameter>
$<$<NOT:$<CXX_COMPILER_ID:MSVC>>:-Wall -Wextra -Wpedantic -Werror>
)
if (MSVC)