diff options
author | Hendrik Tews <hendrik@askra.de> | 2012-11-03 21:12:02 +0000 |
---|---|---|
committer | Hendrik Tews <hendrik@askra.de> | 2012-11-03 21:12:02 +0000 |
commit | f7d28e6a8f9bc683b093628c9bbc38322ae4fd50 (patch) | |
tree | bbb25fc21c831927f51d318e2186cf0ce0b389e2 /coq/coq-compile-common.el | |
parent | c3fafdf54d54c78124e76a72f4ecacb43dc5fcf1 (diff) |
make coq-include-options independent of current buffer
Diffstat (limited to 'coq/coq-compile-common.el')
-rw-r--r-- | coq/coq-compile-common.el | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/coq/coq-compile-common.el b/coq/coq-compile-common.el index 62ecfff4..4e2e7802 100644 --- a/coq/coq-compile-common.el +++ b/coq/coq-compile-common.el @@ -344,9 +344,11 @@ options they are translated." (setq entry (cdr entry))) (list "-R" (expand-file-name (car entry)) "-as" (nth 1 entry))))) -(defun coq-include-options (file) +(defun coq-include-options (file coq-load-path) "Build the list of include options for coqc, coqdep and coqtop. -The options list includes all entries from `coq-load-path' +The options list includes all entries from argument COQ-LOAD-PATH +\(which should be `coq-load-path' of the buffer that invoked the +compilation) prefixed with suitable options and, if `coq-load-path-include-current' is enabled, the directory base of FILE. The resulting list is fresh for every call, callers can @@ -370,7 +372,7 @@ FILE should be an absolute file name. It can be nil if ;; coqtop always adds the current directory to the LoadPath, so don't ;; include it in the -I options. (let ((coq-load-path-include-current nil)) - (append coq-prog-args (coq-include-options nil)))) + (append coq-prog-args (coq-include-options nil coq-load-path)))) ;; ignore library files |