faster fast builds

This commit is contained in:
Joey Hess 2013-02-27 20:07:30 -04:00
parent 95a244d9c4
commit b1e1043bdb
2 changed files with 8 additions and 2 deletions

View file

@ -10,11 +10,11 @@ build: $(all)
# We bypass cabal, and only run the main ghc --make command for a
# fast development built. Note: Does not rebuild C libraries.
fast: dist/caballog
$$(grep 'ghc --make' dist/caballog | head -n 1 | sed 's/ -O / /')
$$(grep 'ghc --make' dist/caballog | head -n 1)
ln -sf dist/build/git-annex/git-annex git-annex
dist/caballog:
cabal configure -f-Production
cabal configure -f"-Production Fast"
cabal build -v2 | tee $@
Build/SysConfig.hs: configure.hs Build/TestConfig.hs Build/Configure.hs

View file

@ -55,6 +55,9 @@ Flag DNS
Flag Production
Description: Enable production build (slower build; faster binary)
Flag Fast
Description: Faster build; slower binary
Flag Android
Description: Building for Android
Default: False
@ -81,6 +84,9 @@ Executable git-annex
if flag(Production)
GHC-Options: -O2
if flag(Fast)
GHC-Options: -O0
if flag(TestSuite)
Build-Depends: testpack, HUnit
CPP-Options: -DWITH_TESTSUITE