mirror of
https://git.savannah.gnu.org/git/make.git
synced 2025-01-12 08:40:55 +00:00
* tests/run_make_tests.pl (subst_make_string): Force use of /
On Windows the path to the helper tool will contain '\': this will fail if recipes are run with a POSIX shell. Convert '\' to '/' on Windows. While here, escape any spaces in the path as well.
This commit is contained in:
parent
3822f77c1d
commit
acbef3f612
1 changed files with 13 additions and 2 deletions
|
@ -220,7 +220,11 @@ sub valid_option
|
||||||
# [2] (string): Answer we should get back.
|
# [2] (string): Answer we should get back.
|
||||||
# [3] (integer): Exit code we expect. A missing code means 0 (success)
|
# [3] (integer): Exit code we expect. A missing code means 0 (success)
|
||||||
|
|
||||||
|
$makefile = undef;
|
||||||
$old_makefile = undef;
|
$old_makefile = undef;
|
||||||
|
$mkpath = undef;
|
||||||
|
$make_name = undef;
|
||||||
|
$helptool = undef;
|
||||||
|
|
||||||
sub subst_make_string
|
sub subst_make_string
|
||||||
{
|
{
|
||||||
|
@ -230,9 +234,8 @@ sub subst_make_string
|
||||||
s/#MAKE#/$make_name/g;
|
s/#MAKE#/$make_name/g;
|
||||||
s/#PERL#/$perl_name/g;
|
s/#PERL#/$perl_name/g;
|
||||||
s/#PWD#/$cwdpath/g;
|
s/#PWD#/$cwdpath/g;
|
||||||
my $help = File::Spec->catfile($fqsrcdir, 'tests', 'thelp.pl');
|
|
||||||
# If we're using a shell
|
# If we're using a shell
|
||||||
s/#HELPER#/$perl_name $help/g;
|
s/#HELPER#/$perl_name $helptool/g;
|
||||||
return $_;
|
return $_;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -615,6 +618,14 @@ sub set_more_defaults
|
||||||
$fqsrcdir = File::Spec->rel2abs($srcdir);
|
$fqsrcdir = File::Spec->rel2abs($srcdir);
|
||||||
$fqblddir = File::Spec->rel2abs($blddir);
|
$fqblddir = File::Spec->rel2abs($blddir);
|
||||||
|
|
||||||
|
# Find the helper tool
|
||||||
|
$helptool = File::Spec->catfile($fqsrcdir, 'tests', 'thelp.pl');
|
||||||
|
|
||||||
|
# It's difficult to quote this properly in all the places it's used so
|
||||||
|
# ensure it doesn't need to be quoted.
|
||||||
|
$helptool =~ s,\\,/,g if $port_type = 'W32';
|
||||||
|
$helptool =~ s, ,\\ ,g;
|
||||||
|
|
||||||
# Get Purify log info--if any.
|
# Get Purify log info--if any.
|
||||||
|
|
||||||
if (exists $ENV{PURIFYOPTIONS}
|
if (exists $ENV{PURIFYOPTIONS}
|
||||||
|
|
Loading…
Reference in a new issue