(Message Headers): Extend
[gnus] / make.bat
1 @echo off\r
2 \r
3 rem Written by Frank Schmitt <ich@frank-schmitt.net>\r
4 rem based on the work by David Charlap (shamino@writeme.com)\r
5 rem .\r
6 rem Clear PWD so emacs doesn't get confused\r
7 set GNUS_PWD_SAVE=%PWD%\r
8 set PWD=\r
9 set ERROR=:\r
10 \r
11 if "%1" == "" goto usage\r
12 \r
13 rem Emacs 20.7 no longer includes emacs.bat. Use emacs.exe if the batch file is\r
14 rem not present -- this also fixes the problem about too many parameters on Win9x.\r
15 if exist %1\emacs.bat goto ebat\r
16 if exist %1\emacs.exe goto eexe\r
17 if exist %1\xemacs.exe goto xemacs\r
18 goto noemacs\r
19 \r
20 :ebat\r
21 set EMACS=emacs.bat\r
22 echo.\r
23 echo ***************************************************************************\r
24 echo * Using emacs.bat (If you've got en Emacs >= 20.3 please remove Emacs.bat,\r
25 echo * it isn't needed anymore.\r
26 echo ***************************************************************************\r
27 echo.\r
28 goto emacs\r
29 \r
30 :eexe\r
31 set EMACS=emacs.exe\r
32 echo.\r
33 echo ***************************************************************************\r
34 echo * Using emacs.exe\r
35 echo ***************************************************************************\r
36 echo.\r
37 goto emacs\r
38 \r
39 :emacs\r
40 if not "%2" == "/copy" goto emacsnocopy\r
41 if not exist %1\..\site-lisp mkdir %1\..\site-lisp\r
42 if not exist %1\..\site-lisp\gnus mkdir %1\..\site-lisp\gnus\r
43 if not exist %1\..\site-lisp\subdirs.el set subdirwarning=yes\r
44 :emacsnocopy\r
45 set EMACS_ARGS=-batch -q -no-site-file\r
46 set GNUS_INFO_DIR=%1\..\info\r
47 set GNUS_LISP_DIR=%1\..\site-lisp\gnus\lisp\r
48 set GNUS_ETC_DIR=%1\..\site-lisp\gnus\etc\r
49 goto lisp\r
50 \r
51 :xemacs\r
52 set EMACS=xemacs.exe\r
53 if not "%2" == "/copy" goto xemacsnocopy\r
54 if not exist %1\..\..\site-packages\ mkdir %1\..\..\site-packages\\r
55 if not exist %1\..\..\site-packages\info mkdir %1\..\..\site-packages\info\r
56 if not exist %1\..\..\site-packages\lisp mkdir %1\..\..\site-packages\lisp\r
57 if not exist %1\..\..\site-packages\etc mkdir %1\..\..\site-packages\etc\r
58 :xemacsnocopy\r
59 set EMACS_ARGS=-batch -no-autoloads\r
60 set GNUS_INFO_DIR=%1\..\..\site-packages\info\r
61 set GNUS_LISP_DIR=%1\..\..\site-packages\lisp\gnus\r
62 set GNUS_ETC_DIR=%1\..\..\site-packages\etc\r
63 echo.\r
64 echo ***************************************************************************\r
65 echo * Using xemacs.exe\r
66 echo ***************************************************************************\r
67 echo.\r
68 goto lisp\r
69 \r
70 :lisp\r
71 set EMACSBATCH=call %1\%EMACS% %EMACS_ARGS%\r
72 cd lisp\r
73 if exist gnus-load.el del gnus-load.el\r
74 echo.\r
75 echo Stand by while generating autoloads.\r
76 echo.\r
77 %EMACSBATCH% -l ./dgnushack.el -f dgnushack-make-cus-load .\r
78 if ErrorLevel 1 set ERROR=make-cus-load\r
79 %EMACSBATCH% -l ./dgnushack.el -f dgnushack-make-auto-load .\r
80 if ErrorLevel 1 set ERROR=%ERROR%,make-auto-load\r
81 %EMACSBATCH% -l ./dgnushack.el -f dgnushack-make-load\r
82 if ErrorLevel 1 set ERROR=%ERROR%,make-load\r
83 echo.\r
84 echo Stand by while compiling lisp files.\r
85 echo.\r
86 %EMACSBATCH% -l ./dgnushack.el -f dgnushack-compile\r
87 if ErrorLevel 1 set ERROR=%ERROR%,compile\r
88 \r
89 if not "%2" == "/copy" goto infotest\r
90 echo.\r
91 echo Stand by while copying lisp files.\r
92 echo.\r
93 if not exist %GNUS_LISP_DIR% mkdir %GNUS_LISP_DIR%\r
94 xcopy /R /Q /Y *.el* %GNUS_LISP_DIR%\r
95 if ErrorLevel 1 set ERROR=%ERROR%,copy-lisp\r
96 goto infotest\r
97 \r
98 :infotest\r
99 cd ..\texi\r
100 if exist sieve del sieve\r
101 makeinfo sieve.texi\r
102 if exist sieve goto minfo\r
103 REM It seems that makeinfo isn't available\r
104 set EMACSINFO=%EMACSBATCH% -l infohack.el -f batch-makeinfo\r
105 echo.\r
106 echo ***************************************************************************\r
107 echo * Using infohack.el, if you've got makeinfo.exe put it in PATH.\r
108 echo ***************************************************************************\r
109 echo.\r
110 goto info\r
111 \r
112 :minfo\r
113 set EMACSINFO=makeinfo\r
114 echo.\r
115 echo ***************************************************************************\r
116 echo * Using makeinfo\r
117 echo ***************************************************************************\r
118 echo.\r
119 goto info\r
120 \r
121 :info\r
122 echo.\r
123 echo Stand by whi