Removal of CRUFT. 50 lashes to those who created CRUFT. Argh.
[Samba.git] / docs / configure.in
blob9d336e232085417e4498ff22143cb6536ed7df27
1 AC_INIT(xslt/latex.xsl)
3 AC_ARG_WITH(samba-sources,
4 [ --with-samba-sources=DIR Specify path to Samba sources],
5 [ test "$withval" && SPECIFIED_SOURCEDIR="$withval" ])
7 LATEX_DOCUMENTCLASS_OPTIONS="letterpaper,11pt,openright,twoside"
8 AC_ARG_ENABLE(prentice-hall,
9 [ --enable-prentice-hall     Produce Prentice-Hall compatible output],
10 [ test "$enableval" && LATEX_DOCUMENTCLASS_OPTIONS="letterpaper,10pt,openleft,twoside,ph" ])
11 AC_SUBST(LATEX_DOCUMENTCLASS_OPTIONS)
13 DOC_BUILD_DATE=`date '+%d-%m-%Y'`
14 AC_SUBST(DOC_BUILD_DATE)
15 AC_SUBST(SAMBASOURCEDIR)
17 DOCS_TARGET_REQUIRE_PROGRAM(XSLTPROC, xsltproc, ALL)
18 DOCS_TARGET_REQUIRE_PROGRAM(RM, rm, ALL)
19 DOCS_TARGET_REQUIRE_PROGRAM(DIA, dia, ALL)
21 # Check dia version number
22 [ DIA_VERSION=`$DIA -v | egrep -o '([0-9]+)\.([0-9]+)'`]
23 DIA_MAJ_VERSION=`echo $DIA_VERSION | cut -d . -f 1`
24 DIA_MIN_VERSION=`echo $DIA_VERSION | cut -d . -f 2`
26 if test "$DIA_MAJ_VERSION" -le "0"
27 then
28         if test "$DIA_MIN_VERSION" -le "92" && test -z "$DISPLAY" 
29         then
30                 AC_MSG_ERROR([Dia below 0.93 requires an X environment. Set \$DISPLAY or install Dia 0.93 or higher])
31         fi
34 DOCS_TARGET_REQUIRE_PROGRAM(MAKEINDEX, makeindex, LATEX)
35 DOCS_TARGET_REQUIRE_PROGRAM(PDFLATEX, pdflatex, PDF)
36 DOCS_TARGET_REQUIRE_PROGRAM(EPSTOPDF, epstopdf, PDF)
37 DOCS_TARGET_REQUIRE_PROGRAM(THUMBPDF, thumbpdf, PDF)
38 DOCS_TARGET_REQUIRE_PROGRAM(PNGTOPNM, pngtopnm, PS)
39 DOCS_TARGET_REQUIRE_PROGRAM(PNMTOPS, pnmtops, PS)
40 DOCS_TARGET_REQUIRE_PROGRAM(LATEX, latex, PS)
41 DOCS_TARGET_REQUIRE_PROGRAM(DVIPS, dvips, PS)
42 DOCS_TARGET_REQUIRE_PROGRAM(PLUCKERBUILD, plucker-build, PLUCKER)
43 DOCS_TARGET_REQUIRE_PROGRAM(HTML2TEXT, html2text, TXT)
44 DOCS_TARGET_REQUIRE_PROGRAM(PERL, perl, UNDOCUMENTED)
45 DOCS_TARGET_REQUIRE_PROGRAM(XMLLINT, xmllint, VALIDATE)
46 DOCS_TARGET_REQUIRE_PROGRAM(FOP, fop, FOPDF)
47 DOCS_TARGET_REQUIRE_PROGRAM(DB2TEXI, docbook2x-texi, TEXI)
48 DOCS_TARGET_REQUIRE_PROGRAM(MAKEINFO, makeinfo, TEXIINFO)
49 DOCS_TARGET_REQUIRE_DIR([$SPECIFIED_SOURCEDIR $SPECIFIED_SOURCEDIR/source ..], [param/loadparm.c], SAMBASOURCEDIR, UNDOCUMENTED)
51 AC_MSG_RESULT([])
52 AC_MSG_RESULT([Summary:])
53 AC_MSG_RESULT([--------------])
55 DOCS_DEFINE_TARGET(ALL, [], [base requirements], [])
56 DOCS_DEFINE_TARGET(LATEX, ALL, [LaTeX versions], [tex])
57 DOCS_DEFINE_TARGET(PDF, LATEX, [PDF versions], [pdf])
58 DOCS_DEFINE_TARGET(PS, LATEX, [PostScript versions], [ps])
59 DOCS_DEFINE_TARGET(HTML, ALL, [HTML versions], [html])
60 DOCS_DEFINE_TARGET(HTMLHELP, ALL, [HTML Help versions], [htmlhelp])
61 DOCS_DEFINE_TARGET(HTMLMAN, ALL, [HTML versions of the manpages], [htmlman3])
62 DOCS_DEFINE_TARGET(MANPAGES, ALL, [manpages], [manpages3])
63 DOCS_DEFINE_TARGET(PEARSON, ALL, [pearson-compatible XML], [pearson])
64 DOCS_DEFINE_TARGET(PLUCKER, HTML, [plucker versions], [plucker])
65 DOCS_DEFINE_TARGET(VALIDATE, ALL, [validating docbook output], [])
66 DOCS_DEFINE_TARGET(FOPDF, ALL, [PDF versions thru FO], [fo-pdf])
67 DOCS_DEFINE_TARGET(TEXI, ALL, [TexInfo versions], [texi])
68 DOCS_DEFINE_TARGET(TEXIINFO, ALL, [TexInfo Info versions], [texiinfo])
69 DOCS_DEFINE_TARGET(UNDOCUMENTED, MANPAGES, [list of undocumented options], [undocumented])
70 DOCS_DEFINE_TARGET(TXT, HTML, [text versions], [txt])
72 if test x"$TARGETS" = x; then 
73         AC_MSG_ERROR([You won't be able to build any of the docs])
74 else 
75         AC_MSG_RESULT([You will be able to build: $TARGETS])
78 AC_SUBST(TARGETS)
80 AC_OUTPUT( Makefile.settings)