summaryrefslogtreecommitdiff
path: root/win
diff options
context:
space:
mode:
authorVladislav Vaintroub <wlad@mariadb.com>2019-06-27 19:33:25 +0200
committerVladislav Vaintroub <wlad@mariadb.com>2019-06-27 19:33:25 +0200
commit74a744b51f3cf9b6426b02074f6587bb01909a45 (patch)
treedc68fa6ecf40cafca86483643e2c32e65a288977 /win
parentb60aee58c7fda4c062f1c595ece7a076abd60e03 (diff)
downloadmariadb-git-74a744b51f3cf9b6426b02074f6587bb01909a45.tar.gz
Windows : Do not package redistributable C runtime , nor merge modules into Windows
installers Rely on Universal CRT to be on every computer we install.
Diffstat (limited to 'win')
-rw-r--r--win/packaging/CMakeLists.txt35
-rw-r--r--win/packaging/create_msi.cmake6
-rw-r--r--win/packaging/extra.wxs.in10
3 files changed, 1 insertions, 50 deletions
diff --git a/win/packaging/CMakeLists.txt b/win/packaging/CMakeLists.txt
index b4ff20b773d..1b8f7c8fc42 100644
--- a/win/packaging/CMakeLists.txt
+++ b/win/packaging/CMakeLists.txt
@@ -178,39 +178,6 @@ IF(CMAKE_GENERATOR MATCHES "Visual Studio")
SET(CONFIG_PARAM "-DCMAKE_INSTALL_CONFIG_NAME=${CMAKE_CFG_INTDIR}")
ENDIF()
-IF(MSVC_CRT_TYPE MATCHES "/MD")
- # Find out CRT merge module path, we're going to use it in installer
- # The path and name depends on VS version
- IF(MSVC_VERSION LESS 1900)
- # VS2015
- SET(VCREDIST_MSM_FILENAME Microsoft_VC140_CRT_${WIX_ARCH_SUFFIX}.msm)
- SET(ProgramFilesX86 "ProgramFiles(x86)")
- FIND_FILE(${VCREDIST_MSM_FILENAME}
- NO_DEFAULT_PATH
- PATHS
- "$ENV{${ProgramFilesX86}}/Common Files/Merge Modules"
- "$ENV{ProgramFiles}/Common Files/Merge Modules"
- )
- ELSEIF(MSVC_VERSION LESS 2000)
- # VS2017
- SET(VCREDIST_MSM_FILENAME Microsoft_VC141_CRT_${WIX_ARCH_SUFFIX}.msm)
- FILE(GLOB MSM_LIST "C:/Program Files*/Microsoft Visual Studio/2017/*/VC/Redist/MSVC/*/MergeModules/${VCREDIST_MSM_FILENAME}")
- LIST(LENGTH MSM_LIST LEN)
- IF(LEN GREATER 0)
- LIST(GET MSM_LIST 0 VCRedist_MSM)
- ENDIF()
- ELSE()
- # Post-VS2017. Needs to be ported when new VS is out
- MESSAGE(WARNING
- "Name of redistributable merge module not known for this version of MSVC")
- ENDIF()
- IF (NOT VCRedist_MSM)
- MESSAGE(WARNING "Can't find merge module ${VCREDIST_MSM_FILENAME}")
- ELSE()
- FILE(TO_NATIVE_PATH ${VCRedist_MSM} VCRedist_MSM)
- # MESSAGE("VCRedist_MSM=${VCRedist_MSM}")
- ENDIF()
-ENDIF()
ADD_CUSTOM_TARGET(
MSI
@@ -243,7 +210,7 @@ ADD_CUSTOM_TARGET(
-DWITH_THIRD_PARTY="${WITH_THIRD_PARTY}"
-DWIXCA_LOCATION="$<TARGET_FILE:wixca>"
-DMSVC_CRT_TYPE="${MSVC_CRT_TYPE}"
- -DVCRedist_MSM="${VCRedist_MSM}"
+ -DDYNAMIC_UCRT_LINK="${DYNAMIC_UCRT_LINK}"
-P ${CMAKE_CURRENT_SOURCE_DIR}/create_msi.cmake
)
ADD_DEPENDENCIES(MSI wixca)
diff --git a/win/packaging/create_msi.cmake b/win/packaging/create_msi.cmake
index ad935803a1e..7cb932390b5 100644
--- a/win/packaging/create_msi.cmake
+++ b/win/packaging/create_msi.cmake
@@ -59,12 +59,6 @@ IF(CMAKE_INSTALL_CONFIG_NAME)
SET(CONFIG_PARAM "-DCMAKE_INSTALL_CONFIG_NAME=${CMAKE_INSTALL_CONFIG_NAME}")
ENDIF()
-IF((MSVC_CRT_TYPE MATCHES "/MD") AND (NOT VCRedist_MSM))
- # Something was wrong, we package VC runtime merge modules
- # when compiled with dynamic C runtime.
- MESSAGE(FATAL_ERROR "Redistributable merge module was not found")
-ENDIF()
-
SET(COMPONENTS_ALL "${CPACK_COMPONENTS_ALL}")
FOREACH(comp ${COMPONENTS_ALL})
SET(ENV{DESTDIR} testinstall/${comp})
diff --git a/win/packaging/extra.wxs.in b/win/packaging/extra.wxs.in
index 1955799f6f9..183a691ac93 100644
--- a/win/packaging/extra.wxs.in
+++ b/win/packaging/extra.wxs.in
@@ -651,16 +651,6 @@
<?endif ?>
- <?if "@VCRedist_MSM@" != "" ?>
- <!-- VC runtime merge module -->
- <DirectoryRef Id="TARGETDIR">
- <Merge Id="VCRedist" SourceFile="@VCRedist_MSM@" DiskId="1" Language="0"/>
- </DirectoryRef>
- <Feature Id="VCRedist" Title="Visual C++ Runtime" AllowAdvertise="no" Display="hidden" Level="1">
- <MergeRef Id="VCRedist"/>
- </Feature>
- <?endif?>
-
<!-- Custom action, call mysql_install_db -->
<SetProperty Sequence='execute' Before='CreateDatabaseCommand' Id="SKIPNETWORKING" Value="--skip-networking" >SKIPNETWORKING</SetProperty>
<SetProperty Sequence='execute' Before='CreateDatabaseCommand' Id="ALLOWREMOTEROOTACCESS" Value="--allow-remote-root-access">ALLOWREMOTEROOTACCESS</SetProperty>