(vmotion): Use minibuf_prompt_width despite window-start.
[emacs.git] / config.bat
blob45aa38199f0f14c82f833e2d72a31d100fd0e00d
1 @echo off\r
2 rem   ----------------------------------------------------------------------\r
3 rem   Configuration script for MSDOS\r
4 rem   This file is part of GNU Emacs.\r
5 \r
6 rem   GNU Emacs is free software; you can redistribute it and/or modify\r
7 rem   it under the terms of the GNU General Public License as published by\r
8 rem   the Free Software Foundation; either version 2, or (at your option)\r
9 rem   any later version.\r
11 rem   GNU Emacs is distributed in the hope that it will be useful,\r
12 rem   but WITHOUT ANY WARRANTY; without even the implied warranty of\r
13 rem   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\r
14 rem   GNU General Public License for more details.\r
16 rem   You should have received a copy of the GNU General Public License\r
17 rem   along with GNU Emacs; see the file COPYING.  If not, write to\r
18 rem   the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.\r
19 rem   ----------------------------------------------------------------------\r
20 rem   YOU'LL NEED THE FOLLOWING UTILITIES TO MAKE EMACS:\r
21 rem\r
22 rem   + djgpp version 1,11\r
23 rem   + make utility that allows breaking of 128 chars limit of commands.\r
24 rem     ndmake (as of version 4.5) won't work due to a line length limit.\r
25 rem   + rm, mv, chmod (From GNU file utilities).\r
26 rem   + sed.\r
27 rem   ----------------------------------------------------------------------\r
28 if not "%2" == "" goto usage\r
29 if "%1" == "msdos" goto msdos\r
30 :usage\r
31 echo Usage: config msdos\r
32 echo [Read the script before you run it; also check that you have all the\r
33 echo necessary utilities.]\r
34 goto end\r
35 rem   ----------------------------------------------------------------------\r
36 :msdos\r
37 rem   Change to the Emacs root\r
38 cd c:\emacs\r
39 rem   ----------------------------------------------------------------------\r
40 Echo Configuring the source directory...\r
41 cd src\r
42 set PATHSH=paths-h.in\r
43 if exist %PATHSH% goto src1\r
44 set PATHSH=paths.h-in\r
45 if exist %PATHSH% goto src1\r
46 echo config: *** The file originally called "src/paths.h.in" cannot be found.\r
47 cd ..\r
48 goto end\r
49 :src1\r
50 set CONFIGH=config-h.in\r
51 if exist %CONFIGH% goto src2\r
52 set CONFIGH=config.h-in\r
53 if exist %CONFIGH% goto src2\r
54 echo config: *** The file originally called "src/config.h.in" cannot be found.\r
55 cd ..\r
56 goto end\r
57 :src2\r
58 set MAKEFILEIN=makefile.in-in\r
59 if exist %MAKEFILEIN% goto src3\r
60 set MAKEFILEIN=makefile-in.in\r
61 if exist %MAKEFILEIN% goto src3\r
62 echo makefile: *** The file originally called "src/makefile.in.in" cannot be found.\r
63 cd ..\r
64 goto end\r
65 :src3\r
67 rem   Create "paths.h"\r
68 rm -f paths.h\r
69 sed -e "s!/lib/emacs!!" -e "s!/usr/local!c:/emacs!" -e "s!/data!/etc!" <%PATHSH% >paths.h\r
71 rem   Create "config.h"\r
72 rm -f config.h\r
73 sed -f ../msdos/sed2.inp <%CONFIGH% >config.h\r
75 rem   On my system dir.h gets in the way.  It's a VMS file so who cares.\r
76 if exist dir.h ren dir.h vmsdir.h\r
78 rem   Create "makefile" from "makefile.in.in" using a context patch.\r
79 rm -f makefile junk.c\r
80 cp %MAKEFILEIN% junk.c\r
81 gcc -E junk.c | sed -f ../msdos/sed1.inp >makefile\r
82 rm -f junk.c\r
83 cd ..\r
84 rem   ----------------------------------------------------------------------\r
85 Echo Configuring the library source directory...\r
86 cd lib-src\r
87 rem   Create "makefile" from "makefile.in".\r
88 copy makefile makefile.bak >nul\r
89 sed -f ../msdos/sed3.inp <makefile.in >makefile\r
90 cd ..\r
91 rem   ----------------------------------------------------------------------\r
92 Echo Configuring the main directory...\r
93 copy msdos\mainmake makefile >nul\r
94 rem   ----------------------------------------------------------------------\r
95 :end\r