drasil-build-0.1.1.0: A framework for code and document generation for scientific software - Build System SubPackage
Safe HaskellSafe-Inferred
LanguageHaskell2010

Build.Drasil

Description

Re-export all contents in drasil-build for external use.

Synopsis

Makefiles

Classes

class RuleTransformer c where Source #

Members can be transformed into a make rule.

Methods

makeRule :: c -> [Rule] Source #

Types and Functions

type Annotation = [Comment] Source #

A Makefile Annotation is made of 0 or more Comments

data Command Source #

A command is made up of MakeStrings and command operators.

mkCheckedCommand :: MakeString -> Command Source #

Creates a Command which fails the make process if it does not return zero.

mkCommand :: MakeString -> Command Source #

Creates a command which executes and ignores the return code.

type Dependencies = [Target] Source #

Dependencies are made up of 0 or more Targets.

data Rule Source #

A Makefile Rule can have comments and commands but needs a target, dependencies, and a type.

mkFile :: Annotation -> Target -> Dependencies -> [Command] -> Rule Source #

Creates a Rule which results in a file being created.

mkRule :: Annotation -> Target -> Dependencies -> [Command] -> Rule Source #

Creates an abstract Rule not associated to a specific file.

(+:+) :: MakeString -> MakeString -> MakeString Source #

Concatenates two MakeStrings with a space in between.

makeS :: String -> MakeString Source #

Constructor for converting a String into a MakeString.

mkFreeVar :: VarName -> MakeString Source #

Constructor for Free variables.

mkImplicitVar :: VarName -> MakeString Source #

Constructor for Implicit variables.

mkWindowsVar :: VarName -> VarVal -> VarVal -> MakeString Source #

Constructor for Windows OS variables.

mkOSVar :: VarName -> VarVal -> VarVal -> VarVal -> MakeString Source #

Constructor for OS variables.

Printers

genMake :: RuleTransformer c => [c] -> Doc Source #

Generates the makefile by calling build after toMake.