Can't link to SDL2 (or boost) on Windows
Posted: Wed May 07, 2014 11:07 pm
Hi,
I am testing CodeLite as an alternative IDE (to VC++) on Windows. I am trying to build simplest SDL2 application using console g++ template but I am getting this compilation errors:
C:\Windows\system32\cmd.exe /c "mingw32-make.exe -j 8 -e -f Makefile"
----------Building project:[ hello - Debug ]----------
mingw32-make[1]: Entering directory 'D:/projects/hello'
g++ -o ./Debug/hello @"hello.txt" -L. -LD:/SDL2-2.0.3-mingw/lib/x86 -lSDL2Main -lSDL2
Warning: .drectve `/manifestdependency:"type='win32' name='Microsoft.VC90.CRT' version='9.0.21022.8' processorArchitecture='x86' publicKeyToken='1fc8b3b9a1e18e3b'" /DEFAULTLIB:"MSVCRT" /DEFAULTLIB:"OLDNAMES" U¸ DWarning: .drectve `' unrecognized
collect2.exe: error: ld returned 5 exit status
mingw32-make[1]: *** [Debug/hello] Error 1
mingw32-make.exe: *** [All] Error 2
hello.mk:79: recipe for target 'Debug/hello' failed
mingw32-make[1]: Leaving directory 'D:/projects/hello'
Makefile:4: recipe for target 'All' failed
0 errors, 0 warnings
I am using official SDL 2.0.3 mingw binaries and this is full source code:
#include <SDL.h>
int main(int argc, char **argv){
if (SDL_Init(SDL_INIT_EVERYTHING) != 0){
return 1;
}
SDL_Quit();
return 0;
}
I am testing CodeLite as an alternative IDE (to VC++) on Windows. I am trying to build simplest SDL2 application using console g++ template but I am getting this compilation errors:
C:\Windows\system32\cmd.exe /c "mingw32-make.exe -j 8 -e -f Makefile"
----------Building project:[ hello - Debug ]----------
mingw32-make[1]: Entering directory 'D:/projects/hello'
g++ -o ./Debug/hello @"hello.txt" -L. -LD:/SDL2-2.0.3-mingw/lib/x86 -lSDL2Main -lSDL2
Warning: .drectve `/manifestdependency:"type='win32' name='Microsoft.VC90.CRT' version='9.0.21022.8' processorArchitecture='x86' publicKeyToken='1fc8b3b9a1e18e3b'" /DEFAULTLIB:"MSVCRT" /DEFAULTLIB:"OLDNAMES" U¸ DWarning: .drectve `' unrecognized
collect2.exe: error: ld returned 5 exit status
mingw32-make[1]: *** [Debug/hello] Error 1
mingw32-make.exe: *** [All] Error 2
hello.mk:79: recipe for target 'Debug/hello' failed
mingw32-make[1]: Leaving directory 'D:/projects/hello'
Makefile:4: recipe for target 'All' failed
0 errors, 0 warnings
I am using official SDL 2.0.3 mingw binaries and this is full source code:
#include <SDL.h>
int main(int argc, char **argv){
if (SDL_Init(SDL_INIT_EVERYTHING) != 0){
return 1;
}
SDL_Quit();
return 0;
}