OSDN Git Service

* gcc.c-torture/execute/execute.exp: Change copyright header to refer to version
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / gcc.dg / format / format.exp
1 #   Copyright (C) 1997, 2000, 2001, 2007 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 3 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 GCC; see the file COPYING3.  If not see
15 # <http://www.gnu.org/licenses/>.
16
17 # Don't run this directory with any default CFLAGS, but run tests with
18 # and without -DWIDE.
19
20 if [info exists TORTURE_OPTIONS] {
21     set old_TORTURE_OPTIONS $TORTURE_OPTIONS
22 } elseif [info exists old_TORTURE_OPTIONS] {
23     unset old_TORTURE_OPTIONS
24 }
25 if [info exists torture_with_loops] {
26     set old_torture_with_loops $torture_with_loops
27 } elseif [info exists old_torture_with_loops] {
28     unset old_torture_with_loops
29 }
30 if [info exists torture_without_loops] {
31     set old_torture_without_loops $torture_without_loops
32 } elseif [info exists old_torture_without_loops] {
33     unset old_torture_without_loops
34 }
35 set TORTURE_OPTIONS [list { } { -DWIDE } ]
36 set torture_with_loops [list { } { -DWIDE } ]
37 set torture_without_loops [list { } { -DWIDE } ]
38
39 # Need to copy the format.h header.
40 if [is_remote host] {
41     remote_download host $srcdir/$subdir/format.h
42 }
43
44 load_lib gcc-dg.exp
45
46 dg-init
47 gcc-dg-runtest [lsort [glob -nocomplain $srcdir/$subdir/*.\[cS\]]] ""
48 if [info exists old_TORTURE_OPTIONS] {
49     set TORTURE_OPTIONS $old_TORTURE_OPTIONS
50 } else {
51     unset TORTURE_OPTIONS
52 }
53 if [info exists old_torture_with_loops] {
54     set torture_with_loops $old_torture_with_loops
55 } else {
56     unset torture_with_loops
57 }
58 if [info exists old_torture_without_loops] {
59     set torture_without_loops $old_torture_without_loops
60 } else {
61     unset torture_without_loops
62 }
63 dg-finish