Mercurial > emacs
comparison make-dist @ 111085:8752cead918b
* make-dist: Avoid listing .el files twice.
Don't try to run autoconf if --no-update.
author | Glenn Morris <rgm@gnu.org> |
---|---|
date | Thu, 21 Oct 2010 20:26:34 -0700 |
parents | 387ef32f980b |
children | d276c036caef |
comparison
equal
deleted
inserted
replaced
111084:8c55e138333b | 111085:8752cead918b |
---|---|
184 \`make-dist.tmp.NNNNN' don't contain any important information, remove | 184 \`make-dist.tmp.NNNNN' don't contain any important information, remove |
185 them, and try again." >&2 | 185 them, and try again." >&2 |
186 exit 1 | 186 exit 1 |
187 fi | 187 fi |
188 | 188 |
189 ### Find where to run Emacs. | 189 if [ $check = yes ]; then |
190 if [ $check = yes ]; | |
191 then | |
192 ### Check for .elc files with no corresponding .el file. | |
193 ls -1 lisp/[a-zA-Z]*.el lisp/[a-z]*/[a-zA-Z0-9]*.el \ | 190 ls -1 lisp/[a-zA-Z]*.el lisp/[a-z]*/[a-zA-Z0-9]*.el \ |
194 lisp/[a-z]*/[a-z]*/[a-zA-Z0-9]*.el \ | 191 lisp/[a-z]*/[a-z]*/[a-zA-Z0-9]*.el \ |
195 lisp/[a-z]*/[a-z]*/[a-z]*/[a-zA-Z0-9]*.el \ | 192 lisp/[a-z]*/[a-z]*/[a-z]*/[a-zA-Z0-9]*.el \ |
196 leim/[a-z]*/[a-z]*.el | sed 's/\.el$/.elc/' > /tmp/el | 193 leim/[a-z]*/[a-z]*.el > /tmp/el |
194 | |
197 ls -1 lisp/[a-zA-Z]*.elc lisp/[a-z]*/[a-zA-Z0-9]*.elc \ | 195 ls -1 lisp/[a-zA-Z]*.elc lisp/[a-z]*/[a-zA-Z0-9]*.elc \ |
198 lisp/[a-z]*/[a-z]*/[a-zA-Z0-9]*.elc \ | 196 lisp/[a-z]*/[a-z]*/[a-zA-Z0-9]*.elc \ |
199 lisp/[a-z]*/[a-z]*/[a-z]*/[a-zA-Z0-9]*.elc \ | 197 lisp/[a-z]*/[a-z]*/[a-z]*/[a-zA-Z0-9]*.elc \ |
200 leim/[a-z]*/[a-z]*.elc > /tmp/elc | 198 leim/[a-z]*/[a-z]*.elc > /tmp/elc |
201 bogosities="`comm -13 /tmp/el /tmp/elc`" | 199 |
202 if [ "${bogosities}" != "" ]; then | 200 ## Check for .elc files with no corresponding .el file. |
201 sed 's/\.el$/.elc/' /tmp/el > /tmp/elelc | |
202 | |
203 bogosities="`comm -13 /tmp/elelc /tmp/elc`" | |
204 if [ x"${bogosities}" != x"" ]; then | |
203 echo "The following .elc files have no corresponding .el files:" | 205 echo "The following .elc files have no corresponding .el files:" |
204 echo "${bogosities}" | 206 echo "${bogosities}" |
205 fi | 207 fi |
206 rm -f /tmp/el /tmp/elc | |
207 | 208 |
208 ### Check for .el files with no corresponding .elc file. | 209 ### Check for .el files with no corresponding .elc file. |
209 ls -1 lisp/[a-zA-Z]*.el lisp/[a-z]*/[a-zA-Z0-9]*.el \ | 210 sed 's/\.elc$/.el/' /tmp/elc > /tmp/elcel |
210 lisp/[a-z]*/[a-z]*/[a-zA-Z0-9]*.el \ | 211 losers="`comm -23 /tmp/el /tmp/elcel`" |
211 lisp/[a-z]*/[a-z]*/[a-z]*/[a-zA-Z0-9]*.el \ | 212 |
212 leim/[a-z]*/[a-z]*.el > /tmp/el | 213 rm -f /tmp/el /tmp/elc /tmp/elcel /tmp/elelc |
213 ls -1 lisp/[a-zA-Z]*.elc lisp/[a-z]*/[a-zA-Z0-9]*.elc \ | 214 |
214 lisp/[a-z]*/[a-z]*/[a-zA-Z0-9]*.el \ | |
215 lisp/[a-z]*/[a-z]*/[a-z]*/[a-zA-Z0-9]*.el \ | |
216 leim/[a-z]*/[a-z]*.elc | sed 's/\.elc$/.el/' > /tmp/elc | |
217 losers="`comm -23 /tmp/el /tmp/elc`" | |
218 bogosities= | 215 bogosities= |
219 for file in $losers; do | 216 for file in $losers; do |
220 if ! grep -q "no-byte-compile: t" $file; then | 217 grep -q "no-byte-compile: t" $file && continue |
221 case $file in | 218 case $file in |
222 site-init.el | site-load.el | site-start.el | default.el) | 219 site-init.el | site-load.el | site-start.el | default.el) continue ;; |
223 ;; | 220 esac |
224 *) | 221 |
225 bogosities="$file $bogosities" | 222 bogosities="$file $bogosities" |
226 ;; | 223 |
227 esac | |
228 fi | |
229 done | 224 done |
230 if [ x"${bogosities}" != x"" ]; then | 225 if [ x"${bogosities}" != x"" ]; then |
231 echo "The following .el files have no corresponding .elc files:" | 226 echo "The following .el files have no corresponding .elc files:" |
232 echo "${bogosities}" | 227 echo "${bogosities}" |
233 fi | 228 fi |
234 rm -f /tmp/el /tmp/elc | 229 fi |
235 fi | 230 |
236 | 231 if [ $update = yes ]; then |
237 ### Make sure configure is newer than configure.in. | 232 |
238 if [ "x`ls -t configure configure.in | sed q`" != "xconfigure" ]; then | 233 ## Make sure configure is newer than configure.in. |
239 echo "\`./configure.in' is newer than \`./configure'" >&2 | 234 if [ "x`ls -t configure configure.in | sed q`" != "xconfigure" ]; then |
240 echo "Running autoconf" >&2 | 235 echo "\`./configure.in' is newer than \`./configure'" >&2 |
241 autoconf || { x=$?; echo Autoconf FAILED! >&2; exit $x; } | 236 echo "Running autoconf" >&2 |
242 fi | 237 autoconf || { x=$?; echo Autoconf FAILED! >&2; exit $x; } |
243 | 238 fi |
244 ### Make sure src/stamp-h.in is newer than configure.in. | 239 |
245 if [ "x`ls -t src/stamp-h.in configure.in | sed q`" != "xsrc/stamp-h.in" ]; then | 240 ## Make sure src/stamp-h.in is newer than configure.in. |
246 echo "\`./configure.in' is newer than \`./src/stamp-h.in'" >&2 | 241 if [ "x`ls -t src/stamp-h.in configure.in | sed q`" != "xsrc/stamp-h.in" ]; then |
247 echo "Running autoheader" >&2 | 242 echo "\`./configure.in' is newer than \`./src/stamp-h.in'" >&2 |
248 autoheader || { x=$?; echo Autoheader FAILED! >&2; exit $x; } | 243 echo "Running autoheader" >&2 |
249 rm -f src/stamp-h.in | 244 autoheader || { x=$?; echo Autoheader FAILED! >&2; exit $x; } |
250 echo timestamp > src/stamp-h.in | 245 rm -f src/stamp-h.in |
251 fi | 246 echo timestamp > src/stamp-h.in |
252 | 247 fi |
253 if [ $update = yes ]; | 248 |
254 then | |
255 echo "Updating Info files" | 249 echo "Updating Info files" |
256 (cd doc/emacs; make info) | 250 (cd doc/emacs; make info) |
257 (cd doc/misc; make info) | 251 (cd doc/misc; make info) |
258 (cd doc/lispref; make info) | 252 (cd doc/lispref; make info) |
259 (cd doc/lispintro; make info) | 253 (cd doc/lispintro; make info) |
266 (cd leim; make leim-list.el EMACS="$EMACS") | 260 (cd leim; make leim-list.el EMACS="$EMACS") |
267 fi | 261 fi |
268 | 262 |
269 echo "Recompiling Lisp files" | 263 echo "Recompiling Lisp files" |
270 $EMACS -batch -f batch-byte-recompile-directory lisp leim | 264 $EMACS -batch -f batch-byte-recompile-directory lisp leim |
271 fi | 265 fi # $update = yes |
272 | 266 |
273 echo "Creating staging directory: \`${tempparent}'" | 267 echo "Creating staging directory: \`${tempparent}'" |
274 | 268 |
275 mkdir ${tempparent} | 269 mkdir ${tempparent} |
276 tempdir="${tempparent}/${emacsname}" | 270 tempdir="${tempparent}/${emacsname}" |