User forums > General (but related to Code::Blocks)

How can I install glut in clodeblocks 64 bit with mingw?

<< < (2/3) > >>

Miguel Gimenez:
I have just tested FreeGlut and it is easy to compile and use; Just use CMake-GUI to generate MinGW makefiles in a new folder (p.e freeglut-3.2.1\Build), open a console in that folder and run mingw32-make. You can then copy the lib folder inside Build to freeglut-3.2.1 and create a global variable in C::B called glut containing the path to the library (p.e. C:\Libraries\freeglut-3.2.1) in the base field and nothing in the other fields.

Then use the wizard to create the project. The only problem I have found with the wizard is the Execution Working Dir being set to $(#glut)/bin when it should be just bin/ . You will need to copy the Build\bin\libfreeglut.dll near the executable.

Other problem with the wizard is with the use of global variables, I specified $(#freeglut) in the wizard but the generated project used a mix of glut and freeglut. In a second try I had to use glut to work around the mix.

cola:
I have installed codeblocks-20.03mingw-setup.exe. How will I compile freeglut-3.2.1?

BlueHazzard:
Make sure your compiler path is in the path variable:
search for gcc.exe in the codeblocks folder.
Check if the path to gcc.exe is in the PATH variable of windows. To check this, open the start menu and type "system environment variables" in the opening dialog -> "Environment variables" -> Uservariables for XXXXXX -> double click on the PATH. Check if the path to gcc is there. If not add it by pressing the "Browse" button

Now install CMake
Open CMake gui and follow a build instruction for freeglut in the internet....


Then you can follow the direction of miguel gimenez...

cola:
I have downloaded freeglut from https://www.transmissionzero.co.uk/files/software/development/GLUT/freeglut-MinGW.zip
Will it work with codeblocks-20.03mingw-setup.exe?

stahta01:
Link to readme from OP last link.https://www.transmissionzero.co.uk/files/software/development/GLUT/Readme.txt

Tim S.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version