- pkg : Lake.Package
The package the library belongs to.
- config : Lake.LeanLibConfig
The library's user-defined configuration.
A Lean library -- its package plus its configuration.
Instances For
The Lean libraries of the package (as an Array).
Equations
- Lake.Package.leanLibs self = Lake.RBArray.foldl (fun a v => Array.push a { pkg := self, config := v }) #[] self.leanLibConfigs
Instances For
Try to find a Lean library in the package with the given name.
Equations
- Lake.Package.findLeanLib? name self = Option.map (fun x => { pkg := self, config := x }) (Lake.RBArray.find? self.leanLibConfigs name)
Instances For
The library's well-formed name.
Equations
- Lake.LeanLib.name self = self.config.name
Instances For
The package's srcDir
joined with the library's srcDir
.
Equations
- Lake.LeanLib.srcDir self = Lake.Package.srcDir self.pkg / self.config.srcDir
Instances For
The library's root directory for lean
(i.e., srcDir
).
Equations
- Lake.LeanLib.rootDir self = Lake.LeanLib.srcDir self
Instances For
The names of the library's root modules
(i.e., the library's roots
configuration).
Equations
- Lake.LeanLib.roots self = self.config.roots
Instances For
Whether the given module is considered local to the library.
Equations
- Lake.LeanLib.isLocalModule mod self = Lake.LeanLibConfig.isLocalModule mod self.config
Instances For
Whether the given module is a buildable part of the library.
Equations
- Lake.LeanLib.isBuildableModule mod self = Lake.LeanLibConfig.isBuildableModule mod self.config
Instances For
The file name of the library's static binary (i.e., its .a
)
Equations
- Lake.LeanLib.staticLibFileName self = { toString := Lake.nameToStaticLib self.config.libName }
Instances For
The path to the static library in the package's libDir
.
Equations
- Lake.LeanLib.staticLibFile self = Lake.Package.nativeLibDir self.pkg / Lake.LeanLib.staticLibFileName self
Instances For
The library's extraDepTargets
configuration.
Equations
- Lake.LeanLib.extraDepTargets self = self.config.extraDepTargets
Instances For
Whether to precompile the library's modules.
Is true if either the package or the library have precompileModules
set.
Equations
- Lake.LeanLib.precompileModules self = (Lake.Package.precompileModules self.pkg || self.config.precompileModules)
Instances For
The library's defaultFacets
configuration.
Equations
- Lake.LeanLib.defaultFacets self = self.config.defaultFacets
Instances For
The library's nativeFacets
configuration.
Equations
- Lake.LeanLib.nativeFacets self = self.config.nativeFacets
Instances For
The build type for modules of this library.
That is, the minimum of package's buildType
and the library's buildType
.
Equations
- Lake.LeanLib.buildType self = min (Lake.Package.buildType self.pkg) self.config.toLeanConfig.buildType
Instances For
The arguments to pass to lean
when compiling the library's Lean files.
That is, the package's moreLeanArgs
plus the library's moreLeanArgs
.
Equations
- Lake.LeanLib.leanArgs self = Lake.Package.moreLeanArgs self.pkg ++ self.config.toLeanConfig.moreLeanArgs
Instances For
The arguments to weakly pass to lean
when compiling the library's Lean files.
That is, the package's weakLeanArgs
plus the library's weakLeanArgs
.
Equations
- Lake.LeanLib.weakLeanArgs self = Lake.Package.weakLeanArgs self.pkg ++ self.config.toLeanConfig.weakLeanArgs
Instances For
The arguments to pass to leanc
when compiling the library's Lean-produced C files.
That is, the build type's leancArgs
, the package's moreLeancArgs
,
and then the library's moreLeancArgs
.
Equations
- Lake.LeanLib.leancArgs self = Lake.BuildType.leancArgs (Lake.LeanLib.buildType self) ++ Lake.Package.moreLeancArgs self.pkg ++ self.config.toLeanConfig.moreLeancArgs
Instances For
The arguments to weakly pass to leanc
when compiling the library's Lean-produced C files.
That is, the package's weakLeancArgs
plus the library's weakLeancArgs
.
Equations
- Lake.LeanLib.weakLeancArgs self = Lake.Package.weakLeancArgs self.pkg ++ self.config.toLeanConfig.weakLeancArgs
Instances For
The arguments to pass to leanc
when linking the shared library.
That is, the package's moreLinkArgs
plus the library's moreLinkArgs
.
Equations
- Lake.LeanLib.linkArgs self = Lake.Package.moreLinkArgs self.pkg ++ self.config.toLeanConfig.moreLinkArgs
Instances For
The arguments to weakly pass to leanc
when linking the shared library.
That is, the package's weakLinkArgs
plus the library's weakLinkArgs
.
Equations
- Lake.LeanLib.weakLinkArgs self = Lake.Package.weakLinkArgs self.pkg ++ self.config.toLeanConfig.weakLinkArgs