diff options
author | Andras Timar <atimar@suse.com> | 2012-04-24 09:24:49 +0200 |
---|---|---|
committer | Andras Timar <atimar@suse.com> | 2012-04-24 09:38:35 +0200 |
commit | 1f9b45377039f5839f8ee4dde265a297ec146062 (patch) | |
tree | f01cd2a4e6f1e4e4391d62ff543fc509074ca0ec /oowintool | |
parent | 858646a5eb5eae8703cfb64cd1cdbc553699a224 (diff) |
fdo#48259 take MSMDir from registry
Diffstat (limited to 'oowintool')
-rwxr-xr-x | oowintool | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/oowintool b/oowintool index 06e6607aeabb..3b8d76311f49 100755 --- a/oowintool +++ b/oowintool @@ -274,17 +274,9 @@ sub msvc_copy_msms($$) { # $postfix is empty for x86, and '_x64' for x64 my ($dest, $postfix) = @_; - my $common_files_path = $ENV{"CommonProgramFiles(x86)"}; - if (!defined $common_files_path) { - $common_files_path = $ENV{CommonProgramFiles}; - if (!defined $common_files_path) { - $common_files_path = "C:\\Program Files\\Common Files"; - } - } - - defined $common_files_path || die "Windows CommonProgramFiles not found"; - my $msm_path = (cygpath $common_files_path . "\\Merge Modules", 'w', $output_format); + 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") { print STDERR "Copying $msm_path/$fname to $dest\n"; copy ("$msm_path/$fname", $dest) || die "copy failed: $!"; |