diff options
author | Ben Boeckel <ben.boeckel@kitware.com> | 2014-11-17 18:10:07 -0500 |
---|---|---|
committer | Ben Boeckel <ben.boeckel@kitware.com> | 2014-11-17 18:19:54 -0500 |
commit | 5680c9cac7725ad265eb01336f80366a2dfddce3 (patch) | |
tree | 8412c91e968f98fd7bd9d50225f43b650cb9aa8e | |
parent | msys: look in msys' directory for files (diff) | |
download | monero-5680c9cac7725ad265eb01336f80366a2dfddce3.tar.xz |
msys: factor out -Werror on msys
There are Windows-related warnings turned into errors here.
-rw-r--r-- | CMakeLists.txt | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index b8bc83a07..43d03a879 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -144,7 +144,10 @@ else() else() set(ARCH_FLAG "-march=${ARCH}") endif() - set(WARNINGS "-Wall -Wextra -Wpointer-arith -Wundef -Wvla -Wwrite-strings -Werror -Wno-error=extra -Wno-error=deprecated-declarations -Wno-error=sign-compare -Wno-error=strict-aliasing -Wno-error=type-limits -Wno-unused-parameter -Wno-error=unused-variable -Wno-error=undef -Wno-error=uninitialized") + set(WARNINGS "-Wall -Wextra -Wpointer-arith -Wundef -Wvla -Wwrite-strings -Wno-error=extra -Wno-error=deprecated-declarations -Wno-error=sign-compare -Wno-error=strict-aliasing -Wno-error=type-limits -Wno-unused-parameter -Wno-error=unused-variable -Wno-error=undef -Wno-error=uninitialized") + if(NOT MINGW) + set(WARNINGS "${WARNINGS} -Werror") + endif() if(CMAKE_C_COMPILER_ID STREQUAL "Clang") set(WARNINGS "${WARNINGS} -Wno-error=mismatched-tags -Wno-error=null-conversion -Wno-overloaded-shift-op-parentheses -Wno-error=shift-count-overflow -Wno-error=tautological-constant-out-of-range-compare -Wno-error=unused-private-field -Wno-error=unneeded-internal-declaration") else() |