0

Currently I'm trying to install the last version of SDL, and I'm trying to link Eclipse,SDL and MingWG.

But after lots of tries, I got an error.

c:/mingw/bin/../lib/gcc/mingw32/4.8.1/../../../../mingw32/bin/ld.exe: cannot find -lSDLmain collect2.exe: error: ld returned 1 exit status

So I guess Eclipse cann't find the SDL_main.h.

But I have specified MingWG,SDLmain,SDL2 in librairy, so I don't really understand how can I fix the problem.

Thank you in advance. All idea is welcome. If you need more information, ask me.

Luigi
  • 4,129
  • 6
  • 37
  • 57
Latsuj
  • 469
  • 1
  • 5
  • 14

1 Answers1

0

"So I guess Eclipse cann't find the SDL_main.h."

No, that's a linker error. You probably missed to specify the path where the linker should lookup the libraries. The -L option is supposed to do this (check the Eclipse c++-Build options please).

Here's some more information: Problems importing libraries to my c++ project, how to fix this?

Community
  • 1
  • 1
πάντα ῥεῖ
  • 1
  • 13
  • 116
  • 190