Safe Haskell | None |
---|
- getCabalLibraryVersion :: String
- getFilesToCopy :: BuildWrapper (OpResult [FilePath])
- cabalV :: BuildWrapper Verbosity
- cabalBuild :: Bool -> WhichCabal -> BuildWrapper (OpResult BuildResult)
- cabalBuild' :: Bool -> Bool -> WhichCabal -> BuildWrapper (OpResult BuildResult)
- cabalConfigure :: WhichCabal -> BuildWrapper (OpResult (Maybe LocalBuildInfo))
- getCabalFile :: WhichCabal -> BuildWrapper FilePath
- cabalInit :: WhichCabal -> BuildWrapper (OpResult (Maybe LocalBuildInfo))
- withCabal :: WhichCabal -> (LocalBuildInfo -> BuildWrapper a) -> BuildWrapper (OpResult (Maybe a))
- parseCabalMessages :: FilePath -> FilePath -> String -> [BWNote]
- setupExe :: FilePath -> FilePath
- dropPrefixes :: [String] -> String -> Maybe String
- stripPrefixIfNeeded :: String -> String -> Maybe String -> Maybe String
- addCurrent :: Maybe (BWNote, [String]) -> [BWNote] -> [BWNote]
- cabalErrorLine :: FilePath -> FilePath -> String -> Maybe (BWNote, [String])
- parseBuildMessages :: FilePath -> FilePath -> FilePath -> String -> [BWNote]
- validLoc :: FilePath -> FilePath -> FilePath -> FilePath
- readInt :: String -> Int -> Int
- makeNote :: BWNote -> [String] -> BWNote
- getBuiltPath :: String -> Maybe FilePath
- data CabalBuildInfo = CabalBuildInfo {}
- canonicalizeBuildInfo :: CabalBuildInfo -> BuildWrapper CabalBuildInfo
- onModulePathsM :: Monad a => ([(Maybe ModuleName, FilePath)] -> a [(Maybe ModuleName, FilePath)]) -> CabalBuildInfo -> a CabalBuildInfo
- onModulePaths :: ([(Maybe ModuleName, FilePath)] -> [(Maybe ModuleName, FilePath)]) -> CabalBuildInfo -> CabalBuildInfo
- getBuildInfo :: FilePath -> Maybe String -> BuildWrapper (OpResult (Maybe (LocalBuildInfo, CabalBuildInfo)))
- fileGhcOptions :: (LocalBuildInfo, CabalBuildInfo) -> BuildWrapper [String]
- fileCppOptions :: CabalBuildInfo -> [String]
- cabalExtensions :: CabalBuildInfo -> (ModuleName, [String])
- getSourceDirs :: BuildInfo -> [FilePath]
- getAllFiles :: LocalBuildInfo -> BuildWrapper [CabalBuildInfo]
- getReferencedFiles :: LocalBuildInfo -> BuildWrapper [CabalBuildInfo]
- stringToModuleName :: String -> Maybe ModuleName
- moduleToString :: ModuleName -> String
- cabalComponents :: BuildWrapper (OpResult [CabalComponent])
- cabalDependencies :: BuildWrapper (OpResult [(FilePath, [CabalPackage])])
- dependencies :: PackageDescription -> [(FilePath, [InstalledPackageInfo])] -> [(FilePath, [CabalPackage])]
- cabalComponentsFromDescription :: PackageDescription -> [CabalComponent]
- cabalComponentFromLibrary :: Library -> CabalComponent
- cabalComponentFromExecutable :: Executable -> CabalComponent
- cabalComponentFromTestSuite :: TestSuite -> CabalComponent
Documentation
:: Bool | do we want output (True) or just compilation without linking? |
-> WhichCabal | use original cabal or temp cabal file |
-> BuildWrapper (OpResult BuildResult) |
run cabal build
:: Bool | can we rerun configure again |
-> Bool | do we want output (True) or just compilation without linking? |
-> WhichCabal | use original cabal or temp cabal file |
-> BuildWrapper (OpResult BuildResult) |
run cabal build
:: WhichCabal | use original cabal or temp cabal file |
-> BuildWrapper (OpResult (Maybe LocalBuildInfo)) | return the build info on success, or Nothing on failure |
run cabal configure
:: WhichCabal | use original cabal or temp cabal file |
-> BuildWrapper FilePath |
get the full path to the cabal file
:: WhichCabal | use original cabal or temp cabal file |
-> BuildWrapper (OpResult (Maybe LocalBuildInfo)) |
get Cabal build info, running configure if needed
:: WhichCabal | use original cabal or temp cabal file |
-> (LocalBuildInfo -> BuildWrapper a) | action to run if we get a build info |
-> BuildWrapper (OpResult (Maybe a)) | the result of the action, or Nothing if we could get Cabal info |
run a action with the cabal build info
parse cabal error messages and transform them in notre
:: FilePath | cabal file |
-> FilePath | path to cabal executable |
-> FilePath | the dist directory |
-> String | the build output |
-> [BWNote] |
parse messages from build
get the path of a file getting compiled
data CabalBuildInfo Source
the cabal build info for a specific component
CabalBuildInfo | |
|
canonicalizeBuildInfo :: CabalBuildInfo -> BuildWrapper CabalBuildInfoSource
canonicalize the paths in the build info
:: Monad a | |
=> ([(Maybe ModuleName, FilePath)] -> a [(Maybe ModuleName, FilePath)]) | the function to apply |
-> CabalBuildInfo | the original build info |
-> a CabalBuildInfo | the result |
apply a function on the build info modules and paths, in a monad
:: ([(Maybe ModuleName, FilePath)] -> [(Maybe ModuleName, FilePath)]) | the function to apply |
-> CabalBuildInfo | the original build info |
-> CabalBuildInfo | the result |
apply a function on the build info modules and paths
:: FilePath | the source file |
-> Maybe String | the cabal component to use, or Nothing if not specified |
-> BuildWrapper (OpResult (Maybe (LocalBuildInfo, CabalBuildInfo))) |
get the build info for a given source file if a source file is in several component, get the first one
:: (LocalBuildInfo, CabalBuildInfo) | the cabal info |
-> BuildWrapper [String] | the module name and the options to pass GHC |
get GHC options for a file
:: CabalBuildInfo | the cabal info |
-> [String] | the list of CPP options |
get CPP options for a file
:: CabalBuildInfo | the cabal info |
-> (ModuleName, [String]) | the module name and cabal extensions |
get the cabal extensions
get the source directory from a build info
:: LocalBuildInfo | the build info |
-> BuildWrapper [CabalBuildInfo] |
get all components, referencing all the files found in the source folders
getReferencedFiles :: LocalBuildInfo -> BuildWrapper [CabalBuildInfo]Source
get all components, referencing only the files explicitely indicated in the cabal file
moduleToString :: ModuleName -> StringSource
convert a ModuleName to a String
cabalComponents :: BuildWrapper (OpResult [CabalComponent])Source
get all components in the Cabal file
:: BuildWrapper (OpResult [(FilePath, [CabalPackage])]) | the result is an array of tuples: the path to the package database, the list of packages in that db that the Cabal file references |
get all the dependencies in the cabal file
:: PackageDescription | the cabal description |
-> [(FilePath, [InstalledPackageInfo])] | the installed packages, by package database location |
-> [(FilePath, [CabalPackage])] | the referenced packages, by package database location |
get all dependencies from the package description and the list of installed packages
cabalComponentsFromDescriptionSource
:: PackageDescription | the package description |
-> [CabalComponent] |
get all components from the package description