summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2012-07-24 17:06:21 +0200
committerStephan Bergmann <sbergman@redhat.com>2012-07-24 17:06:21 +0200
commit6cfe3c93dc55264e57f1057a2911d54232353d13 (patch)
treeba7edaf8aad1e1875a23b3f3eda59cdda73c2541
parentf0460881e7a60d2852d6314991cd3627623d6be8 (diff)
Make bundling Microsoft_VC100_CRT_x86.msm truly optional
Change-Id: I4fa998f33059a6ebc9afe0a9ce65443a115b6db2
-rw-r--r--configure.in9
-rwxr-xr-xoowintool11
-rw-r--r--scp2/source/ooo/vc_redist.scp8
3 files changed, 22 insertions, 6 deletions
diff --git a/configure.in b/configure.in
index ddbb22f1b1f0..6e1ffe51b84d 100644
--- a/configure.in
+++ b/configure.in
@@ -5135,9 +5135,14 @@ fi
AC_SUBST([JITC_PROCESSOR_TYPE])
if test $_os = "WINNT"; then
- SCPDEFS="$SCPDEFS -DWITH_VC_REDIST"
+ AC_MSG_CHECKING([for Microsoft_VC100_CRT_x86.msm])
+ if ./oowintool --msvc-find-msms-vc100; then
+ AC_MSG_RESULT([yes])
+ SCPDEFS="$SCPDEFS -DWITH_VC100_REDIST"
+ else
+ AC_MSG_RESULT([no])
+ fi
fi
-AC_SUBST(WITH_VC_REDIST)
dnl ===================================================================
dnl Checks for Java
diff --git a/oowintool b/oowintool
index 087d478d3bff..9afc1cd40e93 100755
--- a/oowintool
+++ b/oowintool
@@ -47,6 +47,8 @@ sub print_syntax()
print " commands:\n";
print " --msvc-ver - print version of MSVC eg. 6.0\n";
print " --msvc-copy-dlls <dest> - copy msvc[pr]??.dlls into <dest>/msvcp??/\n";
+ print " --msvc-find-msms-vc100 - exit with 0 if Microsoft_VC100_CRT_x86.msm\n";
+ print " is available\n";
print " --msvc-copy-msms <dest> - copy mscrt merge modules to <dest>/msm90/\n";
print " --msvc-copy-msms-64 <ds>- copy the x64 mscrt merge modules to <ds>/msm90/\n";
print " --msvc-productdir - print productdir\n";
@@ -271,6 +273,13 @@ sub msvc_copy_dlls($)
}
}
+sub msvc_find_msms_vc100()
+{
+ 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";
+ return -e "$msm_path/Microsoft_VC100_CRT_x86.msm" ? 0 : 1;
+}
+
sub msvc_copy_msms($$)
{
# $postfix is empty for x86, and '_x64' for x64
@@ -318,6 +327,8 @@ while (@commands) {
my $dest = shift @commands;
defined $dest || die "copy-dlls requires a destination directory";
msvc_copy_dlls( $dest );
+ } elsif ($opt eq '--msvc-find-msms-vc100') {
+ exit msvc_find_msms_vc100();
} elsif ($opt eq '--msvc-copy-msms') {
my $dest = shift @commands;
defined $dest || die "copy-msms requires a destination directory";
diff --git a/scp2/source/ooo/vc_redist.scp b/scp2/source/ooo/vc_redist.scp
index 265a59567fa1..c0e53020d1f9 100644
--- a/scp2/source/ooo/vc_redist.scp
+++ b/scp2/source/ooo/vc_redist.scp
@@ -27,8 +27,6 @@
#include "macros.inc"
-#if defined(WITH_VC_REDIST)
-
MergeModule gid_MergeModule_Microsoft_VC90_CRT_x86
Feature = gm_Root;
Name = "Microsoft_VC90_CRT_x86.msm";
@@ -36,6 +34,8 @@ MergeModule gid_MergeModule_Microsoft_VC90_CRT_x86
ComponentCondition = "VC_REDIST=1";
End
+#if defined(WITH_VC100_REDIST)
+
MergeModule gid_MergeModule_Microsoft_VC100_CRT_x86
Feature = gm_Root;
Name = "Microsoft_VC100_CRT_x86.msm";
@@ -43,6 +43,8 @@ MergeModule gid_MergeModule_Microsoft_VC100_CRT_x86
ComponentCondition = "VC_REDIST=1";
End
+#endif
+
MergeModule gid_MergeModule_policy_9_0_Microsoft_VC90_CRT_x86
Feature = gm_Root;
Name = "policy_9_0_Microsoft_VC90_CRT_x86.msm";
@@ -67,5 +69,3 @@ MergeModule gid_MergeModule_policy_9_0_Microsoft_VC90_CRT_x86_x64
End
#endif
-
-#endif