changed the name of the project

parent b6482afb
......@@ -2,7 +2,7 @@
#----------------------------------------------------------------------------
# Setup the project
cmake_minimum_required(VERSION 2.6 FATAL_ERROR)
project(B1)
project(cosmic_rays)
#----------------------------------------------------------------------------
# Find Geant4 package, activating all available UI and Vis drivers by default
......@@ -28,14 +28,31 @@ include_directories(${PROJECT_SOURCE_DIR}/include)
# Locate sources and headers for this project
# NB: headers are included so they will show up in IDEs
#
file(GLOB sources ${PROJECT_SOURCE_DIR}/src/*.cc)
file(GLOB headers ${PROJECT_SOURCE_DIR}/include/*.hh)
set(PROJECT_SRC
src/B1ActionInitialization.cc
src/B1DetectorConstruction.cc
src/B1EventAction.cc
src/B1PrimaryGeneratorAction.cc
src/B1RunAction.cc
src/B1SteppingAction.cc
)
set(PROJECT_HEADER
include/B1ActionInitialization.hh
include/B1DetectorConstruction.hh
include/B1EventAction.hh
include/B1PrimaryGeneratorAction.hh
include/B1RunAction.hh
include/B1SteppingAction.hh
include/B1Analysis.hh
)
#----------------------------------------------------------------------------
# Add the executable, and link it to the Geant4 libraries
#
add_executable(exampleB1 exampleB1.cc ${sources} ${headers})
target_link_libraries(exampleB1 ${Geant4_LIBRARIES})
add_executable(cosmic_rays cosmic_rays.cc ${PROJECT_SRC} ${PROJECT_HEADER})
target_link_libraries(cosmic_rays ${Geant4_LIBRARIES})
#----------------------------------------------------------------------------
# Copy all scripts to the build directory, i.e. the directory in which we
......@@ -59,15 +76,10 @@ foreach(_script ${EXAMPLEB1_SCRIPTS})
)
endforeach()
#----------------------------------------------------------------------------
# For internal Geant4 use - but has no effect if you build this
# example standalone
#
add_custom_target(B1 DEPENDS exampleB1)
#----------------------------------------------------------------------------
# Install the executable to 'bin' directory under CMAKE_INSTALL_PREFIX
#
install(TARGETS exampleB1 DESTINATION bin)
install(TARGETS cosmic_rays DESTINATION bin)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment