Step 1 :
sudo apt-get update
note : Enter Password (e.g.: root123)
Step 2 :
sudo apt-get install libsfml-dev
Step 3:
Intsall OpenGL.
sudo apt-get install libglu1-mesa-dev freeglut3-dev mesa-common-dev
Step 4:
Save program in Home and open Home in Terminal
OR
Open Terminal :
cd /Home
Step 5:
Compile using:
g++ -c <filename>.cpp
eg. g++ -c EXP1.cpp
Step 6:
Compile using Graphics.hpp
(For EXP1, EXP3, EXP5, EXP7)
g++ <filename>.o -o sfml-app -lsfml-graphics -lsfml-window -lsfml-system
e.g.: g++ EXP1.o -o sfml-app -lsfml-graphics -lsfml-window -lsfml-system
Step 7:
Execute/Run the Output:
./sfml-app
Step 7:
Compiling and Execute/ Run OpenGL Programs
(For EXP2, EXP4, EXP6)
1. Compilation
g++ main.cpp -o firstOpenGlApp -lglut -lGLU -lGL
2. Run / Execution
./firstOpenGlApp