diff options
| author | Richard M. Stallman | 1994-01-07 13:34:12 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1994-01-07 13:34:12 +0000 |
| commit | 3382cd59427d1d87d2d2500fd94462d102eab750 (patch) | |
| tree | 044d36f55f6f09caa2f44333a1115ea27994e6f0 | |
| parent | c4a7b2a414784651b1224ef669a16fabc119e0cd (diff) | |
| download | emacs-3382cd59427d1d87d2d2500fd94462d102eab750.tar.gz emacs-3382cd59427d1d87d2d2500fd94462d102eab750.zip | |
Initial revision
| -rw-r--r-- | config.bat | 101 |
1 files changed, 101 insertions, 0 deletions
diff --git a/config.bat b/config.bat new file mode 100644 index 00000000000..4f8767975b2 --- /dev/null +++ b/config.bat | |||
| @@ -0,0 +1,101 @@ | |||
| 1 | @echo off | ||
| 2 | rem ---------------------------------------------------------------------- | ||
| 3 | rem Configuration script for MSDOS | ||
| 4 | rem This file is part of GNU Emacs. | ||
| 5 | |||
| 6 | rem GNU Emacs is free software; you can redistribute it and/or modify | ||
| 7 | rem it under the terms of the GNU General Public License as published by | ||
| 8 | rem the Free Software Foundation; either version 2, or (at your option) | ||
| 9 | rem any later version. | ||
| 10 | |||
| 11 | rem GNU Emacs is distributed in the hope that it will be useful, | ||
| 12 | rem but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 13 | rem MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 14 | rem GNU General Public License for more details. | ||
| 15 | |||
| 16 | rem You should have received a copy of the GNU General Public License | ||
| 17 | rem along with GNU Emacs; see the file COPYING. If not, write to | ||
| 18 | rem the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. | ||
| 19 | rem ---------------------------------------------------------------------- | ||
| 20 | rem YOU'LL NEED THE FOLLOWING UTILITIES TO MAKE EMACS: | ||
| 21 | rem | ||
| 22 | rem + djgpp. | ||
| 23 | rem + make utility that allows breaking of 128 chars limit of commands. | ||
| 24 | rem ndmake (as of version 4.5) won't work due to a line length limit. | ||
| 25 | rem + rm, mv, chmod (From GNU file utilities). | ||
| 26 | rem + sed. | ||
| 27 | rem + patch (Larry Wall's for instance. I think it's supplied with djgpp). | ||
| 28 | rem ---------------------------------------------------------------------- | ||
| 29 | if not "%2" == "" goto usage | ||
| 30 | if "%1" == "msdos" goto msdos | ||
| 31 | :usage | ||
| 32 | echo Usage: config msdos | ||
| 33 | echo [Read the script before you run it; also check that you have all the | ||
| 34 | echo necessary utilities.] | ||
| 35 | goto end | ||
| 36 | rem ---------------------------------------------------------------------- | ||
| 37 | :msdos | ||
| 38 | rem Change to the Emacs root | ||
| 39 | cd c:\emacs | ||
| 40 | rem ---------------------------------------------------------------------- | ||
| 41 | Echo Configuring the source directory... | ||
| 42 | cd src | ||
| 43 | set PATHSH=paths-h.in | ||
| 44 | if exist %PATHSH% goto src1 | ||
| 45 | set PATHSH=paths.h-in | ||
| 46 | if exist %PATHSH% goto src1 | ||
| 47 | echo config: *** The file originally called "src/paths.h.in" cannot be found. | ||
| 48 | cd .. | ||
| 49 | goto end | ||
| 50 | :src1 | ||
| 51 | set CONFIGH=config-h.in | ||
| 52 | if exist %CONFIGH% goto src2 | ||
| 53 | set CONFIGH=config.h-in | ||
| 54 | if exist %CONFIGH% goto src2 | ||
| 55 | echo config: *** The file originally called "src/config.h.in" cannot be found. | ||
| 56 | cd .. | ||
| 57 | goto end | ||
| 58 | :src2 | ||
| 59 | set MAKEFILEIN=makefile.in-in | ||
| 60 | if exist %MAKEFILEIN% goto src3 | ||
| 61 | set MAKEFILEIN=makefile-in.in | ||
| 62 | if exist %MAKEFILEIN% goto src3 | ||
| 63 | echo makefile: *** The file originally called "src/makefile.in.in" cannot be found. | ||
| 64 | cd .. | ||
| 65 | goto end | ||
| 66 | :src3 | ||
| 67 | |||
| 68 | rem Create "paths.h" | ||
| 69 | rm -f paths.h | ||
| 70 | sed -e "s!/lib/emacs!!" -e "s!/usr/local!c:/emacs!" -e "s!/data!/etc!" <%PATHSH% >paths.h | ||
| 71 | |||
| 72 | rem Create "config.h" | ||
| 73 | rm -f config.h | ||
| 74 | sed -f ../msdos/sed2.inp <%CONFIGH% >config.h | ||
| 75 | |||
| 76 | rem On my system dir.h gets in the way. It's a VMS file so who cares. | ||
| 77 | if exist dir.h ren dir.h vmsdir.h | ||
| 78 | |||
| 79 | rem Create "makefile" from "makefile.in.in" using a context patch. | ||
| 80 | rm -f makefile | ||
| 81 | cp %MAKEFILEIN% makefile | ||
| 82 | patch -p1 -B ! -r patch.rjt makefile ../msdos/patch1 | ||
| 83 | echo All hunks above should have passed! If they didn't, you'll have to | ||
| 84 | echo update manually. That should be easy though. | ||
| 85 | mv makefile junk.c | ||
| 86 | gcc -E junk.c | sed -f ../msdos/sed1.inp >makefile | ||
| 87 | del !makefile | ||
| 88 | del junk.c | ||
| 89 | cd .. | ||
| 90 | rem ---------------------------------------------------------------------- | ||
| 91 | Echo Configuring the library source directory... | ||
| 92 | cd lib-src | ||
| 93 | rem Create "makefile" from "makefile.in". | ||
| 94 | copy makefile makefile.bak >nul | ||
| 95 | sed -f ../msdos/sed3.inp <makefile.in >makefile | ||
| 96 | cd .. | ||
| 97 | rem ---------------------------------------------------------------------- | ||
| 98 | Echo Configuring the main directory... | ||
| 99 | copy msdos\mainmake makefile >nul | ||
| 100 | rem ---------------------------------------------------------------------- | ||
| 101 | :end | ||