Import Geant4 11.0.2 source tree
This commit is contained in:
@@ -29,6 +29,13 @@ add this in the documentation for the changed file as [BUGFIX #BUGNUMBER].
|
||||
* Reverse chronological order (last date on top), please *
|
||||
----------------------------------------------------------
|
||||
|
||||
06 April 2022 - Ben Morgan (cmake-V10-07-56)
|
||||
- Don't add CLHEP_INCLUDE_DIRS directly through include_directories to prevent potential
|
||||
issues with it holding relative paths (reported by Seth Johnson)
|
||||
|
||||
7 March 2022 - Gunter Folger (cmake-V10-07-55)
|
||||
- fix in CMakeCPackOptions.cmake.in to avoid PATH with only /, without \, for g4_small.bmp
|
||||
|
||||
11 February 2022 - Ben Morgan (cmake-V10-07-54)
|
||||
- Apply [GitHub PR 37](https://github.com/Geant4/geant4/pull/37) from gondiaz.
|
||||
- Add G4ptl and G4tasking libraries to link list in geant4-config
|
||||
|
||||
@@ -43,19 +43,6 @@ if(GEANT4_USE_SYSTEM_CLHEP)
|
||||
geant4_save_package_variables(CLHEP CLHEP_DIR)
|
||||
else()
|
||||
set(CLHEP_FOUND TRUE)
|
||||
# TODO: CLHEP_INCLUDE_DIRS still required for windows support
|
||||
# Current way of building DLLs requires build of a temporary
|
||||
# archive lib, and this does not link to dependencies, hence
|
||||
# it does not get their usage requirements.
|
||||
# May be fixable by linking or use of better DLL build mechanism
|
||||
# available in CMake >= 3.4
|
||||
# As other externals will need the same treatment, return
|
||||
# to old CLHEP_INCLUDE_DIRS setting
|
||||
#
|
||||
set(CLHEP_INCLUDE_DIRS "${PROJECT_SOURCE_DIR}/source/externals/clhep/include")
|
||||
|
||||
# All G4*** targets are handled internally to use static or shared
|
||||
# as appropriate, so only need to declare core target name
|
||||
set(CLHEP_LIBRARIES G4clhep)
|
||||
endif()
|
||||
|
||||
@@ -115,7 +102,6 @@ geant4_add_feature(GEANT4_USE_SYSTEM_EXPAT "Using system EXPAT library")
|
||||
|
||||
#-----------------------------------------------------------------------
|
||||
# Find required ZLIB package, defaulting in internal
|
||||
# Rely on ZLIB::ZLIB imported target (since CMake 3.1)
|
||||
option(GEANT4_USE_SYSTEM_ZLIB "Use system zlib library" OFF)
|
||||
if(GEANT4_USE_SYSTEM_ZLIB)
|
||||
find_package(ZLIB REQUIRED)
|
||||
@@ -140,16 +126,14 @@ endif()
|
||||
|
||||
option(GEANT4_USE_TBB "Enable (optional) use of TBB as a tasking backend" ${_default_use_tbb})
|
||||
if(GEANT4_USE_TBB)
|
||||
find_package(TBB REQUIRED)
|
||||
geant4_save_package_variables(TBB TBB_INCLUDE_DIR TBB_LIBRARY TBB_LIBRARY_DEBUG
|
||||
TBB_LIBRARY_RELEASE TBB_ROOT_DIR)
|
||||
find_package(TBB REQUIRED)
|
||||
geant4_save_package_variables(TBB TBB_INCLUDE_DIR TBB_LIBRARY TBB_LIBRARY_DEBUG TBB_LIBRARY_RELEASE TBB_ROOT_DIR)
|
||||
endif()
|
||||
|
||||
geant4_add_feature(GEANT4_USE_TBB "Enable (optional) use of TBB as a tasking backend")
|
||||
|
||||
#-----------------------------------------------------------------------
|
||||
# Find required PTL package, defaulting in internal
|
||||
# Rely on PTL::PTL imported target (since CMake 3.1)
|
||||
# Find required PTL package, defaulting to internal
|
||||
option(GEANT4_USE_SYSTEM_PTL "Use system zlib library" OFF)
|
||||
if(GEANT4_USE_SYSTEM_PTL)
|
||||
find_package(PTL 2.0.0 REQUIRED)
|
||||
@@ -329,13 +313,13 @@ if(GEANT4_USE_ALL_USOLIDS OR GEANT4_USE_PARTIAL_USOLIDS)
|
||||
|
||||
if(GEANT4_USE_ALL_USOLIDS)
|
||||
set(G4GEOM_USE_USOLIDS TRUE)
|
||||
GEANT4_ADD_FEATURE(GEANT4_USE_USOLIDS "Replacing Geant4 solids with all VecGeom equivalents (EXPERIMENTAL)")
|
||||
geant4_add_feature(GEANT4_USE_USOLIDS "Replacing Geant4 solids with all VecGeom equivalents (EXPERIMENTAL)")
|
||||
else()
|
||||
set(G4GEOM_USE_PARTIAL_USOLIDS TRUE)
|
||||
foreach(__g4_usolid_shape ${GEANT4_USE_PARTIAL_USOLIDS_SHAPE_LIST})
|
||||
set(G4GEOM_USE_U${__g4_usolid_shape} TRUE)
|
||||
endforeach()
|
||||
GEANT4_ADD_FEATURE(GEANT4_USE_USOLIDS "Replacing Geant4 solids with VecGeom equivalents for ${GEANT4_USE_PARTIAL_USOLIDS_SHAPE_LIST} (EXPERIMENTAL)")
|
||||
geant4_add_feature(GEANT4_USE_USOLIDS "Replacing Geant4 solids with VecGeom equivalents for ${GEANT4_USE_PARTIAL_USOLIDS_SHAPE_LIST} (EXPERIMENTAL)")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
@@ -376,10 +360,8 @@ if(GEANT4_USE_HDF5)
|
||||
geant4_save_package_variables(HDF5 HDF5_DIR)
|
||||
else()
|
||||
# Otherwise almost certainly used compiler wrapper
|
||||
geant4_save_package_variables(HDF5
|
||||
HDF5_C_COMPILER_EXECUTABLE
|
||||
HDF5_C_LIBRARY_hdf5)
|
||||
endif()
|
||||
geant4_save_package_variables(HDF5 HDF5_C_COMPILER_EXECUTABLE HDF5_C_LIBRARY_hdf5)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
GEANT4_ADD_FEATURE(GEANT4_USE_HDF5 "Building Geant4 analysis library with HDF5 support")
|
||||
geant4_add_feature(GEANT4_USE_HDF5 "Building Geant4 analysis library with HDF5 support")
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
if(CPACK_GENERATOR STREQUAL "NSIS")
|
||||
# There is a bug in NSI that does not handle full unix paths properly.
|
||||
# Make sure there is at least one set of two (2) backlasshes.
|
||||
set(CPACK_PACKAGE_ICON "@PROJECT_SOURCE_DIR@\\cmake\\Templates\\g4_small.bmp")
|
||||
set(CPACK_NSIS_MUI_ICON "@PROJECT_SOURCE_DIR@\\cmake\\Templates\\G4.ico")
|
||||
set(CPACK_NSIS_MUI_UNIICON "@PROJECT_SOURCE_DIR@\\cmake\\Templates\\G4.ico")
|
||||
set(CPACK_NSIS_DISPLAY_NAME "${CPACK_PACKAGE_INSTALL_DIRECTORY}")
|
||||
|
||||
@@ -249,15 +249,6 @@ set(Geant4_system_clhep_FOUND @GEANT4_USE_SYSTEM_CLHEP@)
|
||||
if(Geant4_system_clhep_FOUND)
|
||||
set(Geant4_builtin_clhep_FOUND FALSE)
|
||||
find_dependency(CLHEP @CLHEP_VERSION@ EXACT CONFIG)
|
||||
# Explicitly use include_directories.
|
||||
# - Geant4 and CLHEP use full imported targets with usage requirements,
|
||||
# but ROOT (used in the examples), ignores usage requirements in dictionary
|
||||
# generation steps.
|
||||
# To retain comptibility with examples, explictly include_directories
|
||||
# for CLHEP. This is a *pure workaround* for the use case of a project
|
||||
# using ROOT that generates dictionaries for class headers that
|
||||
# #include Geant4 headers...
|
||||
include_directories(${CLHEP_INCLUDE_DIRS})
|
||||
else()
|
||||
set(Geant4_builtin_clhep_FOUND TRUE)
|
||||
endif()
|
||||
|
||||
Reference in New Issue
Block a user