fix_headers_nugen.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/EventGeneratorBase/evgenbase.h" => "nugen/EventGeneratorBase/evgenbase.h",
9 "nutools/EventGeneratorBase/GENIE/EvtTimeFlat.h" => "nugen/EventGeneratorBase/GENIE/EvtTimeFlat.h",
10 "nutools/EventGeneratorBase/GENIE/EVGBAssociationUtil.h" => "nugen/EventGeneratorBase/GENIE/EVGBAssociationUtil.h",
11 "nutools/EventGeneratorBase/GENIE/EvtTimeFNALBeam.h" => "nugen/EventGeneratorBase/GENIE/EvtTimeFNALBeam.h",
12 "nutools/EventGeneratorBase/GENIE/GENIEHelper.h" => "nugen/EventGeneratorBase/GENIE/GENIEHelper.h",
13 "nutools/EventGeneratorBase/GENIE/MCTruthAndFriendsItr.h" => "nugen/EventGeneratorBase/GENIE/MCTruthAndFriendsItr.h",
14 "nutools/EventGeneratorBase/GENIE/EvtTimeNone.h" => "nugen/EventGeneratorBase/GENIE/EvtTimeNone.h",
15 "nutools/EventGeneratorBase/GENIE/EvtTimeShiftFactory.h" => "nugen/EventGeneratorBase/GENIE/EvtTimeShiftFactory.h",
16 "nutools/EventGeneratorBase/GENIE/GENIE2ART.h" => "nugen/EventGeneratorBase/GENIE/GENIE2ART.h",
17 "nutools/EventGeneratorBase/GENIE/EvtTimeShiftI.h" => "nugen/EventGeneratorBase/GENIE/EvtTimeShiftI.h",
18 "nutools/EventGeneratorBase/GiBUU/GiBUUHelper.h" => "nugen/EventGeneratorBase/GiBUU/GiBUUHelper.h",
19 "nutools/NuReweight/ReweightLabels.h" => "nugen/NuReweight/ReweightLabels.h",
20 "nutools/NuReweight/GENIEReweight.h" => "nugen/NuReweight/GENIEReweight.h",
21 "nutools/NuReweight/art/NuReweight.h" => "nugen/NuReweight/art/NuReweight.h"
22  ); }
23 
24 foreach my $inc (sort keys %header_list) {
25  s&^(\s*#include\s+["<])\Q$inc\E(.*)&${1}$header_list{$inc}${2}& and last;
26 }