blob: e60bbeedadf25e1fe55120f08f0ef34dd906b1cf (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
|
AC_INIT(chklref,2.6.0, jerome.lelong@gmail.com)
AC_PROG_INSTALL
AC_ARG_WITH(texmf-prefix,
[ --with-texmf-prefix prefix to use for texmf [[prefix/share/texmf]]],
[with_texmf_prefix=$withval])
AC_ARG_WITH(perl,
[ --with-perl the perl interpreter to use],
[with_perl=$withval])
if test "x$prefix" = "xNONE" ; then
prefix=/usr/local
fi
if test "x$with_texmf_prefix" != "x" ; then
texmf_prefix=$with_texmf_prefix
else
texmf_prefix=$prefix/share/texmf
fi
if test -z "$texmf_prefix"; then
AC_MSG_ERROR("The specified TEXMF directory $texmf_prefix does not exist.
Consider calling configure with the --with-texmf-prefix option")
fi
bindir=$prefix/bin
LATEXDIR=$texmf_prefix/tex/latex/$PKGNAME
DOCDIR=$texmf_prefix/doc/latex/$PKGNAME
SCRIPTSDIR=$texmf_prefix/scripts/$PKGNAME
AC_SUBST([PKGNAME], ['AC_PACKAGE_NAME'])
AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])
AC_SUBST([PREFIX], ['prefix'])
AC_SUBST(bindir)
AC_SUBST(LATEXDIR)
AC_SUBST(DOCDIR)
AC_SUBST(SCRIPTSDIR)
# latex
AC_PATH_PROG(LATEX_PATH, latex)
if test "x$LATEX_PATH" = "x" ; then
AC_MSG_ERROR("latex command was not found")
fi
AC_SUBST(LATEX_PATH)
# pdflatex
AC_PATH_PROG(PDFLATEX_PATH, pdflatex)
if test "x$PDFLATEX_PATH" = "x" ; then
AC_MSG_ERROR("pdflatex command was not found")
fi
AC_SUBST(PDFLATEX_PATH)
# perl
if test "x$with_perl" != "x" ; then
if test -f "$with_perl"; then
PERL_PATH="$with_perl"
else
PERL_PATH=""
fi
fi
if test "x$PERL_PATH" = "x"; then
AC_PATH_PROG(PERL_PATH, perl)
fi
if test "x$PERL_PATH" = "x" ; then
AC_MSG_ERROR("perl command was not found")
fi
AC_SUBST(PERL_PATH)
AC_OUTPUT(Make.incl
doc/Makefile
src/Makefile
src/chklref
VERSION)
AC_MSG_NOTICE(
[
** Summary **
texm_prefix $texmf_prefix
bindir $bindir
perl interpreter $PERL_PATH
Run make and make install ])
|