diff --git a/configure.ac b/configure.ac
index c69bd14f8900e971105e95a92972dbdc2e3b44a0..46014d0c9072c1e0be07763b24967c09ccbe7d7e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -95,8 +95,11 @@ if test "x$PDFLATEX" != "x" -a "x$BIBTEX" != "x"; then
 	Year = {1996}}
 ], [ax_latex_have_econometrica])
   AC_MSG_RESULT([$ax_latex_have_econometrica])
+
+  AX_LATEX_CLASS([beamer], [ax_latex_have_beamer])
 fi
 AM_CONDITIONAL([HAVE_ECONOMETRICA], [test "x$ax_latex_have_econometrica" = "xyes"])
+AM_CONDITIONAL([HAVE_BEAMER], [test "x$ax_latex_have_beamer" = "xyes"])
 
 AC_CHECK_PROG([DBLATEX], [dblatex], [dblatex])
 AM_CONDITIONAL([HAVE_DBLATEX], [test "x$DBLATEX" != "x"])
@@ -228,6 +231,12 @@ else
   BUILD_DYNARE_USERGUIDE="no (missing one of: pdflatex, bibtex, econometrica BST)"
 fi
 
+if test "x$PDFLATEX" != "x" -a "x$ax_latex_have_beamer" = "xyes"; then
+  BUILD_BEAMER_DOC="yes"
+else
+  BUILD_BEAMER_DOC="no (missing one of: pdflatex, beamer)"
+fi
+
 if test "x$PDFLATEX" != "x"; then
   BUILD_OTHER_PDF_DOC="yes"
 else
@@ -278,6 +287,7 @@ PDF documentation (with "make pdf"):
  Dynare reference manual:               $BUILD_DYNARE_PDF_MANUAL
  Dynare user guide:                     $BUILD_DYNARE_USERGUIDE
  Dynare++ developer documentation:      $BUILD_DYNAREPLUSPLUS_SRCDOC
+ Beamer presentations:                  $BUILD_BEAMER_DOC
  Various other documents:               $BUILD_OTHER_PDF_DOC
 
 HTML documentation (with "make html"):
diff --git a/doc/macroprocessor/Makefile.am b/doc/macroprocessor/Makefile.am
index aaef0a7937672a80b64da8ab0e5ecfea2cc6c09b..dc3f7df0bd3528b436cda8f8a47d3b78cc12446d 100644
--- a/doc/macroprocessor/Makefile.am
+++ b/doc/macroprocessor/Makefile.am
@@ -1,6 +1,8 @@
 if HAVE_PDFLATEX
+if HAVE_BEAMER
 pdf-local: macroprocessor.pdf
 endif
+endif
 
 SRC = macroprocessor.tex old-design.pdf new-design.pdf
 
diff --git a/doc/preprocessor/Makefile.am b/doc/preprocessor/Makefile.am
index 9b70186365994629a986ebb09497895b763a3530..afdbb73a5c594673e4e03f1b731d9ddd521811e6 100644
--- a/doc/preprocessor/Makefile.am
+++ b/doc/preprocessor/Makefile.am
@@ -1,6 +1,8 @@
 if HAVE_PDFLATEX
+if HAVE_BEAMER
 pdf-local: preprocessor.pdf
 endif
+endif
 
 SRC = preprocessor.tex expr.png expr-sharing.png matrices.png overview.png
 
