Fix various regression for building out of tree.
[gnushogi.git] / gnushogi / Makefile.in
index 09d4245..1596717 100644 (file)
@@ -11,8 +11,8 @@
 #
 # GNU Shogi is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either ../version 3 of the License, or (at your option)
-# any later ../version.
+# the Free Software Foundation; either version 3 of the License, or (at your option)
+# any later version.
 #
 # GNU Shogi is distributed in the hope that it will be useful,
 # but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -60,7 +60,7 @@ INFODIR = $(prefix)/info
 LIBS    = -lm
 
 # Display routines.
-LCURSES =   -lcurses -ltermcap
+LCURSES = @LIBCURSES@
 
 
 #
@@ -87,17 +87,11 @@ TEXTBOOK   = -DBOOK=\"$(LIBDIR)/gnushogi.tbk\"
 BINBOOK    = -DBINBOOK=\"$(LIBDIR)/gnushogi.bbk\"
 
 
-# The language file describes capabilities of the program.  It may
-# be useful for customizing gnushogi for non-English-speaking players.
-
-LANGF      = -DLANGFILE=\"../misc/gnushogi.lng\"
-
-
 # The pattern file contains various opening patterns. The program tries to
 # obtain such a pattern in the opening stage. Sequences of opening
 # patterns may be described in order to support the correct order of moves.
 
-PATTERN    = -DPATTERNFILE=\"../misc/gnushogi.pat\"
+PATTERN    = -DPATTERNFILE=\"$(ROOT)/misc/gnushogi.pat\"
 
 
 all:
@@ -112,7 +106,7 @@ COMMONFILES = \
                 attacks.o      \
                 book.o         \
                 commondsp.o    \
-                cursesdsp.o    \
+                @CURSESDSP@    \
                 dspwrappers.o  \
                 eval.o         \
                 genmove.o      \
@@ -177,7 +171,7 @@ eval.o: eval.c
        $(CC) $(CFLAGS) -c $<
 
 init.o: init.c
-       $(CC)  $(CFLAGS) $(LANGF) -c $<
+       $(CC)  $(CFLAGS) -c $<
 
 main.o: main.c
        $(CC) $(CFLAGS) $(BINBOOK) -c $<
@@ -207,7 +201,7 @@ util.o: util.c
 # Files specific to particular targets.
 
 pat2inc.o: pat2inc.c
-       $(CC) $(CFLAGS) $(LANGF) $(BINBOOK) $(PATTERN) -c $<
+       $(CC) $(CFLAGS) $(BINBOOK) $(PATTERN) -c $<
 
 sizetest.o: sizetest.c
        $(CC) $(CFLAGS) -c $<
@@ -261,22 +255,22 @@ clean:
 gnushogi:   $(GNUSHOGI_FILES)
 pat2inc:       $(PAT2INCFILES)
 sizetest:      sizetest.o 
-attacks.o:     attacks.c gnushogi.h $(ROOT)/version.h
-book.o:        book.c gnushogi.h $(ROOT)/version.h
-commondsp.o:   commondsp.c gnushogi.h $(ROOT)/version.h
-cursesdsp.o:   cursesdsp.c gnushogi.h $(ROOT)/version.h
-dspwrappers.o: dspwrappers.c gnushogi.h $(ROOT)/version.h
-genmove.o:     genmove.c gnushogi.h $(ROOT)/version.h
-globals.o:     globals.c gnushogi.h $(ROOT)/version.h
-eval.o:        eval.c eval.h gnushogi.h $(ROOT)/version.h $(SRCDIR)/pattern.h
-init.o:        init.c gnushogi.h $(ROOT)/version.h $(SRCDIR)/pattern.h
-main.o:        main.c gnushogi.h $(ROOT)/version.h
+attacks.o:     attacks.c gnushogi.h
+book.o:        book.c gnushogi.h
+commondsp.o:   commondsp.c gnushogi.h
+cursesdsp.o:   cursesdsp.c gnushogi.h
+dspwrappers.o: dspwrappers.c gnushogi.h
+genmove.o:     genmove.c gnushogi.h
+globals.o:     globals.c gnushogi.h
+eval.o:        eval.c eval.h gnushogi.h $(SRCDIR)/pattern.h
+init.o:        init.c gnushogi.h $(SRCDIR)/pattern.h
+main.o:        main.c gnushogi.h
 makepattern.o: pattern.c gnushogi.h $(SRCDIR)/pattern.h
 pattern.o:     pattern.c gnushogi.h $(SRCDIR)/pattern.h $(SRCDIR)/pattern.inc
-rawdsp.o:      rawdsp.c gnushogi.h $(ROOT)/version.h
-search.o:      search.c gnushogi.h $(ROOT)/version.h
-tcontrl.o:     tcontrl.c gnushogi.h $(ROOT)/version.h
-util.o:        util.c gnushogi.h $(ROOT)/version.h
+rawdsp.o:      rawdsp.c gnushogi.h
+search.o:      search.c gnushogi.h
+tcontrl.o:     tcontrl.c gnushogi.h
+util.o:        util.c gnushogi.h
 pat2inc.o:     pat2inc.c $(SRCDIR)/pattern.h $(SRCDIR)/gnushogi.h
 sizetest.o:    sizetest.c $(SRCDIR)/gnushogi.h $(SRCDIR)/eval.h
 gnushogi.bbk:  gnushogi