# - Try to find GEANT4 # Once done this will define # # GEANT4_FOUND - system has GEANT4 # GEANT4_INCLUDE_DIR - the GEANT4 include directory # GEANT4_LIBRARIES - The libraries needed to use GEANT4 # GEANT4_DEFINITIONS - Compiler switches required for using GEANT4 # if (GEANT4_INCLUDE_DIR AND GEANT4_LIBRARY_DIR) SET (GEANT4_INCLUDE_DIR GEANT4_INCLUDE_DIR-NOTFOUND) SET (GEANT4_LIB_DIR GEANT4_LIB_DIR-NOTFOUND) SET (GEANT4_PLISTS_LIB_DIR GEANT4_PLISTS_LIB_DIR-NOTFOUND) endif (GEANT4_INCLUDE_DIR AND GEANT4_LIBRARY_DIR) FIND_PATH(GEANT4_INCLUDE_DIR NAMES G4Event.hh PATHS /misc/cbmsoft/Debian3.1/transport/geant4/include ${ROOTSIM}/transport/geant4/include NO_DEFAULT_PATH ) SET(GEANT4_INCLUDE_DIR /misc/cbmsoft/Debian3.1/transport/geant4/include /misc/cbmsoft/Debian3.1/transport/geant4/source/interfaces/common/include /misc/cbmsoft/Debian3.1/transport/geant4/physics_lists/hadronic/Packaging/include /misc/cbmsoft/Debian3.1/transport/geant4/physics_lists/hadronic/QGSP/include ${ROOTSIM}/transport/geant4/include ${ROOTSIM}/transport/geant4/source/interfaces/common/include ${ROOTSIM}/transport/geant4/physics_lists/hadronic/Packaging/include ${ROOTSIM}/transport/geant4/physics_lists/hadronic/QGSP/include ) FIND_PATH(GEANT4_LIB_DIR NAMES libG4baryons.so PATHS /misc/cbmsoft/Debian3.1/transport/geant4/lib/Linux-g++ ${ROOTSIM}/transport/geant4/lib/Linux-g++ NO_DEFAULT_PATH ) FIND_PATH(GEANT4_PLISTS_LIB_DIR NAMES libLHEP.a PATHS /misc/cbmsoft/Debian3.1/transport/geant4/lib/plists/Linux-g++ ${ROOTSIM}/transport/geant4/lib/plists/Linux-g++ NO_DEFAULT_PATH ) IF (GEANT4_PLISTS_LIB_DIR AND GEANT4_LIB_DIR) SET(GEANT4_LIBRARY_DIR ${GEANT4_PLISTS_LIB_DIR} ${GEANT4_LIB_DIR}) ENDIF (GEANT4_PLISTS_LIB_DIR AND GEANT4_LIB_DIR) if (GEANT4_INCLUDE_DIR AND GEANT4_LIBRARY_DIR) set(GEANT4_FOUND TRUE) endif (GEANT4_INCLUDE_DIR AND GEANT4_LIBRARY_DIR) if (GEANT4_FOUND) if (NOT GEANT4_FIND_QUIETLY) message(STATUS "Found GEANT4: ${GEANT4_LIBRARY_DIR}") endif (NOT GEANT4_FIND_QUIETLY) SET(LD_LIBRARY_PATH ${LD_LIBRARY_PATH} ${GEANT4_LIBRARY_DIR}) else (GEANT4_FOUND) if (GEANT4_FIND_REQUIRED) message(FATAL_ERROR "Could NOT find GEANT4") endif (GEANT4_FIND_REQUIRED) endif (GEANT4_FOUND)