Vikas Rawal <vikasli...@agrarianresearch.org> writes: >> > I have been trying to figure out how to do this. I saw Suvayu's config >> > files which he has kindly kept on github >> > (https://github.com/suvayu/.emacs.d). >> > >> > I tried to evaluate the following lines >> > >> > (add-to-list 'org-latex-classes >> > '("beamer" >> > "\\documentclass\[presentation\]\{beamer\}" >> > ("\\section\{%s\}" . "\\section*\{%s\}") >> > ("\\subsection\{%s\}" . "\\subsection*\{%s\}") >> > ("\\subsubsection\{%s\}" . "\\subsubsection*\{%s\}"))) >> > >> > >> > But I get the following error: >> > >> > Symbol's value as variable is void: org-latex-classes >> > >> > Why should that be? >> >> You may be using an outdated version (maint branch?). Otherwise, latex >> back-end may not be loaded, but it is by default (see >> `org-export-backends'). > > I shifted from the elpa version to the version downloaded using git > repository. But I still get this error. org-version says: > > Org-mode version 7.9.3f (release_7.9.3f-1360-g2d3add @ > /home/vikas/lisp/org-mode/lisp/)
Without configuration, export framework and default back-ends are not loaded along with Org, but the first you need them (by calling an autoloaded function). You may be trying to modify `org-latex-classes' before having `ox-latex' loaded. You can either explicitly (require 'ox-latex) before that, which will load all export framework along with Org, or use the following construct: (eval-after-load 'ox-latex '(add-to-list ...)) In the latter case, you still get framework loaded only when you need it the first time. Regards, -- Nicolas Goaziou