[svn:parrot] r35927 - trunk/config/init

[email protected] Fri, 23 Jan 2009 14:12:35 -0800 (PST)
Newsgroups perl.cvs.parrot
Message-ID <[email protected]>
Author: rurban
Date: Fri Jan 23 14:12:34 2009
New Revision: 35927

Modified:
   trunk/config/init/install.pm

Log:
Fix #166 Install path on Win32

make "C:/Parrot" the default win32 prefix
- This is 1. analog to ActivePerl, strawberry and vanilla perl,
- and 2. it is technically hard to get the ${PROGRAMFILES} path 
  if undefined, and without perl libwin32.



Modified: trunk/config/init/install.pm
==============================================================================
--- trunk/config/init/install.pm	(original)
+++ trunk/config/init/install.pm	Fri Jan 23 14:12:34 2009
@@ -29,7 +29,7 @@
 sub runstep {
     my ( $self, $conf ) = @_;
 
-    my $prefix = $conf->options->get('prefix') || "/usr/local";
+    my $prefix = $conf->options->get('prefix') || ($^O eq 'MSWin32' ? "C:/Parrot" : "/usr/local");
     $prefix =~ s{/\z}{};
     my $ep = $conf->options->get('exec-prefix');
     $ep =~ s{/\z}{} if defined $ep;