问题
I've been trying desperately to get my application (15 C# dlls and 1 C++/CLI dll with C++ Runtime DLL dependencies) to deploy with ClickOnce. I got it to work by just copying the Release folder, but ClickOnce refuses to copy the files (msvcm80.dll, msvcp80.dll and msvcr80.dll) and deploy them in this folder.
I did this nutty workaround (supply msvcm80.dll, msvcp80.dll and msvcr80.dll as Content/Copy If Newer and then at startup, create the Microsoft.VC80.CRT folder, copy those DLLs, and create Microsoft.VC80.CRT.manifest) that seems to work, but this all just feels wrong to me.
Am I missing something?
回答1:
I'm stupid: I just found this:
On Publish tab of Properties page of my startup project: click Prerequisites... button > check Visual C++ Runtime Libraries, radio button setting: Download prerequisites from the component vendor's web site.
It seems to work the way one might expect!
回答2:
There should be a msi from microsoft that deploys those for you. I used....
instructions
and download vcredist_x86.exedownload
来源:https://stackoverflow.com/questions/213957/clickonce-getting-msvcrt-c-dlls-on-users-machine