Warning, /geant4/examples/extended/medical/dna/jetcounter/CMakeLists.txt is written in an unsupported language. File is not indexed.
0001 cmake_minimum_required(VERSION 3.16...3.27)
0002 project(jetcounter)
0003
0004 # GEANT4 core
0005 find_package(Geant4 REQUIRED ui_all vis_all)
0006 include(${Geant4_USE_FILE})
0007 include_directories(${PROJECT_SOURCE_DIR}/include)
0008
0009 # root
0010 find_package(ROOT)
0011 include_directories(${ROOT_INCLUDE_DIRS})
0012
0013
0014 set(CMAKE_BUILD_TYPE release)
0015
0016 # User code
0017 file(GLOB sources ${PROJECT_SOURCE_DIR}/src/*.cc)
0018 file(GLOB headers ${PROJECT_SOURCE_DIR}/include/*.hh)
0019
0020 add_executable(jetcounter jetcounter.cc ${sources} ${headers})
0021 target_link_libraries(jetcounter ${Geant4_LIBRARIES})
0022 target_link_libraries(jetcounter ${ROOT_LIBRARIES})
0023
0024 set(OTHERS
0025 init_phys.in primaries.in run.mac vis.mac
0026 energy.spectrum
0027 plot.py)
0028
0029 foreach(_other ${OTHERS})
0030 configure_file(
0031 ${PROJECT_SOURCE_DIR}/${_other}
0032 ${PROJECT_BINARY_DIR}/${_other}
0033 COPYONLY
0034 )
0035 endforeach()