-1

I have app which I think needs Microsoft c++ libraries. This app makes a proxy, and probably uses proxy jobs module ( C ). I need to add only this proxy jobs module or files make this work, without installing Microsoft Visual C++ 2008 Redistributable Package (x86), because application needs to be open as a "Guest" without admin rights, and I can' instal that package. Anyone have solution for this problem? I was trying to find only the proxy jobs module but without success. When I try to run this app I get an error: Can't run this application because configuration is incorrect.

pb2q
  • 58,613
  • 19
  • 146
  • 147
  • Try to link CRT statically to the program: http://stackoverflow.com/questions/37398/how-do-i-make-a-fully-statically-linked-exe-with-visual-studio-express-2005 – Nemanja Boric Apr 04 '13 at 14:34

2 Answers2

0

Use static linking for the runtime library. In Visual Studio 2010 (should be similar in other versions), go to this configuration setting:

Project properties > Configuration Properties > C/C++ > Code Generation > Runtime Library.

For the Debug configuration, change it to Multi-threaded Debug (/MTd) and for Release, change it to Multi-threaded (/MT).

All projects and dependencies which make up your final executable will need to be compiled with the /MT option for this to work.

JBentley
  • 6,099
  • 5
  • 37
  • 72
  • But, my program is wroten in Delphi, and in resourcures i have this proxy.exe which is compiled i only unpack it, and run by CreateProcess with parameters, i need another solution – user2245316 Apr 04 '13 at 14:55
  • 1
    @user2245316 You have C++ in the question title, and in the tags, and you haven't mentioned Delphi anywhere. Please post accurate questions. – JBentley Apr 04 '13 at 14:55
  • @user2245316 If you're dealing with a pre-compiled executable for which you have no source code, then you are stuck with what you have. You could simply supply the relevant .DLL files in the same folder as the executable (to avoid the need for the redistributable to be installed), however there may be licensing issues with this. – JBentley Apr 04 '13 at 14:58
  • but where i can find these dll's? according to network, proxy, – user2245316 Apr 04 '13 at 15:15
  • @user2245316 What do you mean, "according to network, proxy"? Try something like [Dependency Walker](http://www.dependencywalker.com/) to find out what files you need, then copy them from the relevant redistributable on your dev machine, or alternatively, just copy everything from the redistributable (but again, be aware of potential licensing issues). – JBentley Apr 04 '13 at 17:13
  • How to extract and explore Microsoft Visual C++ 2008 Redistributable Package (x86) ? – user2245316 Apr 04 '13 at 17:55
  • @user2245316 See [here](http://msdn.microsoft.com/en-gb/library/vstudio/ms235299.aspx) for an explanation of how to deploy files (note that they mention placing the DLLs directly in the application folder, which is what I suggested), and [here](http://msdn.microsoft.com/en-gb/library/vstudio/8kche8ah.aspx) to work out which files to deploy. – JBentley Apr 04 '13 at 18:43
0

I checked by tasklist command: tasklist /m /fi "IMAGENAME eq applicationame.exe" >C:/result.txt

I got result file: ntdll.dll, wow64.dll, wow64win.dll, wow64cpu.dll
So these dll's dosent exists in http://msdn.microsoft.com/en-gb/library/vstudio/8kche8ah.aspx and i think they're included in Windows Os, so any another idea why on another xp i got this error?