Commit 2b2008d6 authored by Andrey Mokhov's avatar Andrey Mokhov
Browse files

Add trackBuildSystem switch (perhaps, temporarily).

parent 6b0b4ab1
......@@ -11,6 +11,7 @@ import Oracles.Setting
import Oracles.ArgsHash
import Settings.Args
import Settings.Util
import Settings.User
import Settings.Builders.Ar
-- Build a given target using an appropriate builder and acquiring necessary
......@@ -23,7 +24,7 @@ buildWithResources rs target = do
path <- builderPath builder
argList <- interpret target getArgs
-- The line below forces the rule to be rerun if the args hash has changed
checkArgsHash target
when trackBuildSystem $ checkArgsHash target
withResources rs $ do
putBuild $ "/--------\n" ++ "| Running "
++ show builder ++ " with arguments:"
......
......@@ -9,12 +9,14 @@ import Oracles.PackageData
import Oracles.WindowsRoot
import Oracles.PackageDeps
import Oracles.Dependencies
import Settings.User
import Control.Monad
oracleRules :: Rules ()
oracleRules = do
configOracle -- see Oracles.Base
packageDataOracle -- see Oracles.PackageData
packageDepsOracle -- see Oracles.PackageDeps
dependenciesOracle -- see Oracles.Dependencies
argsHashOracle -- see Oracles.ArgsHash
windowsRootOracle -- see Oracles.WindowsRoot
configOracle -- see Oracles.Base
packageDataOracle -- see Oracles.PackageData
packageDepsOracle -- see Oracles.PackageDeps
dependenciesOracle -- see Oracles.Dependencies
when trackBuildSystem argsHashOracle -- see Oracles.ArgsHash
windowsRootOracle -- see Oracles.WindowsRoot
module Settings.User (
userArgs, userPackages, userWays, userRtsWays, userTargetDirectory,
userKnownPackages, integerLibrary,
buildHaddock, validating, ghciWithDebugger, ghcProfiled,
trackBuildSystem, buildHaddock, validating, ghciWithDebugger, ghcProfiled,
dynamicGhcPrograms, laxDependencies
) where
......@@ -42,6 +42,14 @@ integerLibrary = integerGmp2
-- * Bool: a plain Boolean flag whose value is known at compile time
-- * Action Bool: a flag whose value can depend on the build environment
-- * Predicate: a flag depending on the build environment and the current target
-- Set this to True if you are making any changes in the build system and want
-- appropriate rebuilds to be initiated. Switching this to False speeds things
-- up a little (particularly zero builds).
-- WARNING: changing this setting leads to a complete rebuild.
trackBuildSystem :: Bool
trackBuildSystem = False
validating :: Bool
validating = False
......@@ -59,4 +67,3 @@ laxDependencies = False
buildHaddock :: Predicate
buildHaddock = return True
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment