Skip to content

Commit a1f7f71

Browse files
committed
Import Geant4 9.4.3 source tree
1 parent 0c9e661 commit a1f7f71

File tree

530 files changed

+10790
-10161
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

530 files changed

+10790
-10161
lines changed

CMakeLists.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# 21st September 2010 Ben Morgan
55
#
66
# $Id: CMakeLists.txt,v 1.6 2010-12-08 16:36:34 bmorgan Exp $
7-
# GEANT4 Tag $Name: geant4-09-04-patch-02 $
7+
# GEANT4 Tag $Name: not supported by cvs2svn $
88
#
99

1010
#------------------------------------------------------------------------------
@@ -39,10 +39,10 @@ project(geant4)
3939
# Define the version of the project - can be used to generate sources,
4040
# but just used for CPack the the moment
4141
#
42-
set(${PROJECT_NAME}_VERSION "9.4.2")
42+
set(${PROJECT_NAME}_VERSION "9.4.3")
4343
set(${PROJECT_NAME}_VERSION_MAJOR "9")
4444
set(${PROJECT_NAME}_VERSION_MINOR "4")
45-
set(${PROJECT_NAME}_VERSION_PATCH "2")
45+
set(${PROJECT_NAME}_VERSION_PATCH "3")
4646

4747
#------------------------------------------------------------------------------
4848
# Set up path to internal set of CMake modules.

ReleaseNotes/Patch4.9.4-3.txt

