2016-10-14 01:41:39 +03:00
|
|
|
.PHONY: build configure doc install linecount nodefault pinstall lib_clean relib fast test_js test_c stylize test test_clean lib_doc lib_doc_clean user_doc_html user_doc_pdf user_docs
|
2016-07-27 15:46:10 +03:00
|
|
|
|
|
|
|
ARGS=
|
|
|
|
TEST-JOBS=
|
|
|
|
TEST-ARGS=
|
2013-03-21 20:14:37 +04:00
|
|
|
|
2012-10-29 22:56:53 +04:00
|
|
|
include config.mk
|
2013-03-21 20:14:37 +04:00
|
|
|
-include custom.mk
|
2012-10-29 22:56:53 +04:00
|
|
|
|
2015-01-04 20:04:02 +03:00
|
|
|
ifdef CI
|
|
|
|
CABALFLAGS += -f CI
|
2016-08-03 02:02:04 +03:00
|
|
|
ifndef APPVEYOR
|
2016-07-27 15:46:10 +03:00
|
|
|
TEST-ARGS += --color always
|
2015-01-04 20:04:02 +03:00
|
|
|
endif
|
2016-08-03 02:02:04 +03:00
|
|
|
endif
|
2015-01-04 20:04:02 +03:00
|
|
|
|
2013-03-21 20:14:37 +04:00
|
|
|
install:
|
2019-08-28 02:09:23 +03:00
|
|
|
$(CABAL) v1-install $(CABALFLAGS)
|
2011-10-14 20:59:53 +04:00
|
|
|
|
2013-03-21 20:14:37 +04:00
|
|
|
pinstall: CABALFLAGS += --enable-executable-profiling
|
|
|
|
pinstall: dist/setup-config
|
2019-08-28 02:09:23 +03:00
|
|
|
$(CABAL) v1-install $(CABALFLAGS)
|
2011-10-25 15:46:47 +04:00
|
|
|
|
2013-03-21 20:14:37 +04:00
|
|
|
build: dist/setup-config
|
2019-08-28 02:09:23 +03:00
|
|
|
$(CABAL) v1-build $(CABALFLAGS)
|
2011-10-14 20:59:53 +04:00
|
|
|
|
2016-10-20 00:36:24 +03:00
|
|
|
test: doc test_c stylize
|
2016-10-14 01:41:39 +03:00
|
|
|
|
|
|
|
stylize:
|
|
|
|
./stylize.sh
|
2013-11-30 18:10:26 +04:00
|
|
|
|
|
|
|
test_c:
|
2020-01-25 07:49:53 +03:00
|
|
|
$(CABAL) v1-test $(ARGS) --test-options \
|
2016-07-27 15:46:10 +03:00
|
|
|
"$(TEST-ARGS) --rerun-update +RTS -N$(TEST-JOBS) -RTS"
|
2013-10-09 02:20:06 +04:00
|
|
|
|
2014-01-30 18:41:34 +04:00
|
|
|
test_js:
|
2020-01-25 07:49:53 +03:00
|
|
|
$(CABAL) v1-test $(ARGS) --test-options \
|
2016-07-27 15:46:10 +03:00
|
|
|
"$(TEST-ARGS) --node --rerun-update +RTS -N$(TEST-JOBS) -RTS"
|
|
|
|
|
|
|
|
test_update:
|
2020-01-25 07:49:53 +03:00
|
|
|
$(CABAL) v1-test $(ARGS) --test-options \
|
2016-07-27 15:46:10 +03:00
|
|
|
"$(TEST-ARGS) --accept +RTS -N$(TEST-JOBS) -RTS"
|
2014-01-30 18:41:34 +04:00
|
|
|
|
2016-07-27 15:46:10 +03:00
|
|
|
test_clean:
|
|
|
|
rm -f test/*~
|
|
|
|
rm -f test/*/output
|
2015-12-15 23:01:14 +03:00
|
|
|
|
2013-11-03 15:06:55 +04:00
|
|
|
lib_clean:
|
2013-11-20 21:38:22 +04:00
|
|
|
$(MAKE) -C libs IDRIS=../../dist/build/idris/idris RTS=../../dist/build/rts/libidris_rts clean
|
2013-11-03 15:06:55 +04:00
|
|
|
|
|
|
|
relib: lib_clean
|
2019-08-28 02:09:23 +03:00
|
|
|
$(CABAL) v1-install $(CABALFLAGS)
|
2012-01-18 18:34:47 +04:00
|
|
|
|
2013-03-21 20:14:37 +04:00
|
|
|
linecount:
|
2015-10-19 01:08:35 +03:00
|
|
|
wc -l src/Idris/*.hs src/Idris/Elab/*.hs src/Idris/Core/*.hs src/IRTS/*.hs src/Pkg/*.hs src/Util/*.hs
|
2011-10-14 20:59:53 +04:00
|
|
|
|
2013-02-26 14:17:12 +04:00
|
|
|
#Note: this doesn't yet link to Hackage properly
|
2013-03-21 20:14:37 +04:00
|
|
|
doc: dist/setup-config
|
2020-01-25 05:58:36 +03:00
|
|
|
$(CABAL) v1-haddock --hyperlink-source --html --hoogle --html-location="https://hackage.haskell.org/packages/archive/\$$pkg/latest/doc/html" --haddock-options="--title Idris"
|
2013-02-26 14:17:12 +04:00
|
|
|
|
2014-05-21 14:29:59 +04:00
|
|
|
lib_doc:
|
2014-06-12 20:50:04 +04:00
|
|
|
$(MAKE) -C libs IDRIS=../../dist/build/idris/idris doc
|
2014-05-21 14:29:59 +04:00
|
|
|
|
|
|
|
lib_doc_clean:
|
2014-06-12 20:50:04 +04:00
|
|
|
$(MAKE) -C libs IDRIS=../../dist/build/idris/idris doc_clean
|
2011-10-14 20:59:53 +04:00
|
|
|
|
2015-03-18 10:44:23 +03:00
|
|
|
user_docs: user_doc_html user_doc_pdf
|
|
|
|
|
|
|
|
user_doc_clean:
|
|
|
|
$(MAKE) -C docs clean
|
|
|
|
|
|
|
|
user_doc_html:
|
|
|
|
$(MAKE) -C docs html
|
|
|
|
|
|
|
|
user_doc_pdf:
|
|
|
|
$(MAKE) -C docs latexpdf
|
|
|
|
|
2015-07-13 17:23:30 +03:00
|
|
|
fast:
|
2019-08-28 02:09:23 +03:00
|
|
|
$(CABAL) v1-install $(CABALFLAGS) --ghc-option=-O0
|
2015-07-13 17:23:30 +03:00
|
|
|
|
2013-03-21 20:14:37 +04:00
|
|
|
dist/setup-config:
|
2019-08-28 02:09:23 +03:00
|
|
|
$(CABAL) v1-configure $(CABALFLAGS)
|