]> code.delx.au - gnu-emacs/blobdiff - admin/nt/makedist.bat
Version 3.15
[gnu-emacs] / admin / nt / makedist.bat
index e756d16467e5832329b69af189ecb57fa563a48b..db9d9026aec8838e35e3bb82b5f1367e23ac05c9 100755 (executable)
@@ -1,6 +1,10 @@
 @echo off
 
-set TAR=wtar
+rem Beware broken ports of tar. Recent cygwin versions work well, older
+rem cygwin versions and the current MSys port have problems with DOS
+rem line ends when reading file names from a file. Other ports have their
+rem own problems too.
+set TAR=tar
 
 rem Make a copy of current Emacs source
 if (%3) == () goto usage
@@ -22,13 +26,14 @@ if not (%4) == () goto end
 
 set eld=emacs-%1/lisp
 
-rem Keep this list in sync with the DONTCOMPILE list in lisp/Makefile.in
+rem List of Lisp files that are not compiled and that should be
+rem included in the bin distribution.
 
-set elfiles=%eld%/cus-load.el %eld%/cus-start.el %eld%/emacs-lisp/cl-specs.el %eld%/eshell/esh-maint.el %eld%/eshell/esh-groups.el %eld%/finder-inf.el %eld%/forms-d2.el %eld%/forms-pass.el %eld%/generic-x.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%/loaddefs.el %eld%/loadup.el %eld%/mail/blessmail.el %eld%/patcomp.el %eld%/paths.el %eld%/play/bruce.el %eld%/subdirs.el %eld%/term/internal.el %eld%/term/AT386.el  %eld%/term/apollo.el %eld%/term/bobcat.el %eld%/term/iris-ansi.el %eld%/term/keyswap.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%/term/xterm.el %eld%/version.el
+rem It would be better to generate this list automatically.  It is the
+rem list of all .el files for which there is no corresponding .elc
+rem file, minus ldefs-boot.el.  --lute
 