Lines changed: 184 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,184 @@
1+
2+
Geant4 9.4 - patch-03 Release Notes
3+
-----------------------------------
4+
5+
9 December 2011
6+
7+
List of fixes included in this public patch since the public release 9.4.p02:
8+
9+
o Configuration:
10+
-------------
11+
+ Darwin-g++.gmk: modified OGLLIBS settings for proper configuration of
12+
OpenGL libraries in combination with Qt. Allow use of Qt libraries not
13+
installed as Framework. Also addressing problem report #1267.
14+
Removed unnecessary 'gcov' linkage for dynamic libraries.
15+
+ G4UI_BUILD.gmk: added setting of G4INTY_BUILD_XT for OPENGLXM and OIX.
16+
Visualization drivers need Xt, so this covers the case when the user
17+
does not build Xt from G4UI_BUILD flags. Addressing problem report #1250.
18+
19+
o Digits_Hits:
20+
-----------
21+
+ G4THitsMap: removed the print-out of total value, to avoid inconsistency
22+
caused by a class <T> which does not have += operator or cannot be
23+
initilized to 0. Addressing to the problem report #1258.
24+
+ Fixed some Coverity defects for uninitialised pointers in
25+
G4TDigiCollection and G4THitsCollection.
26+
27+
o Error Propagation:
28+
-----------------
29+
+ Defined method GetTranfMat() in G4ErrorFreeTrajectoryState.
30+
Addresses problem report #1248.
31+
32+
o Geometry:
33+
--------
34+
+ divisions:
35+
o Optimise initialization of phi angles in parameterisation for tubs
36+
and cons.
37+
+ magnetic_field:
38+
o Corrected computation of 'omegac' G4EqEMFieldWithEDM, G4Mag_SpinEqRhs
39+
and G4EqEMFieldWithSpin with more coherent formula. Simplified formula
40+
for computation of kinetic energy in G4FieldTrack.
41+
+ navigation:
42+
o Fix in locator classes and navigator to address cases of tracks stuck
43+
on boundary of volumes: improved the condition for accepting a
44+
candidate intersection with a boundary in all locator classes, now
45+
checking if the track enters in the new volume.
46+
Resolves long-standing issue reported by ATLAS.
47+
+ solids/Boolean:
48+
o Corrected protection in G4SubtractionSolid::DistanceToIn(p,v)
49+
introduced previously and relaxed to not cause event abortion.
50+
+ solids/CSG:
51+
o G4Sphere: fix for setting of relative radial tolerances when setters
52+
for radiuses are explicitely called (affecting parameterisations on
53+
radius for spheres).
54+
Relaxed validity condition in construction for the minimum size of the
55+
outer radius.
56+
+ solids/specific:
57+
o Fix in G4TriangularFacet::Intersect() to take into account geometrical
58+
tolerance and cases of zero distance from surface's facet; fixed tests
59+
where square root was compared to half Cartesian tolerance; now
60+
compared to kCarTolerance. Addressing problem report #1242.
61+
o Fix in G4TessellatedSolid::DistanceToOut(p) and DistanceToIn(p) to
62+
exactly compute distance from facet avoiding use of 'outgoing' flag
63+
shortcut variant. Addressing problem report #1242.
64+
o Fix in G4Paraboloid::DistanceToIn(p,v) and DistanceToIn(p) to properly
65+
take into account tolerance and provide better estimation of distance
66+
respectively. Addresses problem report #1234.
67+
o Fix in G4EllipticalCone in DistanceToIn(p,v) to exclude imaginary
68+
solution (virtual cone) when distance is calculated.
69+
o Defined SetReferences() and InvertFacets() to
70+
G4GenericTrap::CreatePolyhedron() for proper visualisation of Boolean
71+
compositions with G4GenericTrap.
72+
o Defined SetReferences() to G4TessellatedSolid::CreatePolyhedron()
73+
for proper visualisation of Boolean compositions with
74+
G4TessellatedSolid. Addresses problem report #1235.
75+
o Fixed logic in G4VTwistSurface::GetEdgeVisibility() in treatment of
76+
corners.
77+
+ volumes:
78+
o Use WIN32 instead of G4LIB_BUILD_DLL as flag for protecting allocator
79+
choice in G4NavigationHistory on Windows.
80+
81+
o Global:
82+
------
83+
+ Added missing post-const qualifier to G4String::compareTo() methods
84+
+ Changed date for patch-03 to release 9.4.
85+
86+
o Graphical Representations:
87+
-------------------------
88+
+ G4PolyhedronArbitrary: defined SetReferences() and InvertFacets() methods
89+
necessary at the end to complete the polyhedron, in particular if the
90+
polyhedron suffers subsequent Boolean operations.
91+
+ Consistently make use of G4 types in HepPolyhedron and BooleanProcessor.
92+
93+
o Persistency:
94+
-----------
95+
+ ascii:
96+
* Fixed case of dereferencing null pointer in G4tgbGeometryDumper
97+
DumpRotationMatrix() method.
98+
* Fixed bug on the usage of units. Addressing problem report #1240.
99+
* Fixed trivial compilation warning from Xcode in G4tgbVolume.
100+
+ gdml:
101+
* Fixes in reader to properly consider units in import for G4GenericTrap,
102+
G4EllipticalTube, G4TessellatedSolid and G4Tet.
103+
104+
o Electromagnetic Processes:
105+
-------------------------
106+
+ HighEnergy:
107+
o Removed include of unused header in G4GammaConversionToMuons.
108+
+ Standard:
109+
o G4CoulombScatteringModel, G4eCoulombScatteringModel: increased
110+
low-energy threshold from 1 eV to 1 keV, below this threshold
111+
particle energy is set to zero
112+
o G4UrbanMscModel90, G4UrbanMscModel92, G4UrbanMscModel93: added
113+
protection for sampling of angle for very small steps and high
114+
energy e-. Fixing rare cases of back-reflection.
115+
+ Utils:
116+
o G4EmModelManager: fixed bug in algorithm to smooth cross-sections
117+
between different models. Responsible for observed discrepancy in
118+
lateral shower shapes reported by CMS.
119+
+ Xrays:
120+
o G4SynchrotronRadiation, G4SynchrotronRadiationInMat: fixed length
121+
of C-arrays for the interface with EM field.
122+
Addressing problem report #1236.
123+
o Fixed compilation warnings for variables set but not used.
124+
Fixed some Coverity defects.
125+
126+
o Hadronic Processes:
127+
------------------
128+
+ cross_sections:
129+
o G4ElectroNuclearCrossSection: protections to avoid FPE numerical
130+
problems at low energies
131+
+ management:
132+
o G4HadronicProcess: changed order of checks, first track status,
133+
second cross-section (avoid computation of cross-section for zero
134+
energy particles).
135+
+ models/cascade:
136+
o G4CascadeInterface: added protection for proton target conservation
137+
failures. These happen due to elastic scattering near threshold.
138+
139+
o Generic Processes:
140+
-----------------
141+
+ Parameterisations/gflash:
142+
o Fixed bug in G4FlashShowerModel::ModelTrigger() for energy condition.
143+
o Fixed Coverity defects, mainly related to uninitialised static data.
144+
+ Transportation:
145+
o Modified calcuation of 'deltaTime' for optical photons in
146+
G4Transportation (and G4CoupledTtansportation). The final velocity
147+
obtained by G4Track CalculateVelocityForOpticalPhoton() should be
148+
used instead of the initial velocity of the step.
149+
Addressing problem report #1239.
150+
151+
o Track:
152+
-----
153+
+ Fix problems related to treatment of weight in G4ParticleChange.
154+
Addressing problem report #1243.
155+
+ Use G4VelocityTable as singleton to avoid unnecessary creation of
156+
G4PhysicsVector objects in the event loop.
157+
158+
o Examples:
159+
--------
160+
+ Updated reference outputs.
161+
+ extended/parameterisations/gflash
162+
o Fixed bug in ExGflashSensitiveDetector::Initialize() for creation of
163+
new hits collection.
164+
+ novice/N04
165+
o Optimised initialisation of Phi angles in parameterisations to avoid
166+
recomputation of trigonometry.
167+
168+
169+
----------------------------------------------------------------------------
170+
171+
Technical Notes
172+
---------------
173+
174+
o This patch should be applied on top of release 9.4 or 9.4.p02.
175+
o Technical notes distributed for release 9.4 are also applicable and
176+
valid for this patch.
177+
178+
The code and rebuilt binary libraries for release 9.4.p03 are available
179+
through our "Download" Web page:
180+
http://cern.ch/geant4/support/download.shtml
181+
182+
Please refer to the Geant4 User Documentation:
183+
http://cern.ch/geant4/support/userdocuments.shtml
184+
for further information about using Geant4.

