Hello,
I tried to get DevIL (previously called OpenIL, an image library for OpenGL) running, without succes yet.
I downloaded the Win32 package, placed all the include file (.h) in "include/IL/" and the .lib files, .exp files and .dll files in the "lib/" directory. I even tried to put the .dll files in "windows/system32/". I include all the header files, and use Project -> Build options -> Linker -> Add to add all the .lib files.
I don't know where to place the .dll files, and what .exp files are. This is what I get when I want to initialize the image library:
Project : GLFW Application
Compiler : GNU GCC Compiler (called directly)
Directory : G:\Documents and Settings\Taco\Bureaublad\Coding\C\GLFW\
--------------------------------------------------------------------------------
Switching to target: default
Linking executable: glfw.exe
.objs\main.o:main.cpp:(.text+0x5b8): undefined reference to `_imp__ilInit@0'
.objs\main.o:main.cpp:(.text+0x5bf): undefined reference to `_imp__iluInit@0'
.objs\main.o:main.cpp:(.text+0x5cd): undefined reference to `_imp__ilutRenderer@4'
collect2: ld returned 1 exit status
Process terminated with status 1 (0 minutes, 0 seconds)
I saw that the text "_imp__ilInit@0" etc, are in the library files. So whats wrong, .dll or .lib files? Or something else ^^,
Thank you very much,
Decrius
Thank you for the reply :)
I also tried another image library, which has only 1 .dll 1 .h and 1 .lib file.
Result:
Project : GLFW Application
Compiler : GNU GCC Compiler (called directly)
Directory : G:\Documents and Settings\Taco\Bureaublad\Coding\C\GLFW\
--------------------------------------------------------------------------------
Switching to target: default
mingw32-g++.exe -L"J:\Program Files\CodeBlocks\lib" -o glfw.exe .objs\main.o -lglut32 -lglu32 -lopengl32 -lfreeimage -lglfw -lopengl32 -lglu32 -luser32 -lkernel32 -lgdi32 -mwindows
/mingw/lib/crt2.o:crt1.c:(.text+0x16a): undefined reference to `__cpu_features_init'
collect2: ld returned 1 exit status
Process terminated with status 1 (0 minutes, 0 seconds)
Maybe I don't use the linker right?
FreeImage.lib (shouldn't it be .a?) is placed in the lib directory. Build -> Compiler Options -> Linker -> right text area is where I put this line:
-lfreeimage
Decrius