Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

vcrun2015/17/19/22: manually install msvcp140.dll #2313

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 36 additions & 10 deletions src/winetricks
Original file line number Diff line number Diff line change
Expand Up @@ -12873,9 +12873,11 @@ load_vcrun2015()
w_set_winver winxp
fi

# Setup will refuse to install ucrtbase because builtin's version number is higher, so manually replace it
# See https://bugs.winehq.org/show_bug.cgi?id=46317
w_try_cabextract --directory="${W_TMP}/win32" "${W_CACHE}"/vcrun2015/vc_redist.x86.exe -F 'a10'
# Setup will refuse to install msvcp140 & ucrtbase because builtin's version number is higher, so manually replace them
# See https://bugs.winehq.org/show_bug.cgi?id=46317 and
# https://bugs.winehq.org/show_bug.cgi?id=57518
w_try_cabextract --directory="${W_TMP}/win32" "${W_CACHE}"/"${W_PACKAGE}"/vc_redist.x86.exe -F 'a10'
w_try_cabextract --directory="${W_SYSTEM32_DLLS}" "${W_TMP}/win32/a10" -F 'msvcp140.dll'
w_try_cabextract --directory="${W_SYSTEM32_DLLS}" "${W_TMP}/win32/a10" -F 'ucrtbase.dll'

w_try_cd "${W_CACHE}"/"${W_PACKAGE}"
Expand All @@ -12886,8 +12888,9 @@ load_vcrun2015()
# Also install the 64-bit version
# 2022/09/16: d7257265dbc0635c96dd67ddf938a09abe0866cb2d4fa05f8b758c8644e724e4
w_download https://download.microsoft.com/download/6/D/F/6DF3FF94-F7F9-4F0B-838C-A328D1A7D0EE/vc_redist.x64.exe d7257265dbc0635c96dd67ddf938a09abe0866cb2d4fa05f8b758c8644e724e4
# Also replace 64-bit ucrtbase.dll
w_try_cabextract --directory="${W_TMP}/win64" "${W_CACHE}"/vcrun2015/vc_redist.x64.exe -F 'a10'
# Also replace 64-bit msvcp140.dll & ucrtbase.dll
w_try_cabextract --directory="${W_TMP}/win64" "${W_CACHE}"/"${W_PACKAGE}"/vc_redist.x64.exe -F 'a10'
w_try_cabextract --directory="${W_SYSTEM64_DLLS}" "${W_TMP}/win32/a10" -F 'msvcp140.dll'
w_try_cabextract --directory="${W_SYSTEM64_DLLS}" "${W_TMP}/win64/a10" -F 'ucrtbase.dll'
w_try_ms_installer "${WINE}" vc_redist.x64.exe ${W_OPT_UNATTENDED:+/q}
;;
Expand Down Expand Up @@ -12956,9 +12959,11 @@ load_vcrun2017()
w_set_winver winxp
fi

# Setup will refuse to install ucrtbase because builtin's version number is higher, so manually replace it
# See https://bugs.winehq.org/show_bug.cgi?id=46317
w_try_cabextract --directory="${W_TMP}/win32" "${W_CACHE}"/vcrun2017/vc_redist.x86.exe -F 'a10'
# Setup will refuse to install msvcp140 & ucrtbase because builtin's version number is higher, so manually replace them
# See https://bugs.winehq.org/show_bug.cgi?id=46317 and
# https://bugs.winehq.org/show_bug.cgi?id=57518
w_try_cabextract --directory="${W_TMP}/win32" "${W_CACHE}"/"${W_PACKAGE}"/vc_redist.x86.exe -F 'a10'
w_try_cabextract --directory="${W_SYSTEM32_DLLS}" "${W_TMP}/win32/a10" -F 'msvcp140.dll'
w_try_cabextract --directory="${W_SYSTEM32_DLLS}" "${W_TMP}/win32/a10" -F 'ucrtbase.dll'

