1 include $(top_srcdir)/common.mk
3 PHONY=check test all check-elget test-elget help
4 EXTRA_DIST += gcd.py gcd.rb gdb
6 #: overall help on running the make targets
8 @echo "The main function of this Makefile is to facilitate running tests."
10 @echo "To run all of the tests, use targets \"test\", \"check\" or \"check-short\"."
15 @echo " make check-short"
17 @echo "The -short target uses a filter written in Ruby to remove extreanous output."
19 @echo "To run a specific test like test-srcbuf.el, change \".el\" to"
20 @echo "\".run\". For example:"
22 @echo " make test-srcbuf.run"
24 @echo "Tests can also be run via the Emacs el-get package and this loads dependent emacs "
25 @echo "package, like load-relative. To do this, use targets, \"check-elget\","
26 @echo "\"test-elget\", or \"check-short-elget\"."
28 @echo "To run a specific test like test-srcbuf.el via el-get change \".el\""
29 @echo "to \".elrun\" For example:"
31 @echo " make test-srcbuf.elrun"
34 #: same thing as "check"
37 #: same thing as "check-elget"
38 test-elget: check-elget
40 test_files := $(wildcard test-*.el)
42 CHECK_FILES = $(notdir $(test_files:.el=.run))
43 EL_GET_CHECK_FILES = $(notdir $(test_files:.el=.elrun))
48 #: Run all tests via el-get
49 check-elget: $(EL_GET_CHECK_FILES)
51 #: Run all tests with minimum verbosity
53 $(MAKE) check 2>&1 | ruby ../make-check-filter.rb
55 #: Run all tests with minimum verbosity via el-get
57 $(MAKE) check-elget 2>&1 | ruby ../make-check-filter.rb
60 (cd $(top_srcdir)/test && $(EMACS) --batch --no-site-file --no-splash --load $(@:.run=.el))
62 #: Run tests using el-get to specify external Lisp dependencies
64 (cd $(top_srcdir)/test && $(EMACS) --batch --no-site-file --no-splash --load ../el-get-install.el --load $(@:.elrun=.el))
66 # Whatever it is you want to do, it should be forwarded to the
67 # to top-level directories