diff --git a/GNUmakefile b/GNUmakefile index 010aa7d..7291e0f 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -45,6 +45,7 @@ CPPFLAGS += -DG4MULTITHREADED #CPPFLAGS += -DDEBUG_PLACEMENT #CPPFLAGS += -DDEBUG_SECTIONPLANE #CPPFLAGS += -DDEBUG_SECTIONPLANE_ZAVE +#CPPFLAGS += -DG4VERSION_10_04_OR_LATER=1 # If you want to build against Geant4.10.03 or greater, you will need this line uncommented #CPPFLAGS += -DG4VUSERPHYSICSLIST_HAS_GETPARTICLEITERATOR diff --git a/src/GlueXDetectorConstruction.cc b/src/GlueXDetectorConstruction.cc index aa40002..9648026 100644 --- a/src/GlueXDetectorConstruction.cc +++ b/src/GlueXDetectorConstruction.cc @@ -446,8 +446,13 @@ void GlueXDetectorConstruction::CloneF() // First time we see this FM, let's clone and remember... G4ChordFinder *cfinder = masterFM->GetChordFinder(); +#if G4VERSION_10_04_OR_LATER + G4VIntegrationDriver *midriver = cfinder->GetIntegrationDriver(); + double stepMinimum = 1e-2; +#else G4MagInt_Driver *midriver = cfinder->GetIntegrationDriver(); double stepMinimum = midriver->GetHmin(); +#endif G4MagIntegratorStepper *stepper = midriver->GetStepper(); const G4Field *field = masterFM->GetDetectorField(); diff --git a/src/GlueXPhysicsList.hh b/src/GlueXPhysicsList.hh index c259d79..b2ef805 100644 --- a/src/GlueXPhysicsList.hh +++ b/src/GlueXPhysicsList.hh @@ -59,7 +59,7 @@ class GlueXPhysicsList: public G4VModularPhysicsList #endif G4OpticalPhysics *fOpticalPhysics; -#ifndef G4VUSERPHYSICSLIST_HAS_GETPARTICLEITERATOR +#ifndef G4VERSION_10_04_OR_LATER // This member function gets introduced into base class // G4VUserPhysicsList in release Geant4.10.03, but until // we abandon ability to build under previous releases,