cmake/Modules/Geant4ConfigureConfigScript.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
# known bindir as an executable.
99
#
1010
# $Id: Geant4ConfigureConfigScript.cmake,v 1.4 2010-12-13 17:31:59 bmorgan Exp $
11-
# GEANT4 Tag $Name: geant4-09-04-patch-02 $
11+
# GEANT4 Tag $Name: not supported by cvs2svn $
1212
#
1313

1414
#-----------------------------------------------------------------------------

cmake/Modules/Geant4InterfaceOptions.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
# Specific UI/Vis options are also handled here.
77
#
88
# $Id: Geant4InterfaceOptions.cmake,v 1.5 2010-11-26 18:52:16 bmorgan Exp $
9-
# GEANT4 Tag $Name: geant4-09-04-patch-02 $
9+
# GEANT4 Tag $Name: not supported by cvs2svn $
1010
#
1111

1212
if(UNIX)

cmake/Modules/Geant4ToolchainBackwardCompatibility.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
# pointing up one directory level.
4040
#
4141
# $Id: Geant4ToolchainBackwardCompatibility.cmake,v 1.10 2010-12-13 19:03:34 bmorgan Exp $
42-
# GEANT4 Tag $Name: geant4-09-04-patch-02 $
42+
# GEANT4 Tag $Name: not supported by cvs2svn $
4343
#
4444

4545

cmake/Templates/geant4-config.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
# Autogenerated by CMake DO NOT EDIT
77
#
88
# $Id: geant4-config.in,v 1.3 2010-12-14 13:53:45 bmorgan Exp $
9-
# GEANT4 Tag $Name: geant4-09-04-patch-02 $
9+
# GEANT4 Tag $Name: not supported by cvs2svn $
1010
#
1111
#------------------------------------------------------------------------------
1212

config/G4UI_BUILD.gmk

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# $Id: G4UI_BUILD.gmk,v 1.5 2007/10/03 12:15:05 lgarnier Exp $
1+
# $Id: G4UI_BUILD.gmk,v 1.5 2007-10-03 12:15:05 lgarnier Exp $
22
# -------------------------------------------------------------
33
# Interfaces-specific CPPFLAGS for BUILD phase.
44
# John Allison, 6th July 1998.
@@ -14,32 +14,38 @@ ifndef G4UI_NONE
1414
# GAG_SESSION
1515
# TERMINAL_SESSION
1616

