1 # Copyright (C) 2013-2019 CEA/DEN, EDF R&D, OPEN CASCADE
3 # This library is free software; you can redistribute it and/or
4 # modify it under the terms of the GNU Lesser General Public
5 # License as published by the Free Software Foundation; either
6 # version 2.1 of the License, or (at your option) any later version.
8 # This library is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 # Lesser General Public License for more details.
13 # You should have received a copy of the GNU Lesser General Public
14 # License along with this library; if not, write to the Free Software
15 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
19 # Author: Roman NIKOLAEV
22 # OpenCascade detection for Salome
24 # !! Please read the generic detection procedure in SalomeMacros.cmake !!
27 # TODO: RNV: Check different OCCT layouts !!!
28 SALOME_FIND_PACKAGE_AND_DETECT_CONFLICTS(OpenCASCADE OpenCASCADE_INCLUDE_DIR 2)
32 IF(NOT CAS_FIND_QUIETLY)
33 MESSAGE(STATUS "Found OpenCascade version: ${OpenCASCADE_VERSION}")
36 # OPENCASCADE definitions
37 SET(OpenCascade_DEFINITIONS ${OpenCASCADE_C_FLAGS} ${OpenCASCADE_CXX_FLAGS})
38 SET(OpenCascade_LDFLAGS ${OpenCASCADE_LINKER_FLAGS})
40 SALOME_ACCUMULATE_HEADERS(OpenCASCADE_INCLUDE_DIR)
41 SALOME_ACCUMULATE_ENVIRONMENT(LD_LIBRARY_PATH ${OpenCASCADE_LIBRARY_DIR})
44 # TODO: Detect OpenCASCADE if it is distributed without CMake configuration.
45 IF(NOT CAS_FIND_QUIETLY)
46 MESSAGE(STATUS "Could not find OpenCASCADE ...")