annotate make-dist @ 616:3c1ffcac443f

Initial revision
author Jim Blandy <jimb@redhat.com>
date Sun, 19 Apr 1992 08:53:10 +0000
parents
children eca8812e61cd
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
616
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
1 #!/bin/sh
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
2 #
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
3 # make-dist: create an Emacs distribution tar file from the current
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
4 # source tree. This basically creates a duplicate directory
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
5 # structure, and then hard links into it only those files that should
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
6 # be distributed. This means that if you add a file with an odd name,
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
7 # you should make sure that this script will include it.
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
8
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
9 progname="$0"
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
10
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
11 # Exit if a command fails.
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
12 set -e
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
13
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
14 # Print out each line we read, for debugging's sake.
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
15 # set -v
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
16
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
17 cleanup=yes
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
18
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
19 while [ $# -gt 0 ]; do
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
20 case "$1" in
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
21 "--no-cleanup" )
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
22 cleanup=no
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
23 ;;
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
24 * )
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
25 echo "${progname}: Unrecognized argument: $1" >&2
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
26 exit 1
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
27 ;;
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
28 esac
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
29 shift
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
30 done
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
31
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
32 # Make sure we're running in the right place.
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
33 if [ ! -d src -o ! -f src/lisp.h -o ! -d lisp -o ! -f lisp/version.el ]; then
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
34 echo "${progname}: must run in the top directory of the Emacs" >&2
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
35 echo "distribution tree. Cd to that directory and try again." >&2
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
36 exit 1
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
37 fi
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
38
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
39 # Find out which version of Emacs this is.
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
40 version=`grep 'defconst[ ]*emacs-version' lisp/version.el \
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
41 | sed -e 's/^.*"\([0-9]+\.[0-9]+\)\..*$/\1/'`
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
42 if [ ! "${version}" ]; then
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
43 echo "${progname}: can't find current emacs version in ./lisp/version.el." >&2
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
44 exit 1
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
45 fi
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
46
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
47 # Make sure the subdirectory is available.
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
48 tempparent="make-dist.$$"
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
49 if [ -d ${tempparent} ]; then
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
50 echo "${progname}: staging directory ${tempparent} already exists.
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
51 Perhaps a previous invocation of ${progname} failed to clean up
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
52 after itself. Check that directories whose names are of the form
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
53 make-dist.NNNNN don't contain any important information, remove them,
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
54 and try again." >&2
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
55 exit 1
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
56 fi
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
57
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
58 echo "Creating staging directory: ${tempparent}"
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
59 mkdir ${tempparent}
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
60 emacsname="emacs-${version}"
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
61 tempdir="${tempparent}/${emacsname}"
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
62
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
63 echo "Creating top directory: ${tempdir}"
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
64 mkdir ${tempdir}
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
65
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
66 # We copy in the top-level files before creating the subdirectories in
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
67 # hopes that this will make the top-level files appear first in the
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
68 # tar file.
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
69 echo "Copying top-level files."
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
70 ln INSTALL PROBLEMS README ${tempdir}
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
71 ln ChangeLog Makefile.in build-install.in configure make-dist ${tempdir}
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
72
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
73 echo "Creating subdirectories."
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
74 for subdir in lisp lisp/term src src/m src/s lib-src oldXMenu \
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
75 etc lock local-lisp arch-lib cpp info man shortnames; do
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
76 mkdir ${tempdir}/${subdir}
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
77 done
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
78
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
79 echo "Copying lisp."
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
80 # Don't distribute =*.el files, site-init.el, or site-load.el.
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
81 (cd lisp
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
82 ln [a-zA-Z]*.el ../${tempdir}/lisp
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
83 ln [a-zA-Z]*.elc ../${tempdir}/lisp
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
84 ln [a-zA-Z]*.defns ../${tempdir}/lisp
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
85 ln ChangeLog README ../${tempdir}/lisp
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
86 cd ../${tempdir}/lisp
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
87 rm -f site-init site-init.el site-init.elc
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
88 rm -f site-load site-load.el site-load.elc)
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
89
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
90 echo "Copying lisp/term."
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
91 # Don't distribute =*.el files.
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
92 (cd lisp/term
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
93 ln [a-zA-Z]*.el ../../${tempdir}/lisp/term
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
94 ln [a-zA-Z]*.elc ../../${tempdir}/lisp/term
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
95 ln README ../../${tempdir}/lisp/term)
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
96
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
97 echo "Copying src."
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
98 # Don't distribute =*.[ch] files, or the configured versions of
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
99 # config.h.in, paths.h.in, or Makefile.in.
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
100 (cd src
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
101 ln [a-zA-Z]*.c ../${tempdir}/src
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
102 ln [a-zA-Z]*.h ../${tempdir}/src
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
103 ln [a-zA-Z]*.s ../${tempdir}/src
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
104 ln README Makefile.in ymakefile ChangeLog config.h.in paths.h.in \
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
105 ../${tempdir}/src
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
106 ln .gdbinit .dbxinit ../${tempdir}/src
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
107 ln *.com *.opt vms-pp.trans vmsbuild ../${tempdir}/src
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
108 cd ../${tempdir}/src
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
109 etags *.h *.c ../lisp/*.el)
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
110
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
111 echo "Copying src/m."
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
112 (cd src/m
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
113 ln README *.h ../../${tempdir}/src/m)
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
114
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
115 echo "Copying src/s."
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
116 (cd src/s
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
117 ln README *.h ../../${tempdir}/src/s)
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
118
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
119 echo "Copying lib-src."
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
120 (cd lib-src
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
121 ln [a-zA-Z]*.c [a-zA-Z]*.h [a-zA-Z]*.y [a-zA-Z]*.lex ../${tempdir}/lib-src
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
122 ln ChangeLog Makefile.in README testfile ../${tempdir}/lib-src)
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
123
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
124 echo "Copying oldXMenu."
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
125 (cd oldXMenu
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
126 ln *.c *.h ../${tempdir}/oldXMenu
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
127 ln README Makefile Imakefile ChangeLog ../${tempdir}/oldXMenu)
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
128
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
129 echo "Copying etc."
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
130 # Don't distribute DOC files, backups, autosaves, or tex litter.
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
131 (cd etc
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
132 ln [0-9a-zA-Z]* ../${tempdir}/etc
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
133 cd ../${tempdir}/etc
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
134 # Avoid an error when expanding the wildcards later.
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
135 for dummy in DOC-dummy dummy~ \#dummy\# dummy.dvi dummy.log; do
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
136 ln MACHINES ${dummy}
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
137 done
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
138 rm -f DOC* *~ \#*\# *.dvi *.log core)
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
139
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
140 # For now, we comment these out, since I'm not changing them any.
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
141 #!! echo "Copying cpp."
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
142 #!! (cd cpp
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
143 #!! ln cccp.c cexp.y Makefile README ../${tempdir}/cpp)
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
144 #!!
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
145 #!! echo "Copying info."
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
146 #!! # Don't distribute backups or autosaves.
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
147 #!! (cd info
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
148 #!! ln [a-zA-Z]* ../${tempdir}/info
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
149 #!! cd ../${tempdir}/info
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
150 #!! # Avoid an error when expanding the wildcards later.
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
151 #!! ln emacs dummy~ ; ln emacs \#dummy\#
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
152 #!! rm -f *~ \#*\# core)
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
153 #!!
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
154 #!! echo "Copying man."
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
155 #!! (cd man
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
156 #!! ln *.tex *.texinfo *.texi *.aux *.cps *.fns *.kys *.vrs ../${tempdir}/man
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
157 #!! ln *.c ../${tempdir}/man
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
158 #!! ln ChangeLog Makefile README split-man ../${tempdir}/man)
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
159
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
160 echo "Copying shortnames."
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
161 (cd shortnames
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
162 ln *.c ../${tempdir}/shortnames
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
163 ln Makefile reserved special ../${tempdir}/shortnames)
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
164
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
165 echo "Making sure copying notices are symlinks."
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
166 if [ -f ${tempdir}/etc/COPYING ]; then
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
167 rm ${tempdir}/etc/COPYING
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
168 ln etc/COPYING ${tempdir}/etc/COPYING
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
169 fi
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
170 for subdir in lisp src lib-src info shortnames; do
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
171 if [ -f ${tempdir}/${subdir}/COPYING ]; then
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
172 rm ${tempdir}/${subdir}/COPYING
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
173 fi
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
174 ln -s ../etc/COPYING ${tempdir}/${subdir}
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
175 done
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
176
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
177 echo "Creating tar file."
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
178 (cd ${tempparent}; tar cvf - ${emacsname}) | compress > ${emacsname}.tar.Z
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
179
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
180 if [ "${cleanup}" = yes ]; then
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
181 echo "Cleaning up the staging directory."
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
182 rm -rf ${tempparent}
3c1ffcac443f Initial revision
Jim Blandy <jimb@redhat.com>
parents:
diff changeset
183 fi