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-2012 Zmanda, Inc. All Rights Reserved.
32 # This program is free software; you can redistribute it and/or
33 # modify it under the terms of the GNU General Public License
34 # as published by the Free Software Foundation; either version 2
35 # of the License, or (at your option) any later version.
37 # This program is distributed in the hope that it will be useful, but
38 # WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
39 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
42 # You should have received a copy of the GNU General Public License along
43 # with this program; if not, write to the Free Software Foundation, Inc.,
44 # 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
46 # This special exception to the GPL applies to versions of the
47 # Autoconf Macro released by the Autoconf Macro Archive. When you
48 # make and distribute a modified version of the Autoconf Macro, you
49 # may extend this special exception to the GPL to apply to your
50 # modified version as well.
52 # Contact information: Zmanda Inc., 465 S. Mathilda Ave., Suite 300
53 # Sunnyvale, CA 94086, USA, or: http://www.zmanda.com
55 AC_DEFUN([AC_PROG_XSLTPROC],
58 AC_SUBST(XSLTPROC_FLAGS)
60 # The (lack of) whitespace and overquoting here are all necessary for
63 AS_HELP_STRING([--with-xsltproc[[[[[=PATH]]]]]],
64 [Use the xsltproc binary in in PATH.]),
65 [ ac_with_xsltproc=$withval; ],
66 [ ac_with_xsltproc=maybe; ])
68 AC_ARG_WITH(xsltproc-flags,
69 AS_HELP_STRING([ --with-xsltproc-flags=FLAGS],
70 [Flags to pass to xsltproc (default $1)]),
71 [ if test "x$withval" == "xno"; then
74 if test "x$withval" != "xyes"; then
75 XSLTPROC_FLAGS="$withval"
80 # search for xsltproc if it wasn't specified
81 if test "$ac_with_xsltproc" = "yes" -o "$ac_with_xsltproc" = "maybe"; then
82 AC_PATH_PROGS(XSLTPROC,xsltproc,,$LOCSYSPATH)
84 if test "$ac_with_xsltproc" != "no"; then
85 if test -x "$ac_with_xsltproc"; then
86 XSLTPROC="$ac_with_xsltproc";
88 AMANDA_MSG_WARN([Specified xsltproc of $ac_with_xsltproc isn't executable; searching for an alternative.])
89 AC_PATH_PROGS(XSLTPROC,xsltproc,,$LOCSYSPATH)