IncludeFiles

From Mu2eWiki
Revision as of 04:56, 7 September 2023 by Kutschke (talk | contribs) (→‎C++ Code)
Jump to navigation Jump to search

Finding Include Files

C++ Code

 In the Mu2e repositories, you will see include directives that take one of the following forms,
#include "Offline/RecoDataProducts/inc/KalSeed.hh"
#include "art/Framework/Principal/Event.h"
#include "TH1F.h"
#include <iostream>

The remainder of this page will discuss how to find the source code for header files included in the Mu2e code.


Package/Prefix Environment Variable Namespace Source - Be careful to use the correct tag!
art ART_INC art:: https://github.com/art-framework-suite/art
artdaq-core ARTDAQ_CORE_INC artdaq:: https://github.com/art-daq/artdaq_core
artdaq-core-mu2e ARTDAQ_CORE_MU2E_INC mu2e:: https://github.com/Mu2e/artdaq_core_mu2e
art_root_io ART_ROOT_IO_INC art:: https://github.com/art-framework-suite/art-root-io
boost BOOST_INC boost:: https://github.com/boostorg/boost
BTrk BTRK_INC (none) https://github.com/KFTrack/BTrk
canvas CANVAS_INC art:: https://github.com/art-framework-suite/canvas
cetlib CETLIB_INC cet:: https://github.com/art-framework-suite/cetlib
cetlib_except CETLIB_EXCEPT_INC cet:: https://github.com/art-framework-suite/cetlib-except
CLHEP CLHEP_INC CLHEP:: https://gitlab.cern.ch/CLHEP/CLHEP
fhiclcpp FHICLCPP_INC fhicl:: https://github.com/art-framework-suite/fhicl-cpp
Geant4 G4INCLUDE (none) https://gitlab.cern.ch/geant4/geant4
gsl GSL_INC (none) https://github.com/ampl/gsl
KinKal KINKAL_INC KinKal:: https://github.com/KFTrack/KinKal]
mu2e_pcie_utils MU2E_PCIE_UTILS_INC DTCLib:: https://github.com/Mu2e/mu2e_pcie_utils
messagefacility MESSAGEFACILITY_INC mf:: https://github.com/art-framework-suite/messagefacility
tbb TBB_INC tbb::
xercesc XERCES_C_INC xercesc:: https://github.com/apache/xerces-c
(no prefix) ROOT_INC (none) https://github.com/root-project/root

Files Included from ROOT

The syntax to incluude a root header file is to specify a path relative to $ROOT_INC. Because of the way that the root repository is structured, this results in most include directives containing only the filename. In almost all cases, the filename starts with a capital letter T, for example

 #include "TH1F.h"

There are a small number of exceptional cases in which the filename starts with a capital letter R. Two cases that occur in the Mu2e code base are:

 #include "Rtypes.h"
 #include "Riostream.h" 

Finally, some header files live in subdirectories under $ROOT_INC. The two subdirectories that occur in the Mu2e code base are Math and TVMA, for example

 #include "Math/Vector3D.h"
 #include "TMVA/Factory.h"

Exceptions

One other exception was found in a recent scan of Offline. The file included with,

 #include "dtcInterfaceLib/DTC_Packets.h"

is found in the repository mu2e_pcie_utils, which can be found in the above table.

FCL Files

Auxillary Files

 SimpleConfig, BField maps ...