-rem set term_elfiles=%eld%/term/AT386.el %eld%/term/apollo.el %eld%/term/bg-mouse.el %eld%/term/bobcat.el %eld%/term/internal.el %eld%/term/iris-ansi.el %eld%/term/keyswap.el %eld%/term/linux.el %eld%/term/lk201.el %eld%/term/news.el %eld%/term/pc-win.el %eld%/term/sun-mouse.el %eld%/term/sun.el %eld%/term/sup-mouse.el %eld%/term/tvi970.el %eld%/term/vt100.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/w32-win.el %eld%/term/wyse50.el %eld%/term/x-win.el %eld%/term/xterm.el
-
-rem set elcfiles=%eld%/*.elc %eld%/emacs-lisp/*.elc %eld%/emulation/*.elc %eld%/gnus/*.elc %eld%/international/*.elc %eld%/language/*.elc %eld%/mail/*.elc %eld%/play/*.elc %eld%/progmodes/*.elc %eld%/term/*.elc %eld%/textmodes/*.elc
+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
 
 set fns_el=
 for %%f in (emacs-%1/bin/fns*) do set fns_el=%fns_el% emacs-%1/bin/%%f
@@ -36,21 +41,18 @@ for %%f in (emacs-%1/bin/fns*) do set fns_el=%fns_el% emacs-%1/bin/%%f
 echo Create bin distribution
 copy %3\README.W32 emacs-%1\README.W32
 
-rem %TAR% --exclude temacs.exe --exclude emacs.mdp --exclude *.pdb
-rem --exclude *.opt --exclude *.el --exclude *~ -cvf - emacs-%1/BUGS
-rem emacs-%1/GETTING.GNU.SOFTWARE emacs-%1/README emacs-%1/README.W32
-rem emacs-%1/bin %fns_el% emacs-%1/etc emacs-%1/info emacs-%1/lisp %elfiles%
-rem %term_elfiles% emacs-%1/lock emacs-%1/site-lisp -cvf - | gzip -9 > %2-bin-i386.tar.gz
-
-del #files#
-for %%f in (emacs-%1/BUGS emacs-%1/GETTING.GNU.SOFTWARE emacs-%1/README emacs-%1/README.W32) do echo %%f>>#files#
-for %%f in (emacs-%1/bin/fns*) do echo emacs-%1/bin/%%f>>#files#
-for %%f in (emacs-%1/bin emacs-%1/etc emacs-%1/info emacs-%1/lisp %elfiles%) do echo %%f>>#files#
-for %%f in (%eld%/term/*.el) do echo %eld%/term/%%f>>#files#
-for %%f in (emacs-%1/lock emacs-%1/site-lisp emacs-%1/site-lisp/subdirs.el) do echo %%f>>#files#
-%TAR% --exclude temacs.exe --exclude emacs.mdp --exclude *.pdb --exclude *.opt --exclude *.el --exclude *~ -T #files# -cvf - | gzip -9 > %2-bin-i386.tar.gz
+del #files# #elfiles#
+for %%f in (emacs-%1/BUGS emacs-%1/README emacs-%1/README.W32) do echo %%f>>#files#
+for %%f in (emacs-%1/bin/fns*) do echo emacs-%1/bin/%%f>>#elfiles#
+for %%f in (emacs-%1/bin emacs-%1/etc emacs-%1/info emacs-%1/lisp) do echo %%f>>#files#
+for %%f in (emacs-%1/lock emacs-%1/site-lisp) do echo %%f>>#files#
+for %%f in (%elfiles% emacs-%1/site-lisp/subdirs.el) do echo %%f>>#elfiles#
+
+%TAR% --exclude temacs.exe --exclude emacs.mdp --exclude *.pdb --exclude *.opt --exclude "*.el" --exclude "*~" -T #files# -cvf %2-bin-i386.tar
+%TAR% -T #elfiles# -rvf %2-bin-i386.tar
+gzip -9 %2-bin-i386.tar
 del emacs-%1\README.W32
-del #files#
+rem del #files# #elfiles#
 if not (%4) == () goto end
 
 :fullbin
@@ -58,7 +60,7 @@ if not (%4) == () goto end
 echo Create full bin distribution
 copy %3\README.W32 emacs-%1\README.W32
 
-%TAR% --exclude temacs.exe --exclude emacs.mdp --exclude *.pdb --exclude *.opt --exclude *~ -cvf - emacs-%1/BUGS emacs-%1/GETTING.GNU.SOFTWARE 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
+%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
 del emacs-%1\README.W32
 if not (%4) == () goto end
 
@@ -100,15 +102,22 @@ echo Create zip files for bin and lisp archives
 mkdir distrib
 cd distrib
 gunzip -c ..\%2-bin-i386.tar.gz | %TAR% xf -
-zip -rp9 em%5_bin %2
+rem Need to split emacs.exe into fragments because it is too big now
+rem to fit on a floppy even by itself.
+copy %3\stitch.bat %2\bin
+cd %2\bin
+split -b 1000000 emacs.exe emacs
+del emacs.exe
+cd ..\..
+zip -rp9 em%5bin %2
 rm -rf %2
-zipsplit -n 1400000 -b .. em%5_bin.zip
-del em%5_bin.zip
+zipsplit -n 1400000 -b .. em%5bin.zip
+del em%5bin.zip
 gunzip -c ..\%2-lisp.tar.gz | %TAR% xf -
-zip -rp9 em%5_lis %2
+zip -rp9 em%5lis %2
 rm -rf %2
-zipsplit -n 1400000 -b .. em%5_lis.zip
-del em%5_lis.zip
+zipsplit -n 1400000 -b .. em%5lis.zip
+del em%5lis.zip
 cd ..
 
 goto end
@@ -120,3 +129,7 @@ echo   (e.g., %0 19.34 emacs-19.34.5 d:\andrewi\distfiles)
 echo Or: %0 emacs-version dist-basename distfiles "zipfiles" short-version
 echo   (e.g., %0 20.6 emacs-20.6 d:\andrewi\distfiles zipfiles 206)
 :end
+
+goto skipArchTag
+   arch-tag: 6e2ddd92-c1c9-4992-b6b5-207aaab72f68
+:skipArchTag