fix_headers_nug4.pl
Go to the documentation of this file.
1 use strict;
2 
3 use vars qw(%subdir_list);
4 use vars qw(%header_list);
5 
6 # explicit headers to avoid conflicts with experiment code
7 BEGIN { %header_list = (
8 "nutools/ParticleNavigation/EmEveIdCalculator.h" => "nug4/ParticleNavigation/EmEveIdCalculator.h",
9 "nutools/ParticleNavigation/ParticleList.h" => "nug4/ParticleNavigation/ParticleList.h",
10 "nutools/ParticleNavigation/ParticleHistory.h" => "nug4/ParticleNavigation/ParticleHistory.h",
11 "nutools/ParticleNavigation/EveIdCalculator.h" => "nug4/ParticleNavigation/EveIdCalculator.h",
12 "nutools/MagneticField/MagneticField.h" => "nug4/MagneticField/MagneticField.h",
13 "nutools/G4Base/UserAction.h" => "nug4/G4Base/UserAction.h",
14 "nutools/G4Base/ConvertMCTruthToG4.h" => "nug4/G4Base/ConvertMCTruthToG4.h",
15 "nutools/G4Base/UserActionManager.h" => "nug4/G4Base/UserActionManager.h",
16 "nutools/G4Base/DetectorConstruction.h" => "nug4/G4Base/DetectorConstruction.h",
17 "nutools/G4Base/PrimaryParticleInformation.h" => "nug4/G4Base/PrimaryParticleInformation.h",
18 "nutools/G4Base/ExampleAction.h" => "nug4/G4Base/ExampleAction.h",
19 "nutools/G4Base/UserActionFactory.h" => "nug4/G4Base/UserActionFactory.h",
20 "nutools/G4Base/G4Helper.h" => "nug4/G4Base/G4Helper.h",
21 "nutools/G4Base/G4PhysicsProcessFactorySingleton.hh" => "nug4/G4Base/G4PhysicsProcessFactorySingleton.hh",
22 "nutools/G4Base/G4PhysListFactorySingleton.hh" => "nug4/G4Base/G4PhysListFactorySingleton.hh",
23 "nutools/G4Base/G4PhysListFactory.hh" => "nug4/G4Base/G4PhysListFactory.hh",
24 "nutools/G4Base/G4PhysListRegisterOld.icc" => "nug4/G4Base/G4PhysListRegisterOld.icc",
25 "nutools/G4Base/G4PhysicsProcessRegisterOld.icc" => "nug4/G4Base/G4PhysicsProcessRegisterOld.icc"
26  ); }
27 
28 foreach my $inc (sort keys %header_list) {
29  s&^(\s*#include\s+["<])\Q$inc\E(.*)&${1}$header_list{$inc}${2}& and last;
30 }