Mercurial > hg > xemacs-beta
comparison lib-src/update-elc.sh @ 78:c7528f8e288d r20-0b34
Import from CVS: tag r20-0b34
author | cvs |
---|---|
date | Mon, 13 Aug 2007 09:05:42 +0200 |
parents | 54cc21c15cbb |
children | 1ce6082ce73f |
comparison
equal
deleted
inserted
replaced
77:6cb4f478e7bc | 78:c7528f8e288d |
---|---|
26 fi | 26 fi |
27 | 27 |
28 | 28 |
29 EMACS=${XEMACS:-./src/xemacs}; export EMACS | 29 EMACS=${XEMACS:-./src/xemacs}; export EMACS |
30 REAL=`cd \`dirname $EMACS\` ; pwd | sed 's:^/tmp_mnt::'`/`basename $EMACS` | 30 REAL=`cd \`dirname $EMACS\` ; pwd | sed 's:^/tmp_mnt::'`/`basename $EMACS` |
31 BYTECOMP="$REAL -batch -q -no-site-file -l bytecomp" | |
31 echo "Recompiling in `pwd|sed 's:^/tmp_mnt::'`" | 32 echo "Recompiling in `pwd|sed 's:^/tmp_mnt::'`" |
32 echo " with $REAL..." | 33 echo " with $REAL..." |
33 | 34 |
35 prune_vc="( -name SCCS -o -name RCS -o -name CVS ) -prune -o" | |
34 | 36 |
35 # $els is a list of all .el files | 37 # $els is a list of all .el files |
36 # $elcs is a list of all .elc files | 38 # $elcs is a list of all .elc files |
37 els=/tmp/rcl1.$$ ; elcs=/tmp/rcl2.$$ | 39 els=/tmp/rcl1.$$ ; elcs=/tmp/rcl2.$$ |
38 rm -f $els $elcs | 40 rm -f $els $elcs |
59 | 61 |
60 # first recompile the byte-compiler, so that the other compiles take place | 62 # first recompile the byte-compiler, so that the other compiles take place |
61 # with the latest version (assuming we're compiling the lisp dir of the emacs | 63 # with the latest version (assuming we're compiling the lisp dir of the emacs |
62 # we're running, which might not be the case, but often is.) | 64 # we're running, which might not be the case, but often is.) |
63 echo "Checking the byte compiler..." | 65 echo "Checking the byte compiler..." |
64 $REAL -batch -q -no-site-file -f batch-byte-recompile-directory lisp/bytecomp | 66 $BYTECOMP -f batch-byte-recompile-directory lisp/bytecomp |
65 | 67 |
66 # Prepare for byte-compiling directories with directory-specific instructions | 68 # Prepare for byte-compiling directories with directory-specific instructions |
67 make_special_commands='' | 69 make_special_commands='' |
68 make_special () { | 70 make_special () { |
69 dir="$1"; shift; | 71 dir="$1"; shift; |
80 make_special viper elc | 82 make_special viper elc |
81 make_special gnus some | 83 make_special gnus some |
82 make_special w3 | 84 make_special w3 |
83 make_special url # really part of w3 | 85 make_special url # really part of w3 |
84 make_special hyperbole elc | 86 make_special hyperbole elc |
85 make_special oobr HYPB_ELC= elc | 87 make_special oobr HYPB_ELC='' elc |
86 make_special eos -k # not stricly necessary... | 88 make_special eos -k # not stricly necessary... |
87 make_special ilisp compile -f Makefile | 89 make_special ilisp elc -f Makefile |
88 | 90 |
89 ignore_pattern='' | 91 ignore_pattern='' |
90 for dir in $ignore_dirs ; do | 92 for dir in $ignore_dirs ; do |
91 ignore_pattern="${ignore_pattern}/\\/$dir\\//d | 93 ignore_pattern="${ignore_pattern}/\\/$dir\\//d |
92 /\\/$dir\$/d | 94 /\\/$dir\$/d |
111 \!/sunpro/sunpro-load.el$!d | 113 \!/sunpro/sunpro-load.el$!d |
112 ' | 114 ' |
113 | 115 |
114 echo "Compiling files without .elc..." | 116 echo "Compiling files without .elc..." |
115 NUMTOCOMPILE=20 # compile this many files with each invocation | 117 NUMTOCOMPILE=20 # compile this many files with each invocation |
116 comm -23 $els $elcs | sed "$ignore_pattern" | \ | 118 comm -23 $els $elcs | \ |
117 xargs -t -n$NUMTOCOMPILE $REAL -batch -q -no-site-file -f batch-byte-compile | 119 sed "$ignore_pattern" | \ |
120 xargs -t -n$NUMTOCOMPILE $BYTECOMP -f batch-byte-compile | |
118 echo "Compiling files without .elc... Done" | 121 echo "Compiling files without .elc... Done" |
119 | 122 |
120 | 123 |
121 echo "Compiling files with out-of-date .elc..." | 124 echo "Compiling files with out-of-date .elc..." |
122 find lisp/. -name SCCS -prune -o -type d -print | sed "$ignore_pattern" | \ | 125 find lisp/. -name CVS -prune -o -name SCCS -prune -o -type d -print | \ |
126 sed "$ignore_pattern" | \ | |
123 xargs -t $REAL -batch -q -no-site-file -f batch-byte-recompile-directory | 127 xargs -t $REAL -batch -q -no-site-file -f batch-byte-recompile-directory |
124 echo "Compiling files with out-of-date .elc... Done" | 128 echo "Compiling files with out-of-date .elc... Done" |
125 | 129 |
126 | 130 |
127 eval "$make_special_commands" | 131 eval "$make_special_commands" |