* wl-summary.el (wl-summary-pick): Fix for no match.
[elisp/wanderlust.git] / WL-MK
diff --git a/WL-MK b/WL-MK
index c02018e..008697e 100644 (file)
--- a/WL-MK
+++ b/WL-MK
@@ -43,7 +43,7 @@
             ;; ignore broken module
             (not (featurep 'tinycustom)))
   (when (and (boundp 'emacs-major-version)
-            (eq emacs-major-version 19)
+            (= emacs-major-version 19)
             (>= emacs-minor-version 29))
     (message "%s" "
   Warning: You don't seem to have \"new custom\" package installed.
@@ -96,7 +96,6 @@
     (setq load-path (cons (expand-file-name ".") load-path))
     (setq load-path (cons (expand-file-name WLDIR)
                          (cons (expand-file-name ELMODIR) load-path)))
-    (setq wl-icon-dir (expand-file-name ICONDIR))
     ;; load custom file if exists.  `WL-CFG.el' override for committer.
     (load "./WL-CFG" t nil nil)
     ;; load-path
        (setq load-path (cons (expand-file-name UTILSDIR) load-path)))
     (require 'install)
     (load "./WL-ELS" nil nil t)
-    (condition-case ()
-       (require 'mime-setup)
-      (error (error "No MIME module was detected. Please install SEMI.")))
+    ;; product.el version check
+    (require 'product)
+    (if (not (fboundp 'product-version-as-string))
+       (error "Please install new APEL.  See INSTALL or INSTALL.ja"))
     ;; smtp.el version check.
     (require 'smtp)
     (if (not (fboundp 'smtp-send-buffer))
-       (error "Please install new FLIM.  See INSTALL or INSTALL.ja."))))
+       (error "Please install new FLIM.  See INSTALL or INSTALL.ja"))
+    (condition-case ()
+       (require 'mime-setup)
+      (error (error "Cannot load `mime-setup'.  Please install SEMI")))))
 
 (defun config-wl-pixmap-dir (&optional packagedir)
   "Examine pixmap directory where icon files should go."
       (if (string= pixmap-dir "NONE")
          (if packagedir
              (expand-file-name "etc/wl/" packagedir)
-           (if (or (featurep 'xemacs)
-                   (and (boundp 'emacs-major-version)
-                        (>= emacs-major-version 21)))
-               (expand-file-name "wl/icons/" data-directory)))
+           (expand-file-name "wl/icons/" data-directory))
        pixmap-dir)))
   (if PIXMAPDIR
       (princ (format "PIXMAPDIR is %s\n" PIXMAPDIR)))
   (config-wl-pixmap-dir)
   (princ "\n"))
 
+(defun update-version ()
+  "Update version number of documents."
+  (config-wl-package)
+  (load-file "elmo/elmo-version.el")
+  (let ((version (mapconcat
+                 'number-to-string
+                 (product-version (product-find 'elmo-version))
+                 ".")))
+    (princ (concat "Update version number to " version "\n"))
+    ;; generate version.tex
+    (with-temp-buffer
+      (insert "\\def\\versionnumber{" version "}\n")
+      (write-region (point-min) (point-max) (expand-file-name
+                                            "version.tex" "doc")))
+    ;; generate version.texi
+    (with-temp-buffer
+      (insert "@set VERSION " version "\n")
+      (write-region (point-min) (point-max) (expand-file-name
+                                            "version.texi" "doc")))))
+
 (defun test-wl ()
   "Run test suite for developer."
   (config-wl-package)
   (if (not (file-directory-p PIXMAPDIR))
       (make-directory PIXMAPDIR t))
   (let* ((case-fold-search t)
-        (icons (directory-files ICONDIR t "\\.x[bp]m$"))
+        (icons (directory-files ICONDIR t
+                                (cond ((featurep 'xemacs)
+                                       "\\.x[bp]m$")
+                                      ((and (boundp 'emacs-major-version)
+                                            (>= emacs-major-version 21))
+                                       "\\.img$\\|\\.x[bp]m$")
+                                      ((featurep 'mule)
+                                       "\\.img$\\|\\.xbm$"))))
         icon dest)
     (while icons
       (setq icon (car icons)
 
 (defun config-wl-package-xmas ()
   (if (not (featurep 'xemacs))
-      (error "This directive is only for XEmacs."))
+      (error "This directive is only for XEmacs"))
   (config-wl-package-subr)
   ;; PACKAGEDIR check.
   (let (package-dir)