Permalink
Browse files

Get Configure to work on Win32. open seems not to return false if $ex…

…e doesn't exist, this works around it somewhat. Cleaner solutions welcome, but this works.
  • Loading branch information...
jnthn committed Feb 10, 2009
1 parent 196ea50 commit f202f7fbfd8cd7efe5833413307b2e40ed23adec
Showing with 5 additions and 2 deletions.
  1. +5 −2 Configure.pl
View
@@ -21,6 +21,9 @@
exit(0);
}
# Work out slash character to use.
my $slash = $^O eq 'MSWin32' ? '\\' : '/';
# If we're in a Parrot build tree and --parrot-config isn't
# specified, use the build tree's reconfigure.pl and exit.
# if (!$options{'parrot-config'} && -e "../../tools/dev/reconfigure.pl") {
@@ -33,7 +36,7 @@
# Get a list of parrot-configs to invoke.
my @parrot_config_exe =
qw(parrot/parrot_config parrot_config ../../parrot_config);
("parrot${slash}parrot_config", "parrot_config", "..${slash}..${slash}parrot_config.exe");
if ($options{'parrot-config'} && $options{'parrot-config'} ne '1') {
@parrot_config_exe = ($options{'parrot-config'});
}
@@ -79,7 +82,7 @@ sub read_parrot_config {
if (/(\w+) => '(.*)'/) { $config{$1} = $2 }
}
close $PARROT_CONFIG;
last;
last if %config;
}
}
%config;

0 comments on commit f202f7f

Please sign in to comment.