diff --git a/m4/ax_latex_class.m4 b/m4/ax_latex_class.m4
new file mode 100644
index 0000000000000000000000000000000000000000..0c1a951923f944788c0ef3fbe7a4cb884bf4607c
--- /dev/null
+++ b/m4/ax_latex_class.m4
@@ -0,0 +1,68 @@
+# ===========================================================================
+#         http://www.nongnu.org/autoconf-archive/ax_latex_class.html
+# ===========================================================================
+#
+# OBSOLETE MACRO
+#
+#   Deprecated because of licensing issues. The Lesser GPL imposes licensing
+#   restrictions on the generated configure script unless it is augmented
+#   with an Autoconf Exception clause.
+#
+# SYNOPSIS
+#
+#   AX_LATEX_CLASS(CLASSNAME,VARIABLETOSET[,ACTION-IF-FOUND[,ACTION-IF-NOT-FOUND]])
+#
+# DESCRIPTION
+#
+#   This macros test is class CLASSNAME exists and work and set
+#   VARIABLETOSET to yes or no If ACTION-IF-FOUND (and ACTION-IF-NOT-FOUND)
+#   are set, do the correct action
+#
+# LICENSE
+#
+#   Copyright (c) 2008 Boretti Mathieu <boretti@eig.unige.ch>
+#   Copyright (c) 2009 Dynare Team
+#
+#   This library is free software; you can redistribute it and/or modify it
+#   under the terms of the GNU Lesser General Public License as published by
+#   the Free Software Foundation; either version 2.1 of the License, or (at
+#   your option) any later version.
+#
+#   This library is distributed in the hope that it will be useful, but
+#   WITHOUT ANY WARRANTY; without even the implied warranty of
+#   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser
+#   General Public License for more details.
+#
+#   You should have received a copy of the GNU Lesser General Public License
+#   along with this library. If not, see <http://www.gnu.org/licenses/>.
+
+AC_DEFUN([AX_LATEX_CLASS],[
+AC_CACHE_CHECK([for usability of class $1],[ac_cv_latex_class_]translit($1,[-],[_]),[
+AX_LATEX_TEST([\documentclass{$1}
+\begin{document}
+\end{document}],[ac_cv_latex_class_]translit($1,[-],[_]))
+])
+$2=$[ac_cv_latex_class_]translit($1,[-],[_]) ; export $2;
+AC_SUBST($2)
+ifelse($#,2,[],$#,3,[
+    if test "[$]$2" = "yes" ;
+    then
+        $3
+    fi
+],$#,4,[
+    ifelse($3,[],[
+        if test "[$]$2" = "no" ;
+        then
+            $4
+        fi
+    ],[
+        if test "[$]$2" = "yes" ;
+        then
+            $3
+        else
+            $4
+        fi
+    ])
+])
+
+])
diff --git a/m4/ax_latex_test.m4 b/m4/ax_latex_test.m4
new file mode 100644
index 0000000000000000000000000000000000000000..4d5b73a3480172830b9861e74f13af402c864e6c
--- /dev/null
+++ b/m4/ax_latex_test.m4
@@ -0,0 +1,56 @@
+# ===========================================================================
+#          http://www.nongnu.org/autoconf-archive/ax_latex_test.html
+# ===========================================================================
+#
+# OBSOLETE MACRO
+#
+#   Deprecated because of licensing issues. The Lesser GPL imposes licensing
+#   restrictions on the generated configure script unless it is augmented
+#   with an Autoconf Exception clause.
+#
+# SYNOPSIS
+#
+#   AX_LATEX_TEST(FILEDATA,VARIABLETOSET,[NOCLEAN])
+#
+# DESCRIPTION
+#
+#   This macros execute the latex application with FILEDATA as input and set
+#   VARIABLETOSET the yes or no depending of the result if NOCLEAN is set,
+#   the folder used for the test is not delete after testing.
+#
+#   The macro assumes that the variable PDFLATEX is set.
+#
+# LICENSE
+#
+#   Copyright (c) 2008 Boretti Mathieu <boretti@eig.unige.ch>
+#   Copyright (c) 2009 Dynare Team
+#
+#   This library is free software; you can redistribute it and/or modify it
+#   under the terms of the GNU Lesser General Public License as published by
+#   the Free Software Foundation; either version 2.1 of the License, or (at
+#   your option) any later version.
+#
+#   This library is distributed in the hope that it will be useful, but
+#   WITHOUT ANY WARRANTY; without even the implied warranty of
+#   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser
+#   General Public License for more details.
+#
+#   You should have received a copy of the GNU Lesser General Public License
+#   along with this library. If not, see <http://www.gnu.org/licenses/>.
+
+AC_DEFUN([AX_LATEX_TEST],[
+rm -rf conftest.dir/.acltx
+AS_MKDIR_P([conftest.dir/.acltx])
+cd conftest.dir/.acltx
+m4_ifval([$2],[$2="no"; export $2;])
+cat > conftest.tex << ACLEOF
+$1
+ACLEOF
+cat conftest.tex | $PDFLATEX 2>&1 1>output m4_ifval([$2],[&& $2=yes])
+cd ..
+cd ..
+sed 's/^/| /' conftest.dir/.acltx/conftest.tex >&5
+echo "$as_me:$LINENO: executing cat conftest.tex | $PDFLATEX" >&5
+sed 's/^/| /' conftest.dir/.acltx/output >&5
+m4_ifval([$3],,[rm -rf conftest.dir/.acltx])
+])