From 9b9726dff2d76b30a9852b8449a314730b4a2d97 Mon Sep 17 00:00:00 2001 From: adam Date: Mon, 14 Mar 2011 11:30:40 +0000 Subject: [PATCH] *** empty log message *** --- salome_adm/cmake_files/FindPLATFORM.cmake | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/salome_adm/cmake_files/FindPLATFORM.cmake b/salome_adm/cmake_files/FindPLATFORM.cmake index a49a8c507..4b08dbf0f 100644 --- a/salome_adm/cmake_files/FindPLATFORM.cmake +++ b/salome_adm/cmake_files/FindPLATFORM.cmake @@ -42,12 +42,21 @@ ENDIF(NOT CMAKE_BUILD_TYPE) IF(WINDOWS) ELSE(WINDOWS) - SET(TROLL_VAL $ENV{I_AM_A_TROLL_I_DO_NOT_FIX_${MODULE}_WARNINGS}) - IF(X${TROLL_VAL} STREQUAL X1) - ELSE(X${TROLL_VAL} STREQUAL X1) + SET(ADD_WERROR ON) + SET(NAMES ACCEPT_SALOME_WARNINGS ACCEPT_${MODULE}_WARNINGS I_AM_A_TROLL_I_DO_NOT_FIX_${MODULE}_WARNINGS) + FOREACH(name ${NAMES}) + SET(VAL $ENV{${name}}) + IF(X${VAL} STREQUAL X0) + SET(ADD_WERROR ON) + ENDIF(X${VAL} STREQUAL X0) + IF(X${VAL} STREQUAL X1) + SET(ADD_WERROR OFF) + ENDIF(X${VAL} STREQUAL X1) + ENDFOREACH(name ${NAMES}) + IF(ADD_WERROR) SET(CMAKE_C_FLAGS "-Werror") SET(CMAKE_CXX_FLAGS "-Werror") - ENDIF(X${TROLL_VAL} STREQUAL X1) + ENDIF(ADD_WERROR) ENDIF(WINDOWS) IF(CMAKE_BUILD_TYPE) -- 2.39.2