summaryrefslogtreecommitdiff
path: root/oowintool
diff options
context:
space:
mode:
authorNorbert Thiebaud <nthiebaud@gmail.com>2012-07-19 07:38:31 -0500
committerNorbert Thiebaud <nthiebaud@gmail.com>2012-07-19 07:38:31 -0500
commit238eba337cedda17a9ed1ce7e91755c66446195a (patch)
tree9755a9d8f2d2cd01086bb833cec52c1cd3e28ba6 /oowintool
parent859018061956b1937c7be3809a9858cbd610fa9c (diff)
make the vc2010 redist optional
Change-Id: Ib81f168fa65d7a4affb15ce07f1a49ad1b2df479
Diffstat (limited to 'oowintool')
-rwxr-xr-xoowintool23
1 files changed, 14 insertions, 9 deletions
diff --git a/oowintool b/oowintool
index fbc647dcb2a8..087d478d3bff 100755
--- a/oowintool
+++ b/oowintool
@@ -1,4 +1,5 @@
-#!/usr/bin/perl -w # -*- tab-width: 4; cperl-indent-level: 4; indent-tabs-mode: nil -*-
+#!/usr/bin/perl -w
+# -*- tab-width: 4; cperl-indent-level: 4; indent-tabs-mode: nil -*-
use File::Copy;
@@ -40,7 +41,7 @@ sub reg_find_key($)
sub print_syntax()
{
print "oowintool [option] ...\n";
- print " encoding options\n";
+ print " encoding options\n";
print " -w - windows form\n";
print " -u - unix form (default)\n";
print " commands:\n";
@@ -69,7 +70,7 @@ sub cygpath($$$)
$path =~ s|\\*\s*$||;
}
- # 'Unterminated quoted string errors' from 'ash' when
+ # 'Unterminated quoted string errors' from 'ash' when
# forking cygpath so - reimplement cygpath in perl [ gack ]
if ($format eq 'u' && $input_format eq 'w') {
$path =~ s|\\|/|g;
@@ -206,7 +207,7 @@ sub print_csc_compiler_dir()
sub print_dotnetsdk_dir()
{
- my $dir =
+ my $dir =
reg_get_value ("HKEY_LOCAL_MACHINE/SOFTWARE/Microsoft/.NETFramework/sdkInstallRootv1.1") ||
reg_get_value ("HKEY_LOCAL_MACHINE/SOFTWARE/Microsoft/.NETFramework/sdkInstallRootv2.0");
if ($dir) {
@@ -222,7 +223,7 @@ sub print_jdk_dir()
reg_get_value ("HKEY_LOCAL_MACHINE/SOFTWARE/JavaSoft/Java\ Development\ Kit/1.5/JavaHome") ||
reg_get_value ("HKEY_LOCAL_MACHINE/SOFTWARE/JavaSoft/Java\ Development\ Kit/1.4/JavaHome") ||
reg_get_value ("HKEY_LOCAL_MACHINE/SOFTWARE/JavaSoft/Java\ Development\ Kit/1.3/JavaHome");
- print cygpath($dir, 'w', $output_format);
+ print cygpath($dir, 'w', $output_format);
}
sub copy_dll($$$)
@@ -241,11 +242,11 @@ sub msvc_find_version($)
{
my $checkpath = shift;
my $ver = find_msvc();
- my $srcdir = (cygpath ($ver->{'product_dir'}, 'w', 'u') . '/' .
+ my $srcdir = (cygpath ($ver->{'product_dir'}, 'w', 'u') . '/' .
$ver->{$checkpath});
-d $srcdir && return $ver;
$ver = find_msvs();
- $srcdir = (cygpath ($ver->{'product_dir'}, 'w', 'u') . '/' .
+ $srcdir = (cygpath ($ver->{'product_dir'}, 'w', 'u') . '/' .
$ver->{$checkpath});
-d $srcdir && return $ver;
return undef;
@@ -256,7 +257,7 @@ sub msvc_copy_dlls($)
my $dest = shift;
my $ver = msvc_find_version('dll_path');
defined $ver || return;
- my $srcdir = (cygpath ($ver->{'product_dir'}, 'w', 'u') . '/' .
+ my $srcdir = (cygpath ($ver->{'product_dir'}, 'w', 'u') . '/' .
$ver->{'dll_path'});
copy_dll ($srcdir, "msvcp" . $ver->{'dll_suffix'} . ".dll",
@@ -280,10 +281,14 @@ sub msvc_copy_msms($$)
my $msm_path = (cygpath reg_get_value ("HKEY_LOCAL_MACHINE/SOFTWARE/Microsoft/VisualStudio/9.0/Setup/VS/MSMDir"), 'w', $output_format);
defined $msm_path || die "MSMDir not found";
- foreach $fname ("Microsoft_VC90_CRT_x86$postfix.msm", "policy_9_0_Microsoft_VC90_CRT_x86$postfix.msm", "Microsoft_VC100_CRT_x86$postfix.msm") {
+ foreach $fname ("Microsoft_VC90_CRT_x86$postfix.msm", "policy_9_0_Microsoft_VC90_CRT_x86$postfix.msm") {
print STDERR "Copying $msm_path/$fname to $dest\n";
copy ("$msm_path/$fname", $dest) || die "copy failed: $!";
}
+ foreach $fname ("Microsoft_VC100_CRT_x86$postfix.msm") {
+ print STDERR "Copying $msm_path/$fname to $dest\n";
+ copy ("$msm_path/$fname", $dest) || print "copy failed: $!";
+ }
}
if (!@ARGV) {