Update: removed request of 4 points in ITS (Renu)
[u/mrichter/AliRoot.git] / cmake / modules / FindCLHEP.cmake
CommitLineData
e969a926 1# - Try to find CLHEP
2# Once done this will define
3#
4# CLHEP_FOUND - system has CLHEP
5# CLHEP_INCLUDE_DIR - the CLHEP include directory
6# CLHEP_LIBRARIES - The libraries needed to use CLHEP
7# CLHEP_DEFINITIONS - Compiler switches required for using CLHEP
8#
9
10if (CLHEP_INCLUDE_DIR AND CLHEP_LIBRARY_DIR)
11 SET (CLHEP_INCLUDE_DIR CLHEP_INCLUDE_DIR-NOTFOUND)
12 SET (CLHEP_LIB_DIR CLHEP_LIB_DIR-NOTFOUND)
13 SET (CLHEP_PLISTS_LIB_DIR CLHEP_PLISTS_LIB_DIR-NOTFOUND)
14endif (CLHEP_INCLUDE_DIR AND CLHEP_LIBRARY_DIR)
15
16MESSAGE(STATUS "Looking for CLHEP...")
17
18FIND_PATH(CLHEP_INCLUDE_DIR NAMES CLHEP PATHS
19 ${SIMPATH}/cern/clhep/include
20 NO_DEFAULT_PATH
21)
22
23FIND_PATH(CLHEP_LIBRARY_DIR NAMES libCLHEP.so libCLHEP.dylib PATHS
24 ${SIMPATH}/cern/clhep/lib
25 NO_DEFAULT_PATH
26)
27
28if (CLHEP_INCLUDE_DIR AND CLHEP_LIBRARY_DIR)
29 set(CLHEP_FOUND TRUE)
30endif (CLHEP_INCLUDE_DIR AND CLHEP_LIBRARY_DIR)
31
32if (CLHEP_FOUND)
33 if (NOT CLHEP_FIND_QUIETLY)
34 MESSAGE(STATUS "Looking for CLHEP... - found ${CLHEP_LIBRARY_DIR}")
35# message(STATUS "Found CLHEP: ${CLHEP_LIBRARY_DIR}")
36 SET(LD_LIBRARY_PATH ${LD_LIBRARY_PATH} ${CLHEP_LIBRARY_DIR})
37 endif (NOT CLHEP_FIND_QUIETLY)
38else (CLHEP_FOUND)
39 if (CLHEP_FIND_REQUIRED)
40 message(FATAL_ERROR "Looking for CLHEP... - Not found")
41 endif (CLHEP_FIND_REQUIRED)
42endif (CLHEP_FOUND)
43