X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=win32%2Fconfig_sh.PL;h=0e1d351c1a8d1853db01fac340c026f695eb9890;hb=d722968f91639a851375cb3aeb7df128909c0779;hp=b1c7b9f59295b01d4d5717486fecdbecfc0a7430;hpb=7a958ec31151f9d03a26dcab8abdf5c57315dc96;p=p5sagit%2Fp5-mst-13.2.git diff --git a/win32/config_sh.PL b/win32/config_sh.PL index b1c7b9f..0e1d351 100644 --- a/win32/config_sh.PL +++ b/win32/config_sh.PL @@ -42,8 +42,6 @@ while (@{$optref} && $optref->[0] =~ /^([\w_]+)=(.*)$/) { my $pl_h = '../patchlevel.h'; -$opt{VERSION} = $]; -$opt{INST_VER} =~ s|~VERSION~|$]|g; if (-e $pl_h) { open PL, "<$pl_h" or die "Can't open $pl_h: $!"; while () { @@ -53,17 +51,11 @@ if (-e $pl_h) { } close PL; } -elsif ($] =~ /^(\d+)\.(\d\d\d)?(\d\d)?$/) { # should always be true - $opt{PERL_REVISION} = $1; - $opt{PERL_VERSION} = int($2 || 0); - $opt{PERL_SUBVERSION} = $3; - $opt{PERL_APIVERSION} = $]; -} else { - die "Can't parse perl version ($])"; + die "Can't find $pl_h: $!"; } - -$opt{PERL_SUBVERSION} ||= '00'; +$opt{VERSION} = "$opt{PERL_REVISION}.$opt{PERL_VERSION}.$opt{PERL_SUBVERSION}"; +$opt{INST_VER} =~ s|~VERSION~|$opt{VERSION}|g; $opt{'cf_by'} = $ENV{USERNAME} unless $opt{'cf_by'}; $opt{'cf_email'} = $opt{'cf_by'} . '@' . (gethostbyname('localhost'))[0]