use only relative paths for better compatibility with mixed Cygwin/NTEmacs installations
* UTILITIES/org-fixup.el(org-make-org-install): Use relative filenames throughout, and query Emacs for directory names where a full path is required. This avoids Cygwin/POSIX paths being misinterpreted by a stock NTEmacs. Use the same regex as (org-reload) for enumerating the files to byte-compile. * default.mk: Factor out standard load-path for Emacs started in lisp/ into BATCHL and use this in defaults. Make all paths to be interpreted by Emacs relative so Cygwin and NTEmacs can coexist.
This commit is contained in:
parent
42f7ba0d02
commit
372948a88f
|
@ -54,18 +54,18 @@
|
||||||
(toggle-read-only 0)
|
(toggle-read-only 0)
|
||||||
(write-file "org-version.el")))
|
(write-file "org-version.el")))
|
||||||
|
|
||||||
(defun org-make-org-install (absfile)
|
(defun org-make-org-install ()
|
||||||
(with-temp-buffer
|
(with-temp-buffer
|
||||||
(set-visited-file-name absfile)
|
(set-visited-file-name "org-install.el")
|
||||||
(insert ";;; org-install.el --- autogenerated file, do not edit\n;;\n;;; Code:\n")
|
(insert ";;; org-install.el --- autogenerated file, do not edit\n;;\n;;; Code:\n")
|
||||||
(let ((files (directory-files (file-name-directory absfile) 'full "^[^.#~]*\\.el$")))
|
(let ((files (directory-files default-directory nil "^\\(org\\|ob\\)\\(-.*\\)?\\.el$")))
|
||||||
(mapc (lambda (f) (generate-file-autoloads f)) files))
|
(mapc (lambda (f) (generate-file-autoloads f)) files))
|
||||||
(insert "\f\n(provide 'org-install)\n")
|
(insert "\f\n(provide 'org-install)\n")
|
||||||
(insert "\f\n;; Local Variables:\n;; version-control: never\n")
|
(insert "\f\n;; Local Variables:\n;; version-control: never\n")
|
||||||
(insert ";; no-byte-compile: t\n;; no-update-autoloads: t\n")
|
(insert ";; no-byte-compile: t\n;; no-update-autoloads: t\n")
|
||||||
(insert ";; coding: utf-8\n;; End:\n;;; org-install.el ends here\n")
|
(insert ";; coding: utf-8\n;; End:\n;;; org-install.el ends here\n")
|
||||||
(toggle-read-only 0)
|
(toggle-read-only 0)
|
||||||
(write-file absfile)))
|
(save-buffer)))
|
||||||
|
|
||||||
(defun org-make-autoloads ()
|
(defun org-make-autoloads ()
|
||||||
(let* ((origin default-directory)
|
(let* ((origin default-directory)
|
||||||
|
@ -79,7 +79,7 @@
|
||||||
(cd dirlisp)
|
(cd dirlisp)
|
||||||
(org-fixup)
|
(org-fixup)
|
||||||
(org-make-org-version (org-release) (org-git-version) dirodt)
|
(org-make-org-version (org-release) (org-git-version) dirodt)
|
||||||
(org-make-org-install (concat dirlisp "org-install.el")))
|
(org-make-org-install))
|
||||||
(cd origin))))
|
(cd origin))))
|
||||||
|
|
||||||
(defun org-make-autoloads-compile (&rest force)
|
(defun org-make-autoloads-compile (&rest force)
|
||||||
|
|
41
default.mk
41
default.mk
|
@ -47,8 +47,8 @@ req-ob-lang = --eval '(require '"'"'ob-$(ob-lang))'
|
||||||
req-extra = --eval '(require '"'"'$(req))'
|
req-extra = --eval '(require '"'"'$(req))'
|
||||||
BTEST = $(BATCH) \
|
BTEST = $(BATCH) \
|
||||||
$(BTEST_PRE) \
|
$(BTEST_PRE) \
|
||||||
--eval '(add-to-list '"'"'load-path "lisp")' \
|
--eval '(add-to-list '"'"'load-path "./lisp")' \
|
||||||
--eval '(add-to-list '"'"'load-path "testing")' \
|
--eval '(add-to-list '"'"'load-path "./testing")' \
|
||||||
$(BTEST_POST) \
|
$(BTEST_POST) \
|
||||||
-l org-install.el \
|
-l org-install.el \
|
||||||
-l testing/org-test.el \
|
-l testing/org-test.el \
|
||||||
|
@ -58,13 +58,28 @@ BTEST = $(BATCH) \
|
||||||
-f org-test-run-batch-tests
|
-f org-test-run-batch-tests
|
||||||
|
|
||||||
# Using emacs in batch mode.
|
# Using emacs in batch mode.
|
||||||
BATCH = $(EMACS) -batch -Q
|
|
||||||
# BATCH = $(EMACS) -batch -vanilla # XEmacs
|
# BATCH = $(EMACS) -batch -vanilla # XEmacs
|
||||||
|
BATCH = $(EMACS) -batch -Q
|
||||||
|
|
||||||
|
# Emacs must be started in lisp directory
|
||||||
|
BATCHL = $(BATCH) \
|
||||||
|
--eval '(add-to-list '"'"'load-path ".")'
|
||||||
|
|
||||||
|
# How to generate org-install.el
|
||||||
|
MAKE_ORG_INSTALL = $(BATCHL) \
|
||||||
|
--eval '(load "org-compat.el")' \
|
||||||
|
--eval '(load "../UTILITIES/org-fixup.el")' \
|
||||||
|
--eval '(org-make-org-install)'
|
||||||
|
|
||||||
|
# How to generate org-version.el
|
||||||
|
MAKE_ORG_VERSION = $(BATCHL) \
|
||||||
|
--eval '(load "org-compat.el")' \
|
||||||
|
--eval '(load "../UTILITIES/org-fixup.el")' \
|
||||||
|
--eval '(org-make-org-version "$(ORGVERSION)" "$(GITVERSION)" "$(datadir)")'
|
||||||
|
|
||||||
# How to byte-compile the whole source directory
|
# How to byte-compile the whole source directory
|
||||||
ELCDIR = $(BATCH) \
|
ELCDIR = $(BATCHL) \
|
||||||
--eval '(add-to-list '"'"'load-path ".")' \
|
--eval '(batch-byte-recompile-directory 0)'
|
||||||
--eval '(batch-byte-recompile-directory 0)'
|
|
||||||
|
|
||||||
# How to make a pdf file from a texinfo file
|
# How to make a pdf file from a texinfo file
|
||||||
TEXI2PDF = texi2pdf --batch --clean
|
TEXI2PDF = texi2pdf --batch --clean
|
||||||
|
@ -104,17 +119,3 @@ SUDO = sudo
|
||||||
# Name of the program to install info files
|
# Name of the program to install info files
|
||||||
# INSTALL_INFO = ginstall-info # Debian: avoid harmless warning message
|
# INSTALL_INFO = ginstall-info # Debian: avoid harmless warning message
|
||||||
INSTALL_INFO = install-info
|
INSTALL_INFO = install-info
|
||||||
|
|
||||||
# How to generate org-install.el
|
|
||||||
MAKE_ORG_INSTALL = $(BATCH) \
|
|
||||||
--eval '(add-to-list '"'"'load-path ".")' \
|
|
||||||
--eval '(load "org-compat.el")' \
|
|
||||||
--eval '(load "../UTILITIES/org-fixup.el")' \
|
|
||||||
--eval '(org-make-org-install "$(CURDIR)/lisp/org-install.el")'
|
|
||||||
|
|
||||||
# How to generate org-version.el
|
|
||||||
MAKE_ORG_VERSION = $(BATCH) \
|
|
||||||
--eval '(add-to-list '"'"'load-path ".")' \
|
|
||||||
--eval '(load "org-compat.el")' \
|
|
||||||
--eval '(load "../UTILITIES/org-fixup.el")' \
|
|
||||||
--eval '(org-make-org-version "$(ORGVERSION)" "$(GITVERSION)" "$(datadir)")'
|
|
||||||
|
|
Loading…
Reference in New Issue