# Where to find the source code. $(srcdir) will be the doc/misc subdirectory
# of the source tree. This is set by configure's '--srcdir' option.
srcdir=@srcdir@
-
+top_srcdir = @top_srcdir@
top_builddir = @top_builddir@
## Where the output files go.
abs_top_builddir = @abs_top_builddir@
EMACS = ${abs_top_builddir}/src/emacs
-emacs = "${EMACS}" -batch --no-site-file --no-site-lisp
+emacs = "${EMACS}" -batch --no-site-file --no-site-lisp --eval '(setq load-prefer-newer t)'
# Generated .texi files go in srcdir so they can be included in the
# release tarfile along with the others.
# Work in srcdir (and use abs_top_builddir) so that +setupfile and
# things like org-setup's "version" macro work. Sigh.
define org_template
- $(1:.org=.texi): $(1)
+ $(1:.org=.texi): $(1) ${top_srcdir}/lisp/org/ox-texinfo.el
$${AM_V_GEN}cd "$${srcdir}" && $${emacs} -l ox-texinfo \
-f org-texinfo-export-to-texinfo-batch $$(notdir $$<) $$(notdir $$@)
endef