;;; -*-Emacs-Lisp-*- ;;; ;;; $Id: mk-tgnus,v 5.0 1996/06/27 15:01:37 morioka Exp $ ;;; (setq load-path (append (mapcar (function (lambda (path) (expand-file-name path (getenv "PWD")) )) '("." ".." "../../tl/" "../../mel/")) load-path)) (require 'emu) (defun compile-tm-gnus () (load "gnus.el") (require 'nntp) (require 'tm-view) (require 'tm-partial) (require 'tm-edit) (princ (format "%s\n" gnus-version)) (cond ((boundp 'gnus-original-article-buffer) (require 'tm-gnus) (byte-compile-file "tm-gnus5.el") ) ((string-match "Gnus v5\\|September Gnus" gnus-version) (require 'tm-gnus) (byte-compile-file "tm-gnus4.el") ) ((string-match "GNUS 4" gnus-version) (require 'tm-gnus) (byte-compile-file "tm-gnus4.el") ) ((string-match "GNUS 3" gnus-version) (require 'tm-gnus) (byte-compile-file "tm-gnus3.el") )) ;;(byte-compile-file "tm-gnus.el") ) (defconst el-file-mode (+ (* 64 6)(* 8 4) 4)) (defun install-el (path file) (let ((full-path (expand-file-name file path))) (if (file-exists-p full-path) (set-file-modes full-path el-file-mode) ) (copy-file file full-path t t) (princ (format "%s -> %s\n" file path)) )) (defun install-el-files (path &rest files) (mapcar (function (lambda (file) (if (file-exists-p file) (install-el path file) ))) files)) (defun install-elc (path file) (let ((full-path (expand-file-name file path))) (copy-file file full-path t t) (delete-file file) (princ (format "%s -> %s\n" file path)) )) (defun install-elc-files (path &rest files) (mapcar (function (lambda (file) (if (file-exists-p file) (install-elc path file) ))) files)) (defun install-tm-gnus () (let ((path (car command-line-args-left))) (princ (format "%s\n" emacs-version)) (if (not (file-exists-p path)) (make-directory path t) ) (cond (running-emacs-18 (install-el-files path "tm-gnus.el" "tm-gnus3.el" "tm-gnus4.el" "tm-gd3.el") (install-elc-files path ;;"tm-gnus.elc" "tm-gnus3.elc" "tm-gnus4.elc") ) ((and running-emacs-19 (<= emacs-minor-version 29)) (install-el-files path "tm-gnus.el" "tm-gnus4.el" "tm-gd3.el") (install-elc-files path ;;"tm-gnus.elc" "tm-gnus4.elc") ) ((and running-xemacs-19 (<= emacs-minor-version 13)) (install-el-files path "tm-gnus.el" "tm-gnus5.el" "tm-gnus4.el" "tm-gd3.el") (install-elc-files path ;;"tm-gnus.elc" "tm-gnus5.elc" "tm-gnus4.elc") ) ((and running-emacs-19 (<= emacs-minor-version 31)) (install-el-files path "tm-gnus.el" "tm-gnus5.el" "tm-gnus4.el") (install-elc-files path ;;"tm-gnus.elc" "tm-gnus5.elc" "tm-gnus4.elc") ) (t (install-el-files path "tm-gnus.el" "tm-gnus5.el") (install-elc-files path ;;"tm-gnus.elc" "tm-gnus5.elc") )) (setq command-line-args-left (cdr command-line-args-left)) ))