X-Git-Url: http://git.chise.org/gitweb/?a=blobdiff_plain;f=WL-MK;h=88f8dc8ae46dfe962b2097821f00a3b0082f7207;hb=a239186ddb65a69cbcc0d8fbd3f1be932f201fdb;hp=89d7af2e22a34b86a097adce9d83630c1fe45602;hpb=6e6538e72bdd4d598d7715d4ceb68c449621421d;p=elisp%2Fwanderlust.git diff --git a/WL-MK b/WL-MK index 89d7af2..88f8dc8 100644 --- a/WL-MK +++ b/WL-MK @@ -212,25 +212,25 @@ (defun wl-scan-source (path) (let (ret) - (mapcar - '(lambda (x) - (mapcar '(lambda (y) - (setq ret (append (list y (concat y "c")) ret))) - (directory-files x nil "\\(.+\\)\\.el$" t))) + (mapc + (lambda (x) + (mapc (lambda (y) + (setq ret (append (list y (concat y "c")) ret))) + (directory-files x nil "\\(.+\\)\\.el$" t))) path) ret)) (defun wl-uninstall (objs path) ;(message (mapconcat 'identity objs " ")) - (mapcar - '(lambda (x) - (let ((filename (expand-file-name x path))) - (if (and (file-exists-p filename) - (file-writable-p filename)) - (progn - (princ (format "%s was uninstalled.\n" filename)) - (delete-file filename))))) + (mapc + (lambda (x) + (let ((filename (expand-file-name x path))) + (if (and (file-exists-p filename) + (file-writable-p filename)) + (progn + (princ (format "%s was uninstalled.\n" filename)) + (delete-file filename))))) objs)) @@ -246,9 +246,9 @@ (defun compile-wl-package () (config-wl-package) (make-wl-news) - (mapcar - '(lambda (x) - (compile-elisp-modules (cdr x) (car x))) + (mapc + (lambda (x) + (compile-elisp-modules (cdr x) (car x))) modules-alist)) (defun install-wl-icons () @@ -265,16 +265,29 @@ "\\.img$\\|\\.xbm$"))))) (install-files icons ICONDIR PIXMAPDIR nil 'overwrite))) +(defun uninstall-wl-icons () + (let* ((case-fold-search t) + (icons (directory-files PIXMAPDIR t "\\.img$\\|\\.x[bp]m$")) + icon) + (while icons + (setq icon (car icons) + icons (cdr icons)) + (if (and (file-exists-p icon) + (file-writable-p icon)) + (progn + (princ (format "%s was uninstalled.\n" icon)) + (delete-file icon)))))) + (defun install-wl-package () (compile-wl-package) (let ((wl-install-dir (expand-file-name WL_PREFIX LISPDIR)) (elmo-install-dir (expand-file-name ELMO_PREFIX LISPDIR))) - (mapcar - '(lambda (x) - (install-elisp-modules (cdr x) (car x) - (if (string= (car x) ELMODIR) - elmo-install-dir - wl-install-dir))) + (mapc + (lambda (x) + (install-elisp-modules (cdr x) (car x) + (if (string= (car x) ELMODIR) + elmo-install-dir + wl-install-dir))) modules-alist)) (if PIXMAPDIR (install-wl-icons))) @@ -291,17 +304,7 @@ (wl-uninstall (wl-scan-source (list ELMODIR)) elmo-install-dir)) (if PIXMAPDIR - (let* ((case-fold-search t) - (icons (directory-files PIXMAPDIR t "\\.x[bp]m$")) - icon) - (while icons - (setq icon (car icons) - icons (cdr icons)) - (if (and (file-exists-p icon) - (file-writable-p icon)) - (progn - (princ (format "%s was uninstalled.\n" icon)) - (delete-file icon))))))) + (uninstall-wl-icons))) (defun config-wl-package-xmas () @@ -333,9 +336,9 @@ (Custom-make-dependencies) ;; WL-AUTOLOAD-MODULES (compile-elisp-modules WL-AUTOLOAD-MODULES WLDIR) - (mapcar - '(lambda (x) - (compile-elisp-modules (cdr x) (car x))) + (mapc + (lambda (x) + (compile-elisp-modules (cdr x) (car x))) modules-alist)) (defun install-wl-package-xmas () @@ -354,9 +357,9 @@ ;; copy xpm files (install-wl-icons) - (mapcar '(lambda (x) - (install-elisp-modules (cdr x) (car x) LISPDIR)) - modules-alist) + (mapc (lambda (x) + (install-elisp-modules (cdr x) (car x) LISPDIR)) + modules-alist) ;; WL-AUTOLOAD-MODULES (install-elisp-modules WL-AUTOLOAD-MODULES WLDIR LISPDIR) ;; @@ -403,7 +406,7 @@ (wl-detect-info-directory) (cond ((null wl-info-lang)) ((listp wl-info-lang) - (mapcar 'wl-texinfo-format-file wl-info-lang)) + (mapc 'wl-texinfo-format-file wl-info-lang)) ((stringp wl-info-lang) (wl-texinfo-format-file wl-info-lang)))) @@ -414,7 +417,7 @@ (defun wl-texinfo-install () (cond ((null wl-info-lang)) ((listp wl-info-lang) - (mapcar 'wl-texinfo-install-file wl-info-lang)) + (mapc 'wl-texinfo-install-file wl-info-lang)) ((stringp wl-info-lang) (wl-texinfo-install-file wl-info-lang))))