diff options
author | Steve Hay <SteveHay@planit.com> | 2006-12-12 18:02:19 +0000 |
---|---|---|
committer | Steve Hay <SteveHay@planit.com> | 2006-12-12 18:02:19 +0000 |
commit | d51fa99c5107c0415d86d56dbd39d3eeeb3412e4 (patch) | |
tree | e3713335f28beb9589bb7d27c6b661f6b7e2ea59 /win32/config_sh.PL | |
parent | 2fbd95182c64b8e753ad9c73dfca52cbf4473140 (diff) | |
download | perl-d51fa99c5107c0415d86d56dbd39d3eeeb3412e4.tar.gz |
Restore (differently) the setting of $Config{osvers} on Win32
that was removed by #29509
p4raw-id: //depot/perl@29533
Diffstat (limited to 'win32/config_sh.PL')
-rw-r--r-- | win32/config_sh.PL | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/win32/config_sh.PL b/win32/config_sh.PL index b4af906757..884db4a537 100644 --- a/win32/config_sh.PL +++ b/win32/config_sh.PL @@ -73,8 +73,13 @@ $opt{INST_VER} =~ s|~VERSION~|$opt{VERSION}|g; $opt{'version_patchlevel_string'} = "version $opt{PERL_VERSION} subversion $opt{PERL_SUBVERSION}"; $opt{'version_patchlevel_string'} .= " patchlevel $opt{PERL_PATCHLEVEL}" if exists $opt{PERL_PATCHLEVEL}; -#$opt{'osvers'} = join '.', (Win32::GetOSVersion())[1,2]; -$opt{'osvers'} = "4.0"; +my $ver = `ver 2>nul`; +if ($ver =~ /Version (\d+\.\d+)/) { + $opt{'osvers'} = $1; +} +else { + $opt{'osvers'} = '4.0'; +} if (exists $opt{cc}) { # cl and bcc32 version detection borrowed from Test::Smoke's configsmoke.pl |