]> SALOME platform Git repositories - modules/yacs.git/commitdiff
Salome HOME
Merge branch 'master' of https://git.salome-platform.org/git/modules/yacs V8_0_pre
authorAnthony Geay <anthony.geay@edf.fr>
Fri, 30 Oct 2015 13:10:48 +0000 (14:10 +0100)
committerAnthony Geay <anthony.geay@edf.fr>
Fri, 30 Oct 2015 13:10:48 +0000 (14:10 +0100)
adm/cmake/SalomeSetupPlatform.cmake
src/runtime/RuntimeSALOME.cxx

index 1548daeafc20c5b924a6b0f81c2a0171ee73e550..6d8fbf1d2bd6a7357f2ec08ec3f4251b7efa0115 100755 (executable)
@@ -165,3 +165,17 @@ IF(NOT WIN32)
     SET(CMAKE_C_FLAGS    "${CMAKE_C_FLAGS} -fprofile-arcs -ftest-coverage")
   ENDIF()
 ENDIF()
+
+# C++11 support
+INCLUDE(CheckCXXCompilerFlag)
+CHECK_CXX_COMPILER_FLAG("-std=c++11" COMPILER_SUPPORTS_CXX11)
+CHECK_CXX_COMPILER_FLAG("-std=c++0x" COMPILER_SUPPORTS_CXX0X)
+IF(COMPILER_SUPPORTS_CXX11)
+    MESSAGE(STATUS "Enable C++11 support")
+    SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
+ELSEIF(COMPILER_SUPPORTS_CXX0X)
+    MESSAGE(STATUS "Enable C++0x support")
+    SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++0x")
+ELSE()
+    MESSAGE(WARNING "Compiler ${CMAKE_CXX_COMPILER} has no C++11 support.")
+ENDIF()
index 0ac34e183a676cd83e037f493d6d6e1f60bf011e..6fb3e1700ed3c72bbbc40c42f24db8c41b1ea6a6 100644 (file)
@@ -644,7 +644,7 @@ InputPort * RuntimeSALOME::createInputPort(const std::string& name,
     {
       stringstream msg;
       msg << "Cannot create " << impl << " InputPort" ;
-      msg << " ("__FILE__ << ":" << __LINE__ << ")";
+      msg << " (" << __FILE__ << ":" << __LINE__ << ")";
       throw Exception(msg.str());
     }
 }
@@ -674,7 +674,7 @@ OutputPort * RuntimeSALOME::createOutputPort(const std::string& name,
     {
       stringstream msg;
       msg << "Cannot create " << impl << " OutputPort" ;
-      msg << " ("__FILE__ << ":" << __LINE__ << ")";
+      msg << " (" << __FILE__ << ":" << __LINE__ << ")";
       throw Exception(msg.str());
     }
 }
@@ -745,7 +745,7 @@ InputPort* RuntimeSALOME::adapt(InputPort* source,
     {
       stringstream msg;
       msg << "Cannot adapt " << imp_source << " InputPort to " << impl;
-      msg << " ("__FILE__ << ":" << __LINE__ << ")";
+      msg << " (" << __FILE__ << ":" << __LINE__ << ")";
       throw ConversionException(msg.str());
     }
 }
@@ -1065,7 +1065,7 @@ InputPort* RuntimeSALOME::adapt(InputXmlPort* source,
     {
       stringstream msg;
       msg << "Cannot connect InputXmlPort to " << impl << " implementation";
-      msg << " ("__FILE__ << ":" << __LINE__ << ")";
+      msg << " (" << __FILE__ << ":" << __LINE__ << ")";
       throw ConversionException(msg.str());
     }
 }
@@ -1759,7 +1759,7 @@ InputPort* RuntimeSALOME::adapt(InputCppPort* source,
     {
       stringstream msg;
       msg << "Cannot connect InputCppPort to " << impl << " implementation";
-      msg << " ("__FILE__ << ":" << __LINE__ << ")";
+      msg << " (" << __FILE__ << ":" << __LINE__ << ")";
       throw ConversionException(msg.str());
     }
 }