annotate lib-src/tm-au @ 149:538048ae2ab8 r20-3b1

Import from CVS: tag r20-3b1
author cvs
date Mon, 13 Aug 2007 09:36:16 +0200
parents 0d2f883870bc
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
4
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
1 #!/bin/sh -
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
2 #
98
0d2f883870bc Import from CVS: tag r20-1b1
cvs
parents: 86
diff changeset
3 # $Id: tm-au,v 1.6 1997/02/15 22:20:26 steve Exp $
4
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
4 #
86
364816949b59 Import from CVS: tag r20-0b93
cvs
parents: 82
diff changeset
5 # Copyright 1994,1995,1996,1997 Free Software Foundation, Inc.
364816949b59 Import from CVS: tag r20-0b93
cvs
parents: 82
diff changeset
6
364816949b59 Import from CVS: tag r20-0b93
cvs
parents: 82
diff changeset
7 # This program is free software; you can redistribute it and/or modify
364816949b59 Import from CVS: tag r20-0b93
cvs
parents: 82
diff changeset
8 # it under the terms of the GNU General Public License as published by
364816949b59 Import from CVS: tag r20-0b93
cvs
parents: 82
diff changeset
9 # the Free Software Foundation; either version 2, or (at your option)
364816949b59 Import from CVS: tag r20-0b93
cvs
parents: 82
diff changeset
10 # any later version.
364816949b59 Import from CVS: tag r20-0b93
cvs
parents: 82
diff changeset
11 #
364816949b59 Import from CVS: tag r20-0b93
cvs
parents: 82
diff changeset
12 # This program is distributed in the hope that it will be useful,
364816949b59 Import from CVS: tag r20-0b93
cvs
parents: 82
diff changeset
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
364816949b59 Import from CVS: tag r20-0b93
cvs
parents: 82
diff changeset
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
364816949b59 Import from CVS: tag r20-0b93
cvs
parents: 82
diff changeset
15 # GNU General Public License for more details.
364816949b59 Import from CVS: tag r20-0b93
cvs
parents: 82
diff changeset
16 #
364816949b59 Import from CVS: tag r20-0b93
cvs
parents: 82
diff changeset
17 # You should have received a copy of the GNU General Public License
364816949b59 Import from CVS: tag r20-0b93
cvs
parents: 82
diff changeset
18 # along with GNU Emacs; see the file COPYING. If not, write to the
364816949b59 Import from CVS: tag r20-0b93
cvs
parents: 82
diff changeset
19 # Free Software Foundation, Inc., 59 Temple Place - Suite 330,
364816949b59 Import from CVS: tag r20-0b93
cvs
parents: 82
diff changeset
20 # Boston, MA 02111-1307, USA.
14
9ee227acff29 Import from CVS: tag r19-15b90
cvs
parents: 10
diff changeset
21
80
1ce6082ce73f Import from CVS: tag r20-0b90
cvs
parents: 76
diff changeset
22 PATH=${PATH:-/usr/bin:/bin}:`dirname $0 2>/dev/null`; export PATH
1ce6082ce73f Import from CVS: tag r20-0b90
cvs
parents: 76
diff changeset
23
4
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
24 if [ "$TM_TMP_DIR" = "" ]; then
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
25 TM_TMP_DIR=/tmp
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
26 export TM_TMP_DIR
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
27 fi
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
28
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
29 if [ "$5" = "" ]; then
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
30 filename="$TM_TMP_DIR/mime$$.au"
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
31 else
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
32 filename="$TM_TMP_DIR/$5"
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
33 fi
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
34
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
35
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
36 case "$4" in
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
37 "play")
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
38 echo "$2; $3 ->"
76
c0c698873ce1 Import from CVS: tag r20-0b33
cvs
parents: 70
diff changeset
39 tmdecode $3 $1 $filename
4
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
40 if [ "$AUDIOSERVER" = "" ]; then
98
0d2f883870bc Import from CVS: tag r20-1b1
cvs
parents: 86
diff changeset
41 case "`uname`" in
0d2f883870bc Import from CVS: tag r20-1b1
cvs
parents: 86
diff changeset
42 IRIX ) sfplay $filename ;;
0d2f883870bc Import from CVS: tag r20-1b1
cvs
parents: 86
diff changeset
43 OSF1 ) decsound -play $filename ;;
0d2f883870bc Import from CVS: tag r20-1b1
cvs
parents: 86
diff changeset
44 * ) cat $filename > /dev/audio ;;
0d2f883870bc Import from CVS: tag r20-1b1
cvs
parents: 86
diff changeset
45 esac
4
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
46 else
98
0d2f883870bc Import from CVS: tag r20-1b1
cvs
parents: 86
diff changeset
47 autool -v 40 $filename
4
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
48 fi
98
0d2f883870bc Import from CVS: tag r20-1b1
cvs
parents: 86
diff changeset
49
76
c0c698873ce1 Import from CVS: tag r20-0b33
cvs
parents: 70
diff changeset
50 trap 'rm -f $filename' 0 1 2 3 13 15
4
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
51 ;;
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
52 "extract")
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
53 echo "$2; $3 -> $filename"
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
54 echo "extract to $filename"
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
55 tmdecode $3 $1 $filename
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
56 ;;
b82b59fe008d Import from CVS: tag r19-15b3
cvs
parents:
diff changeset
57 esac