1 ##### http://autoconf-archive.cryp.to/ac_prog_xsltproc.html
5 # AC_PROG_XSLTPROC([default-flags])
9 # Finds an xsltproc executable.
12 # default-flags is the default $XSLTPROC_FLAGS, which will be
13 # overridden if the user specifies --with-xsltproc-flags.
16 # $XSLTPROC contains the path to xsltproc, or is empty if none was
17 # found or the user specified --without-xsltproc. $XSLTPROC_FLAGS
18 # contains the flags to use with xsltproc.
26 # Dustin J. Mitchell <dustin@zmanda.com>
30 # Copyright (c) 2007,2008 Zmanda, Inc. All Rights Reserved.
32 # This program is free software; you can redistribute it and/or modify it
33 # under the terms of the GNU General Public License version 2 as published
34 # by the Free Software Foundation.
36 # This program is distributed in the hope that it will be useful, but
37 # WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
38 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
41 # You should have received a copy of the GNU General Public License along
42 # with this program; if not, write to the Free Software Foundation, Inc.,
43 # 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
45 # This special exception to the GPL applies to versions of the
46 # Autoconf Macro released by the Autoconf Macro Archive. When you
47 # make and distribute a modified version of the Autoconf Macro, you
48 # may extend this special exception to the GPL to apply to your
49 # modified version as well.
51 # Contact information: Zmanda Inc., 465 S. Mathilda Ave., Suite 300
52 # Sunnyvale, CA 94086, USA, or: http://www.zmanda.com
54 AC_DEFUN([AC_PROG_XSLTPROC],
57 AC_SUBST(XSLTPROC_FLAGS)
59 # The (lack of) whitespace and overquoting here are all necessary for
62 AS_HELP_STRING([--with-xsltproc[[[[[=PATH]]]]]],
63 [Use the xsltproc binary in in PATH.]),
64 [ ac_with_xsltproc=$withval; ],
65 [ ac_with_xsltproc=maybe; ])
67 AC_ARG_WITH(xsltproc-flags,
68 AS_HELP_STRING([ --with-xsltproc-flags=FLAGS],
69 [Flags to pass to xsltproc (default $1)]),
70 [ if test "x$withval" == "xno"; then
73 if test "x$withval" != "xyes"; then
74 XSLTPROC_FLAGS="$withval"
79 # search for xsltproc if it wasn't specified
80 if test "$ac_with_xsltproc" = "yes" -o "$ac_with_xsltproc" = "maybe"; then
81 AC_PATH_PROGS(XSLTPROC,xsltproc,,$LOCSYSPATH)
83 if test "$ac_with_xsltproc" != "no"; then
84 if test -x "$ac_with_xsltproc"; then
85 XSLTPROC="$ac_with_xsltproc";
87 AMANDA_MSG_WARN([Specified xsltproc of $ac_with_xsltproc isn't executable; searching for an alternative.])
88 AC_PATH_PROGS(XSLTPROC,xsltproc,,$LOCSYSPATH)