|
|
|
|
# Copyright (C) 1992-2019, 2020 Free Software Foundation, Inc.
|
|
|
|
|
#
|
|
|
|
|
# This file is part of DejaGnu.
|
|
|
|
|
#
|
|
|
|
|
# DejaGnu is free software; you can redistribute it and/or modify it
|
|
|
|
|
# under the terms of the GNU General Public License as published by
|
|
|
|
|
# the Free Software Foundation; either version 3 of the License, or
|
|
|
|
|
# (at your option) any later version.
|
|
|
|
|
#
|
|
|
|
|
# DejaGnu is distributed in the hope that it will be useful, but
|
|
|
|
|
# WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
|
# General Public License for more details.
|
|
|
|
|
#
|
|
|
|
|
# You should have received a copy of the GNU General Public License
|
|
|
|
|
# along with DejaGnu; if not, write to the Free Software Foundation,
|
|
|
|
|
# Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
|
|
|
|
|
|
|
|
|
|
# Searches in the appropriate place (the board_info array) for the specified
|
|
|
|
|
# information.
|
|
|
|
|
#
|
|
|
|
|
proc board_info { machine op args } {
|
|
|
|
|
global target_info
|
|
|
|
|
global board_info
|
|
|
|
|
|
|
|
|
|
verbose "board_info $machine $op $args" 3
|
|
|
|
|
|
* runtest.exp, baseboards/basic-sim.exp, baseboards/cf.exp,
baseboards/cris-sim.exp, baseboards/i960-cyclone.exp,
baseboards/mcore-moto-sim.exp, baseboards/mips64vr4100-sim.exp,
baseboards/mmixware-sim.exp, baseboards/op50n.exp,
baseboards/rom68k-idp.exp, baseboards/sparclite-sim-le.exp,
baseboards/usparc-cygmon.exp, config/base-config.exp,
config/base68k.exp, config/ddb-ether.exp, config/ddb.exp,
config/dos.exp, config/gdb-comm.exp, config/gdb_stub.exp,
config/i386-bozo.exp, config/i960.exp, config/m68k-emc.exp,
config/netware.exp, config/sid.exp, config/sim.exp,
config/tic80.exp, config/unix.exp, config/vxworks.exp,
lib/debugger.exp, lib/dejagnu.exp, lib/dg.exp, lib/framework.exp,
lib/ftp.exp, lib/kermit.exp, lib/libgloss.exp, lib/remote.exp,
lib/rlogin.exp, lib/rsh.exp, lib/target.exp, lib/targetdb.exp,
lib/telnet.exp, lib/tip.exp, lib/utils.exp: Put braces around if
expressions throughout.
21 years ago
|
|
|
if {[info exists target_info($machine,name)]} {
|
|
|
|
|
set machine $target_info($machine,name)
|
|
|
|
|
}
|
* runtest.exp, lib/utils.exp, lib/targetdb.exp, lib/target.exp,
lib/remote.exp, lib/framework.exp, lib/dg.exp, config/vxworks.exp,
config/sim.exp, config/gdb_stub.exp, config/aarch64-fv8.exp,
baseboards/vr4300-sim.exp, baseboards/vr4111-sim.exp,
baseboards/vr4100-sim.exp, baseboards/sh-sid.exp,
baseboards/mt-sid.exp, baseboards/mips-sim.exp,
baseboards/mips-sim-idt64.exp, baseboards/mips-sim-idt32.exp,
baseboards/i386-sid.exp, baseboards/arm-sim.exp,
baseboards/arm-ice.exp, baseboards/androideabi.exp,
testsuite/runtest.all/utils.test,
testsuite/runtest.all/target.test: Replace string literal
comparisons using == and != with 'eq' and 'ne'.
8 years ago
|
|
|
if { $op eq "exists" } {
|
|
|
|
|
if { [llength $args] == 0 } {
|
|
|
|
|
return [info exists board_info($machine,name)]
|
|
|
|
|
} else {
|
|
|
|
|
return [info exists board_info($machine,[lindex $args 0])]
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
if { [llength $args] == 0 } {
|
|
|
|
|
verbose "getting $machine $op" 3
|
* runtest.exp, baseboards/basic-sim.exp, baseboards/cf.exp,
baseboards/cris-sim.exp, baseboards/i960-cyclone.exp,
baseboards/mcore-moto-sim.exp, baseboards/mips64vr4100-sim.exp,
baseboards/mmixware-sim.exp, baseboards/op50n.exp,
baseboards/rom68k-idp.exp, baseboards/sparclite-sim-le.exp,
baseboards/usparc-cygmon.exp, config/base-config.exp,
config/base68k.exp, config/ddb-ether.exp, config/ddb.exp,
config/dos.exp, config/gdb-comm.exp, config/gdb_stub.exp,
config/i386-bozo.exp, config/i960.exp, config/m68k-emc.exp,
config/netware.exp, config/sid.exp, config/sim.exp,
config/tic80.exp, config/unix.exp, config/vxworks.exp,
lib/debugger.exp, lib/dejagnu.exp, lib/dg.exp, lib/framework.exp,
lib/ftp.exp, lib/kermit.exp, lib/libgloss.exp, lib/remote.exp,
lib/rlogin.exp, lib/rsh.exp, lib/target.exp, lib/targetdb.exp,
lib/telnet.exp, lib/tip.exp, lib/utils.exp: Put braces around if
expressions throughout.
21 years ago
|
|
|
if {[info exists board_info($machine,$op)]} {
|
|
|
|
|
return $board_info($machine,$op)
|
|
|
|
|
} else {
|
|
|
|
|
return ""
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
return ""
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
proc target_info { op args } {
|
|
|
|
|
return [eval "board_info target \"$op\" $args"]
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
proc host_info { op args } {
|
|
|
|
|
return [eval "board_info host \"$op\" $args"]
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
# Set ENTRY to VALUE for the current board.
|
|
|
|
|
#
|
|
|
|
|
proc set_board_info { entry value } {
|
|
|
|
|
global board_info board
|
* runtest.exp, baseboards/basic-sim.exp, baseboards/cf.exp,
baseboards/cris-sim.exp, baseboards/i960-cyclone.exp,
baseboards/mcore-moto-sim.exp, baseboards/mips64vr4100-sim.exp,
baseboards/mmixware-sim.exp, baseboards/op50n.exp,
baseboards/rom68k-idp.exp, baseboards/sparclite-sim-le.exp,
baseboards/usparc-cygmon.exp, config/base-config.exp,
config/base68k.exp, config/ddb-ether.exp, config/ddb.exp,
config/dos.exp, config/gdb-comm.exp, config/gdb_stub.exp,
config/i386-bozo.exp, config/i960.exp, config/m68k-emc.exp,
config/netware.exp, config/sid.exp, config/sim.exp,
config/tic80.exp, config/unix.exp, config/vxworks.exp,
lib/debugger.exp, lib/dejagnu.exp, lib/dg.exp, lib/framework.exp,
lib/ftp.exp, lib/kermit.exp, lib/libgloss.exp, lib/remote.exp,
lib/rlogin.exp, lib/rsh.exp, lib/target.exp, lib/targetdb.exp,
lib/telnet.exp, lib/tip.exp, lib/utils.exp: Put braces around if
expressions throughout.
21 years ago
|
|
|
if {![info exists board_info($board,$entry)]} {
|
|
|
|
|
set board_info($board,$entry) $value
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
#
|
|
|
|
|
# Append VALUE to ENTRY for the current board.
|
|
|
|
|
#
|
|
|
|
|
proc add_board_info { entry value } {
|
|
|
|
|
global board_info board
|
|
|
|
|
lappend board_info($board,$entry) $value
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
# Fill in ENTRY with VALUE for the current target.
|
|
|
|
|
#
|
|
|
|
|
proc set_currtarget_info { entry value } {
|
|
|
|
|
global board_info
|
|
|
|
|
|
|
|
|
|
set board [target_info name]
|
|
|
|
|
|
* runtest.exp, baseboards/basic-sim.exp, baseboards/cf.exp,
baseboards/cris-sim.exp, baseboards/i960-cyclone.exp,
baseboards/mcore-moto-sim.exp, baseboards/mips64vr4100-sim.exp,
baseboards/mmixware-sim.exp, baseboards/op50n.exp,
baseboards/rom68k-idp.exp, baseboards/sparclite-sim-le.exp,
baseboards/usparc-cygmon.exp, config/base-config.exp,
config/base68k.exp, config/ddb-ether.exp, config/ddb.exp,
config/dos.exp, config/gdb-comm.exp, config/gdb_stub.exp,
config/i386-bozo.exp, config/i960.exp, config/m68k-emc.exp,
config/netware.exp, config/sid.exp, config/sim.exp,
config/tic80.exp, config/unix.exp, config/vxworks.exp,
lib/debugger.exp, lib/dejagnu.exp, lib/dg.exp, lib/framework.exp,
lib/ftp.exp, lib/kermit.exp, lib/libgloss.exp, lib/remote.exp,
lib/rlogin.exp, lib/rsh.exp, lib/target.exp, lib/targetdb.exp,
lib/telnet.exp, lib/tip.exp, lib/utils.exp: Put braces around if
expressions throughout.
21 years ago
|
|
|
if {![info exists board_info($board,$entry)]} {
|
|
|
|
|
set board_info($board,$entry) $value
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
# Unset ENTRY for the current board being defined.
|
|
|
|
|
#
|
|
|
|
|
proc unset_board_info { entry } {
|
|
|
|
|
global board_info board
|
|
|
|
|
|
* runtest.exp, baseboards/basic-sim.exp, baseboards/cf.exp,
baseboards/cris-sim.exp, baseboards/i960-cyclone.exp,
baseboards/mcore-moto-sim.exp, baseboards/mips64vr4100-sim.exp,
baseboards/mmixware-sim.exp, baseboards/op50n.exp,
baseboards/rom68k-idp.exp, baseboards/sparclite-sim-le.exp,
baseboards/usparc-cygmon.exp, config/base-config.exp,
config/base68k.exp, config/ddb-ether.exp, config/ddb.exp,
config/dos.exp, config/gdb-comm.exp, config/gdb_stub.exp,
config/i386-bozo.exp, config/i960.exp, config/m68k-emc.exp,
config/netware.exp, config/sid.exp, config/sim.exp,
config/tic80.exp, config/unix.exp, config/vxworks.exp,
lib/debugger.exp, lib/dejagnu.exp, lib/dg.exp, lib/framework.exp,
lib/ftp.exp, lib/kermit.exp, lib/libgloss.exp, lib/remote.exp,
lib/rlogin.exp, lib/rsh.exp, lib/target.exp, lib/targetdb.exp,
lib/telnet.exp, lib/tip.exp, lib/utils.exp: Put braces around if
expressions throughout.
21 years ago
|
|
|
if {[info exists board_info($board,$entry)]} {
|
|
|
|
|
unset board_info($board,$entry)
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
# Unset ENTRY for the current board being defined.
|
|
|
|
|
#
|
|
|
|
|
proc unset_currtarget_info { entry } {
|
|
|
|
|
global board_info
|
|
|
|
|
|
|
|
|
|
set board [target_info name]
|
|
|
|
|
|
* runtest.exp, baseboards/basic-sim.exp, baseboards/cf.exp,
baseboards/cris-sim.exp, baseboards/i960-cyclone.exp,
baseboards/mcore-moto-sim.exp, baseboards/mips64vr4100-sim.exp,
baseboards/mmixware-sim.exp, baseboards/op50n.exp,
baseboards/rom68k-idp.exp, baseboards/sparclite-sim-le.exp,
baseboards/usparc-cygmon.exp, config/base-config.exp,
config/base68k.exp, config/ddb-ether.exp, config/ddb.exp,
config/dos.exp, config/gdb-comm.exp, config/gdb_stub.exp,
config/i386-bozo.exp, config/i960.exp, config/m68k-emc.exp,
config/netware.exp, config/sid.exp, config/sim.exp,
config/tic80.exp, config/unix.exp, config/vxworks.exp,
lib/debugger.exp, lib/dejagnu.exp, lib/dg.exp, lib/framework.exp,
lib/ftp.exp, lib/kermit.exp, lib/libgloss.exp, lib/remote.exp,
lib/rlogin.exp, lib/rsh.exp, lib/target.exp, lib/targetdb.exp,
lib/telnet.exp, lib/tip.exp, lib/utils.exp: Put braces around if
expressions throughout.
21 years ago
|
|
|
if {[info exists board_info($board,$entry)]} {
|
|
|
|
|
unset board_info($board,$entry)
|
|
|
|
|
}
|
|
|
|
|
}
|