17+
# Special case: if OPENGLXM vis driver requested, G4Xt must be built.
18+
ifdef G4VIS_BUILD_OPENGLXM_DRIVER
19+
G4INTY_BUILD_XT = 1
20+
endif
21+
22+
# Special case: if OIX vis driver requested, G4Xt must be built.
23+
ifdef G4VIS_BUILD_OIX_DRIVER
24+
G4INTY_BUILD_XT = 1
25+
endif
26+
1727
ifdef G4UI_BUILD_XM_SESSION
18-
G4UI_BUILD = 1
1928
G4UI_BUILD_BASIC_SESSION = 1
2029
G4INTY_BUILD_XT = 1
2130
INC_XM = 1
2231
CPPFLAGS += -DG4UI_BUILD_XM_SESSION
2332
endif
2433

2534
ifdef G4UI_BUILD_QT_SESSION
26-
G4UI_BUILD = 1
2735
G4UI_BUILD_BASIC_SESSION = 1
2836
G4INTY_BUILD_QT = 1
2937
INC_QT = 1
3038
CPPFLAGS += -DG4UI_BUILD_QT_SESSION
3139
endif
3240

3341
ifdef G4UI_BUILD_XAW_SESSION
34-
G4UI_BUILD = 1
3542
G4UI_BUILD_BASIC_SESSION = 1
3643
G4INTY_BUILD_XT = 1
3744
INC_XAW = 1
3845
CPPFLAGS += -DG4UI_BUILD_XAW_SESSION
3946
endif
4047

4148
ifdef G4UI_BUILD_WIN32_SESSION
42-
G4UI_BUILD = 1
4349
G4UI_BUILD_BASIC_SESSION = 1
4450
G4INTY_BUILD_WIN32 = 1
4551
CPPFLAGS += -DG4UI_BUILD_WIN32_SESSION

config/History

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,28 @@ committal in the CVS repository !
1616
* Reverse chronological order (last date on top), please *
1717
----------------------------------------------------------
1818

19+
9th December 2011 Gabriele Cosmo (config-V09-03-23)
20+
- Corrected condition for determining QT_AS_FRAMEWORK flag depending on
21+
how QTHOME is defined in Darwin setups. Addresses problem report #1267.
22+
23+
8th December 2011 Gabriele Cosmo
24+
- Removed unnecessary 'gcov' linkage for dynamic libraries in Darwin-g++.gmk.
25+
26+
22nd November 2011 Gabriele Cosmo
27+
- Corrected path in Darwin-g++ setup introduced in previously.
28+
29+
10th November 2011 Gunter Folger
30+
- Allow use of Qt libraries not installed as Framework in Darwin-g++.gmk.
31+
32+
21st september 2011 John Allison (config-V09-03-22)
33+
- G4UI_BUILD.gmk: Added G4INTY_BUILD_XT = 1 for G4VIS_BUILD_OPENGLXM_DRIVER
34+
and G4VIS_BUILD_OIX_DRIVER. The vis drivers need Xt, so this covers
35+
the case when the user does not build Xt from G4UI_BUILD flags.
36+
37+
3rd August 2011 Gabriele Cosmo
38+
- Darwin-g++.gmk: modified OGLLIBS settings to support MacOSX 10.7 Lion
39+
for proper configuration of OpenGL libraries in combination with Qt.
40+
1941
9th May 2011 Gabriele Cosmo (config-V09-03-21)
2042
- Workaround in binmake.gmk to avoid clashes with flag LDFLAGS set in the
2143
user's environment beforehand.

config/scripts/env.csh.SH

100644100755
File mode changed.

config/scripts/env.sh.SH

100644100755
File mode changed.

config/scripts/install.sh.SH

100644100755
File mode changed.

config/sys/Darwin-g++.gmk

