endif
### define sources for the front-end and backend
-
-GTKsources = gtk/xboard.c gtk/xboard.h \
+GTKsources = gtk/xboard.c gtk/xboard.h \
gtk/xoptions.c gtk/xtimer.c \
gtk/xengineoutput.c
-Xsources = xaw/xboard.c xaw/xboard.h \
- xaw/xengineoutput.c \
+Xsources = xaw/xboard.c xaw/xboard.h \
+ xaw/xengineoutput.c \
xaw/xgamelist.c xaw/xgamelist.h \
- xaw/xhistory.c xaw/xhistory.h \
- xaw/xoptions.c
-
+ xaw/xhistory.c xaw/xhistory.h \
+ xaw/xoptions.c \
+ bitmaps/checkmark.bm bitmaps/icon_black.bm bitmaps/icon_white.bm
+
+if withGTK
+ FRONTENDsources = $(GTKsources)
+ FRONTENDextras = $(Xsources)
+ headers = -I gtk
+endif
+if withXaw
+ FRONTENDsources = $(Xsources)
+ FRONTENDextras = $(GTKsources)
+ headers = -I xaw -DX11
+endif
-backendsources = backend.c backend.h backendz.h \
+xboard_SOURCES = backend.c backend.h backendz.h \
book.c \
childio.c childio.h \
common.h \
history.c nhistory.c \
menus.c menus.h \
usounds.c usystem.c usystem.h \
- $(ZPY)
-
-### combine sources depending on front-end
-
-if withGTK
- xboard_SOURCES = $(backendsources) $(GTKsources)
- headers = -I gtk
-endif
-if withXaw
- xboard_SOURCES = $(backendsources) $(Xsources)
- headers = -I xaw -DX11
-endif
+ $(ZPY) $(FRONTENDsources)
###
xboard.texi gpl.texinfo texi2man texinfo.tex xboard.man xboard.desktop \
xboard-fen-viewer.desktop xboard-pgn-viewer.desktop xboard-tourney.desktop xboard.xml \
COPYRIGHT FAQ.html engine-intf.html ics-parsing.txt readme.htm zippy.README \
- xboard.conf.in SHORTLOG DIFFSTAT history.c ABOUT-NLS
+ xboard.conf.in SHORTLOG DIFFSTAT history.c ABOUT-NLS $(FRONTENDextras)
DISTCLEANFILES = stamp-h
[with_Xaw=yes],
[with_Xaw=no])
-dnl | make results available in Makefile.am
-AM_CONDITIONAL([withGTK], [test x"$with_GTK" = x"yes"])
-AM_CONDITIONAL([withXaw], [test x"$with_Xaw3d" = x"yes"])
-AM_CONDITIONAL([withXaw], [test x"$with_Xaw" = x"yes"])
-
dnl | check for libraries
if test x"$with_GTK" = x"yes" ; then
PKG_CHECK_MODULES([GTK], [ gtk+-2.0 >= 2.16.0 gmodule-2.0 ])
[AC_MSG_ERROR([--with-Xaw3d was given, but test for Xaw3d failed. Make sure that you have Xaw3d installed, else you might want to try the configure option --without-Xaw3d])],
[-lXaw])])
-dnl | no Xaw3d, check for Xaw
+dnl | no Xaw3d, check for Xaw; make it the default
if test x"$with_Xaw3d" = x"no" ; then
+ with_Xaw=yes
save_cflags="$CFLAGS"
save_cppflags="$CPPFLAGS"
CFLAGS="$CFLAGS $X_CFLAGS"
fi
+dnl | make results available in Makefile.am
+AM_CONDITIONAL([withGTK], [test x"$with_GTK" = x"yes"])
+AM_CONDITIONAL([withXaw], [test x"$with_Xaw3d" = x"yes"])
+AM_CONDITIONAL([withXaw], [test x"$with_Xaw" = x"yes"])
+
+
AC_SUBST(FRONTEND_CFLAGS)
AC_SUBST(FRONTEND_LIBS)