Skip to content

vcrun2017/2019/2022: fix msvcp140_2.dll not being replaced on Wine 11+#2495

Open
SurenIV wants to merge 1 commit intoWinetricks:masterfrom
SurenIV:fix/vcrun2022-msvcp140_2
Open

vcrun2017/2019/2022: fix msvcp140_2.dll not being replaced on Wine 11+#2495
SurenIV wants to merge 1 commit intoWinetricks:masterfrom
SurenIV:fix/vcrun2022-msvcp140_2

Conversation

@SurenIV
Copy link
Copy Markdown
Contributor

@SurenIV SurenIV commented Mar 19, 2026

Wine 11+ ships builtin msvcp140_2.dll with a higher version number (14.50) than what vcredist provides (14.44). The Microsoft installer compares versions and refuses to downgrade, leaving the builtin in place instead of replacing it with the native DLL.

A workaround for msvcp140.dll already exists (see #2465), but msvcp140_2.dll has the same problem and is not being replaced.

This PR adds manual extraction of msvcp140_2.dll from the vcredist cabinet files for vcrun2017, vcrun2019, and vcrun2022, similar to what is already done for vcrun2026.

  • vcrun2017: extract msvcp140_2.dll alongside msvcp140.dll and ucrtbase.dll (both x86 and x64)
  • vcrun2019: extract msvcp140_2.dll alongside msvcp140.dll (both x86 and x64)
  • vcrun2022: switch from single-file extraction to full cab extraction and mv -f (as in vcrun2026), extracting both msvcp140.dll and msvcp140_2.dll

Related: #2464, #2465

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant