I am trying to connect glewwith my project in code::blocksby following these steps:
glew
code::blocks
//1- copied all the header files(glew.h....) to C:\Program Files (x86)\CodeBlocks\MinGW\include and //the libs to C:\Program Files (x86)\CodeBlocks\MinGW\lib //2-added the libs to the compiler Build Options > Linker Settings > add (considered to add glew32s.lib at the top) |undefined reference to `glewInit@0'|
not sure what is missing here!
An old question that I know but had the same problem and finally found its problem.
I needed to link 'glew32s' to my project and have it FIRST on the list. in Code :: Blocks:
, , , .
, .lib .
.lib
glew32.lib / .exe , , .lib , opengl32.lib.
glew32.lib
.exe
opengl32.lib
main.cpp.
main.cpp
#pragma comment(lib, "opengl32.lib") #pragma comment(lib, "glew32.lib")