CRT Dependencies Detection - App Deployment
-
Hi, I'm using VS 2005 to create a win32 application. Now that i have my exe running i'd like to deploy my application and make it run on a dev-free environment. Does anyone have an idea how to detect the exe dependencies? Of course i've used the dependency walker and i've got a list of dlls that need to sit in the app dir beside my exe. But still, my exe won't run outside visual studio and i get "abnormal program termination". I'd highly appriciate your help. Thanks. Snir.
-
Hi, I'm using VS 2005 to create a win32 application. Now that i have my exe running i'd like to deploy my application and make it run on a dev-free environment. Does anyone have an idea how to detect the exe dependencies? Of course i've used the dependency walker and i've got a list of dlls that need to sit in the app dir beside my exe. But still, my exe won't run outside visual studio and i get "abnormal program termination". I'd highly appriciate your help. Thanks. Snir.
You have to execute vcredist_x86.exe on the target machine. This will install the C-runtime and MFC libraries on the target machine. You can download it from here[^] (scroll down if you have SP1 installed for visual studio). You need of course to distribute the release version of your programs.
Cédric Moonen Software developer
Charting control [v1.3] -
Hi, I'm using VS 2005 to create a win32 application. Now that i have my exe running i'd like to deploy my application and make it run on a dev-free environment. Does anyone have an idea how to detect the exe dependencies? Of course i've used the dependency walker and i've got a list of dlls that need to sit in the app dir beside my exe. But still, my exe won't run outside visual studio and i get "abnormal program termination". I'd highly appriciate your help. Thanks. Snir.
-
Hi, I'm using VS 2005 to create a win32 application. Now that i have my exe running i'd like to deploy my application and make it run on a dev-free environment. Does anyone have an idea how to detect the exe dependencies? Of course i've used the dependency walker and i've got a list of dlls that need to sit in the app dir beside my exe. But still, my exe won't run outside visual studio and i get "abnormal program termination". I'd highly appriciate your help. Thanks. Snir.
It doesn't sound like dependencies are your issue. If I were you I'd build a Release build of your project but switch Debugging information on (Program Database). Make sure your project has the path to the CRT source code ( You did install it with VS 2005 didn't you ) in it's includes. Run the release build and when it tries to quit on you attach the debugger and see if you can figure out what's going on. There are not that many possible causes for "abnormal program termination" on startup so you've got a reasonable chance of cracking it. Did you try to use the CRT file system during static initialization or try to allocate a negative or > 0x7FFFFFFF amount of heap memory? Those are the sorts of things that might silently fail in Debug but may blow you out of the sky in a Release build.
Nothing is exactly what it seems but everything with seems can be unpicked.
-
It doesn't sound like dependencies are your issue. If I were you I'd build a Release build of your project but switch Debugging information on (Program Database). Make sure your project has the path to the CRT source code ( You did install it with VS 2005 didn't you ) in it's includes. Run the release build and when it tries to quit on you attach the debugger and see if you can figure out what's going on. There are not that many possible causes for "abnormal program termination" on startup so you've got a reasonable chance of cracking it. Did you try to use the CRT file system during static initialization or try to allocate a negative or > 0x7FFFFFFF amount of heap memory? Those are the sorts of things that might silently fail in Debug but may blow you out of the sky in a Release build.
Nothing is exactly what it seems but everything with seems can be unpicked.
Thanks for your reply. My release version runs smoothly from within VS. Problems like those you describe would have prevented it from initializing properly even from within VS. Hence my guess that it has to do with the enveloping CRT environment. Running the exe from outside VS fails! Even on a computer that has a full VS installed. Snir.
-
Thanks for your reply. My release version runs smoothly from within VS. Problems like those you describe would have prevented it from initializing properly even from within VS. Hence my guess that it has to do with the enveloping CRT environment. Running the exe from outside VS fails! Even on a computer that has a full VS installed. Snir.
:confused: The normal expectation would be that running the Release build from within VS and running the Release build on a computer with VS installed are the same thing. You could always try the catchall solution of turning off incremental linking in your project settings and doing a full rebuild. The CRT environment is what's keeling over but that is essentially just a statically linked library or an implicitly linked Dll depending on your project settings ( Make sure if you have multiple modules that the CRT settings are consistent throughout ) Beyond that it's not to easy to get the old veteran that is MSVCRT.DLL to fail in such an arbitrary manner.
Nothing is exactly what it seems but everything with seems can be unpicked.