Download M4 Source Macro Index Page

ac_latex_classes

Synopsis

AC_LATEX_CLASSES([<class1>,<class2>,...],<var>)

Description

Test if class1 exists and if not class2 and so and set $var to the right value

 AC_LATEX_CLASSES([allo,book,bnjour],book)
 should set $book="book"

Author

Mathieu Boretti boretti@bss-network.com

Last Modified

2005-01-21

M4 Source Code

define(_AC_LATEX_CLASSES_INTERNE,[
        ifelse($#,1,[],$#,2,[
                AC_LATEX_CLASS($2,$1)
        ],[
                AC_LATEX_CLASS($2,$1)
                if test "$$1" = "yes";
                then
                        $1=$2 ; export $1 ;
                else
                        _AC_LATEX_CLASSES_INTERNE($1,m4_shift(m4_shift($@)))
                fi;
        ])
])

AC_DEFUN([AC_LATEX_CLASSES],[
        _AC_LATEX_CLASSES_INTERNE($2,$1)
        AC_SUBST($2)
])