on master help sign in
Use cabal instead of runghc Setup if available

--HG-- extra : convert_revision : 47402ade1e4b59e3357b65cbeaa3af48176456fa

commit29ba0abcf4b96b8804cec1f539fcf6b6c86e729e authorBryan O'Sullivan <bos@serpentine.com> dateSat 15 Aug 2009, 04:42 (17 years ago) parent1688bac
1 file changed+7
tests/Makefile+7
tests/Makefile+7
@@ -9,13 +9,20 @@ lib := ../dist/build/libHStext-$(version).a
99lib-srcs := $(shell grep '^ *Data' ../text.cabal | \
1010 sed -e 's,\.,/,g' -e 's,$$,.hs,')
1111
12+cabal := $(shell which cabal 2>/dev/null)
13+
1214all: qc coverage
1315
1416lib: $(lib)
1517
1618$(lib): $(lib-srcs:%=../%)
19+ifeq ($(cabal),)
1720 cd .. && runghc Setup configure --user --prefix=$(HOME)
1821 cd .. && runghc Setup build
22+else
23+ cd .. && cabal configure
24+ cd .. && cabal build
25+endif
1926
2027Properties.o: QuickCheckUtils.o
2128