Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Problems building SFML-2.0  (Read 3704 times)

0 Members and 1 Guest are viewing this topic.

phraze

  • Newbie
  • *
  • Posts: 6
    • MSN Messenger - phraze@gmail.com
    • View Profile
Problems building SFML-2.0
« on: February 22, 2010, 06:41:17 am »
Tried to build SFML2.0 on GNU/Linux Debian 64bit:

Code: [Select]
phraze@phraze-laptop:~/downloads/branches/sfml2$ make
make[1]: Entering directory `/home/phraze/downloads/branches/sfml2/src/SFML'
make[2]: Entering directory `/home/phraze/downloads/branches/sfml2/src/SFML/System'
g++ -shared -Wl,-soname,libsfml-system.so.2.0 -o ../../../lib/libsfml-system.so.2.0 Clock.o Lock.o Mutex.o Randomizer.o Sleep.o String.o Thread.o ThreadLocal.o Utf.o ./Unix/Initializer.o ./Unix/MutexImpl.o ./Unix/Platform.o ./Unix/ThreadImpl.o ./Unix/ThreadLocalImpl.o -lpthread
make[2]: Leaving directory `/home/phraze/downloads/branches/sfml2/src/SFML/System'
make[2]: Entering directory `/home/phraze/downloads/branches/sfml2/src/SFML/Window'
g++ -o Linux/ContextGLX.o -c Linux/ContextGLX.cpp -W -Wall -pedantic -g -O2 -DNDEBUG -I../../../include -I../../ -fPIC
Linux/ContextGLX.cpp: In member function 'void sf::priv::ContextGLX::CreateContext(sf::priv::ContextGLX*, unsigned int, const sf::ContextSettings&)':
Linux/ContextGLX.cpp:229: error: 'PFNGLXCREATECONTEXTATTRIBSARBPROC' was not declared in this scope
Linux/ContextGLX.cpp:229: error: expected `;' before 'glXCreateContextAttribsARB'
Linux/ContextGLX.cpp:230: error: 'glXCreateContextAttribsARB' was not declared in this scope
Linux/ContextGLX.cpp:239: error: 'GLX_CONTEXT_MAJOR_VERSION_ARB' was not declared in this scope
Linux/ContextGLX.cpp:240: error: 'GLX_CONTEXT_MINOR_VERSION_ARB' was not declared in this scope
Linux/ContextGLX.cpp:228: warning: unused variable 'name'
make[2]: *** [Linux/ContextGLX.o] Error 1
make[2]: Leaving directory `/home/phraze/downloads/branches/sfml2/src/SFML/Window'
make[1]: *** [sfml-window] Error 2
make[1]: Leaving directory `/home/phraze/downloads/branches/sfml2/src/SFML'
make: *** [sfml] Error 2


Help anyone?

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Problems building SFML-2.0
« Reply #1 on: February 22, 2010, 09:09:14 am »
Apparently, my local glxext.h is ignored and the system's one (which is not up to date) is included instead.

It seems that some systems need a special #define to avoid this issue. Can you update your working copy and tell me if it's ok now?
Laurent Gomila - SFML developer

Tank

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1486
    • View Profile
    • Blog
    • Email
Problems building SFML-2.0
« Reply #2 on: February 22, 2010, 11:06:48 am »
phraze, what version of Debian are you using? I'm using Sid and don't have any problems, so far.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Problems building SFML-2.0
« Reply #3 on: February 22, 2010, 11:15:33 am »
Quote from: "Tank"
phraze, what version of Debian are you using? I'm using Sid and don't have any problems, so far.

This is because some implementations have a glx.h header that includes glxext.h, and some others don't. And when the system's glxext.h header is included, SFML's one is ignored.
Laurent Gomila - SFML developer

panithadrum

  • Sr. Member
  • ****
  • Posts: 304
    • View Profile
    • Skyrpex@Github
    • Email
Problems building SFML-2.0
« Reply #4 on: February 22, 2010, 03:40:35 pm »
I have problems building SFML2 too (Windows, VS2005).

Code: [Select]
5>LINK : warning LNK4098: la biblioteca predeterminada'LIBCMT' entra en conflicto con otras bibliotecas; use la biblioteca /NODEFAULTLIB:biblioteca
5>GLCheck.obj : error LNK2001: símbolo externo "class std::basic_ostream<char,struct std::char_traits<char> > & __cdecl sf::Err(void)" (?Err@sf@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@std@@XZ) sin resolver
5>Image.obj : error LNK2001: símbolo externo "class std::basic_ostream<char,struct std::char_traits<char> > & __cdecl sf::Err(void)" (?Err@sf@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@std@@XZ) sin resolver
5>ImageLoader.obj : error LNK2001: símbolo externo "class std::basic_ostream<char,struct std::char_traits<char> > & __cdecl sf::Err(void)" (?Err@sf@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@std@@XZ) sin resolver
5>Shader.obj : error LNK2001: símbolo externo "class std::basic_ostream<char,struct std::char_traits<char> > & __cdecl sf::Err(void)" (?Err@sf@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@std@@XZ) sin resolver
5>RenderImage.obj : error LNK2019: símbolo externo "class std::basic_ostream<char,struct std::char_traits<char> > & __cdecl sf::Err(void)" (?Err@sf@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@std@@XZ) sin resolver al que se hace referencia en la función "public: bool __thiscall sf::RenderImage::Create(unsigned int,unsigned int,bool)" (?Create@RenderImage@sf@@QAE_NII_N@Z)
5>RenderImageImplFBO.obj : error LNK2001: símbolo externo "class std::basic_ostream<char,struct std::char_traits<char> > & __cdecl sf::Err(void)" (?Err@sf@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@std@@XZ) sin resolver
5>RenderImageImplPBuffer.obj : error LNK2001: símbolo externo "class std::basic_ostream<char,struct std::char_traits<char> > & __cdecl sf::Err(void)" (?Err@sf@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@std@@XZ) sin resolver
5>Font.obj : error LNK2001: símbolo externo "class std::basic_ostream<char,struct std::char_traits<char> > & __cdecl sf::Err(void)" (?Err@sf@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@std@@XZ) sin resolver
5>C:\Archivos de programa\development\sfml2\build\vc2005\..\..\lib\vc2005\sfml-graphics-d.dll : fatal error LNK1120: 1 externos sin resolver

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Problems building SFML-2.0
« Reply #5 on: February 22, 2010, 04:37:15 pm »
Clear and rebuild completely.
Laurent Gomila - SFML developer

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Problems building SFML-2.0
« Reply #6 on: February 22, 2010, 04:42:21 pm »
Oops sorry, it was my fault, I forgot to add a file to the VS2005 project. It should work now ;)
Laurent Gomila - SFML developer