Configuration#
- class lsst.sconsUtils.dependencies.Configuration(cfgFile, headers=(), libs=None, hasSwigFiles=True, includeFileDirs=('include',), libFileDirs=('lib',), hasDoxygenInclude=False, hasDoxygenTag=True, eupsProduct=None)#
Bases:
objectBase class for defining how to configure an LSST sconsUtils package.
Aliased as
lsst.sconsUtils.Configuration.An
ups/*.cfgfile should contain an instance of this class called “config”. Most LSST packages will be able to use this class directly instead of subclassing it.The only important method is configure(), which modifies an SCons environment to use the package. If a subclass overrides configure, it may not need to call the base class
__init__(), whose only purpose is to define a number of instance variables used by configure().Parameters#
- cfgFile
str The name of the calling .cfg file, usually just passed in with the special variable
__file__. This will be parsed to extract the package name and root.- headers
listofstr, optional A list of headers provided by the package, to be used in autoconf-style tests.
- libs
listordict, optional A list or dictionary of libraries provided by the package. If a dictionary is provided,
libs["main"]should contain a list of regular libraries provided by the library. Other keys are “python” and “test”, which refer to libraries that are only linked against compiled Python modules and unit tests, respectively. If a list is provided, the list is used as “main”. These are used both for autoconf-style tests and to supportenv.getLibs(...), which recursively computes the libraries a package must be linked with.- hasSwigFiles
bool, optional Accepted for backwards compatibility and ignored; SWIG support has been removed from sconsUtils.
- hasDoxygenInclude
bool, optional If True, the package provides a Doxygen include file with the name
<root>/doc/<name>.inc.- hasDoxygenTag
bool, optional If True, the package generates a Doxygen TAG file.
- includeFileDirs
collections.abc.Sequence, optional List of directories that should be searched for include files.
- libFileDirs
collections.abc.Sequence, optional List of directories that should be searched for libraries.
- eupsProduct
str Name of the EUPS product for the package, if different from the name of the
.cfgfile.
Methods Summary
configure(conf, packages[, build])Update an SCons environment to make use of the package.
getEupsData(eupsProduct)Get EUPS version and product directory for named product.
parseFilename(cfgFile)Parse the name of a .cfg file and return package name and root.
Methods Documentation
- configure(conf, packages, build=True)#
Update an SCons environment to make use of the package.
Parameters#
- conf
SCons.Configure An SCons Configure context. The SCons Environment conf.env should be updated by the configure function.
- packages
dict A dictionary containing the configuration modules of all dependencies (or
Noneif the dependency was optional and was not found). The<module>.config.configure(...)method will have already been called on all dependencies.- build
bool, optional If True, this is the package currently being built, and packages in “buildRequired” and “buildOptional” dependencies will also be present in the packages dict.
- conf
- cfgFile