A new macro MANDIR is passed fro the configure process to the compiler
in a -D option to inform XBoard where to find its manual page.
GITVERSION=$(shell sh -c 'git describe --dirty --always 2>/dev/null')
AM_CPPFLAGS=-DINFODIR='"$(infodir)"' @X_CFLAGS@ @CAIRO_CFLAGS@ @FRONTEND_CFLAGS@ -DSYSCONFDIR='"$(sysconfdir)"' \
-DLOCALEDIR='"$(localedir)"' -DSVGDIR='"$(svgdir)"' -D__GIT_VERSION='"$(GITVERSION)"' \
- -DCONFIGURE_OPTIONS='"@CONFIGURE_OPTIONS@"' -DDATADIR='"$(datadir)/games/xboard"' $(headers)
+ -DCONFIGURE_OPTIONS='"@CONFIGURE_OPTIONS@"' -DDATADIR='"$(datadir)/games/xboard"' -DMANDIR='"$(mandir)"' $(headers)
ACLOCAL_AMFLAGS = -I m4
void
DisplayHelp (char *name)
{
- char *manFile = DATADIR "/../../man/man6/xboard.6";
+ char *manFile = MANDIR "/man6/xboard.6";
FILE *f = fopen(manFile, "r");
if(f) {
GetHelpText(f, name);