You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@geode.apache.org by bb...@apache.org on 2020/06/09 20:17:27 UTC

[geode-native] branch develop updated: GEODE-8207: Enfore No Unknown Pragmas as Error (#608)

This is an automated email from the ASF dual-hosted git repository.

bbender pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/geode-native.git


The following commit(s) were added to refs/heads/develop by this push:
     new f994444  GEODE-8207: Enfore No Unknown Pragmas as Error (#608)
f994444 is described below

commit f99444426e0a5d6fa637a4c175fa9ea517f384cb
Author: M. Oleske <mo...@users.noreply.github.com>
AuthorDate: Tue Jun 9 13:17:16 2020 -0700

    GEODE-8207: Enfore No Unknown Pragmas as Error (#608)
---
 CMakeLists.txt                               | 2 --
 cppcache/integration/framework/GfshExecute.h | 5 ++++-
 cppcache/src/TcrMessage.cpp                  | 4 ++++
 cryptoimpl/SSLImpl.hpp                       | 7 +++++++
 4 files changed, 15 insertions(+), 3 deletions(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 106c5b8..73c50e1 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -215,7 +215,6 @@ elseif (CMAKE_CXX_COMPILER_ID MATCHES "GNU")
   target_compile_options(_WarningsAsError INTERFACE
     -Werror
     -Wall
-    -Wno-unknown-pragmas #TODO fix
     -Wno-unused-variable #TODO fix
     -Wpedantic
     # -Wshadow TODO fix
@@ -241,7 +240,6 @@ elseif(CMAKE_CXX_COMPILER_ID MATCHES "Clang")
     -Werror
     -Wall
     -Wextra
-    -Wno-unknown-pragmas #TODO fix
     -Wno-unused-variable #TODO fix
     -Wno-unused-function #TODO fix
     -Wno-used-but-marked-unused #TODO fix
diff --git a/cppcache/integration/framework/GfshExecute.h b/cppcache/integration/framework/GfshExecute.h
index acc8411..897e77a 100644
--- a/cppcache/integration/framework/GfshExecute.h
+++ b/cppcache/integration/framework/GfshExecute.h
@@ -26,12 +26,15 @@
 #include <string>
 
 #include <geode/Exception.hpp>
-
+#ifdef _SOLARIS
 #pragma error_messages(off, oklambdaretmulti, wvarhidemem, \
                        w_constexprnonlitret, explctspectypename)
+#endif
 #include <boost/process.hpp>
+#ifdef _SOLARIS
 #pragma error_messages(on, oklambdaretmulti, wvarhidemem, \
                        w_constexprnonlitret, explctspectypename)
+#endif
 
 #include "Gfsh.h"
 #include "TestConfig.h"
diff --git a/cppcache/src/TcrMessage.cpp b/cppcache/src/TcrMessage.cpp
index 9f1c80b..43894c2 100644
--- a/cppcache/src/TcrMessage.cpp
+++ b/cppcache/src/TcrMessage.cpp
@@ -42,7 +42,9 @@
 #include "util/JavaModifiedUtf8.hpp"
 #include "util/string.hpp"
 
+#ifdef _SOLARIS
 #pragma error_messages(off, SEC_UNINITIALIZED_MEM_READ)
+#endif
 
 namespace apache {
 namespace geode {
@@ -3322,7 +3324,9 @@ TcrMessageHelper::ChunkObjectType TcrMessageHelper::readChunkPartHeader(
   return ChunkObjectType::OBJECT;
 }
 
+#ifdef _SOLARIS
 #pragma error_messages(default, SEC_UNINITIALIZED_MEM_READ)
+#endif
 
 }  // namespace client
 }  // namespace geode
diff --git a/cryptoimpl/SSLImpl.hpp b/cryptoimpl/SSLImpl.hpp
index 2c61763..a70e965 100644
--- a/cryptoimpl/SSLImpl.hpp
+++ b/cryptoimpl/SSLImpl.hpp
@@ -20,12 +20,17 @@
 #ifndef GEODE_CRYPTOIMPL_SSLIMPL_H_
 #define GEODE_CRYPTOIMPL_SSLIMPL_H_
 
+#ifdef _WIN32
 #pragma warning(push)
 #pragma warning(disable : 4311)
 #pragma warning(disable : 4302)
+#endif
+
 #pragma pack(push)
 
+#ifdef _WIN32
 #pragma error_messages(off, macroredef)
+#endif
 
 #include <ace/INET_Addr.h>
 #include <ace/OS.h>
@@ -35,7 +40,9 @@
 #include <ace/SSL/SSL_SOCK_Connector.h>
 #include <ace/Time_Value.h>
 
+#ifdef _WIN32
 #pragma error_messages(on, macroredef)
+#endif
 
 #pragma pack(pop)