2 # Makefile for GNU Shogi
4 # Copyright (c) 2013 Yann Dirson and the Free Software Foundation
6 # This file is part of GNU Shogi.
8 # GNU Shogi is free software; you can redistribute it and/or modify
9 # it under the terms of the GNU General Public License as published by
10 # the Free Software Foundation; either version 1, or (at your option)
13 # GNU Shogi is distributed in the hope that it will be useful,
14 # but WITHOUT ANY WARRANTY; without even the implied warranty of
15 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 # GNU General Public License for more details.
18 # You should have received a copy of the GNU General Public License
19 # along with GNU Shogi; see the file COPYING. If not, write to
20 # the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
23 pkgbindatadir = $(pkglibdir)
25 bin_PROGRAMS = gnushogi gnuminishogi
26 noinst_PROGRAMS = pat2inc sizetest
28 pkgbindata_DATA = gnushogi.bbk
29 # gnuminishogi.bbk would be empty
31 AM_CFLAGS = @CEXTRAFLAGS@ @WARNINGS@
33 # The hashfile is a record of positions seen. It is used by
34 # GNU Shogi to avoid making the same mistakes, a form of learning.
36 HASH = -DHASHFILE=\"$(pkglibdir)/$(PROGNAME).hsh\"
39 # The "book" is a record of the first few moves, for playing good
40 # moves easily and quickly, saving time, and irritating the human
43 TEXTBOOK = -DBOOK=\"$(pkglibdir)/$(PROGNAME).tbk\"
44 BINBOOK = -DBINBOOK=\"$(pkglibdir)/$(PROGNAME).bbk\"
47 # The pattern file contains various opening patterns. The program tries to
48 # obtain such a pattern in the opening stage. Sequences of opening
49 # patterns may be described in order to support the correct order of moves.
52 -DHASHFILE=\"$(pkglibdir)/gnushogi.hsh\" \
53 -DBOOK=\"$(pkglibdir)/gnushogi.tbk\" \
54 -DBINBOOK=\"$(pkglibdir)/gnushogi.bbk\"
55 gnuminishogi_CPPFLAGS = \
57 -DHASHFILE=\"$(pkglibdir)/gnuminishogi.hsh\" \
58 -DBOOK=\"$(pkglibdir)/gnuminishogi.tbk\" \
59 -DBINBOOK=\"$(pkglibdir)/gnuminishogi.bbk\"
91 gnuminishogi_SOURCES = \
96 EXTRA_gnushogi_SOURCES = \
98 EXTRA_gnuminishogi_SOURCES = \
102 gnushogi-pattern.inc \
103 gnuminishogi-pattern.inc
105 gnushogi_DEPENDENCIES = @CURSESDSP@
106 gnushogi_LDADD = @CURSESDSP@ @LIBCURSES@
107 gnuminishogi_DEPENDENCIES = @CURSESDSPMINI@
108 gnuminishogi_LDADD = @CURSESDSPMINI@ @LIBCURSES@
115 pat2inc_LDADD = @LIBCURSES@
117 gnushogi-pattern.inc: $(top_srcdir)/misc/gnushogi.pat pat2inc
119 gnuminishogi-pattern.inc: $(top_srcdir)/misc/gnuminishogi.pat pat2inc
122 gnushogi.bbk: $(top_srcdir)/misc/gnushogi.tbk gnushogi
125 echo quit | ./gnushogi -R -b _tmp_t -B $@ -S 8000 -P 40 3 0
127 gnuminishogi.bbk: $(top_srcdir)/misc/gnuminishogi.tbk gnuminishogi
130 echo quit | ./gnuminishogi -R -b _tmp_t -B $@ -S 8000 -P 40 3 0