Safe Haskell | None |
---|
This module holds a long list of lenses that access the Atoms record, the record that holds the input data from which the debianization is to be constructed.
- data Atoms = Atoms {
- noDocumentationLibrary_ :: Set Bool
- noProfilingLibrary_ :: Set Bool
- omitLTDeps_ :: Set Bool
- compilerVersion_ :: Maybe Version
- buildDir_ :: Set FilePath
- flags_ :: Flags
- debianNameMap_ :: Map PackageName VersionSplits
- control_ :: SourceDebDescription
- sourcePackageName_ :: Maybe SrcPkgName
- revision_ :: Maybe String
- debVersion_ :: Maybe DebianVersion
- maintainerOld_ :: Maybe NameAddr
- cabalFlagAssignments_ :: Set (FlagName, Bool)
- sourceFormat_ :: Maybe SourceFormat
- watch_ :: Maybe Text
- intermediateFiles_ :: Set (FilePath, Text)
- rulesHead_ :: Maybe Text
- rulesFragments_ :: Set Text
- warning_ :: Set Text
- utilsPackageNames_ :: Set BinPkgName
- changelog_ :: Maybe ChangeLog
- comments_ :: Maybe [[Text]]
- missingDependencies_ :: Set BinPkgName
- extraLibMap_ :: Map String Relations
- execMap_ :: Map String Relations
- epochMap_ :: Map PackageName Int
- packageInfo_ :: Map PackageName PackageInfo
- compat_ :: Maybe Int
- copyright_ :: Maybe Text
- license_ :: Maybe License
- licenseFile_ :: Maybe Text
- apacheSite_ :: Map BinPkgName (String, FilePath, Text)
- logrotateStanza_ :: Map BinPkgName (Set Text)
- link_ :: Map BinPkgName (Set (FilePath, FilePath))
- postInst_ :: Map BinPkgName Text
- postRm_ :: Map BinPkgName Text
- preInst_ :: Map BinPkgName Text
- preRm_ :: Map BinPkgName Text
- sourceArchitecture_ :: Maybe PackageArchitectures
- binaryArchitectures_ :: Map BinPkgName PackageArchitectures
- sourcePriority_ :: Maybe PackagePriority
- binaryPriorities_ :: Map BinPkgName PackagePriority
- sourceSection_ :: Maybe Section
- binarySections_ :: Map BinPkgName Section
- install_ :: Map BinPkgName (Set (FilePath, FilePath))
- installTo_ :: Map BinPkgName (Set (FilePath, FilePath))
- installData_ :: Map BinPkgName (Set (FilePath, FilePath))
- file_ :: Map BinPkgName (Set (FilePath, Text))
- installCabalExec_ :: Map BinPkgName (Set (String, FilePath))
- installCabalExecTo_ :: Map BinPkgName (Set (String, FilePath))
- installDir_ :: Map BinPkgName (Set FilePath)
- installInit_ :: Map BinPkgName Text
- executable_ :: Map BinPkgName InstallFile
- serverInfo_ :: Map BinPkgName Server
- website_ :: Map BinPkgName Site
- backups_ :: Map BinPkgName String
- extraDevDeps_ :: Relations
- packageDescription_ :: Maybe PackageDescription
- compiler_ :: Maybe CompilerId
- newAtoms :: Atoms
- data Flags = Flags {
- verbosity_ :: Int
- dryRun_ :: Bool
- validate_ :: Bool
- debAction_ :: DebAction
- data DebAction
- data DebType
- data PackageInfo = PackageInfo {
- cabalName :: PackageName
- devDeb :: Maybe (BinPkgName, DebianVersion)
- profDeb :: Maybe (BinPkgName, DebianVersion)
- docDeb :: Maybe (BinPkgName, DebianVersion)
- data Site = Site {}
- data Server = Server {
- hostname :: String
- port :: Int
- headerMessage :: String
- retry :: String
- serverFlags :: [String]
- installFile :: InstallFile
- data InstallFile = InstallFile {}
- defaultFlags :: Flags
- showAtoms :: Atoms -> IO ()
- verbosity :: Lens Atoms Int
- dryRun :: Lens Atoms Bool
- validate :: Lens Atoms Bool
- debAction :: Lens Atoms DebAction
- flags :: Lens Atoms Flags
- warning :: Lens Atoms (Set Text)
- compilerVersion :: Lens Atoms (Maybe Version)
- buildDir :: Lens Atoms (Set FilePath)
- extraLibMap :: Lens Atoms (Map String Relations)
- execMap :: Lens Atoms (Map String Relations)
- cabalFlagAssignments :: Lens Atoms (Set (FlagName, Bool))
- packageDescription :: Lens Atoms (Maybe PackageDescription)
- compiler :: Lens Atoms (Maybe CompilerId)
- debianNameMap :: Lens Atoms (Map PackageName VersionSplits)
- epochMap :: Lens Atoms (Map PackageName Int)
- executable :: Lens Atoms (Map BinPkgName InstallFile)
- serverInfo :: Lens Atoms (Map BinPkgName Server)
- website :: Lens Atoms (Map BinPkgName Site)
- backups :: Lens Atoms (Map BinPkgName String)
- apacheSite :: Lens Atoms (Map BinPkgName (String, FilePath, Text))
- missingDependencies :: Lens Atoms (Set BinPkgName)
- utilsPackageNames :: Lens Atoms (Set BinPkgName)
- sourcePackageName :: Lens Atoms (Maybe SrcPkgName)
- revision :: Lens Atoms (Maybe String)
- debVersion :: Lens Atoms (Maybe DebianVersion)
- packageInfo :: Lens Atoms (Map PackageName PackageInfo)
- omitLTDeps :: Lens Atoms (Set Bool)
- noProfilingLibrary :: Lens Atoms (Set Bool)
- noDocumentationLibrary :: Lens Atoms (Set Bool)
- copyright :: Lens Atoms (Maybe Text)
- license :: Lens Atoms (Maybe License)
- licenseFile :: Lens Atoms (Maybe Text)
- sourceArchitectures :: Lens Atoms (Maybe PackageArchitectures)
- extraDevDeps :: Lens Atoms Relations
- rulesHead :: Lens Atoms (Maybe Text)
- rulesFragments :: Lens Atoms (Set Text)
- postInst :: Lens Atoms (Map BinPkgName Text)
- postRm :: Lens Atoms (Map BinPkgName Text)
- preInst :: Lens Atoms (Map BinPkgName Text)
- preRm :: Lens Atoms (Map BinPkgName Text)
- compat :: Lens Atoms (Maybe Int)
- sourceFormat :: Lens Atoms (Maybe SourceFormat)
- watch :: Lens Atoms (Maybe Text)
- changelog :: Lens Atoms (Maybe ChangeLog)
- comments :: Lens Atoms (Maybe [[Text]])
- control :: Lens Atoms SourceDebDescription
- logrotateStanza :: Lens Atoms (Map BinPkgName (Set Text))
- link :: Lens Atoms (Map BinPkgName (Set (FilePath, FilePath)))
- install :: Lens Atoms (Map BinPkgName (Set (FilePath, FilePath)))
- installTo :: Lens Atoms (Map BinPkgName (Set (FilePath, FilePath)))
- installData :: Lens Atoms (Map BinPkgName (Set (FilePath, FilePath)))
- file :: Lens Atoms (Map BinPkgName (Set (FilePath, Text)))
- installCabalExec :: Lens Atoms (Map BinPkgName (Set (String, FilePath)))
- installCabalExecTo :: Lens Atoms (Map BinPkgName (Set (String, FilePath)))
- installDir :: Lens Atoms (Map BinPkgName (Set FilePath))
- installInit :: Lens Atoms (Map BinPkgName Text)
- intermediateFiles :: Lens Atoms (Set (FilePath, Text))
Documentation
Bits and pieces of information about the mapping from cabal package
names and versions to debian package names and versions. In essence,
an Atoms
value represents a package's debianization. The lenses in
this module are used to get and set the values hidden in this Atoms
value. Many of the values should be left alone to be set when the
debianization is finalized.
Atoms | |
|
This record supplies information about the task we want done - debianization, validataion, help message, etc.
Flags | |
|
A redundant data type, too lazy to expunge.
data PackageInfo Source
PackageInfo | |
|
Information about the web site we are packaging.
Information about the server we are packaging.
Server | |
|
dryRun :: Lens Atoms BoolSource
Don't write anything, just output a description of what would have happened
validate :: Lens Atoms BoolSource
Make sure the version number and package names of the supplied and generated debianizations match.
debAction :: Lens Atoms DebActionSource
Debianize, SubstVars, or Usage. I'm no longer sure what SubstVars does, but someone may still be using it.
flags :: Lens Atoms FlagsSource
Obsolete record containing verbosity, dryRun, validate, and debAction.
compilerVersion :: Lens Atoms (Maybe Version)Source
Set the compiler version, this is used when loading the cabal file to
buildDir :: Lens Atoms (Set FilePath)Source
The build directory. This can be set by an argument to the Setup
script.
When Setup
is run manually it is just dist
, when it is run by
dpkg-buildpackage
the compiler name is appended, so it is typically
dist-ghc
. Cabal-debian needs the correct value of buildDir to find
the build results.
extraLibMap :: Lens Atoms (Map String Relations)Source
Map from cabal Extra-Lib names to debian binary package names.
execMap :: Lens Atoms (Map String Relations)Source
Map from cabal Build-Tool names to debian binary package names.
cabalFlagAssignments :: Lens Atoms (Set (FlagName, Bool))Source
Cabal flag assignments to use when loading the cabal file.
packageDescription :: Lens Atoms (Maybe PackageDescription)Source
The result of loading a .cabal file
debianNameMap :: Lens Atoms (Map PackageName VersionSplits)Source
Map from cabal version number ranges to debian package names. This is a result of the fact that only one version of a debian package can be installed at a given time, while multiple versions of a cabal package can.
epochMap :: Lens Atoms (Map PackageName Int)Source
Map of Debian epoch numbers assigned to cabal packages.
executable :: Lens Atoms (Map BinPkgName InstallFile)Source
Create a package to hold a cabal executable
serverInfo :: Lens Atoms (Map BinPkgName Server)Source
Create a package for a server
apacheSite :: Lens Atoms (Map BinPkgName (String, FilePath, Text))Source
Create an apache configuration file with the given (domain, logdir, filetext). This is called when expanding the result of the website lens above.
Lower level hints about the debianization
missingDependencies :: Lens Atoms (Set BinPkgName)Source
List if packages that should be omitted from any dependency list - e.g. a profiling package missing due to use of noProfilingPackage lens elsewhere.
utilsPackageNames :: Lens Atoms (Set BinPkgName)Source
Override the package name used to hold left over data files and executables. Usually only one package is specified, but if more then one are they will each receive the same list of files.
sourcePackageName :: Lens Atoms (Maybe SrcPkgName)Source
Override the debian source package name constructed from the cabal name
revision :: Lens Atoms (Maybe String)Source
Revision string used in constructing the debian verison number from the cabal version
debVersion :: Lens Atoms (Maybe DebianVersion)Source
Exact debian version number, overrides the version generated from the cabal version
packageInfo :: Lens Atoms (Map PackageName PackageInfo)Source
No longer sure what the purpose of this lens is.
omitLTDeps :: Lens Atoms (Set Bool)Source
Set this to filter any less-than dependencies out of the generated debian dependencies. (Not sure if this is implemented.)
sourceArchitectures :: Lens Atoms (Maybe PackageArchitectures)Source
The architectures supported by this source package - Any
,
All
, or some list of specific architectures.
extraDevDeps :: Lens Atoms RelationsSource
Extra install dependencies for the devel library. Redundant with depends, but kept for backwards compatibility. Also, I think maybe this is or was needed because it can be set before the exact name of the library package is known.
compat :: Lens Atoms (Maybe Int)Source
The debian/compat
file, contains the minimum compatible version
of the debhelper
package. If not given the version number of the
installed debhelper package is used.
sourceFormat :: Lens Atoms (Maybe SourceFormat)Source
The debian/source/format
file.
comments :: Lens Atoms (Maybe [[Text]])Source
Comment entries for the latest changelog entry (DebLogComments [[Text]])
control :: Lens Atoms SourceDebDescriptionSource
The debian/control
file. Many of the following lenses access parts of the SourceDebDescription
.
logrotateStanza :: Lens Atoms (Map BinPkgName (Set Text))Source
Add a stanza to the binary package's logrotate script.
link :: Lens Atoms (Map BinPkgName (Set (FilePath, FilePath)))Source
Add entries to a binary deb's debian/foo.links file.
install :: Lens Atoms (Map BinPkgName (Set (FilePath, FilePath)))Source
Install files into directories by adding entries to the binary deb's debian/foo.install file.
installTo :: Lens Atoms (Map BinPkgName (Set (FilePath, FilePath)))Source
Rename and install files. This is done by adding rules to debian/rules.
installData :: Lens Atoms (Map BinPkgName (Set (FilePath, FilePath)))Source
Install files into the a binary deb's data directory, usrshare/packagename-version. This expands to either an install or an installTo.
file :: Lens Atoms (Map BinPkgName (Set (FilePath, Text)))Source
Create a file in the binary deb with the given text. This is done by writing the file into the cabalInstall directory and adding an entry to the binary deb's .install file.
installCabalExec :: Lens Atoms (Map BinPkgName (Set (String, FilePath)))Source
Install a cabal executable into a binary deb. FIXME: change signature to BinPkgName -> Lens Atoms (Set (String, FilePath))
installCabalExecTo :: Lens Atoms (Map BinPkgName (Set (String, FilePath)))Source
Rename and install a cabal executable FIXME: change signature to BinPkgName -> Lens Atoms (Set (String, FilePath))
installDir :: Lens Atoms (Map BinPkgName (Set FilePath))Source
Create directories in the package FIXME: change signature to BinPkgName -> Lens Atoms (Set FilePath)
installInit :: Lens Atoms (Map BinPkgName Text)Source
Create an etcinit.d file in the package FIXME: change signature to BinPkgName -> Lens Atoms Text