-
-
Notifications
You must be signed in to change notification settings - Fork 198
VCRUNTIME140_1.dll was not found 1.9.1 #743
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
Comments
You suspect that this will not work with newer version of windows? It might be related to #713 that we drop something that is required to run everywhere, need to look into that. |
To work around this problem in the portable version of windows 10, I manually add these two dll's in the ksnip directory:
That's how it works for me |
But that's not good to have to add some dlls manually, we should deliver what we need to run, though this will increase the package size by factor of 2 I think. |
I'm not sure, but I think the microsoft dll's cannot be attached together with the program, you need to send a VCRedist_x64.exe installer with the program. But that doesn't make sense in a portable version, where the Windows user is not allowed to install programs. https://docs.microsoft.com/en-us/cpp/windows/determining-which-dlls-to-redistribute?view=msvc-160 |
Just triggered a build with changed flags for windeployqt, which does the packaging for windows. Can someone test the package in 20min or so. @antrrax if I recall correctly without this flag you get vc_redist.x64.exe packaged. |
I did the test here on a virtual machine. Without installing vc_redist.x64.exe it will give error with as dll's. But installing the vc_redist.x64.exe included in the package, Ksnip worked correctly. However, when these microsoft dll's are required, the distribution of the program is no longer portable. Since users without administrator permission will not be able to install vc_redist.x64.exe |
Nah, I don't like it that there must be something installed additionally. Is this also affecting the msi package or just the portable? |
I did the test with ksnip version .zip (Continuous build) |
Now I tested the msi version of ksnip (Continuous build) on windows 10 and 11 in a virtual machine. In both cases the .msi installer does not automatically install vc_redist.exe Then the dll error appears when running ksnip Windows 11 Pro x64 Windows 10 Pro x64 |
@antrrax can you check if this was an issue with |
I tested several previous versions of ksnip and they didn't work. The problem is that 'Microsoft Visual C++ 2015-2019 Redistributable' (vcredist) is not a native Windows component. So you would need to add code in the installer to check if vcredist is already present otherwise, first install vcredist and then install ksnip. How to: Install Prerequisites in Windows Installer Deployment I'm not sure, but apparently msi doesn't have this pre-installation function: See the example of the sketchup 2017: If you unzip the file 'sketchupmake-2017-2-2555-90783-en-us-x64.exe' you will see SketchUp2017-x64.msi and the prerequisite files |
Maybe use Notes: cmake: MSVC_RUNTIME_LIBRARY or use CL env. |
Where are we using those flags? |
Sorry, I mean "Maybe use -MT instead -MD". cl.exe use cmake hide executed commands, but you can enable verbose logging But first of all we need to check how binary deps (openssl and others) are build... |
OK, I recompile ksnip with some modifications (cmake build flags) and my version not references to Qt (in ksnip case) installed via aqtinstall as binary. Next I'll try to use static qt build.... |
@dafanasiev Thanks for looking into this, and yes, it's expected to be referenced by Qt as Qt is the one who needs it. But anyways, I think we need to package |
Many apps on Github, the devs do only for Windows a Portable. Perhaps you figure out the msi reasoning, then retire the msi. Nothing wrong being all Portable. |
I would like to keep the msi, it's a signed package that can be installed automatically, especially for companies relevant. |
Can someone test again? I've now added the two missing dlls directly to the zip package, does that fix the issue? |
Nevermind, it doesn't work with those two, either the dlls are wrong or it doesn't work like that in general. Let me try something else. |
Ok, now the runtime is in the package, can you please test again? |
Windows 11, virtual machine msi version, displayed these dll error messages in sequence: MSVCP140.dll zip version didn't work either |
I've added only |
Windows 11, virtual machine on another PC that I don't have access to at the moment, I just add these 2 dll's in version 1.91(zip) and that's enough: |
Let's try adding just |
Ok, triggered a new build with the two |
Ok, it's all in there now. |
Windows 11, virtual machine zip - Presented the following error: msi - same 4 dlls error messages -- Tomorrow I do a test with the dlls I have on another PC and they already work on version 1.91 |
Strange, ok, let me know what you have found out. |
Windows 10 I think there is some conflict with your dll's. |
I didn't find |
Can you test again? |
Add e new version, now with additionally the files without _1. Let's try that again. |
I tested the zip version In virtual machine, now works on both windows 10 and windows 11 |
Very good. I'm just wondering a bit that user @carloscadux reported that the MSI package is now working properly too but I haven't done anything there yet, can someone check the MSI package quickly before I copy the dlls there too? |
I tested the msi version On a virtual machine with windows 10, it still didn't work |
Thanks, I'll try to add those missing files to the MSI next. I'll let you know when I've added them. |
Actually, just tested build 1-8c5c3ae. Because of the dll issue it is not working in a clean install of Windows 10. |
No worries, all good. I'll add the dlls then it should be working. Just need to find few spare minutes to do the change. |
Ok, it's now in the ZIP and MSI package, I think it should work everywhere now. |
ZIP and MSI package are working now on a clean installation of Windows 10. |
Finally, then I'm closing this issue and wrapping up |
Attempting to open 1.9.1 Windows Portable, for me fails with: VCRUNTIME140_1.dll was not found.

I held back reporting, due to 1.9.0 W P working & my decision choice for running safely one Windows version behind; 20H2 instead of 21H1.
Today I was expecting Windows 10 21H2 to be released a week after Patch Tuesday, did not happen.
Due to users choosing multiple versions & Windows 11, I chose to inform you, first so you know;
then can determine what happened, choose to fix for compatibility for all, or just notate in release notes.
https://www.bleepingcomputer.com/tutorials/fix-missing-vcruntime140dll-dll-error-in-windows/
VCRUNTIME is on the user for running an older Visual C++ 2015 Redistributable.
But my situation I have 2017, not 2015. Thnx, for a much appreciated excellent program for Windows Portable & Mac.
The text was updated successfully, but these errors were encountered: