VirtualBox

Ignore:
Timestamp:
Jun 19, 2012 10:44:52 PM (12 years ago)
Author:
bird
Message:

gnumake/current -> 3.82-cvs.

Location:
vendor/gnumake/current
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • vendor/gnumake/current

    • Property svn:ignore deleted
  • vendor/gnumake/current/tests

    • Property svn:ignore deleted
  • vendor/gnumake/current/tests/test_driver.pl

    r1989 r2596  
    77#
    88# Copyright (C) 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
    9 # 2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
     9# 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software
     10# Foundation, Inc.
    1011# This file is part of GNU Make.
    1112#
     
    3031# variables and then calls &toplevel, which does all the real work.
    3132
    32 # $Id: test_driver.pl,v 1.24 2007/11/04 21:54:02 psmith Exp $
     33# $Id: test_driver.pl,v 1.30 2010/07/28 05:39:50 psmith Exp $
    3334
    3435
     
    5455$test_timeout = 5;
    5556
     57# Path to Perl
     58$perl_name = $^X;
    5659
    5760# %makeENV is the cleaned-out environment.
     
    236239{
    237240  # Set up an initial value.  In perl5 we can do it the easy way.
    238   #
    239241  $osname = defined($^O) ? $^O : '';
     242
     243  # Find a path to Perl
    240244
    241245  # See if the filesystem supports long file names with multiple
     
    273277    if ($osname =~ /not found/i)
    274278    {
    275         $osname = "(something unixy with no uname)";
     279        $osname = "(something posixy with no uname)";
    276280    }
    277281    elsif ($@ ne "" || $?)
     
    280284        if ($@ ne "" || $?)
    281285        {
    282             $osname = "(something unixy)";
     286            $osname = "(something posixy)";
    283287        }
    284288    }
     
    436440      $diffext = 'd';
    437441      $baseext = 'b';
     442      $runext = 'r';
    438443      $extext = '';
    439444    } else {
     
    441446      $diffext = 'diff';
    442447      $baseext = 'base';
     448      $runext = 'run';
    443449      $extext = '.';
    444450    }
     
    446452    $diff_filename = "$testpath.$diffext";
    447453    $base_filename = "$testpath.$baseext";
     454    $run_filename = "$testpath.$runext";
    448455    $tmp_filename = "$testpath.$tmpfilesuffix";
    449456
     
    459466    $tests_run = 0;
    460467    $tests_passed = 0;
     468
    461469    $code = do $perl_testname;
    462470
     
    692700
    693701    &create_file (&get_basefile, $answer);
     702    &create_file (&get_runfile, $command_string);
    694703
    695704    print "\nCreating Difference File ...\n" if $debug;
     
    699708    local($command) = "diff -c " . &get_basefile . " " . $logfile;
    700709    &run_command_with_output(&get_difffile,$command);
     710  } else {
     711      &rmfiles ();
    701712  }
    702713
     
    792803      local $SIG{ALRM} = sub { die "timeout\n"; };
    793804      alarm $test_timeout;
    794       $code = system @_;
     805      $code = system(@_);
    795806      alarm 0;
    796807  };
     
    829840  my $filename = shift;
    830841
    831   print "\nrun_command_with_output($filename): @_\n" if $debug;
     842  print "\nrun_command_with_output($filename,$runname): @_\n" if $debug;
    832843  &attach_default_output ($filename);
    833844  my $code = _run_command(@_);
     
    12021213}
    12031214
     1215# This subroutine returns a command filename with a number appended
     1216# to the end corresponding to how many logfiles (and thus command files)
     1217# have been created in the current running test.
     1218
     1219sub get_runfile
     1220{
     1221  return ($run_filename . &num_suffix ($num_of_logfiles));
     1222}
     1223
    12041224# just like logfile, only a generic tmp filename for use by the test.
    12051225# they are automatically cleaned up unless -keep was used, or the test fails.
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette