OSDN Git Service

* g++.old-deja/g++.other/eh4.C: Fix typo.
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / g++.old-deja / old-deja.exp
1 # Copyright (C) 1988, 90, 91, 92, 1994, 1997, 2000 Free Software Foundation, Inc.
2
3 # This program is free software; you can redistribute it and/or modify
4 # it under the terms of the GNU General Public License as published by
5 # the Free Software Foundation; either version 2 of the License, or
6 # (at your option) any later version.
7
8 # This program is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
11 # GNU General Public License for more details.
12
13 # You should have received a copy of the GNU General Public License
14 # along with this program; if not, write to the Free Software
15 # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.  
16
17 # This file was written by Rob Savoye. (rob@cygnus.com)
18
19 #
20 # these tests come from the original DejaGnu test suite 
21 # developed at Cygnus Support. If this isn't deja gnu, I
22 # don't know what is...
23 #
24
25 # load support procs
26 load_lib old-dejagnu.exp
27 load_lib g++.exp
28
29
30 # When a testcase doesn't have any special options, use these.
31 if ![info exists DEFAULT_CXXFLAGS] {
32     set DEFAULT_CXXFLAGS "-ansi -pedantic-errors -Wno-long-long"
33
34 }
35
36 old-dejagnu-init
37 global GXX_UNDER_TEST
38
39 #
40 # main test loop
41 #
42
43 set dirlen [expr [string length "$srcdir/$subdir"] + 1];
44 foreach file [lsort [find $srcdir/$subdir *.C]] {
45     # If we're only testing specific files and this isn't one of them, skip it.
46     set tfile [string range $file $dirlen end];
47     if ![runtest_file_p $runtests $tfile] then {
48         continue
49     }
50     verbose "Testing $file"
51
52     # We don't want old-dejagnu.exp to have to know about all the global
53     # variables we use.  For now we tell it about CXXFLAGS and LIBS and
54     # leave LDFLAGS alone.
55     old-dejagnu $GXX_UNDER_TEST "$file" "$tfile" "" "$DEFAULT_CXXFLAGS" "-lstdc++"
56 }
57
58 # The framework doesn't like to see any error remnants,
59 # so remove them.
60 if [info exists errorInfo] then {
61       unset errorInfo
62 }