diff lisp/mel/mel-g.el @ 30:ec9a17fef872 r19-15b98

Import from CVS: tag r19-15b98
author cvs
date Mon, 13 Aug 2007 08:52:29 +0200
parents 441bb1e64a06
children e04119814345
line wrap: on
line diff
--- a/lisp/mel/mel-g.el	Mon Aug 13 08:51:58 2007 +0200
+++ b/lisp/mel/mel-g.el	Mon Aug 13 08:52:29 2007 +0200
@@ -1,53 +1,53 @@
-;;;
 ;;; mel-g.el: Gzip64 encoder/decoder for GNU Emacs
-;;;
-;;; Copyright (C) 1995,1996 MORIOKA Tomohiko
-;;; Copyright (C) 1996 Shuhei KOBAYASHI
-;;;
-;;; Author: Shuhei KOBAYASHI <shuhei-k@jaist.ac.jp>
-;;;         modified by MORIOKA Tomohiko <morioka@jaist.ac.jp>
-;;; Maintainer: Shuhei KOBAYASHI <shuhei-k@jaist.ac.jp>
-;;; Created: 1995/10/25
-;;; Version:
-;;;	$Id: mel-g.el,v 1.4 1997/03/02 03:43:25 steve Exp $
-;;; Keywords: MIME, base64, gzip
-;;;
-;;; This file is not part of MEL (MIME Encoding Library) yet.
-;;;
-;;; This program is free software; you can redistribute it and/or
-;;; modify it under the terms of the GNU General Public License as
-;;; published by the Free Software Foundation; either version 2, or
-;;; (at your option) any later version.
-;;;
-;;; This program is distributed in the hope that it will be useful,
-;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
-;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-;;; General Public License for more details.
-;;;
-;;; You should have received a copy of the GNU General Public License
-;;; along with This program.  If not, write to the Free Software
-;;; Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
-;;;
+
+;; Copyright (C) 1995,1996,1997 MORIOKA Tomohiko
+;; Copyright (C) 1996 Shuhei KOBAYASHI
+
+;; Author: Shuhei KOBAYASHI <shuhei-k@jaist.ac.jp>
+;;	modified by MORIOKA Tomohiko <morioka@jaist.ac.jp>
+;; Maintainer: Shuhei KOBAYASHI <shuhei-k@jaist.ac.jp>
+;; Created: 1995/10/25
+;; Version: $Id: mel-g.el,v 1.5 1997/03/09 02:37:18 steve Exp $
+;; Keywords: Gzip64, base64, gzip, MIME
+
+;; This file is not part of MEL (MIME Encoding Library) yet.
+
+;; This program is free software; you can redistribute it and/or
+;; modify it under the terms of the GNU General Public License as
+;; published by the Free Software Foundation; either version 2, or (at
+;; your option) any later version.
+
+;; This program is distributed in the hope that it will be useful, but
+;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+;; General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING.  If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+
 ;;; Code:
 
 (require 'emu)
+(require 'file-detect)
 
 
 ;;; @ variables
 ;;;
 
-(defvar gzip64-external-encoder `("sh" "-c"
-				  ,(concat
-				    "gzip -c | "
-				    (expand-file-name "mmencode"
-						      exec-directory)))
+(defvar gzip64-external-encoder
+  (let ((file (file-installed-p "mmencode" exec-path)))
+    (and file
+	 (` ("sh" "-c" (, (concat "gzip -c | " file))))
+	 ))
   "*list of gzip64 encoder program name and its arguments.")
 
-(defvar gzip64-external-decoder `("sh" "-c"
-				  ,(concat
-				    (expand-file-name "mmencode"
-						      exec-directory)
-				    " -u | gzip -dc"))
+(defvar gzip64-external-decoder
+  (let ((file (file-installed-p "mmencode" exec-path)))
+    (and file
+	 (` ("sh" "-c" (, (concat file " -u | gzip -dc"))))
+	 ))
   "*list of gzip64 decoder program name and its arguments.")