From 7dd847c6852c979a9a93bfe3577a032ebe0cff3a Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Wed, 3 Oct 2012 12:12:59 +0200 Subject: [PATCH 1/6] Revert "mk/default.mk: Restore datadir." This reverts commit ded873cb8fbf91c98eeab5d187eda57a1e773005. --- mk/default.mk | 3 --- 1 file changed, 3 deletions(-) diff --git a/mk/default.mk b/mk/default.mk index b3befad62..94ef825aa 100644 --- a/mk/default.mk +++ b/mk/default.mk @@ -13,9 +13,6 @@ prefix = /usr/share # Where local lisp files go. lispdir= $(prefix)/emacs/site-lisp/org -# Where local data files go. -datadir = $(prefix)/emacs/etc/org - # Where info files go. infodir = $(prefix)/info From 156b42e4f27f73480e5fe9773a162d9851b05959 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Wed, 3 Oct 2012 12:13:07 +0200 Subject: [PATCH 2/6] Revert "org-odt.el (org-odt-styles-dir): Try more directories" This reverts commit fc8ad1347e103b399d0fcdb617d99e5bf06b80b6. --- lisp/org-odt.el | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/lisp/org-odt.el b/lisp/org-odt.el index 117c824c8..c41708034 100644 --- a/lisp/org-odt.el +++ b/lisp/org-odt.el @@ -150,11 +150,7 @@ Also add it to `rng-schema-locating-files'." (let* ((d (expand-file-name "../" (org-find-library-dir "org-odt.el"))) (styles-dir-list (list (concat d "etc/styles/") ;; ELPA and Git - (concat d "etc/org/") ;; Org from Emacs - (concat d "../" - (number-to-string emacs-major-version) "." - (number-to-string emacs-minor-version) "/etc/org/") - (concat data-directory "org/"))) ;; Custom install + (concat d "etc/org/"))) styles-dir) (setq styles-dir (car @@ -168,8 +164,8 @@ Also add it to `rng-schema-locating-files'." "OrgOdtStyles.xml" sd))) sd)) styles-dir-list)))) - (or (expand-file-name styles-dir) - (message "Cannot find factory styles files for Org ODT, aborting"))) + (or styles-dir + (error "Cannot find factory styles files for Org ODT, aborting"))) "Directory that holds auxiliary XML files used by the ODT exporter. This directory contains the following XML files - From eba20536e966d27c07db166b6e6aa46d81a72937 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Wed, 3 Oct 2012 12:13:17 +0200 Subject: [PATCH 3/6] Revert "org-e-odt.el: Bugfix: default to the correct directory for styles." This reverts commit 27c673781309f1ad58a55c4130b793ff18fc7ac9. --- contrib/lisp/org-e-odt.el | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/contrib/lisp/org-e-odt.el b/contrib/lisp/org-e-odt.el index 69fbea17a..14147c71d 100644 --- a/contrib/lisp/org-e-odt.el +++ b/contrib/lisp/org-e-odt.el @@ -117,12 +117,9 @@ (defconst org-e-odt-styles-dir (let* ((d (expand-file-name (org-find-library-dir "org-e-odt.el"))) (styles-dir-list (list - (concat d "etc/styles/") ;; ELPA and Git - (concat d "etc/org/") ;; Org from Emacs - (concat d "../" - (number-to-string emacs-major-version) "." - (number-to-string emacs-minor-version) "/etc/org/") - (concat data-directory "org/"))) ;; Custom install + (concat d "../../etc/styles/") ;; Git + (concat d "../../etc/org/") ;; system + (concat d "../etc/org/"))) ;; ELPA org-plus styles-dir) (setq styles-dir (car @@ -136,8 +133,8 @@ "OrgOdtStyles.xml" sd))) sd)) styles-dir-list)))) - (or (expand-file-name styles-dir) - (message "Cannot find factory styles files for Org ODT"))) + (or styles-dir + (error "Cannot find factory styles files for Org ODT, aborting"))) "Directory that holds auxiliary XML files used by the ODT exporter. This directory contains the following XML files - @@ -1829,7 +1826,7 @@ CONTENTS is nil. INFO is a plist holding contextual information." ;;;; Latex Environment -(eval-after-load 'org-odt +(eval-after-load 'org-e-odt '(ad-deactivate 'org-format-latex-as-mathml)) ;; (defadvice org-format-latex-as-mathml ; FIXME From 1a029166a720b205456b4b5f2763dd8e17359704 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Wed, 3 Oct 2012 12:13:26 +0200 Subject: [PATCH 4/6] Revert "Fix compiler warnings introduced in commit d042e3a." This reverts commit 79e907fd8c2a650e17f9703f7332dab51d534b8f. --- contrib/lisp/org-e-odt.el | 4 +++- lisp/org-odt.el | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/contrib/lisp/org-e-odt.el b/contrib/lisp/org-e-odt.el index 14147c71d..d7f21b6ef 100644 --- a/contrib/lisp/org-e-odt.el +++ b/contrib/lisp/org-e-odt.el @@ -387,7 +387,9 @@ Also add it to `rng-schema-locating-files'." (file-readable-p (expand-file-name "schemas.xml" schema-dir))) schema-dir - (when value (message "No OpenDocument schema files"))))) + (when value + (message "No OpenDocument schema files" value)) + nil))) (when org-e-odt-schema-dir (eval-after-load 'rng-loc '(add-to-list 'rng-schema-locating-files diff --git a/lisp/org-odt.el b/lisp/org-odt.el index c41708034..249bd0a57 100644 --- a/lisp/org-odt.el +++ b/lisp/org-odt.el @@ -139,7 +139,9 @@ Also add it to `rng-schema-locating-files'." (file-readable-p (expand-file-name "schemas.xml" schema-dir))) schema-dir - (when value (message "No OpenDocument schema files"))))) + (when value + (message "No OpenDocument schema files" value)) + nil))) (when org-export-odt-schema-dir (eval-after-load 'rng-loc '(add-to-list 'rng-schema-locating-files From 5c9006de49b87d90e3b2ffe0f32e2ab479a80be6 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Wed, 3 Oct 2012 12:13:33 +0200 Subject: [PATCH 5/6] Revert "Fix previous commit." This reverts commit 5f9177ad3a5a8f12fbbca8d0b666de9eb8c3e73a. --- mk/default.mk | 5 ++++- mk/org-fixup.el | 10 +++------- 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/mk/default.mk b/mk/default.mk index 94ef825aa..dcd29476a 100644 --- a/mk/default.mk +++ b/mk/default.mk @@ -13,6 +13,9 @@ prefix = /usr/share # Where local lisp files go. lispdir= $(prefix)/emacs/site-lisp/org +# Where local data files go. +datadir = $(prefix)/emacs/etc/org + # Where info files go. infodir = $(prefix)/info @@ -88,7 +91,7 @@ MAKE_ORG_INSTALL = $(BATCHL) \ MAKE_ORG_VERSION = $(BATCHL) \ --eval '(load "org-compat.el")' \ --eval '(load "../mk/org-fixup.el")' \ - --eval '(org-make-org-version "$(ORGVERSION)" "$(GITVERSION)")' + --eval '(org-make-org-version "$(ORGVERSION)" "$(GITVERSION)" "$(datadir)")' # How to byte-compile the whole source directory ELCDIR = $(BATCHL) \ diff --git a/mk/org-fixup.el b/mk/org-fixup.el index 2e2d48aa2..57542749c 100644 --- a/mk/org-fixup.el +++ b/mk/org-fixup.el @@ -27,7 +27,7 @@ (require 'autoload) (require 'org-compat "org-compat.el") -(defun org-make-org-version (org-release org-git-version) +(defun org-make-org-version (org-release org-git-version odt-dir) "Make the file org-version.el in the current directory. This function is internally used by the build system and should be used by foreign build systems or installers to produce this @@ -50,11 +50,7 @@ the Git work tree)." \"The Git version of org-mode. Inserted by installing org-mode or when a release is made.\" (let ((org-git-version \"" org-git-version "\")) - org-git-version)) -\f\n\(provide 'org-version\) -\f\n;; Local Variables:\n;; version-control: never -;; no-byte-compile: t -;; coding: utf-8\n;; End:\n;;; org-version.el ends here\n") + org-git-version))") (toggle-read-only 0) (write-file "org-version.el"))) @@ -89,7 +85,7 @@ manual install when the build system can't be used." (progn (cd dirlisp) (org-fixup) - (org-make-org-version (org-release) (org-git-version)) + (org-make-org-version (org-release) (org-git-version) dirodt) (org-make-org-loaddefs) (when compile (byte-recompile-directory dirlisp 0 force))) (cd origin)))) From 21478e1733e01cdf3a3f91e8b56f0d3aa3617fd5 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Wed, 3 Oct 2012 12:13:47 +0200 Subject: [PATCH 6/6] Revert "org-odt.el (and org-e-odt.el): Simplify the way style/schema files are found" This reverts commit d042e3add1e62b4273524673fe1a18009d69a439. --- contrib/lisp/org-e-odt.el | 155 ++++++++++++++++++++++++++------------ lisp/org-odt.el | 145 +++++++++++++++++++++++------------ mk/org-fixup.el | 14 +++- 3 files changed, 215 insertions(+), 99 deletions(-) diff --git a/contrib/lisp/org-e-odt.el b/contrib/lisp/org-e-odt.el index d7f21b6ef..b2f7479d6 100644 --- a/contrib/lisp/org-e-odt.el +++ b/contrib/lisp/org-e-odt.el @@ -107,6 +107,18 @@ ;;; Internal Variables +(defconst org-e-odt-lib-dir + (file-name-directory load-file-name) + "Location of ODT exporter. +Use this to infer values of `org-e-odt-styles-dir' and +`org-e-odt-schema-dir'.") + +(defvar org-e-odt-data-dir + (expand-file-name "../../etc/" org-e-odt-lib-dir) + "Data directory for ODT exporter. +Use this to infer values of `org-e-odt-styles-dir' and +`org-e-odt-schema-dir'.") + (defconst org-e-odt-special-string-regexps '(("\\\\-" . "­\\1") ; shy ("---\\([^-]\\)" . "—\\1") ; mdash @@ -114,34 +126,69 @@ ("\\.\\.\\." . "…")) ; hellip "Regular expressions for special string conversion.") +(defconst org-e-odt-schema-dir-list + (list + (and org-e-odt-data-dir + (expand-file-name "./schema/" org-e-odt-data-dir)) ; bail out + (eval-when-compile + (and (boundp 'org-e-odt-data-dir) org-e-odt-data-dir ; see make install + (expand-file-name "./schema/" org-e-odt-data-dir)))) + "List of directories to search for OpenDocument schema files. +Use this list to set the default value of +`org-e-odt-schema-dir'. The entries in this list are +populated heuristically based on the values of `org-e-odt-lib-dir' +and `org-e-odt-data-dir'.") + +(defconst org-e-odt-styles-dir-list + (list + (and org-e-odt-data-dir + (expand-file-name "./styles/" org-e-odt-data-dir)) ; bail out + (eval-when-compile + (and (boundp 'org-e-odt-data-dir) org-e-odt-data-dir ; see make install + (expand-file-name "./styles/" org-e-odt-data-dir))) + (expand-file-name "../../etc/styles/" org-e-odt-lib-dir) ; git + (expand-file-name "./etc/styles/" org-e-odt-lib-dir) ; elpa + (expand-file-name "./org/" data-directory) ; system + ) + "List of directories to search for OpenDocument styles files. +See `org-e-odt-styles-dir'. The entries in this list are populated +heuristically based on the values of `org-e-odt-lib-dir' and +`org-e-odt-data-dir'.") + (defconst org-e-odt-styles-dir - (let* ((d (expand-file-name (org-find-library-dir "org-e-odt.el"))) - (styles-dir-list (list - (concat d "../../etc/styles/") ;; Git - (concat d "../../etc/org/") ;; system - (concat d "../etc/org/"))) ;; ELPA org-plus - styles-dir) - (setq styles-dir - (car - (delq nil - (mapcar (lambda (sd) - (when (and (file-readable-p - (expand-file-name - "OrgOdtContentTemplate.xml" sd)) - (file-readable-p - (expand-file-name - "OrgOdtStyles.xml" sd))) - sd)) - styles-dir-list)))) - (or styles-dir - (error "Cannot find factory styles files for Org ODT, aborting"))) + (let* ((styles-dir + (catch 'styles-dir + (message "Debug (org-e-odt): Searching for OpenDocument styles files...") + (mapc (lambda (styles-dir) + (when styles-dir + (message "Debug (org-e-odt): Trying %s..." styles-dir) + (when (and (file-readable-p + (expand-file-name + "OrgOdtContentTemplate.xml" styles-dir)) + (file-readable-p + (expand-file-name + "OrgOdtStyles.xml" styles-dir))) + (message "Debug (org-e-odt): Using styles under %s" + styles-dir) + (throw 'styles-dir styles-dir)))) + org-e-odt-styles-dir-list) + nil))) + (unless styles-dir + (error "Error (org-e-odt): Cannot find factory styles files, aborting")) + styles-dir) "Directory that holds auxiliary XML files used by the ODT exporter. This directory contains the following XML files - -\"OrgOdtStyles.xml\" and \"OrgOdtContentTemplate.xml\". -These XML files are used as the default values of -`org-export-odt-styles-file' and -`org-export-odt-content-template-file'.") + \"OrgOdtStyles.xml\" and \"OrgOdtContentTemplate.xml\". These + XML files are used as the default values of + `org-e-odt-styles-file' and + `org-e-odt-content-template-file'. + +The default value of this variable varies depending on the +version of org in use and is initialized from +`org-e-odt-styles-dir-list'. Note that the user could be using org +from one of: org's own private git repository, GNU ELPA tar or +standard Emacs.") (defconst org-e-odt-bookmark-prefix "OrgXref.") @@ -333,26 +380,28 @@ visually." ;;;; Document schema (defcustom org-e-odt-schema-dir - (let* ((d (expand-file-name (org-find-library-dir "org-e-odt.el"))) - (schema-dir-list (list (concat d "../etc/schema/"))) ;; ELPA and Git - schema-dir) - (setq schema-dir - (car - (delq nil - (mapcar (lambda (sd) - (when (and (file-readable-p - (expand-file-name - "od-manifest-schema-v1.2-cs01.rnc" sd)) - (file-readable-p - (expand-file-name - "od-schema-v1.2-cs01.rnc" sd)) - (file-readable-p - (expand-file-name - "schemas.xml" sd))) - sd)) - schema-dir-list)))) - (or schema-dir - (message "No OpenDocument schema files installed"))) + (let* ((schema-dir + (catch 'schema-dir + (message "Debug (org-e-odt): Searching for OpenDocument schema files...") + (mapc + (lambda (schema-dir) + (when schema-dir + (message "Debug (org-e-odt): Trying %s..." schema-dir) + (when (and (file-readable-p + (expand-file-name "od-manifest-schema-v1.2-cs01.rnc" + schema-dir)) + (file-readable-p + (expand-file-name "od-schema-v1.2-cs01.rnc" + schema-dir)) + (file-readable-p + (expand-file-name "schemas.xml" schema-dir))) + (message "Debug (org-e-odt): Using schema files under %s" + schema-dir) + (throw 'schema-dir schema-dir)))) + org-e-odt-schema-dir-list) + (message "Debug (org-e-odt): No OpenDocument schema files installed") + nil))) + schema-dir) "Directory that contains OpenDocument schema files. This directory contains: @@ -365,13 +414,15 @@ that `rng-schema-locating-files' is updated and auto-validation of OpenDocument XML takes place based on the value `rng-nxml-auto-validate-flag'. -The OASIS schema files are available only in the Org's private -git repository. It is *not* bundled with GNU ELPA tar or -standard Emacs distribution." +The default value of this variable varies depending on the +version of org in use and is initialized from +`org-e-odt-schema-dir-list'. The OASIS schema files are available +only in the org's private git repository. It is *not* bundled +with GNU ELPA tar or standard Emacs distribution." :type '(choice (const :tag "Not set" nil) (directory :tag "Schema directory")) - :group 'org-e-odt + :group 'org-export-e-odt :version "24.1" :set (lambda (var value) @@ -388,13 +439,16 @@ Also add it to `rng-schema-locating-files'." (expand-file-name "schemas.xml" schema-dir))) schema-dir (when value - (message "No OpenDocument schema files" value)) + (message "Error (org-e-odt): %s has no OpenDocument schema files" + value)) nil))) (when org-e-odt-schema-dir (eval-after-load 'rng-loc '(add-to-list 'rng-schema-locating-files (expand-file-name "schemas.xml" org-e-odt-schema-dir)))))) + + ;;;; Document styles (defcustom org-e-odt-content-template-file nil @@ -1828,7 +1882,8 @@ CONTENTS is nil. INFO is a plist holding contextual information." ;;;; Latex Environment -(eval-after-load 'org-e-odt + +(eval-after-load 'org-odt '(ad-deactivate 'org-format-latex-as-mathml)) ;; (defadvice org-format-latex-as-mathml ; FIXME diff --git a/lisp/org-odt.el b/lisp/org-odt.el index 249bd0a57..7e7e5e1b0 100644 --- a/lisp/org-odt.el +++ b/lisp/org-odt.el @@ -84,27 +84,52 @@ ("\\.\\.\\." . "…")) ; hellip "Regular expressions for special string conversion.") +(defconst org-odt-lib-dir (file-name-directory load-file-name) + "Location of ODT exporter. +Use this to infer values of `org-odt-styles-dir' and +`org-export-odt-schema-dir'.") + +(defvar org-odt-data-dir nil + "Data directory for ODT exporter. +Use this to infer values of `org-odt-styles-dir' and +`org-export-odt-schema-dir'.") + +(defconst org-odt-schema-dir-list + (list + (and org-odt-data-dir + (expand-file-name "./schema/" org-odt-data-dir)) ; bail out + (eval-when-compile + (and (boundp 'org-odt-data-dir) org-odt-data-dir ; see make install + (expand-file-name "./schema/" org-odt-data-dir)))) + "List of directories to search for OpenDocument schema files. +Use this list to set the default value of +`org-export-odt-schema-dir'. The entries in this list are +populated heuristically based on the values of `org-odt-lib-dir' +and `org-odt-data-dir'.") + (defcustom org-export-odt-schema-dir - (let* ((d (expand-file-name "../" (org-find-library-dir "org-odt.el"))) - (schema-dir-list (list (concat d "etc/schema/"))) ;; ELPA and Git - schema-dir) - (setq schema-dir - (car - (delq nil - (mapcar (lambda (sd) - (when (and (file-readable-p - (expand-file-name - "od-manifest-schema-v1.2-cs01.rnc" sd)) - (file-readable-p - (expand-file-name - "od-schema-v1.2-cs01.rnc" sd)) - (file-readable-p - (expand-file-name - "schemas.xml" sd))) - sd)) - schema-dir-list)))) - (or schema-dir - (message "No OpenDocument schema files installed"))) + (let* ((schema-dir + (catch 'schema-dir + (message "Debug (org-odt): Searching for OpenDocument schema files...") + (mapc + (lambda (schema-dir) + (when schema-dir + (message "Debug (org-odt): Trying %s..." schema-dir) + (when (and (file-readable-p + (expand-file-name "od-manifest-schema-v1.2-cs01.rnc" + schema-dir)) + (file-readable-p + (expand-file-name "od-schema-v1.2-cs01.rnc" + schema-dir)) + (file-readable-p + (expand-file-name "schemas.xml" schema-dir))) + (message "Debug (org-odt): Using schema files under %s" + schema-dir) + (throw 'schema-dir schema-dir)))) + org-odt-schema-dir-list) + (message "Debug (org-odt): No OpenDocument schema files installed") + nil))) + schema-dir) "Directory that contains OpenDocument schema files. This directory contains: @@ -117,9 +142,11 @@ that `rng-schema-locating-files' is updated and auto-validation of OpenDocument XML takes place based on the value `rng-nxml-auto-validate-flag'. -The OASIS schema files are available only in the Org's private -git repository. It is *not* bundled with GNU ELPA tar or -standard Emacs distribution." +The default value of this variable varies depending on the +version of org in use and is initialized from +`org-odt-schema-dir-list'. The OASIS schema files are available +only in the org's private git repository. It is *not* bundled +with GNU ELPA tar or standard Emacs distribution." :type '(choice (const :tag "Not set" nil) (directory :tag "Schema directory")) @@ -140,7 +167,8 @@ Also add it to `rng-schema-locating-files'." (expand-file-name "schemas.xml" schema-dir))) schema-dir (when value - (message "No OpenDocument schema files" value)) + (message "Error (org-odt): %s has no OpenDocument schema files" + value)) nil))) (when org-export-odt-schema-dir (eval-after-load 'rng-loc @@ -148,33 +176,56 @@ Also add it to `rng-schema-locating-files'." (expand-file-name "schemas.xml" org-export-odt-schema-dir)))))) +(defconst org-odt-styles-dir-list + (list + (and org-odt-data-dir + (expand-file-name "./styles/" org-odt-data-dir)) ; bail out + (eval-when-compile + (and (boundp 'org-odt-data-dir) org-odt-data-dir ; see make install + (expand-file-name "./styles/" org-odt-data-dir))) + (expand-file-name "../etc/styles/" org-odt-lib-dir) ; git + (expand-file-name "./etc/styles/" org-odt-lib-dir) ; elpa + (expand-file-name "./org/" data-directory) ; system + ) + "List of directories to search for OpenDocument styles files. +See `org-odt-styles-dir'. The entries in this list are populated +heuristically based on the values of `org-odt-lib-dir' and +`org-odt-data-dir'.") + (defconst org-odt-styles-dir - (let* ((d (expand-file-name "../" (org-find-library-dir "org-odt.el"))) - (styles-dir-list (list - (concat d "etc/styles/") ;; ELPA and Git - (concat d "etc/org/"))) - styles-dir) - (setq styles-dir - (car - (delq nil - (mapcar (lambda (sd) - (when (and (file-readable-p - (expand-file-name - "OrgOdtContentTemplate.xml" sd)) - (file-readable-p - (expand-file-name - "OrgOdtStyles.xml" sd))) - sd)) - styles-dir-list)))) - (or styles-dir - (error "Cannot find factory styles files for Org ODT, aborting"))) + (let* ((styles-dir + (catch 'styles-dir + (message "Debug (org-odt): Searching for OpenDocument styles files...") + (mapc (lambda (styles-dir) + (when styles-dir + (message "Debug (org-odt): Trying %s..." styles-dir) + (when (and (file-readable-p + (expand-file-name + "OrgOdtContentTemplate.xml" styles-dir)) + (file-readable-p + (expand-file-name + "OrgOdtStyles.xml" styles-dir))) + (message "Debug (org-odt): Using styles under %s" + styles-dir) + (throw 'styles-dir styles-dir)))) + org-odt-styles-dir-list) + nil))) + (unless styles-dir + (error "Error (org-odt): Cannot find factory styles files, aborting")) + styles-dir) "Directory that holds auxiliary XML files used by the ODT exporter. This directory contains the following XML files - -\"OrgOdtStyles.xml\" and \"OrgOdtContentTemplate.xml\". -These XML files are used as the default values of -`org-export-odt-styles-file' and -`org-export-odt-content-template-file'.") + \"OrgOdtStyles.xml\" and \"OrgOdtContentTemplate.xml\". These + XML files are used as the default values of + `org-export-odt-styles-file' and + `org-export-odt-content-template-file'. + +The default value of this variable varies depending on the +version of org in use and is initialized from +`org-odt-styles-dir-list'. Note that the user could be using org +from one of: org's own private git repository, GNU ELPA tar or +standard Emacs.") (defvar org-odt-file-extensions '(("odt" . "OpenDocument Text") diff --git a/mk/org-fixup.el b/mk/org-fixup.el index 57542749c..7b59efb88 100644 --- a/mk/org-fixup.el +++ b/mk/org-fixup.el @@ -50,7 +50,14 @@ the Git work tree)." \"The Git version of org-mode. Inserted by installing org-mode or when a release is made.\" (let ((org-git-version \"" org-git-version "\")) - org-git-version))") + org-git-version)) +;;;\#\#\#autoload +\(defvar org-odt-data-dir \"" odt-dir "\" + \"The location of ODT styles.\") +\f\n\(provide 'org-version\) +\f\n;; Local Variables:\n;; version-control: never +;; no-byte-compile: t +;; coding: utf-8\n;; End:\n;;; org-version.el ends here\n") (toggle-read-only 0) (write-file "org-version.el"))) @@ -80,7 +87,10 @@ force re-compilation. This function is provided for easier manual install when the build system can't be used." (let* ((origin default-directory) (dirlisp (org-find-library-dir "org")) - (dirorg (concat dirlisp "../" ))) + (dirorg (concat dirlisp "../" )) + (dirodt (if (boundp 'org-odt-data-dir) + org-odt-data-dir + (concat dirorg "etc/")))) (unwind-protect (progn (cd dirlisp)