Maurice Lombardi wrote:
OK I have downloaded gpc-20000719. Everythings (demos and test suite) works now both with gmp 2.2 and gmp 3.01 downloaded from djgpp site. fjf119 and fjf120 also work now.
Fine.
There is a problem to run the test suite on djgpp. It is the same that forced djgpp maintainers to split the build process with a build.bat. For a too large number of compilations, program stops or crashes do to lost dpmi handles. This is fortunately reset when going back to dos (even within a bat file). The solution is thus to split the running of tests in chunks (of 250 files). The attached files dostest.bat which calls dodostst.sh and makefile.dos, to be put in the test directory do that automatically. type dostest the result are concatenated into a file test_sum.out and typed at end.
I'm a bit concerned with the changes to the Makefile (two similar versions of the same file are always harder to maintain -- and there will probably more changes to the Makefile in the future).
First, I think you don't have to comment out MASK because the command line setting in dodostst.sh should override it, anyway.
Then, SHELL should probably be set to /bin/sh (which `make' under DJGPP will change to the correct path automagically). I think we can do this in the main Makefile if it doesn't break things on other systems. On Unix, it's no problem, but I don't know about Cygwin and Mingw. Chief, you might want to test it -- perhaps it'll be necessary to set SHELL to the full path of sh.exe before calling make (if you don't already have to do this, anyway).
Finally, I think the output redicrection can also be done in the shell file, i.e.:
make SHELL=sh MASK="$FILES" >> test_sum.out
If you're concerned about the messages ("Running the test suite..."), I can add another target, say `pascal.check-nomsg' which will not write the messages, together with a target `msg' which will just output the messages, in case you want to run this first. -- Or wait, perhaps even better: run `pascal.check-long' in the loop, and pipe the concatenated results through test_sum at the end -- this should be more convenient as the results will be listed as a total.
BTW, what does the for loop in dodostst.sh do? Doesn't make SHELL=sh MASK="`cat $1`" pascal.check-long >> test_sum.out work already? Then, you could probably get by without dodostst.sh at all, by just inserting it into the batch file (don't worry about the `` -- command.com will not expand them, of course, but sh called by make later will do so).
Finally, I suggest to change test_sum.out to make.out because "sum" is then no more appropriate, and other scripts already use make.out, and the Makefile will remove make.out in the `extraclean' target. Likewise, renaming list.* to dtlist.* might avoid conflict with possible later list* test programs...
This results in the following file (provided you agree to release it under the GPL). I'm testing it under DosEmu, and it seems to work. I'll upload it already -- if it doesn't work for you, let me know.
@echo off
rem Script to run the GPC Test Suite under DJGPP on a system that rem suffers from losing DPMI handles (such as MS-Windows). rem rem Copyright (C) 2000 Free Software Foundation, Inc. rem rem Authors: Maurice Lombardi [Maurice.Lombardi@ujf-grenoble.fr] rem Frank Heckenbach [frank@pascal.gnu.de] rem rem This file is part of GNU Pascal. rem rem GNU Pascal is free software; you can redistribute it and/or modify rem it under the terms of the GNU General Public License as published by rem the Free Software Foundation; either version 2, or (at your option) rem any later version. rem rem GNU Pascal is distributed in the hope that it will be useful, rem but WITHOUT ANY WARRANTY; without even the implied warranty of rem MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the rem GNU General Public License for more details. rem rem You should have received a copy of the GNU General Public License rem along with GNU Pascal; see the file COPYING. If not, write to the rem Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA rem 02111-1307, USA.
if exist make.out del make.out if exist dtlist.* del dtlist.* make msg ls -1 *.pas | split -l 250 - dtlist. for %%f in (dtlist.*) do make MASK="`cat %%f`" pascal.check-long >> make.out sh test_sum < make.out
Frank
Frank Heckenbach a écrit :
if exist make.out del make.out if exist dtlist.* del dtlist.* make msg ls -1 *.pas | split -l 250 - dtlist. for %%f in (dtlist.*) do make MASK="`cat %%f`" pascal.check-long >> make.out sh test_sum < make.out
Works perfectly ! You simply much better know the syntax of shells and makefiles.
Many thanks
Maurice
On 21 Jul 00, at 1:45, Frank Heckenbach wrote:
I'm a bit concerned with the changes to the Makefile (two similar versions of the same file are always harder to maintain -- and there will probably more changes to the Makefile in the future).
First, I think you don't have to comment out MASK because the command line setting in dodostst.sh should override it, anyway.
Then, SHELL should probably be set to /bin/sh (which `make' under DJGPP will change to the correct path automagically). I think we can do this in the main Makefile if it doesn't break things on other systems. On Unix, it's no problem, but I don't know about Cygwin and Mingw. Chief, you might want to test it -- perhaps it'll be necessary to set SHELL to the full path of sh.exe before calling make (if you don't already have to do this, anyway).
Setting 'SHELL=" in 'Makefile' (however you set it, and whatever you do with it) does not work under Cygwin, if 'sh.exe' is not in '/bin'. So, please assume that, under Cygwin/Mingw, you do need to have a copy of 'sh.exe' in '/bin', else the scripts must point to its correct location.
Best regards, The Chief -------- Prof. Abimbola A. Olowofoyeku (The African Chief) Author of: Chief's Installer Pro v5.22.1 for Win32 http://www.bigfoot.com/~African_Chief/chief32.htm Email: African_Chief@bigfoot.com