OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gcc-4.2.2/] [gcc/] [testsuite/] [objc.dg/] [gnu-encoding/] [gnu-encoding.exp] - Blame information for rev 149

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 149 jeremybenn
# GCC Objective-C testsuite that uses the `dg.exp' driver.
2
#   Copyright (C) 1997, 2001, 2007 Free Software Foundation, Inc.
3
 
4
# This program is free software; you can redistribute it and/or modify
5
# it under the terms of the GNU General Public License as published by
6
# the Free Software Foundation; either version 3 of the License, or
7
# (at your option) any later version.
8
#
9
# This program is distributed in the hope that it will be useful,
10
# but WITHOUT ANY WARRANTY; without even the implied warranty of
11
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12
# GNU General Public License for more details.
13
#
14
# You should have received a copy of the GNU General Public License
15
# along with GCC; see the file COPYING3.  If not see
16
# .
17
 
18
# Load support procs.
19
load_lib objc-dg.exp
20
 
21
# If a testcase doesn't have special options, use these.
22
global DEFAULT_CFLAGS
23
if ![info exists DEFAULT_CFLAGS] then {
24
    set DEFAULT_CFLAGS "-fgnu-runtime"
25
}
26
 
27
# Initialize `dg'.
28
dg-init
29
 
30
#
31
# gnu-encoding tests
32
#
33
set tstobjdir "$tmpdir/objc.dg-struct-layout-encoding-1"
34
set generator "$tmpdir/objc.dg-struct-layout-encoding-1_generate"
35
 
36
set generator_src "$srcdir/$subdir/struct-layout-encoding-1_generate.c"
37
set generator_src "$generator_src $srcdir/$subdir/generate-random.c"
38
set generator_src "$generator_src $srcdir/$subdir/generate-random_r.c"
39
set generator_cmd "-o $generator $generator_src"
40
set status [remote_exec host "$HOSTCC $HOSTCFLAGS $generator_cmd"]
41
set status [lindex $status 0]
42
if { $status == 0 } then {
43
    file delete -force $tstobjdir
44
    file mkdir $tstobjdir
45
    set generator_args "-s $srcdir/$subdir -d $tstobjdir"
46
#    set generator_args "$generator_args -n 15000"
47
    set status [remote_exec host "$generator $generator_args"]
48
    set status [lindex $status 0]
49
    if { $status == 0 } then {
50
        foreach src [lsort [find $tstobjdir *_main.m]] {
51
            # If we're only testing specific files and this isn't one
52
            # of them, skip it.
53
            if ![runtest_file_p $runtests $src] then {
54
                continue
55
            }
56
 
57
            dg-runtest $src "" $DEFAULT_CFLAGS
58
        }
59
    } else {
60
        warning "Could not execute objc.dg/gnu-encoding/struct-layout-encoding-1 generator"
61
    }
62
} else {
63
    warning "Could not compile objc.dg/gnu-encoding/struct-layout-encoding-1 generator"
64
}
65
 
66
 
67
 
68
 
69
 
70
 
71
# All done.
72
dg-finish
73
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.