w_try_cd "${W_CACHE}/${W_PACKAGE}"
Expand All @@ -12973,8 +12978,9 @@ load_vcrun2017()
# 2019/08/14: 5b0cbb977f2f5253b1ebe5c9d30edbda35dbd68fb70de7af5faac6423db575b5
# 2024/10/17: 7cf24eba2bd67ea6229b7dd131e06f4e92ebefc06e36fe401cdd227d7ed78264
w_download https://aka.ms/vs/15/release/vc_redist.x64.exe 7cf24eba2bd67ea6229b7dd131e06f4e92ebefc06e36fe401cdd227d7ed78264
# Also replace 64-bit ucrtbase.dll
w_try_cabextract --directory="${W_TMP}/win64" "${W_CACHE}"/vcrun2017/vc_redist.x64.exe -F 'a10'
# Also replace 64-bit msvcp140.dll & ucrtbase.dll
w_try_cabextract --directory="${W_TMP}/win64" "${W_CACHE}"/"${W_PACKAGE}"/vc_redist.x64.exe -F 'a10'
w_try_cabextract --directory="${W_SYSTEM64_DLLS}" "${W_TMP}/win64/a10" -F 'msvcp140.dll'
w_try_cabextract --directory="${W_SYSTEM64_DLLS}" "${W_TMP}/win64/a10" -F 'ucrtbase.dll'
w_try_ms_installer "${WINE}" vc_redist.x64.exe ${W_OPT_UNATTENDED:+/q}
;;
Expand Down Expand Up @@ -13022,6 +13028,11 @@ load_vcrun2019()
w_set_winver winxp
fi

# Setup will refuse to install msvcp140 because the builtin's version number is higher, so manually replace it
# See https://bugs.winehq.org/show_bug.cgi?id=57518
w_try_cabextract --directory="${W_TMP}/win32" "${W_CACHE}"/"${W_PACKAGE}"/vc_redist.x86.exe -F 'a10'
w_try_cabextract --directory="${W_SYSTEM32_DLLS}" "${W_TMP}/win32/a10" -F 'msvcp140.dll'

w_try_cd "${W_CACHE}"/"${W_PACKAGE}"
w_try_ms_installer "${WINE}" vc_redist.x86.exe ${W_OPT_UNATTENDED:+/q}

Expand Down Expand Up @@ -13049,6 +13060,11 @@ load_vcrun2019()
w_override_dlls native,builtin vcruntime140_1

w_download https://aka.ms/vs/16/release/vc_redist.x64.exe 5d9999036f2b3a930f83b7fe3e2186b12e79ae7c007d538f52e3582e986a37c3

# Also replace 64-bit msvcp140.dll
w_try_cabextract --directory="${W_TMP}/win64" "${W_CACHE}"/"${W_PACKAGE}"/vc_redist.x64.exe -F 'a11'
w_try_cabextract --directory="${W_SYSTEM64_DLLS}" "${W_TMP}/win64/a11" -F 'msvcp140.dll'

w_try_ms_installer "${WINE}" vc_redist.x64.exe ${W_OPT_UNATTENDED:+/q}
;;
esac
Expand Down Expand Up @@ -13116,6 +13132,11 @@ load_vcrun2022()

w_download https://aka.ms/vs/17/release/vc_redist.x86.exe dd1a8be03398367745a87a5e35bebdab00fdad080cf42af0c3f20802d08c25d4

# Setup will refuse to install msvcp140 because the builtin's version number is higher, so manually replace it
# See https://bugs.winehq.org/show_bug.cgi?id=57518
w_try_cabextract --directory="${W_TMP}/win32" "${W_CACHE}"/"${W_PACKAGE}"/vc_redist.x86.exe -F 'a10'
w_try_cabextract --directory="${W_SYSTEM32_DLLS}" "${W_TMP}/win32/a10" -F 'msvcp140.dll'

w_try_cd "${W_CACHE}"/"${W_PACKAGE}"
w_try_ms_installer "${WINE}" vc_redist.x86.exe ${W_OPT_UNATTENDED:+/q}

Expand All @@ -13134,6 +13155,11 @@ load_vcrun2022()
w_override_dlls native,builtin vcruntime140_1

w_download https://aka.ms/vs/17/release/vc_redist.x64.exe 1821577409c35b2b9505ac833e246376cc68a8262972100444010b57226f0940

# Also replace 64-bit msvcp140.dll
w_try_cabextract --directory="${W_TMP}/win64" "${W_CACHE}"/"${W_PACKAGE}"/vc_redist.x64.exe -F 'a11'
w_try_cabextract --directory="${W_SYSTEM64_DLLS}" "${W_TMP}/win64/a11" -F 'msvcp140.dll'

w_try_ms_installer "${WINE}" vc_redist.x64.exe ${W_OPT_UNATTENDED:+/q}
;;
esac
Expand Down
Loading