Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Using SDL_image in Visual studio 2010, with error "application was unable to start correctly 0xc000007b"

I'm trying to do the SDL tutorial here http://lazyfoo.net/SDL_tutorials/lesson03/windows/msvsnet2010e/index.php

I did everything they asked me to do, everything built correctly, but when I tried to run the executable, I always get the error: "application was unable to start correctly 0xc000007b"

I'm using Win7 on a mac (bootcamp), with visual stdio 2010 professional

like image 257
Tony Stark Avatar asked Jan 27 '26 12:01

Tony Stark


2 Answers

If you have placed SDL.dll under C:\Windows\system32 or \SysWOW64 like the tutorial says, doing this may work:

Download SDL.dll (Runtime Libraries > Win32, not the 64-bit version*) and place it in the project folder where the .exe file is located.

E.g. if the project location is C:\myproject, place the SDL.dll at C:\myproject\Debug.

Then you can remove SDL.dll from \system32 or \SysWOW64. This can also prevent version conflicts, like the tutorial suggests.

*) I'm on 64-bit Windows 7, and the 64-bit version of SDL.dll didn't work for me.

like image 175
Matias Kinnunen Avatar answered Jan 29 '26 00:01

Matias Kinnunen


Ensure that the SDL.dll (or SDL2.dll) that the .exe loads (from its own directory, or from a Windows system directory) matches the SDL.lib that it was linked with. Examples:

  • The application was unable to start correctly (0xc000007b)
  • Dev IL linking and compiling error (0xc000007b)

This applies to any version of Visual Studio, 32 or 64 bit, and any of Lazyfoo's tutorials.

like image 37
Camille Goudeseune Avatar answered Jan 29 '26 00:01

Camille Goudeseune



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!