Lines changed: 25 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -76,20 +76,18 @@ ifeq ($(G4SYSTEM),Darwin-g++)
7676
# the following lines are for building on MacOSX 10.5 "Leopard"
7777
OGLLIBS := -Wl,$(QTGLPATH)/Versions/A/Libraries/libGL.dylib -L$(OGLHOME)/lib -lGLU -lGL
7878
else
79-
ifeq ($(DARWIN_VERSION),10)
80-
# the following lines are for building on MacOSX > 10.5
81-
OGLLIBS := -F/System/Library/Frameworks -framework OpenGL -framework AGL
82-
ifeq ($(G4VIS_USE_OPENGLX),1)
83-
OGLLIBS += -L$(OGLHOME)/lib -lGLU -lGL
84-
endif
79+
# the following lines are for building on MacOSX > 10.5
80+
OGLLIBS := -F/System/Library/Frameworks -framework OpenGL -framework AGL
81+
ifeq ($(G4VIS_USE_OPENGLX),1)
82+
OGLLIBS += -L$(OGLHOME)/lib -lGLU -lGL
8583
endif
8684
endif
8785
else
8886
OGLLIBS := -L$(OGLHOME)/lib -lGLU -lGL
8987
endif
9088
endif
9189

92-
# ---- QT Setup block -------------------------------------------------------
90+
# ---- Qt Setup block -------------------------------------------------------
9391

9492
ifndef QTHOME
9593
QTHOME := /Library/Frameworks
@@ -109,31 +107,43 @@ ifeq ($(G4SYSTEM),Darwin-g++)
109107
endif
110108
ifndef QTLIBPATH
111109
ifeq ($(QTHOME),/Library/Frameworks)
112-
QTLIBPATH := -F$(QTHOME)
110+
QTLPATH := $(QTHOME)
113111
else
114-
QTLIBPATH := -F$(QTHOME)/lib
112+
QTLPATH := $(QTHOME)/lib
115113
endif
114+
QTLIBPATH := -F$(QTLPATH)
116115
endif
116+
117+
QT_AS_FRAMEWORK := $(shell test -d $(QTLPATH)/QtCore.framework && echo yes)
118+
117119
ifndef QTLIBS
118-
QTLIBS := $(QTLIBPATH) -framework QtCore -framework QtGui
120+
ifdef QT_AS_FRAMEWORK
121+
QTLIBS := $(QTLIBPATH) -framework QtCore -framework QtGui
122+
else
123+
QTLIBS := -L$(QTLPATH) -lQtCore -lQtGui
124+
endif
119125
endif
120-
ifndef GLQTLIBS
121-
GLQTLIBS := $(QTLIBPATH) -framework QtCore -framework QtGui
122-
GLQTLIBS += -framework QtOpenGL
126+
ifndef GLQTLIBS
127+
ifdef QT_AS_FRAMEWORK
128+
GLQTLIBS := $(QTLIBPATH) -framework QtCore -framework QtGui
129+
GLQTLIBS += -framework QtOpenGL
130+
else
131+
GLQTLIBS := -L$(QTLPATH) -lQtCore -lQtGui -lQtOpenGL
132+
endif
123133
endif
124134

125135
#----------------------------------------------------------------------------
126136

127137
define build-granular-shared-lib
128138
@libdir=`(cd $(@D);/bin/pwd)`; \
129139
cd $(G4TMPDIR); \
130-
$(CXX) -dynamiclib -single_module -lgcov -undefined dynamic_lookup \
140+
$(CXX) -dynamiclib -single_module -undefined dynamic_lookup \
131141
-o $$libdir/$(@F) $(INTYLIBS) *.o
132142
endef
133143
define build-global-shared-lib
134144
@libdir=`(cd $(@D);/bin/pwd)`; \
135145
cd $(G4TMP)/$(G4SYSTEM); \
136-
$(CXX) -dynamiclib -single_module -lgcov -undefined dynamic_lookup \
146+
$(CXX) -dynamiclib -single_module -undefined dynamic_lookup \
137147
-o $$libdir/$(@F) $(INTYLIBS) $(foreach dir,$(SUBLIBS),$(dir)/*.o);
138148
endef
139149

0 commit comments

Comments
 (0)