Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - jucarave

Pages: [1]
1
C / undefined reference to `_imp__*`
« on: January 26, 2015, 08:55:26 pm »
Hello there, this is my first message on the forum.

I've been trying to compile a simple code just to test if CSFML works, I'm using CodeBlocks with GNU GCC compiler but it fails in what I believe is when  it tries to link the libraries (?)

this is the output:

mingw32-gcc.exe  -IC:\CLibs\CSFML-2.1\include\ -c C:\PathToMyProject\CSFMLTest\main.c -o obj\Debug\main.o
mingw32-g++.exe -LC:\CLibs\CSFML-2.1\lib\gcc -o bin\Debug\CSFMLTest.exe obj\Debug\main.o   -lcsfml-graphics -lcsfml-window -lcsfml-system
obj\Debug\main.o:main.c:(.text+0x53): undefined reference to `_imp__sfRenderWindow_create'
obj\Debug\main.o:main.c:(.text+0x6f): undefined reference to `_imp__sfCircleShape_create'
obj\Debug\main.o:main.c:(.text+0x7a): undefined reference to `_imp__sfGreen'
obj\Debug\main.o:main.c:(.text+0x8c): undefined reference to `_imp__sfCircleShape_setFillColor'
obj\Debug\main.o:main.c:(.text+0xa4): undefined reference to `_imp__sfRenderWindow_close'
obj\Debug\main.o:main.c:(.text+0xbd): undefined reference to `_imp__sfRenderWindow_pollEvent'
obj\Debug\main.o:main.c:(.text+0xc8): undefined reference to `_imp__sfWhite'
obj\Debug\main.o:main.c:(.text+0xda): undefined reference to `_imp__sfRenderWindow_clear'
obj\Debug\main.o:main.c:(.text+0xf8): undefined reference to `_imp__sfRenderWindow_drawCircleShape'
obj\Debug\main.o:main.c:(.text+0x106): undefined reference to `_imp__sfRenderWindow_display'
obj\Debug\main.o:main.c:(.text+0x114): undefined reference to `_imp__sfRenderWindow_isOpen'
collect2.exe: error: ld returned 1 exit status
Process terminated with status 1 (0 minute(s), 0 second(s))
11 error(s), 0 warning(s) (0 minute(s), 0 second(s))

I just don't understand that part of the _imp__ but searching online I found that the problem is related to the linking order, but I don't know what to do...

Greetings.

Pages: [1]
anything