Hi all, I decided to try out CSFML today. Unfortunatly I get sompile errors whenever I try static compiling. I'm using MinGW in windows7. Using the command "gcc main.c -Wall -o main.exe -lcsfml-system" works fine but when with lcsfml-system-s i get the following errors
D:/MinGW/lib/libcsfml-system-s.a(Clock.o):Clock.cpp:(.text+0x1e): undefined reference to `__gxx_personality_sj0'
D:/MinGW/lib/libcsfml-system-s.a(Clock.o):Clock.cpp:(.text+0x34): undefined reference to `_Unwind_SjLj_Register'
D:/MinGW/lib/libcsfml-system-s.a(Clock.o):Clock.cpp:(.text+0x59): undefined reference to `sf::Clock::Clock()'
D:/MinGW/lib/libcsfml-system-s.a(Clock.o):Clock.cpp:(.text+0x64): undefined reference to `_Unwind_SjLj_Unregister'
D:/MinGW/lib/libcsfml-system-s.a(Clock.o):Clock.cpp:(.text+0x9a): undefined reference to `_Unwind_SjLj_Resume'
D:/MinGW/lib/libcsfml-system-s.a(Clock.o):Clock.cpp:(.text+0xb5): undefined reference to `sf::Clock::GetElapsedTime() const'
D:/MinGW/lib/libcsfml-system-s.a(Clock.o):Clock.cpp:(.text+0xc5): undefined reference to `sf::Clock::Reset()'
D:/MinGW/lib/libcsfml-system-s.a(Sleep.o):Sleep.cpp:(.text+0x5): undefined reference to `sf::Sleep(float)'
Heres my code for refrence
#include <stdio.h>
#include <stdlib.h>
#include <SFML/System.h>
/*
*
*/
int main()
{
sfClock* clock = sfClock_Create();
while (sfClock_GetTime(clock) < 5.f)
{
printf("time is %f\n", sfClock_GetTime(clock));
sfSleep(0.5f);
}
sfClock_Destroy(clock);
return(0);
}
Normal SFML works fine. What am I doing wrong?