Skip to content
Snippets Groups Projects
Commit caf21254 authored by Phil Edwards's avatar Phil Edwards
Browse files

Makefile.am (DEJATOOL,EXPECT,RUNTEST,RUNTESTFLAGS): Remove unneeded variable assignments.

2003-08-04  Phil Edwards  <pme@gcc.gnu.org>

	* testsuite/Makefile.am (DEJATOOL,EXPECT,RUNTEST,RUNTESTFLAGS):
	Remove unneeded variable assignments.  Leave them for automake.
	* testsuite/lib/libstdc++-v3.exp:  Rename...
	* testsuite/lib/libstdc++.exp:  ...to this.  Adjust function names
	accordingly.
	* testsuite/libstdc++-v3.dg/dg.exp:  Rename...
	* testsuite/libstdc++-dg/normal.exp:  ...to this.  Adjust function
	names accordingly.

From-SVN: r70165
parent f7ab5fa4
No related branches found
No related tags found
No related merge requests found
2003-08-04 Phil Edwards <pme@gcc.gnu.org>
* testsuite/Makefile.am (DEJATOOL,EXPECT,RUNTEST,RUNTESTFLAGS):
Remove unneeded variable assignments. Leave them for automake.
* testsuite/lib/libstdc++-v3.exp: Rename...
* testsuite/lib/libstdc++.exp: ...to this. Adjust function names
accordingly.
* testsuite/libstdc++-v3.dg/dg.exp: Rename...
* testsuite/libstdc++-dg/normal.exp: ...to this. Adjust function
names accordingly.
2003-08-04 Phil Edwards <pme@gcc.gnu.org> 2003-08-04 Phil Edwards <pme@gcc.gnu.org>
* docs/doxygen/guide.html: run_doxygen uses bash. * docs/doxygen/guide.html: run_doxygen uses bash.
......
...@@ -21,23 +21,12 @@ ...@@ -21,23 +21,12 @@
## Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ## Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307,
## USA. ## USA.
AUTOMAKE_OPTIONS = cygnus dejagnu AUTOMAKE_OPTIONS = dejagnu
mkinstalldirs = $(SHELL) $(toplevel_srcdir)/mkinstalldirs mkinstalldirs = $(SHELL) $(toplevel_srcdir)/mkinstalldirs
DEJATOOL = libstdc++-v3
EXPECT = `if [ -f @glibcxx_builddir@/../../expect/expect ] ; then \
echo @glibcxx_builddir@/../../expect/expect ; \
else echo expect ; fi`
RUNTEST = `if [ -f @glibcxx_srcdir@/../dejagnu/runtest ] ; then \
echo @glibcxx_srcdir@/../dejagnu/runtest ; \
else echo runtest; fi`
AM_MAKEFLAGS = -j1 AM_MAKEFLAGS = -j1
AM_RUNTESTFLAGS = AM_RUNTESTFLAGS =
RUNTESTFLAGS =
PWD_COMMAND = $${PWDCMD-pwd} PWD_COMMAND = $${PWDCMD-pwd}
## CXX is actually a "C" compiler. These are real C++ programs. ## CXX is actually a "C" compiler. These are real C++ programs.
......
...@@ -14,30 +14,30 @@ ...@@ -14,30 +14,30 @@
# along with this program; if not, write to the Free Software # along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
# Define libstdc++-v3 callbacks for dg.exp. # Define callbacks for dg.exp. This file is loaded early.
load_lib dg.exp load_lib dg.exp
load_lib libgloss.exp load_lib libgloss.exp
load_lib prune.exp load_lib prune.exp
# Called once, by libstdc++-v3-init below. "Static" to this file. # Called by v3-init below. "Static" to this file.
proc libstdc++-v3-copy-files {srcfiles dstdir} { proc v3-copy-files {srcfiles dstdir} {
foreach f $srcfiles { foreach f $srcfiles {
if { [catch { set symlink [file readlink $f] } x] } then { if { [catch { set symlink [file readlink $f] } x] } then {
file copy -force $f $dstdir file copy -force $f $dstdir
} else { } else {
if { [regexp "^/" "$symlink"] } then { if { [regexp "^/" "$symlink"] } then {
file copy -force $symlink $dstdir file copy -force $symlink $dstdir
} else { } else {
set dirname [file dirname $f] set dirname [file dirname $f]
file copy -force $dirname/$symlink $dstdir file copy -force $dirname/$symlink $dstdir
} }
} }
} }
} }
# Called once, from libstdc++-v3.dg/dg.exp. # Called once, from libstdc++/dg.exp.
proc libstdc++-v3-init { args } { proc v3-init { args } {
global srcdir global srcdir
global outdir global outdir
global blddir global blddir
...@@ -56,15 +56,15 @@ proc libstdc++-v3-init { args } { ...@@ -56,15 +56,15 @@ proc libstdc++-v3-init { args } {
set dg-do-what-default run set dg-do-what-default run
# Copy any required data files. # Copy any required data files.
libstdc++-v3-copy-files [glob -nocomplain "$srcdir/data/*.tst"] $outdir v3-copy-files [glob -nocomplain "$srcdir/data/*.tst"] $outdir
libstdc++-v3-copy-files [glob -nocomplain "$srcdir/data/*.txt"] $outdir v3-copy-files [glob -nocomplain "$srcdir/data/*.txt"] $outdir
# set LD_LIBRARY_PATH so that libgcc_s, libstdc++ binaries can be found. # set LD_LIBRARY_PATH so that libgcc_s, libstdc++ binaries can be found.
# locate libgcc.a so we don't need to account for different values of # locate libgcc.a so we don't need to account for different values of
# SHLIB_EXT on different platforms # SHLIB_EXT on different platforms
set gccdir [lookfor_file $tool_root_dir gcc/libgcc.a] set gccdir [lookfor_file $tool_root_dir gcc/libgcc.a]
if {$gccdir != ""} { if {$gccdir != ""} {
set gccdir [file dirname $gccdir] set gccdir [file dirname $gccdir]
} }
set ld_library_path "." set ld_library_path "."
...@@ -72,15 +72,15 @@ proc libstdc++-v3-init { args } { ...@@ -72,15 +72,15 @@ proc libstdc++-v3-init { args } {
set compiler ${gccdir}/g++ set compiler ${gccdir}/g++
if { [is_remote host] == 0 && [which $compiler] != 0 } { if { [is_remote host] == 0 && [which $compiler] != 0 } {
foreach i "[exec $compiler --print-multi-lib]" { foreach i "[exec $compiler --print-multi-lib]" {
set mldir "" set mldir ""
regexp -- "\[a-z0-9=/\.-\]*;" $i mldir regexp -- "\[a-z0-9=/\.-\]*;" $i mldir
set mldir [string trimright $mldir "\;@"] set mldir [string trimright $mldir "\;@"]
if { "$mldir" == "." } { if { "$mldir" == "." } {
continue continue
} }
if { [llength [glob -nocomplain ${gccdir}/${mldir}/libgcc_s*.so.*]] == 1 } { if { [llength [glob -nocomplain ${gccdir}/${mldir}/libgcc_s*.so.*]] == 1 } {
append ld_library_path ":${gccdir}/${mldir}" append ld_library_path ":${gccdir}/${mldir}"
} }
} }
} }
append ld_library_path ":${blddir}/src/.libs" append ld_library_path ":${blddir}/src/.libs"
...@@ -137,55 +137,55 @@ proc libstdc++-v3-init { args } { ...@@ -137,55 +137,55 @@ proc libstdc++-v3-init { args } {
} }
# Callback from system dg-test. # Callback from system dg-test.
proc libstdc++-v3-dg-test { prog do_what extra_tool_flags } { proc libstdc++-dg-test { prog do_what extra_tool_flags } {
# Set up the compiler flags, based on what we're going to do. # Set up the compiler flags, based on what we're going to do.
switch $do_what { switch $do_what {
"preprocess" { "preprocess" {
set compile_type "preprocess" set compile_type "preprocess"
set output_file "[file rootname [file tail $prog]].i" set output_file "[file rootname [file tail $prog]].i"
} }
"compile" { "compile" {
set compile_type "assembly" set compile_type "assembly"
set output_file "[file rootname [file tail $prog]].s" set output_file "[file rootname [file tail $prog]].s"
} }
"assemble" { "assemble" {
set compile_type "object" set compile_type "object"
set output_file "[file rootname [file tail $prog]].o" set output_file "[file rootname [file tail $prog]].o"
} }
"link" { "link" {
set compile_type "executable" set compile_type "executable"
set output_file "./[file rootname [file tail $prog]].exe" set output_file "./[file rootname [file tail $prog]].exe"
} }
"run" { "run" {
set compile_type "executable" set compile_type "executable"
# FIXME: "./" is to cope with "." not being in $PATH. # FIXME: "./" is to cope with "." not being in $PATH.
# Should this be handled elsewhere? # Should this be handled elsewhere?
# YES. # YES.
set output_file "./[file rootname [file tail $prog]].exe" set output_file "./[file rootname [file tail $prog]].exe"
# This is the only place where we care if an executable was # This is the only place where we care if an executable was
# created or not. If it was, dg.exp will try to run it. # created or not. If it was, dg.exp will try to run it.
remote_file build delete $output_file; remote_file build delete $output_file;
} }
default { default {
perror "$do_what: not a valid dg-do keyword" perror "$do_what: not a valid dg-do keyword"
return "" return ""
} }
} }
set options "" set options ""
if { $extra_tool_flags != "" } { if { $extra_tool_flags != "" } {
lappend options "additional_flags=$extra_tool_flags" lappend options "additional_flags=$extra_tool_flags"
} }
set comp_output [libstdc++-v3_target_compile "$prog" "$output_file" "$compile_type" $options]; set comp_output [v3_target_compile "$prog" "$output_file" "$compile_type" $options];
set comp_output [ prune_g++_output $comp_output ]; set comp_output [ prune_g++_output $comp_output ];
return [list $comp_output $output_file] return [list $comp_output $output_file]
} }
# Called from libstdc++-v3-dg-test above. Calls back into system's # Called from libstdc++-dg-test above. Calls back into system's
# target_compile to actually do the work. # target_compile to actually do the work.
proc libstdc++-v3_target_compile { source dest type options } { proc v3_target_compile { source dest type options } {
global gluefile global gluefile
global wrap_flags global wrap_flags
global cxx global cxx
...@@ -194,8 +194,8 @@ proc libstdc++-v3_target_compile { source dest type options } { ...@@ -194,8 +194,8 @@ proc libstdc++-v3_target_compile { source dest type options } {
global blddir global blddir
if { [target_info needs_status_wrapper] != "" && [info exists gluefile] } { if { [target_info needs_status_wrapper] != "" && [info exists gluefile] } {
lappend options "libs=${gluefile}" lappend options "libs=${gluefile}"
lappend options "ldflags=${wrap_flags}" lappend options "ldflags=${wrap_flags}"
} }
set cxx_final $cxx set cxx_final $cxx
...@@ -215,7 +215,7 @@ proc libstdc++-v3_target_compile { source dest type options } { ...@@ -215,7 +215,7 @@ proc libstdc++-v3_target_compile { source dest type options } {
} }
# Called once, from libstdc++-v3.dg/dg.exp. # Called once, from libstdc++*/dg.exp.
proc v3-list-tests { filename } { proc v3-list-tests { filename } {
global srcdir global srcdir
global outdir global outdir
...@@ -225,16 +225,16 @@ proc v3-list-tests { filename } { ...@@ -225,16 +225,16 @@ proc v3-list-tests { filename } {
# If there is a testsuite_file, use it. # If there is a testsuite_file, use it.
if { [file exists $tests_file] } { if { [file exists $tests_file] } {
set f [open $tests_file] set f [open $tests_file]
while { ! [eof $f] } { while { ! [eof $f] } {
set t [gets $f] set t [gets $f]
if { [string length "$t"] != 0 } { if { [string length "$t"] != 0 } {
lappend sfiles ${srcdir}/${t} lappend sfiles ${srcdir}/${t}
} }
} }
close $f close $f
} else { } else {
verbose "cannot open $tests_file" verbose "cannot open $tests_file"
} }
return $sfiles return $sfiles
} }
...@@ -24,7 +24,7 @@ if ![info exists DEFAULT_CXXFLAGS] then { ...@@ -24,7 +24,7 @@ if ![info exists DEFAULT_CXXFLAGS] then {
# Initialization. # Initialization.
dg-init dg-init
libstdc++-v3-init v3-init
# Main loop. # Main loop.
dg-runtest [v3-list-tests testsuite_files] "" $DEFAULT_CXXFLAGS dg-runtest [v3-list-tests testsuite_files] "" $DEFAULT_CXXFLAGS
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment