From 1457e50ebec24ba16f120604b2747f153845123f Mon Sep 17 00:00:00 2001 From: ageay Date: Mon, 19 Mar 2012 15:01:13 +0000 Subject: [PATCH] cmakization of MED. --- salome_adm/cmake_files/FindCPPUNIT.cmake | 9 ++++++++- salome_adm/cmake_files/FindHDF5.cmake | 12 +++++++++--- 2 files changed, 17 insertions(+), 4 deletions(-) diff --git a/salome_adm/cmake_files/FindCPPUNIT.cmake b/salome_adm/cmake_files/FindCPPUNIT.cmake index 722dec508..656816005 100644 --- a/salome_adm/cmake_files/FindCPPUNIT.cmake +++ b/salome_adm/cmake_files/FindCPPUNIT.cmake @@ -79,7 +79,12 @@ IF(CPPUNIT_STATUS) FIND_PATH(CPPUNIT_INCLUDE_DIR ${CPPUNIT_INCLUDE_TO_FIND} PATHS ${CPPUNIT_INCLUDE_PATHS} ${CPPUNIT_FIND_PATHS_OPTION}) IF(CPPUNIT_INCLUDE_DIR) IF(CPPUNIT_ROOT_USER) - SET(CPPUNIT_INCLUDES -I${CPPUNIT_INCLUDE_DIR}) + SET(CPPUNIT_INCLUDES -I${CPPUNIT_INCLUDE_DIR})# to be removed + IF(${CPPUNIT_INCLUDE_DIR} STREQUAL /usr/include) + SET(CPPUNIT_INCLUDES_DIR) + ELSE(${CPPUNIT_INCLUDE_DIR} STREQUAL /usr/include) + SET(CPPUNIT_INCLUDES_DIR ${CPPUNIT_INCLUDE_DIR}) + ENDIF(${CPPUNIT_INCLUDE_DIR} STREQUAL /usr/include) ENDIF(CPPUNIT_ROOT_USER) MESSAGE(STATUS "${CPPUNIT_INCLUDE_TO_FIND} found in ${CPPUNIT_INCLUDE_DIR}") ELSE(CPPUNIT_INCLUDE_DIR) @@ -130,8 +135,10 @@ ENDIF(CPPUNIT_STATUS) IF(CPPUNIT_STATUS) SET(CPPUNIT_IS_OK 1) + SET(CPPUNIT_FLAGS) IF(WINDOWS) SET(CPPUNIT_INCLUDES ${CPPUNIT_INCLUDES} -DCPPUNIT_DLL) + SET(CPPUNIT_FLAGS "-DCPPUNIT_DLL") ENDIF(WINDOWS) ELSE(CPPUNIT_STATUS) IF(CPPUNIT_IS_MANDATORY) diff --git a/salome_adm/cmake_files/FindHDF5.cmake b/salome_adm/cmake_files/FindHDF5.cmake index c3d52e6a2..7991bce83 100644 --- a/salome_adm/cmake_files/FindHDF5.cmake +++ b/salome_adm/cmake_files/FindHDF5.cmake @@ -103,9 +103,15 @@ IF(HDF5_STATUS) FIND_PATH(HDF5_INCLUDE_DIR ${HDF5_INCLUDE_TO_FIND} PATHS ${HDF5_INCLUDE_PATHS} ${HDF5_FIND_PATHS_OPTION}) IF(HDF5_INCLUDE_DIR) IF(HDF5_ROOT_USER) - SET(HDF5_INCLUDES -I${HDF5_INCLUDE_DIR}) + SET(HDF5_INCLUDES -I${HDF5_INCLUDE_DIR})# to be removed + IF(${HDF5_INCLUDE_DIR} STREQUAL /usr/include) + SET(HDF5_INCLUDES_DIR) + ELSE(${HDF5_INCLUDE_DIR} STREQUAL /usr/include) + SET(HDF5_INCLUDES_DIR ${HDF5_INCLUDE_DIR}) + ENDIF(${HDF5_INCLUDE_DIR} STREQUAL /usr/include) ENDIF(HDF5_ROOT_USER) - SET(HDF5_INCLUDES -DH5_USE_16_API -D_HDF5USEDLL_ ${HDF5_INCLUDES}) + SET(HDF5_FLAGS "-DH5_USE_16_API -D_HDF5USEDLL_") + SET(HDF5_INCLUDES -DH5_USE_16_API -D_HDF5USEDLL_ ${HDF5_INCLUDES})# to be removed MESSAGE(STATUS "${HDF5_INCLUDE_TO_FIND} found in ${HDF5_INCLUDE_DIR}") ELSE(HDF5_INCLUDE_DIR) SET(HDF5_STATUS 0) @@ -155,7 +161,7 @@ ENDIF(HDF5_STATUS) # ---- IF(HDF5_STATUS) - SET(HDF5_CPPFLAGS ${HDF5_INCLUDES}) + SET(HDF5_CPPFLAGS ${HDF5_INCLUDES})# to be removed ELSE(HDF5_STATUS) IF(HDF5_IS_MANDATORY) MESSAGE(FATAL_ERROR "hdf5 not found ... mandatory ... abort") -- 2.39.2