2004-09-17 20:57:45 +04:00
AC_INIT(settings.xsl.in)
2004-04-07 14:15:11 +04:00
PAPERSIZE=""
2005-06-11 00:29:09 +04:00
ULINK_IN_FOOTNOTE="0"
ULINK_SHOW="1"
2004-04-07 14:15:11 +04:00
DOCROP="0"
2004-05-15 20:36:15 +04:00
AC_ARG_WITH(samba-sources,
[ --with-samba-sources=DIR Specify path to Samba sources],
[ test "$withval" && SPECIFIED_SOURCEDIR="$withval" ])
2004-04-07 14:15:11 +04:00
AC_ARG_ENABLE(crop,
2004-05-15 20:36:15 +04:00
[ --enable-crop Whether to use a crop template],
2005-06-11 00:29:09 +04:00
[ test "$enableval" && DOCROP="1" ])
2004-04-07 14:15:11 +04:00
PAPERSIZE="a4paper"
AC_ARG_WITH(papersize,
2004-05-15 20:36:15 +04:00
[ --with-papersize Specify papersize (a4paper,letter) ],
2004-04-07 14:15:11 +04:00
[ test "$withval" && PAPERSIZE="$withval" ])
2004-08-01 20:11:16 +04:00
AC_ARG_ENABLE(printable,
[ --enable-printable Printable output (expand ulinks, etc)],
2005-06-11 00:29:09 +04:00
[ if test "$enableval"; then
ULINK_IN_FOOTNOTE="1"
ULINK_SHOW="0"
fi ])
2004-08-01 20:11:16 +04:00
2004-04-07 14:15:11 +04:00
DOC_BUILD_DATE=`date '+%d-%m-%Y'`
AC_SUBST(DOC_BUILD_DATE)
AC_SUBST(PAPERSIZE)
2005-06-11 00:29:09 +04:00
AC_SUBST(ULINK_IN_FOOTNOTE)
AC_SUBST(ULINK_SHOW)
2004-04-07 14:15:11 +04:00
AC_SUBST(DOCROP)
2004-05-15 20:36:15 +04:00
AC_SUBST(SAMBASOURCEDIR)
2004-04-07 14:15:11 +04:00
2004-04-23 18:23:36 +04:00
DOCS_TARGET_REQUIRE_PROGRAM(XSLTPROC, xsltproc, ALL)
DOCS_TARGET_REQUIRE_PROGRAM(RM, rm, ALL)
2004-09-05 16:36:21 +04:00
DOCS_TARGET_REQUIRE_PROGRAM(DIA, dia, ALL)
2004-09-05 17:26:10 +04:00
# Check dia version number
2004-09-08 19:25:28 +04:00
[ DIA_VERSION=`$DIA -v | egrep -o '([0-9]+)\.([0-9]+)'`]
2004-09-05 17:26:10 +04:00
DIA_MAJ_VERSION=`echo $DIA_VERSION | cut -d . -f 1`
DIA_MIN_VERSION=`echo $DIA_VERSION | cut -d . -f 2`
if test "$DIA_MAJ_VERSION" -le "0"
then
if test "$DIA_MIN_VERSION" -le "92" && test -z "$DISPLAY"
then
AC_MSG_ERROR([Dia below 0.93 requires an X environment. Set \$DISPLAY or install Dia 0.93 or higher])
fi
fi
2004-04-23 18:23:36 +04:00
DOCS_TARGET_REQUIRE_PROGRAM(MAKEINDEX, makeindex, LATEX)
DOCS_TARGET_REQUIRE_PROGRAM(PDFLATEX, pdflatex, PDF)
DOCS_TARGET_REQUIRE_PROGRAM(EPSTOPDF, epstopdf, PDF)
2004-06-12 17:15:38 +04:00
DOCS_TARGET_REQUIRE_PROGRAM(THUMBPDF, thumbpdf, PDF)
2004-04-23 18:23:36 +04:00
DOCS_TARGET_REQUIRE_PROGRAM(PNGTOPNM, pngtopnm, PS)
DOCS_TARGET_REQUIRE_PROGRAM(PNMTOPS, pnmtops, PS)
DOCS_TARGET_REQUIRE_PROGRAM(LATEX, latex, PS)
DOCS_TARGET_REQUIRE_PROGRAM(DVIPS, dvips, PS)
DOCS_TARGET_REQUIRE_PROGRAM(PLUCKERBUILD, plucker-build, PLUCKER)
2004-05-15 20:09:50 +04:00
DOCS_TARGET_REQUIRE_PROGRAM(HTML2TEXT, html2text, TXT)
2004-04-23 18:23:36 +04:00
DOCS_TARGET_REQUIRE_PROGRAM(PERL, perl, UNDOCUMENTED)
2005-03-17 03:13:11 +03:00
DOCS_TARGET_REQUIRE_PROGRAM(XMLLINT, xmllint, VALIDATE)
2005-02-10 11:51:11 +03:00
DOCS_TARGET_REQUIRE_PROGRAM(FOP, fop, FOPDF)
2005-03-11 19:26:19 +03:00
DOCS_TARGET_REQUIRE_PROGRAM(DB2TEXI, docbook2x-texi, TEXI)
DOCS_TARGET_REQUIRE_PROGRAM(MAKEINFO, makeinfo, TEXIINFO)
2005-03-11 18:57:45 +03:00
DOCS_TARGET_REQUIRE_DIR([$SPECIFIED_SOURCEDIR $SPECIFIED_SOURCEDIR/source ..], [param/loadparm.c], SAMBASOURCEDIR, UNDOCUMENTED)
2004-04-23 18:23:36 +04:00
AC_MSG_RESULT([])
AC_MSG_RESULT([Summary:])
AC_MSG_RESULT([--------------])
DOCS_DEFINE_TARGET(ALL, [], [base requirements], [])
DOCS_DEFINE_TARGET(LATEX, ALL, [LaTeX versions], [tex])
DOCS_DEFINE_TARGET(PDF, LATEX, [PDF versions], [pdf])
DOCS_DEFINE_TARGET(PS, LATEX, [PostScript versions], [ps])
DOCS_DEFINE_TARGET(HTML, ALL, [HTML versions], [html])
2004-06-15 01:25:16 +04:00
DOCS_DEFINE_TARGET(HTMLHELP, ALL, [HTML Help versions], [htmlhelp])
2005-06-12 20:46:09 +04:00
DOCS_DEFINE_TARGET(HTMLMAN, ALL, [HTML versions of the manpages], [htmlman3])
DOCS_DEFINE_TARGET(MANPAGES, ALL, [manpages], [manpages3])
2004-06-16 00:12:16 +04:00
DOCS_DEFINE_TARGET(PEARSON, ALL, [pearson-compatible XML], [pearson])
2004-04-23 18:23:36 +04:00
DOCS_DEFINE_TARGET(PLUCKER, HTML, [plucker versions], [plucker])
2005-03-17 03:13:11 +03:00
DOCS_DEFINE_TARGET(VALIDATE, ALL, [validating docbook output], [])
2005-03-13 21:25:08 +03:00
DOCS_DEFINE_TARGET(FOPDF, ALL, [PDF versions thru FO], [fo-pdf])
2005-03-11 19:26:19 +03:00
DOCS_DEFINE_TARGET(TEXI, ALL, [TexInfo versions], [texi])
DOCS_DEFINE_TARGET(TEXIINFO, ALL, [TexInfo Info versions], [texiinfo])
2004-04-23 18:23:36 +04:00
DOCS_DEFINE_TARGET(UNDOCUMENTED, MANPAGES, [list of undocumented options], [undocumented])
2004-05-15 20:09:50 +04:00
DOCS_DEFINE_TARGET(TXT, HTML, [text versions], [txt])
2004-04-23 18:23:36 +04:00
if test x"$TARGETS" = x; then
AC_MSG_ERROR([You won't be able to build any of the docs])
else
AC_MSG_RESULT([You will be able to build: $TARGETS])
fi
AC_SUBST(TARGETS)
2005-01-29 23:05:52 +03:00
AC_OUTPUT( Makefile.settings settings.xsl )