]> code.delx.au - gnu-emacs-elpa/blob - Makefile.am
Added chess-ics2.el, from Dmitry "Troydm" Geurkov
[gnu-emacs-elpa] / Makefile.am
1 BUILT_SOURCES = chess-auto.el
2 CLEANFILES = TAGS chess-auto.el auto-autoloads.el
3 EXTRA_DIST = autogen.sh chess-auto.el.in chess-eco.pos doc/chess.pdf
4 DISTCLEANFILES = chess-eco.fen doc/chess.info doc/chess.pdf $(TESTS)
5 info_TEXINFOS = doc/chess.texi
6 dist_lisp_DATA = _pkg.el chess-eco.fen
7
8 dist_lisp_LISP = \
9 chess.el \
10 chess-ai.el \
11 chess-algebraic.el \
12 chess-announce.el \
13 chess-auto.el \
14 chess-autosave.el \
15 chess-chat.el \
16 chess-clock.el \
17 chess-common.el \
18 chess-crafty.el \
19 chess-database.el \
20 chess-display.el \
21 chess-engine.el \
22 chess-epd.el \
23 chess-fen.el \
24 chess-file.el \
25 chess-game.el \
26 chess-german.el \
27 chess-gnuchess.el \
28 chess-ics.el \
29 chess-ics1.el \
30 chess-ics2.el \
31 chess-images.el \
32 chess-input.el \
33 chess-irc.el \
34 chess-kibitz.el \
35 chess-link.el \
36 chess-log.el \
37 chess-message.el \
38 chess-module.el \
39 chess-network.el \
40 chess-none.el \
41 chess-pgn.el \
42 chess-phalanx.el \
43 chess-plain.el \
44 chess-ply.el \
45 chess-pos.el \
46 chess-puzzle.el \
47 chess-random.el \
48 chess-scid.el \
49 chess-sjeng.el \
50 chess-sound.el \
51 chess-test.el \
52 chess-transport.el \
53 chess-tutorial.el \
54 chess-ucb.el \
55 chess-var.el \
56 chess-eco.el
57
58 chess-auto.el: $(ELFILES)
59 echo ";;; DO NOT MODIFY THIS FILE" > $(top_builddir)/chess-auto.el
60 echo "(if (featurep 'chess-auto) (error \"Already loaded\"))" \
61 >> $(top_builddir)/chess-auto.el
62 $(EMACS) -batch -L $(srcdir) -l chess-maint.el \
63 -f chess-generate-autoloads \
64 $(top_builddir)/chess-auto.el $(srcdir)
65 echo "(provide 'chess-auto)" >> $(top_builddir)/chess-auto.el
66 ln -f $(top_builddir)/chess-auto.el $(top_builddir)/auto-autoloads.el
67
68 chess-eco.fen: chess-eco.pos chess-eco.el
69 $(EMACS) --no-init-file --no-site-file -batch \
70 -L $(srcdir) -l chess-eco -f chess-generate-fen-table \
71 chess-eco.pos chess-eco.fen
72
73 TESTS = chess-test
74 DATABASE = $(shell test -r test/largedb.sg3 && echo test/largedb || echo test/historic.pgn)
75 START = $(shell test -r test/largedb.sg3 && perl -e 'print int(rand(4000000)), "\n";' || echo 0)
76 COUNT = 100000
77
78 # Note: There are 4,209,433 games in test/largedb, if you download the files
79 # from:
80 #
81 # ftp://ftp.newartisans.com/pub/chess/largedb.7z
82 #
83 # If you have a dual-core CPU (or more), you'll get the best performance by
84 # running a separate Emacs for each core. Here's how I run all the tests on
85 # my dual-core MacBook Pro: (Note, removing chess-test is just a precaution,
86 # since the Makefile will not regenerate it if you aborted a previous test
87 # run).
88 #
89 # chess1 $ rm -f chess-test; nice -n 20 make START=0 COUNT=2104715 check
90 # chess2 $ rm -f chess-test; nice -n 20 make START=2104715 COUNT=0 check
91 #
92 # I run both of these using `screen', with a vertical split so I can watch
93 # them both running. I type C-a H in each screen window before starting, so
94 # that all the output is logged to a file I can examine afterward.
95 #
96 # Note that these tests can take days to run. My MacBook Pro gets around
97 # 2,000 plies per second. If you're a Lisp hacker and want to improve the
98 # speed of that, the slowness is pretty much all in `chess-search-position',
99 # in the file chess-pos.el.
100
101 chess-test:
102 echo "$(EMACS) -batch -L $(srcdir) -l chess-test.el -f chess-test '$(DATABASE)' $(START) $(COUNT); rm -f $(top_builddir)/chess-test" > $@
103 chmod u+x $@
104
105 TAGS: $(dist_lisp_LISP)
106 @etags $(dist_lisp_LISP)
107 @echo TAGS rebuilt.
108
109 # Makefile.am ends here