Drop any mention of a doProfiling flag

This commit is contained in:
John Wiegley 2018-05-30 12:10:31 -07:00
parent d40b3f15cb
commit 5c5e90170e
No known key found for this signature in database
GPG key ID: C144D8F4F19FE630
2 changed files with 12 additions and 17 deletions

View file

@ -47,8 +47,8 @@ To build `hnix` for debugging, and with full tracing output and stack traces,
use:
```
$ nix-shell --arg doProfiling true
$ cabal configure --enable-tests --enable-profiling --flags=tracing
$ nix-shell
$ cabal configure --enable-tests --enable-profiling --flags=profiling --flags=tracing
$ cabal build
$ ./dist/build/hnix/hnix -v5 --trace <args> +RTS -xc
```
@ -72,8 +72,8 @@ $ cabal bench
To build `hnix` with profiling enabled:
```
$ nix-shell --arg doProfiling true
$ cabal configure --enable-tests --enable-profiling
$ nix-shell
$ cabal configure --enable-tests --enable-profiling --flags=profiling
$ cabal build
$ ./dist/build/hnix/hnix <args> +RTS -p
```

View file

@ -35,20 +35,16 @@ let
serialise = dontCheck super.serialise;
ghc-datasize =
if doProfiling
then null
else overrideCabal super.ghc-datasize (attrs: {
enableLibraryProfiling = false;
enableExecutableProfiling = false;
});
overrideCabal super.ghc-datasize (attrs: {
enableLibraryProfiling = false;
enableExecutableProfiling = false;
});
ghc-heap-view =
if doProfiling
then null
else overrideCabal super.ghc-heap-view (attrs: {
enableLibraryProfiling = false;
enableExecutableProfiling = false;
});
overrideCabal super.ghc-heap-view (attrs: {
enableLibraryProfiling = false;
enableExecutableProfiling = false;
});
});
});
@ -85,7 +81,6 @@ in haskellPackages.developPackage {
configureFlags =
pkgs.stdenv.lib.optional doTracing "--flags=tracing"
++ pkgs.stdenv.lib.optionals doProfiling ["--flags=profiling" "--enable-profiling"]
++ pkgs.stdenv.lib.optional doStrict "--ghc-options=-Werror";
});