]> git.saurik.com Git - bison.git/blame - djgpp/config.bat
* src/location.h (boundary): Note that a line or column equal
[bison.git] / djgpp / config.bat
CommitLineData
3768a1ae 1@echo off\r
90ddbd5e
JMG
2Rem WARNING WARNING WARNING: This file needs to have DOS CRLF end-of-line\r
3Rem format, or else stock DOS/Windows shells will refuse to run it.\r
4\r
3768a1ae
JMG
5echo Configuring GNU Bison for DJGPP v2.x...\r
6\r
7Rem The SmallEnv tests protect against fixed and too small size\r
8Rem of the environment in stock DOS shell.\r
9\r
10Rem Find out if NLS is wanted or not,\r
11Rem if dependency-tracking is wanted or not,\r
12Rem if caching is wanted or not\r
13Rem and where the sources are.\r
14Rem We always default to NLS support,\r
15Rem no dependency tracking\r
16Rem and to in place configuration.\r
17set ARGS=\r
18set NLS=enabled\r
19if not "%NLS%" == "enabled" goto SmallEnv\r
20set CACHING=enabled\r
21if not "%CACHING%" == "enabled" goto SmallEnv\r
22set DEPENDENCY_TRACKING=disabled\r
23if not "%DEPENDENCY_TRACKING%" == "disabled" goto SmallEnv\r
24set LIBICONV_PREFIX=disabled\r
25if not "%LIBICONV_PREFIX%" == "disabled" goto SmallEnv\r
26set LIBINTL_PREFIX=disabled\r
27if not "%LIBINTL_PREFIX%" == "disabled" goto SmallEnv\r
28set HTML=enabled\r
29if not "%HTML%" == "enabled" goto SmallEnv\r
30set XSRC=.\r
31if not "%XSRC%" == "." goto SmallEnv\r
32\r
33Rem Loop over all arguments.\r
34Rem Special arguments are: NLS, XSRC, CACHE, STATIC_LIBS, LIBICONV_PREFIX, LIBINTL_PREFIX and DEPS.\r
35Rem All other arguments are stored into ARGS.\r
36:ArgLoop\r
37if "%1" == "nls" goto NextArgument\r
38if "%1" == "NLS" goto NextArgument\r
39if "%1" == "no-nls" goto NoNLS\r
40if "%1" == "no-NLS" goto NoNLS\r
41if "%1" == "NO-NLS" goto NoNLS\r
42goto CachingOption\r
43:NoNLS\r
44if "%1" == "no-nls" set NLS=disabled\r
45if "%1" == "no-NLS" set NLS=disabled\r
46if "%1" == "NO-NLS" set NLS=disabled\r
47if not "%NLS%" == "disabled" goto SmallEnv\r
48goto NextArgument\r
49:CachingOption\r
50if "%1" == "cache" goto NextArgument\r
51if "%1" == "CACHE" goto NextArgument\r
52if "%1" == "no-cache" goto NoCaching\r
53if "%1" == "no-CACHE" goto NoCaching\r
54if "%1" == "NO-CACHE" goto NoCaching\r
55goto DependencyOption\r
56:NoCaching\r
57if "%1" == "no-cache" set CACHING=disabled\r
58if "%1" == "no-CACHE" set CACHING=disabled\r
59if "%1" == "NO-CACHE" set CACHING=disabled\r
60if not "%CACHING%" == "disabled" goto SmallEnv\r
61goto NextArgument\r
62:DependencyOption\r
63if "%1" == "no-dep" goto NextArgument\r
64if "%1" == "no-DEP" goto NextArgument\r
65if "%1" == "NO-DEP" goto NextArgument\r
66if "%1" == "dep" goto DependecyTraking\r
67if "%1" == "DEP" goto DependecyTraking\r
68goto LibiconvPrefixOption\r
69:DependecyTraking\r
70if "%1" == "dep" set DEPENDENCY_TRACKING=enabled\r
71if "%1" == "DEP" set DEPENDENCY_TRACKING=enabled\r
72if not "%DEPENDENCY_TRACKING%" == "enabled" goto SmallEnv\r
73goto NextArgument\r
74:LibiconvPrefixOption\r
75if "%1" == "no-libiconvprefix" goto NextArgument\r
76if "%1" == "no-LIBICONVPREFIX" goto NextArgument\r
77if "%1" == "NO-LIBICONVPREFIX" goto NextArgument\r
78if "%1" == "libiconvprefix" goto WithLibiconvPrefix\r
79if "%1" == "LIBICONVPREFIX" goto WithLibiconvPrefix\r
80goto LibintlPrefixOption\r
81:WithLibiconvPrefix\r
82if "%1" == "libiconvprefix" set LIBICONV_PREFIX=enabled\r
83if "%1" == "LIBICONVPREFIX" set LIBICONV_PREFIX=enabled\r
84if not "%LIBICONV_PREFIX%" == "enabled" goto SmallEnv\r
85goto NextArgument\r
86:LibintlPrefixOption\r
87if "%1" == "no-libiconvprefix" goto NextArgument\r
88if "%1" == "no-LIBICONVPREFIX" goto NextArgument\r
89if "%1" == "NO-LIBICONVPREFIX" goto NextArgument\r
90if "%1" == "libintlprefix" goto _WithLibintlPrefix\r
91if "%1" == "LIBINTLPREFIX" goto _WithLibintlPrefix\r
92goto HTMLOption\r
93:_WithLibintlPrefix\r
94if "%1" == "libintlprefix" set LIBINTL_PREFIX=enabled\r
95if "%1" == "LIBINTLPREFIX" set LIBINTL_PREFIX=enabled\r
96if not "%LIBINTL_PREFIX%" == "enabled" goto SmallEnv\r
97:HTMLOption\r
98if "%1" == "withhtml" goto NextArgument\r
99if "%1" == "withHTML" goto NextArgument\r
100if "%1" == "WITHHTML" goto NextArgument\r
101if "%1" == "withouthtml" goto _WithoutHTML\r
102if "%1" == "withoutHTML" goto _WithoutHTML\r
103if "%1" == "WITHOUTHTML" goto _WithoutHTML\r
104goto SrcDirOption\r
105:_WithoutHTML\r
106if "%1" == "withouthtml" set HTML=disabled\r
107if "%1" == "withoutHTML" set HTML=disabled\r
108if "%1" == "WITHOUTHTML" set HTML=disabled\r
109if not "%HTML%" == "disabled" goto SmallEnv\r
110goto NextArgument\r
111:SrcDirOption\r
112echo %1 | grep -q "/"\r
113if errorlevel 1 goto CollectArgument\r
114set XSRC=%1\r
115if not "%XSRC%" == "%1" goto SmallEnv\r
116goto NextArgument\r
117:CollectArgument\r
118set _ARGS=%ARGS% %1\r
119if not "%_ARGS%" == "%ARGS% %1" if not "%_ARGS%" == "%ARGS%%1" goto SmallEnv\r
120echo %_ARGS% | grep -q "[^ ]"\r
121if not errorlevel 0 set ARGS=%_ARGS%\r
122set _ARGS=\r
123:NextArgument\r
124shift\r
125if not "%1" == "" goto ArgLoop\r
126\r
127Rem Create an arguments file for the configure script.\r
128echo --srcdir=%XSRC% > arguments\r
129if "%CACHING%" == "enabled" echo --cache-file=%XSRC%/djgpp/config.cache >> arguments\r
130if "%DEPENDENCY_TRACKING%" == "enabled" echo --enable-dependency-tracking >> arguments\r
131if "%DEPENDENCY_TRACKING%" == "disabled" echo --disable-dependency-tracking >> arguments\r
132if "%LIBICONV_PREFIX%" == "enabled" echo --with-libiconv-prefix >> arguments\r
133if "%LIBICONV_PREFIX%" == "disabled" echo --without-libiconv-prefix >> arguments\r
134if "%LIBINTL_PREFIX%" == "enabled" echo --with-libintl-prefix >> arguments\r
135if "%LIBINTL_PREFIX%" == "disabled" echo --without-libintl-prefix >> arguments\r
136if "%HTML%" == "enabled" echo --enable-html >> arguments\r
137if "%HTML%" == "disabled" echo --disable-html >> arguments\r
138if not "%ARGS%" == "" echo %ARGS% >> arguments\r
139set ARGS=\r
140set CACHING=\r
141set DEPENDENCY_TRACKING=\r
142\r
143if "%XSRC%" == "." goto InPlace\r
144\r
145:NotInPlace\r
146redir -e /dev/null update %XSRC%/configure.orig ./configure\r
147test -f ./configure\r
148if errorlevel 1 update %XSRC%/configure ./configure\r
149\r
150:InPlace\r
151Rem Update configuration files\r
152echo Updating configuration scripts...\r
153test -f ./configure.orig\r
154if errorlevel 1 update configure configure.orig\r
155sed -f %XSRC%/djgpp/config.sed configure.orig > configure\r
156if errorlevel 1 goto SedError\r
157\r
158Rem Make sure they have a config.site file\r
159set CONFIG_SITE=%XSRC%/djgpp/config.site\r
160if not "%CONFIG_SITE%" == "%XSRC%/djgpp/config.site" goto SmallEnv\r
161\r
162Rem Make sure crucial file names are not munged by unpacking\r
163test -f %XSRC%/po/Makefile.in.in\r
164if not errorlevel 1 mv -f %XSRC%/po/Makefile.in.in %XSRC%/po/Makefile.in-in\r
165test -f %XSRC%/po/Makefile.in-in\r
166if errorlevel 1 mv -f %XSRC%/po/Makefile.in %XSRC%/po/Makefile.in-in\r
167test -f %XSRC%/runtime-po/Makefile.in.in\r
168if not errorlevel 1 mv -f %XSRC%/runtime-po/Makefile.in.in %XSRC%/runtime-po/Makefile.in-in\r
169test -f %XSRC%/runtime-po/Makefile.in-in\r
170if errorlevel 1 mv -f %XSRC%/runtime-po/Makefile.in %XSRC%/runtime-po/Makefile.in-in\r
171test -f %XSRC%/data/c++.m4\r
172if not errorlevel 1 mv -f %XSRC%/data/c++.m4 %XSRC%/data/cxx.m4\r
173test -f %XSRC%/data/cxx.m4\r
174if errorlevel 1 mv -f %XSRC%/data/cpp.m4 %XSRC%/data/cxx.m4\r
90ddbd5e
JMG
175:scan_gram_c_Test\r
176test -f %XSRC%/src/c-scan-gram.c\r
177if not errorlevel 1 goto scan_skel_c_Test\r
178test -f %XSRC%/src/scan-gram-c.c\r
179if not errorlevel 1 mv -f %XSRC%/src/scan-gram-c.c %XSRC%/src/c-scan-gram.c\r
180:scan_skel_c_Test\r
181test -f %XSRC%/src/c-scan-skel.c\r
182if not errorlevel 1 goto FixFiles\r
183test -f %XSRC%/src/scan-skel-c.c\r
184if not errorlevel 1 mv -f %XSRC%/src/scan-skel-c.c %XSRC%/src/c-scan-skel.c\r
3768a1ae 185\r
90ddbd5e 186:FixFiles\r
c59929c3 187Rem Fix data/lalr1.cc and data/location.cc to reflect the renaming of c++.m4\r
3768a1ae
JMG
188sed "s/c++\.m4/cxx.m4/" %XSRC%/data/lalr1.cc > lalr1.cc\r
189if errorlevel 1 goto lalr1_ccFileError\r
190mv ./lalr1.cc %XSRC%/data/lalr1.cc\r
c59929c3
JMG
191sed "s/c++\.m4/cxx.m4/" %XSRC%/data/location.cc > location.cc\r
192if errorlevel 1 goto location.ccFileError\r
193mv ./location.cc %XSRC%/data/location.cc\r
3768a1ae
JMG
194\r
195Rem Define DJGPP specific defs in config.hin\r
196echo Editing config.hin...\r
197test -f %XSRC%/config_h.orig\r
198if errorlevel 1 update %XSRC%/config.hin %XSRC%/config_h.orig\r
199sed -f %XSRC%/djgpp/config_h.sed %XSRC%/config_h.orig > config.hin\r
200if errorlevel 1 goto SedError2\r
201mv -f config.hin %XSRC%/config.hin\r
202\r
203\r
204Rem Fixing ilicit testsuite file name.\r
205test -f %XSRC%/tests/c++.at\r
206if not errorlevel 1 mv -f %XSRC%/tests/c++.at %XSRC%/tests/cxx.at\r
207\r
208Rem Fixing ilicit calc++ file names in the calc++ directory.\r
209test -d %XSRC%/examples/calc++\r
210if not errorlevel 1 mv -f %XSRC%/examples/calc++ %XSRC%/examples/calcxx\r
211test -d %XSRC%/examples/calcxx\r
212if errorlevel 1 mv -f %XSRC%/examples/calcpp %XSRC%/examples/calcxx\r
213test -f %XSRC%/examples/calcxx/calc++-scanner.cc\r
214if not errorlevel 1 mv -f %XSRC%/examples/calcxx/calc++-scanner.cc %XSRC%/examples/calcxx/calcxx-scanner.cc\r
215test -f %XSRC%/examples/calcxx/calcxx-scanner.cc\r
216if errorlevel 1 mv -f %XSRC%/examples/calcxx/calcpp-scanner.cc %XSRC%/examples/calcxx/calcxx-scanner.cc\r
217test -f %XSRC%/examples/calcxx/calc++-scanner.ll\r
218if not errorlevel 1 mv -f %XSRC%/examples/calcxx/calc++-scanner.ll %XSRC%/examples/calcxx/calcxx-scanner.ll\r
219test -f %XSRC%/examples/calcxx/calcxx-scanner.ll\r
220if errorlevel 1 mv -f %XSRC%/examples/calcxx/calcpp-scanner.ll %XSRC%/examples/calcxx/calcxx-scanner.ll\r
221test -f %XSRC%/examples/calcxx/calc++-driver.cc\r
222if not errorlevel 1 mv -f %XSRC%/examples/calcxx/calc++-driver.cc %XSRC%/examples/calcxx/calcxx-driver.cc\r
223test -f %XSRC%/examples/calcxx/calcxx-driver.cc\r
224if errorlevel 1 mv -f %XSRC%/examples/calcxx/calcpp-driver.cc %XSRC%/examples/calcxx/calcxx-driver.cc\r
225test -f %XSRC%/examples/calcxx/calc++-driver.hh\r
226if not errorlevel 1 mv -f %XSRC%/examples/calcxx/calc++-driver.hh %XSRC%/examples/calcxx/calcxx-driver.hh\r
227test -f %XSRC%/examples/calcxx/calcxx-driver.hh\r
228if errorlevel 1 mv -f %XSRC%/examples/calcxx/calcpp-driver.hh %XSRC%/examples/calcxx/calcxx-driver.hh\r
229test -f %XSRC%/examples/calcxx/calc++-parser.cc\r
230if not errorlevel 1 mv -f %XSRC%/examples/calcxx/calc++-parser.cc %XSRC%/examples/calcxx/calcxx-parser.cc\r
231test -f %XSRC%/examples/calcxx/calcxx-parser.cc\r
232if errorlevel 1 mv -f %XSRC%/examples/calcxx/calcpp-parser.cc %XSRC%/examples/calcxx/calcxx-parser.cc\r
233test -f %XSRC%/examples/calcxx/calc++-parser.hh\r
234if not errorlevel 1 mv -f %XSRC%/examples/calcxx/calc++-parser.hh %XSRC%/examples/calcxx/calcxx-parser.hh\r
235test -f %XSRC%/examples/calcxx/calcxx-parser.hh\r
236if errorlevel 1 mv -f %XSRC%/examples/calcxx/calcpp-parser.hh %XSRC%/examples/calcxx/calcxx-parser.hh\r
237test -f %XSRC%/examples/calcxx/calc++-parser.stamp\r
238if not errorlevel 1 mv -f %XSRC%/examples/calcxx/calc++-parser.stamp %XSRC%/examples/calcxx/calcxx-parser.stamp\r
239test -f %XSRC%/examples/calcxx/calcxx-parser.stamp\r
240if errorlevel 1 mv -f %XSRC%/examples/calcxx/calcpp-parser.stamp %XSRC%/examples/calcxx/calcxx-parser.stamp\r
241test -f %XSRC%/examples/calcxx/calc++-parser.yy\r
242if not errorlevel 1 mv -f %XSRC%/examples/calcxx/calc++-parser.yy %XSRC%/examples/calcxx/calcxx-parser.yy\r
243test -f %XSRC%/examples/calcxx/calcxx-parser.yy\r
244if errorlevel 1 mv -f %XSRC%/examples/calcxx/calcpp-parser.yy %XSRC%/examples/calcxx/calcxx-parser.yy\r
245test -f %XSRC%/examples/calcxx/calc++.cc\r
246if not errorlevel 1 mv -f %XSRC%/examples/calcxx/calc++.cc %XSRC%/examples/calcxx/calcxx.cc\r
247test -f %XSRC%/examples/calcxx/calcxx.cc\r
248if errorlevel 1 mv -f %XSRC%/examples/calcxx/calcpp.cc %XSRC%/examples/calcxx/calcxx.cc\r
249\r
250Rem Fixing #include lines in calcxx files.\r
251sed "/#[ ]*include/s/++/xx/" %XSRC%/examples/calcxx/calcxx.cc > calcxx.cc\r
252if errorlevel 1 goto calcxxFileError\r
253mv ./calcxx.cc %XSRC%/examples/calcxx/calcxx.cc\r
254sed "/#[ ]*include/s/++/xx/" %XSRC%/examples/calcxx/calcxx-driver.cc > calcxx-driver.cc\r
255if errorlevel 1 goto calcxxFileError\r
256mv ./calcxx-driver.cc %XSRC%/examples/calcxx/calcxx-driver.cc\r
257sed "/#[ ]*include/s/++/xx/" %XSRC%/examples/calcxx/calcxx-driver.hh > calcxx-driver.hh\r
258if errorlevel 1 goto calcxxFileError\r
259mv ./calcxx-driver.hh %XSRC%/examples/calcxx/calcxx-driver.hh\r
260sed "/#[ ]*include/s/++/xx/" %XSRC%/examples/calcxx/calcxx-parser.cc > calcxx-parser.cc\r
261if errorlevel 1 goto calcxxFileError\r
262mv ./calcxx-parser.cc %XSRC%/examples/calcxx/calcxx-parser.cc\r
263sed "/#[ ]*include/s/++/xx/" %XSRC%/examples/calcxx/calcxx-parser.hh > calcxx-parser.hh\r
264if errorlevel 1 goto calcxxFileError\r
265mv ./calcxx-parser.hh %XSRC%/examples/calcxx/calcxx-parser.hh\r
266:sed "/#[ ]*include/s/++/xx/" %XSRC%/examples/calcxx/calcxx-parser.yy > calcxx-parser.yy\r
267:if errorlevel 1 goto calcxxFileError\r
268:mv ./calcxx-parser.yy %XSRC%/examples/calcxx/calcxx-parser.yy\r
269sed "/#[ ]*include/s/++/xx/" %XSRC%/examples/calcxx/calcxx-scanner.cc > calcxx-scanner.cc\r
270if errorlevel 1 goto calcxxFileError\r
271mv ./calcxx-scanner.cc %XSRC%/examples/calcxx/calcxx-scanner.cc\r
272:sed "/#[ ]*include/s/++/xx/" %XSRC%/examples/calcxx/calcxx-scanner.ll > calcxx-scanner.ll\r
273:if errorlevel 1 goto calcxxFileError\r
274:mv ./calcxx-scanner.ll %XSRC%/examples/calcxx/calcxx-scanner.ll\r
275sed "s/calc++/calcxx/" %XSRC%/examples/calcxx/test > test\r
276if errorlevel 1 goto calcxxFileError\r
277mv ./test %XSRC%/examples/calcxx/test\r
278\r
279\r
280Rem Fixing the scanner files to make file names 8.3 valid.\r
281Rem Use only if you want to change the scan-gram.l and scan-skel.l files.\r
282: sed "/outfile=/s/\.yy/yy/" %XSRC%/src/scan-gram.l > scan-gram.l\r
283: if errorlevel 1 goto ScannerFileError\r
284: mv ./scan-gram.l %XSRC%/src/scan-gram.l\r
285: sed "/outfile=/s/\.yy/yy/" %XSRC%/src/scan-skel.l > scan-skel.l\r
286: if errorlevel 1 goto ScannerFileError\r
287: mv ./scan-skel.l %XSRC%/src/scan-skel.l\r
288\r
289\r
290Rem This is required because DOS/Windows are case-insensitive\r
291Rem to file names, and "make install" will do nothing if Make\r
292Rem finds a file called `install'.\r
293if exist INSTALL ren INSTALL INSTALL.txt\r
294\r
295Rem Set SHELL to a sane default or some configure tests stop working\r
296Rem if the package is configured across partitions.\r
297if not "%SHELL%" == "" goto HomeName\r
298set SHELL=/bin/sh\r
299if not "%SHELL%" == "/bin/sh" goto SmallEnv\r
300echo No SHELL found in the environment, using default value\r
301\r
302:HomeName\r
303Rem Set HOME to a sane default so configure stops complaining.\r
304if not "%HOME%" == "" goto HostName\r
305set HOME=%XSRC%/djgpp\r
306if not "%HOME%" == "%XSRC%/djgpp" goto SmallEnv\r
307echo No HOME found in the environment, using default value\r
308\r
309:HostName\r
310Rem Set HOSTNAME so it shows in config.status\r
311if not "%HOSTNAME%" == "" goto hostdone\r
312if "%windir%" == "" goto msdos\r
313set OS=MS-Windows\r
314if not "%OS%" == "MS-Windows" goto SmallEnv\r
315goto haveos\r
316:msdos\r
317set OS=MS-DOS\r
318if not "%OS%" == "MS-DOS" goto SmallEnv\r
319:haveos\r
320if not "%USERNAME%" == "" goto haveuname\r
321if not "%USER%" == "" goto haveuser\r
322echo No USERNAME and no USER found in the environment, using default values\r
323set HOSTNAME=Unknown PC\r
324if not "%HOSTNAME%" == "Unknown PC" goto SmallEnv\r
325goto userdone\r
326:haveuser\r
327set HOSTNAME=%USER%'s PC\r
328if not "%HOSTNAME%" == "%USER%'s PC" goto SmallEnv\r
329goto userdone\r
330:haveuname\r
331set HOSTNAME=%USERNAME%'s PC\r
332if not "%HOSTNAME%" == "%USERNAME%'s PC" goto SmallEnv\r
333:userdone\r
334set _HOSTNAME=%HOSTNAME%, %OS%\r
335if not "%_HOSTNAME%" == "%HOSTNAME%, %OS%" goto SmallEnv\r
336set HOSTNAME=%_HOSTNAME%\r
337:hostdone\r
338set _HOSTNAME=\r
339set OS=\r
340\r
341Rem install-sh is required by the configure script but clashes with the\r
342Rem various Makefile install-foo targets, so we MUST have it before the\r
343Rem script runs and rename it afterwards\r
344test -f %XSRC%/install-sh\r
345if not errorlevel 1 goto NoRen0\r
346test -f %XSRC%/install-sh.sh\r
347if not errorlevel 1 mv -f %XSRC%/install-sh.sh %XSRC%/install-sh\r
348:NoRen0\r
349\r
350if "%NLS%" == "disabled" goto WithoutNLS\r
351\r
352:WithNLS\r
353Rem Check for the needed libraries and binaries.\r
354test -x /dev/env/DJDIR/bin/msgfmt.exe\r
355if errorlevel 1 goto MissingNLSTools\r
356test -x /dev/env/DJDIR/bin/xgettext.exe\r
357if errorlevel 1 goto MissingNLSTools\r
358test -f /dev/env/DJDIR/include/libcharset.h\r
359if errorlevel 1 goto MissingNLSTools\r
360test -f /dev/env/DJDIR/lib/libcharset.a\r
361if errorlevel 1 goto MissingNLSTools\r
362test -f /dev/env/DJDIR/include/iconv.h\r
363if errorlevel 1 goto MissingNLSTools\r
364test -f /dev/env/DJDIR/lib/libiconv.a\r
365if errorlevel 1 goto MissingNLSTools\r
366test -f /dev/env/DJDIR/include/libintl.h\r
367if errorlevel 1 goto MissingNLSTools\r
368test -f /dev/env/DJDIR/lib/libintl.a\r
369if errorlevel 1 goto MissingNLSTools\r
370\r
371Rem Recreate the files in the %XSRC%/po subdir with our ported tools.\r
372redir -e /dev/null rm %XSRC%/po/*.gmo\r
373redir -e /dev/null rm %XSRC%/po/bison.pot\r
374redir -e /dev/null rm %XSRC%/po/cat-id-tbl.c\r
375redir -e /dev/null rm %XSRC%/po/stamp-cat-id\r
376\r
377Rem Update the arguments file for the configure script.\r
378Rem We prefer without-included-gettext because libintl.a from gettext package\r
379Rem is the only one that is garanteed to have been ported to DJGPP.\r
380echo --enable-nls --without-included-gettext >> arguments\r
381goto ConfigurePackage\r
382\r
383:MissingNLSTools\r
384echo Needed libs/tools for NLS not found. Configuring without NLS.\r
385:WithoutNLS\r
386Rem Update the arguments file for the configure script.\r
387echo --disable-nls >> arguments\r
388\r
389:ConfigurePackage\r
390echo Running the ./configure script...\r
391sh ./configure @arguments\r
392if errorlevel 1 goto CfgError\r
393rm arguments\r
394echo Done.\r
395goto End\r
396\r
397:lalr1_ccFileError\r
398echo ./data/lalr1.cc file editing failed!\r
399goto End\r
400\r
c59929c3
JMG
401:location_ccFileError\r
402echo ./data/location.cc file editing failed!\r
403goto End\r
404\r
3768a1ae
JMG
405:calcxxFileError\r
406echo ./examples/calcxx file editing failed!\r
407goto End\r
408\r
409:ScannerFileError\r
410echo ./scanner file editing failed!\r
411goto End\r
412\r
413:SedError\r
414echo ./configure script editing failed!\r
415goto End\r
416\r
417:SedError2\r
418echo ./config.hin editing failed!\r
419goto End\r
420\r
421:CfgError\r
422echo ./configure script exited abnormally!\r
423goto End\r
424\r
425:SmallEnv\r
426echo Your environment size is too small. Enlarge it and run me again.\r
427echo Configuration NOT done!\r
428\r
429:End\r
430test -f %XSRC%/install-sh.sh\r
431if not errorlevel 1 goto NoRen1\r
432test -f %XSRC%/install-sh\r
433if not errorlevel 1 mv -f %XSRC%/install-sh %XSRC%/install-sh.sh\r
434:NoRen1\r
435if "%SHELL%" == "/bin/sh" set SHELL=\r
436if "%HOME%" == "%XSRC%/djgpp" set HOME=\r
437set ARGS=\r
438set CONFIG_SITE=\r
439set HOSTNAME=\r
440set NLS=\r
441set CACHING=\r
442set DEPENDENCY_TRACKING=\r
443set XSRC=\r