| 38 | | if not (%4) == (src) goto :lisp |
|---|
| 39 | | |
|---|
| 40 | | :src |
|---|
| 41 | | |
|---|
| 42 | | echo Create full source distribution, excluding leim |
|---|
| 43 | | %TAR% --exclude leim --exclude _marker --exclude DOC --exclude DOC-X --exclude TAGS --exclude bin --exclude obj --exclude obj-spd --exclude oo --exclude oo-spd --exclude *~ --exclude *.rej -cvf - emacs-%1 | gzip -9 > %2-src.tar.gz |
|---|
| 44 | | if not (%4) == () goto end |
|---|
| 45 | | |
|---|
| 46 | | :lisp |
|---|
| 47 | | echo Create limited elisp source distribution |
|---|
| 48 | | %TAR% --exclude *.rej --exclude *.elc --exclude *~ -cvf - emacs-%1/lisp | gzip -9 > %2-lisp.tar.gz |
|---|
| 49 | | if not (%4) == () goto end |
|---|
| 53 | | set eld=emacs-%1/lisp |
|---|
| 54 | | |
|---|
| 55 | | rem List of Lisp files that are not compiled and that should be |
|---|
| 56 | | rem included in the bin distribution. |
|---|
| 57 | | |
|---|
| 58 | | rem It would be better to generate this list automatically. It is the |
|---|
| 59 | | rem list of all .el files for which there is no corresponding .elc |
|---|
| 60 | | rem file, minus ldefs-boot.el. --lute |
|---|
| 61 | | |
|---|
| 62 | | set elfiles=%eld%/cus-load.el %eld%/emacs-lisp/cl-specs.el %eld%/eshell/esh-groups.el %eld%/eshell/esh-maint.el %eld%/finder-inf.el %eld%/forms-d2.el %eld%/forms-pass.el %eld%/international/latin-1.el %eld%/international/latin-2.el %eld%/international/latin-3.el %eld%/international/latin-4.el %eld%/international/latin-5.el %eld%/international/latin-8.el %eld%/international/latin-9.el %eld%/international/mule-conf.el %eld%/language/czech.el %eld%/language/devanagari.el %eld%/language/english.el %eld%/language/georgian.el %eld%/language/greek.el %eld%/language/hebrew.el %eld%/language/japanese.el %eld%/language/kannada.el %eld%/language/korean.el %eld%/language/lao.el %eld%/language/malayalam.el %eld%/language/misc-lang.el %eld%/language/romanian.el %eld%/language/slovak.el %eld%/language/tamil.el %eld%/language/thai.el %eld%/language/utf-8-lang.el %eld%/loaddefs.el %eld%/loadup.el %eld%/mail/blessmail.el %eld%/mh-e/mh-acros.el %eld%/mh-e/mh-gnus.el %eld%/mh-e/mh-loaddefs.el %eld%/obsolete/keyswap.el %eld%/patcomp.el %eld%/paths.el %eld%/play/bruce.el %eld%/subdirs.el %eld%/term/AT386.el %eld%/term/apollo.el %eld%/term/bobcat.el %eld%/term/internal.el %eld%/term/iris-ansi.el %eld%/term/linux.el %eld%/term/lk201.el %eld%/term/news.el %eld%/term/vt102.el %eld%/term/vt125.el %eld%/term/vt200.el %eld%/term/vt201.el %eld%/term/vt220.el %eld%/term/vt240.el %eld%/term/vt300.el %eld%/term/vt320.el %eld%/term/vt400.el %eld%/term/vt420.el %eld%/term/wyse50.el %eld%/version.el |
|---|
| 63 | | |
|---|
| 64 | | set fns_el= |
|---|
| 65 | | for %%f in (emacs-%1/bin/fns*) do set fns_el=%fns_el% emacs-%1/bin/%%f |
|---|
| 66 | | |
|---|
| 67 | | echo Create bin distribution |
|---|
| 68 | | copy %3\README.W32 emacs-%1\README.W32 |
|---|
| 69 | | |
|---|
| 70 | | del #files# #elfiles# |
|---|
| 71 | | for %%f in (emacs-%1/BUGS emacs-%1/README emacs-%1/README.W32) do echo %%f>>#files# |
|---|
| 72 | | for %%f in (emacs-%1/bin/fns*) do echo emacs-%1/bin/%%f>>#elfiles# |
|---|
| 73 | | for %%f in (emacs-%1/bin emacs-%1/etc emacs-%1/info emacs-%1/lisp) do echo %%f>>#files# |
|---|
| 74 | | for %%f in (emacs-%1/lock emacs-%1/site-lisp) do echo %%f>>#files# |
|---|
| 75 | | for %%f in (%elfiles% emacs-%1/site-lisp/subdirs.el) do echo %%f>>#elfiles# |
|---|
| 76 | | |
|---|
| 77 | | %TAR% --exclude temacs.exe --exclude emacs.mdp --exclude *.pdb --exclude *.opt --exclude "*.el" --exclude "*~" -T #files# -cvf %2-bin-i386.tar |
|---|
| 78 | | %TAR% -T #elfiles# -rvf %2-bin-i386.tar |
|---|
| 79 | | gzip -9 %2-bin-i386.tar |
|---|
| 80 | | del emacs-%1\README.W32 |
|---|
| 81 | | rem del #files# #elfiles# |
|---|
| 82 | | if not (%4) == () goto end |
|---|
| 83 | | |
|---|
| 84 | | :fullbin |
|---|
| 85 | | |
|---|
| 88 | | |
|---|
| 89 | | %TAR% --exclude temacs.exe --exclude emacs.mdp --exclude *.pdb --exclude *.opt --exclude *~ -cvf - emacs-%1/BUGS emacs-%1/README emacs-%1/README.W32 emacs-%1/bin emacs-%1/etc emacs-%1/info emacs-%1/lisp emacs-%1/lock emacs-%1/site-lisp | gzip -9 > %2-fullbin-i386.tar.gz |
|---|
| | 35 | rem Info-ZIP zip seems to be broken on Windows. |
|---|
| | 36 | rem It always writes to zip.zip and treats the zipfile argument as one |
|---|
| | 37 | rem of the files to go in it. |
|---|
| | 38 | rem zip -9 -r %2-bin-i386 emacs-%1/BUGS emacs-%1/README emacs-%1/README.W32 emacs-%1/bin emacs-%1/etc emacs-%1/info emacs-%1/lisp emacs-%1/leim -x emacs.mdp *.pdb *.opt *~ CVS |
|---|
| | 39 | 7z a -tZIP -mx=9 -xr!emacs.mdp -xr!*.pdb -xr!*.opt -xr!*~ -xr!CVS -xr!.arch-inventory %2-bin-i386.zip emacs-%1/BUGS emacs-%1/README emacs-%1/README.W32 emacs-%1/bin emacs-%1/etc emacs-%1/info emacs-%1/lisp emacs-%1/leim |
|---|
| 93 | | :leim |
|---|
| 94 | | |
|---|
| 95 | | echo Create archive with precompiled leim files |
|---|
| 96 | | %TAR% -cvf - emacs-%1/leim/leim-list.el emacs-%1/leim/quail emacs-%1/leim/ja-dic | gzip -9 > %2-leim.tar.gz |
|---|
| 97 | | if not (%4) == () goto end |
|---|
| 98 | | |
|---|
| 99 | | :undumped |
|---|
| 100 | | |
|---|
| 101 | | echo Create archive with extra files needed for redumping emacs |
|---|
| 102 | | copy %3\README-UNDUMP.W32 emacs-%1\README-UNDUMP.W32 |
|---|
| 103 | | copy %3\dump.bat emacs-%1\bin |
|---|
| 104 | | if exist emacs-%1\src\obj-spd\i386\temacs.exe copy emacs-%1\src\obj-spd\i386\temacs.exe emacs-%1\bin |
|---|
| 105 | | if exist emacs-%1\src\oo-spd\i386\temacs.exe copy emacs-%1\src\oo-spd\i386\temacs.exe emacs-%1\bin |
|---|
| 106 | | %TAR% -cvf - emacs-%1/README-UNDUMP.W32 emacs-%1/bin/dump.bat emacs-%1/bin/temacs.exe | gzip -9 > %2-undumped-i386.tar.gz |
|---|
| 107 | | del emacs-%1\bin\temacs.exe |
|---|
| 108 | | del emacs-%1\bin\dump.bat |
|---|
| 109 | | del emacs-%1\README-UNDUMP.W32 |
|---|
| 110 | | if not (%4) == () goto end |
|---|
| 111 | | |
|---|
| 124 | | rem Only do this if explicitly requested |
|---|
| 125 | | :zipfiles |
|---|
| 126 | | |
|---|
| 127 | | echo Create zip files for bin and lisp archives |
|---|
| 128 | | mkdir distrib |
|---|
| 129 | | cd distrib |
|---|
| 130 | | gunzip -c ..\%2-bin-i386.tar.gz | %TAR% xf - |
|---|
| 131 | | rem Need to split emacs.exe into fragments because it is too big now |
|---|
| 132 | | rem to fit on a floppy even by itself. |
|---|
| 133 | | copy %3\stitch.bat %2\bin |
|---|
| 134 | | cd %2\bin |
|---|
| 135 | | split -b 1000000 emacs.exe emacs |
|---|
| 136 | | del emacs.exe |
|---|
| 137 | | cd ..\.. |
|---|
| 138 | | zip -rp9 em%5bin %2 |
|---|
| 139 | | rm -rf %2 |
|---|
| 140 | | zipsplit -n 1400000 -b .. em%5bin.zip |
|---|
| 141 | | del em%5bin.zip |
|---|
| 142 | | gunzip -c ..\%2-lisp.tar.gz | %TAR% xf - |
|---|
| 143 | | zip -rp9 em%5lis %2 |
|---|
| 144 | | rm -rf %2 |
|---|
| 145 | | zipsplit -n 1400000 -b .. em%5lis.zip |
|---|
| 146 | | del em%5lis.zip |
|---|
| 147 | | cd .. |
|---|
| 148 | | |
|---|
| 149 | | goto end |
|---|
| 150 | | |
|---|