   Struggling Setting up SDL
  I have installed Visual C++ 2008 Express Edition. That works fine for me.I downloaded this: http://www.libsdl.org/release/SDL-devel-1.2.13-VC8.zipI copied the folder inside the zip to C:I followed this tutorial: http://lazyfoo.net/SDL_tutorials/lesson01/windows/msvsnet0508e/index.php and it worked fine.I decided to move on to the next tutorial as I know nothing about SDL or any external libraries at all. The next tutorial was this: http://lazyfoo.net/SDL_tutorials/lesson02/index.php I read through the tutorial, getting to grips with each part and then I downloaded the source code and images for it, which I got here: http://lazyfoo.net/downloads/index.php?file=SDLTut_lesson02I went into Visual C++ 2008 Express Edition, and went New Project > Win32 Project and made sure it was an empty project. I clicked Add New Item and I added a C++ file called main. I copied in the code from the tutorial. Then I went to the folder of my project and copied and pasted in both of the images. Then I pasted into the same folder 'SDL.dll'. Then I clicked start debugging.This is what it said:1>------ Build started: Project: HelloWorld, Configuration: Debug Win32 ------1>Compiling...1>main.cpp1>Linking...1>main.obj : error LNK2019: unresolved external symbol _SDL_FreeSurface referenced in function "struct SDL_Surface * __cdecl load_image(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >)" (?load_image@@YAPAUSDL_Surface@@V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z)1>main.obj : error LNK2019: unresolved external symbol _SDL_DisplayFormat referenced in function "struct SDL_Surface * __cdecl load_image(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >)" (?load_image@@YAPAUSDL_Surface@@V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z)1>main.obj : error LNK2019: unresolved external symbol _SDL_LoadBMP_RW referenced in function "struct SDL_Surface * __cdecl load_image(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >)" (?load_image@@YAPAUSDL_Surface@@V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z)1>main.obj : error LNK2019: unresolved external symbol _SDL_RWFromFile referenced in function "struct SDL_Surface * __cdecl load_image(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >)" (?load_image@@YAPAUSDL_Surface@@V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z)1>main.obj : error LNK2019: unresolved external symbol _SDL_UpperBlit referenced in function "void __cdecl apply_surface(int,int,struct SDL_Surface *,struct SDL_Surface *)" (?apply_surface@@YAXHHPAUSDL_Surface@@0@Z)1>main.obj : error LNK2019: unresolved external symbol _SDL_Quit referenced in function _SDL_main1>main.obj : error LNK2019: unresolved external symbol _SDL_Delay referenced in function _SDL_main1>main.obj : error LNK2019: unresolved external symbol _SDL_Flip referenced in function _SDL_main1>main.obj : error LNK2019: unresolved external symbol _SDL_WM_SetCaption referenced in function _SDL_main1>main.obj : error LNK2019: unresolved external symbol _SDL_SetVideoMode referenced in function _SDL_main1>main.obj : error LNK2019: unresolved external symbol _SDL_Init referenced in function _SDL_main1>MSVCRTD.lib(crtexew.obj) : error LNK2019: unresolved external symbol _WinMain@16 referenced in function ___tmainCRTStartup1>C:\Users\Adrian\Documents\Visual Studio 2008\Projects\HelloWorld\Debug\HelloWorld.exe : fatal error LNK1120: 12 unresolved externals1>Build log was saved at "file://c:\Users\Adrian\Documents\Visual Studio 2008\Projects\HelloWorld\HelloWorld\Debug\BuildLog.htm"1>HelloWorld - 13 error(s), 0 warning(s)========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========At the end of the tutorial it said you must have the service pack installed for your compiler. But I had a look and I couldn't find a service pack for Visual C++ 2008 Express Edition, so I don't know what I have done wrong.Any help is greatly appreciated. Thank you   
  I could be wrong but it looks like your compiler is not finding the SDL libraries. The directory that your SDL Library is stored in may be different then that of lazyfoos. Try doing this: Copy your SDL folder into the following folder:C:\Users\Adrian\Documents\Visual Studio 2008\Projects\HelloWorld\HelloWorldThis way you should be able to copy and paste the following code and have a blank window to x out of. #include "SDL\SDL.h"int main(int argc, char* args[]){bool quit = false;while(quit == false){if(SDL_PollEvent(&event)){   if(event.type == SDL_QUIT){//Quit the programquit = true;}}}//Quit SDLSDL_Quit();return 0;}On a side note SDL is a pain in the @$$ to set up on Windows. Once you have it working I'd suggest saving a template so you don't have to set it up each time.   ;Quote:Original post by Chrono1081I could be wrong but it looks like your compiler is not finding the SDL libraries.It's finding SDL.h fine or it wouldn't be compiling and we wouldn't be getting linker errors since those happen only after a successful compile.Quote:From #gamedev on irc.afternet.org[5/24/2009 8:35:05 AM]<Brauss> you guys sound like you know what you're talking about, maybe you could help a beginner. i made a brief thread clearly describing my troubles: http://www.gamedev.net/community/forums/topic.asp?topic_id=535964[5/24/2009 8:35:28 AM]<Matt_D> your not linking the SDL libs[5/24/2009 8:35:47 AM]<Brauss> does include "SDL.h" not do that?[5/24/2009 8:35:51 AM]<Joeh> Nope[5/24/2009 8:35:51 AM]<MaulingMonkey> nope[5/24/2009 8:35:59 AM]<Brauss> what do i need to do then?[5/24/2009 8:36:04 AM]<MaulingMonkey> #include "SDL.h" imports the SDL function definitions so that your code compiles[5/24/2009 8:36:23 AM]<MaulingMonkey> You're getting linker errors, which #include cannot help with as they occur only after everything is already successfully compiling[5/24/2009 8:36:20 AM]<Matt_D> the "Linker" section of your project settings[5/24/2009 8:36:26 AM]<Matt_D> has a "additional libraries' setting[5/24/2009 8:36:33 AM]<Matt_D> linking happens after compilation[5/24/2009 8:36:34 AM]<MaulingMonkey> You need to add sdl.lib (and possibly sdlmain.lib) to your additional libraries listing[5/24/2009 8:36:40 AM]<Matt_D> ^;  Yep I figured I was wrong. I knew it would be one of the two errors :D   