Hello
I can't compile the following code in Code::Blocks in Ubuntu 12.10:
#include <SFML/Graphics.hpp>
int main()
{
sf::RenderWindow window(sf::VideoMode(200, 200), "SFML works!");
sf::CircleShape shape(100.f);
shape.setFillColor(sf::Color::Green);
while (window.isOpen())
{
sf::Event event;
while (window.pollEvent(event))
{
if (event.type == sf::Event::Closed)
window.close();
}
window.clear();
window.draw(shape);
window.display();
}
return 0;
}
When sing Code::Blocks, I've mentioned in the search directories where the includes and libs are under the compiler and debugger settings. I've also done the necessary steps in the project build options too. But still getting an error.
I've compiled SFML sources and have built the libs from from make files at the path
/home/user404/Libraries/SFML_2_1Also, whenever I build my program in debug version, this error pops up:
libGLEW.so.1.7 needed by /home/user404/Libraries/SFML_2_1/lib/libsfml-graphics.so, not foundAnd when I try to install libGLEW.so.1.7 as
sudo apt-get install libglew1.7-dev, this happens in the terminal:
Reading package lists... Done
uilding state information... Done
E: Unable to locate package libglew1.7-dev
E: Couldn't find any package by regex 'libglew1.7-dev'
Any suggestions where's the problem?
Thanks
EDIT:Also, when I am trying to generate makefiles using cmake
cmake -G "Unix Makefiles" -D CMAKE_BUILD_TYPE=Debug -D BUILD_SHARED_LIBS=FALSE, an error pops up :
CMake Error : The source directory "/home/user404/Downloads/SFML_2_1/BUILD_SHARED_LIBS=TRUE" does not exist.
But the part BUILD_SHARED_LIBS=TRUE has nothing to with the search directory