1 (edited by senacpsg.aj256001 2014-05-19 14:20:12)

Topic: Steps to compile Teeworlds on Ubuntu 14.04 LTS

1. Install bam and g++ for the compilation using Synaptic Packs Manager
2. Still using Synaptic it's necessary to install libpython3.all-dev and libfreetype6-dev.
3. Close the Synaptic and at Terminal let's use the following commands:
sudo apt-get install libasound2
“    “    “      libsdl1.2debian
“    “    “      libsdl1.2.dev


4. Now, after all those commands let's compile the source of Teeworlds at Terminal:
Trype the cd and the path of the source forlder. Ex: cd teeworlds-0,6,2-source
Now type bam release for the compilation.




Obs.: For the commands in the Terminal it's important to CLOSE the Synaptic to avoid the conflicts between them.

2 (edited by PhOen!X' 2014-06-22 15:28:49)

Re: Steps to compile Teeworlds on Ubuntu 14.04 LTS

After I installed libsdl1.2debian, libsdl1.2-dev and libfreetype6-dev, I moved all the content of the folders to /usr/include, because when I compiled it, it didn't find SDL.h and tf2build.h After that, when I compiled, I got these errors ( NOTE: I got the g++ compiler from build-essential package using apt-get, and compiled bam from source. [is that important??])

[1/1] #1 link teeworlds
objs/engine/client/client.o: In function `CClient::Run()':
client.cpp:(.text+0x49d0): undefined reference to `SDL_Init'
client.cpp:(.text+0x49dd): undefined reference to `SDL_Quit'
client.cpp:(.text+0x4af1): undefined reference to `SDL_GetError'
client.cpp:(.text+0x513b): undefined reference to `SDL_Quit'
objs/engine/client/input.o: In function `CInput::Init()':
input.cpp:(.text+0x20): undefined reference to `SDL_EnableUNICODE'
objs/engine/client/input.o: In function `CInput::MouseRelative(float*, float*)':
input.cpp:(.text+0xc1): undefined reference to `SDL_GetMouseState'
input.cpp:(.text+0xeb): undefined reference to `SDL_WarpMouse'
input.cpp:(.text+0x141): undefined reference to `SDL_GetRelativeMouseState'
objs/engine/client/input.o: In function `CInput::MouseModeAbsolute()':
input.cpp:(.text+0x16a): undefined reference to `SDL_ShowCursor'
objs/engine/client/input.o: In function `CInput::MouseModeRelative()':
input.cpp:(.text+0x197): undefined reference to `SDL_ShowCursor'
objs/engine/client/input.o: In function `CInput::Update()':
input.cpp:(.text+0x258): undefined reference to `SDL_GetKeyState'
input.cpp:(.text+0x293): undefined reference to `SDL_GetMouseState'
input.cpp:(.text+0x354): undefined reference to `SDL_PollEvent'
objs/engine/client/input.o: In function `CInput::Init()':
input.cpp:(.text+0x30): undefined reference to `SDL_EnableKeyRepeat'
objs/engine/client/input.o: In function `CInput::MouseModeAbsolute()':
input.cpp:(.text+0x18c): undefined reference to `SDL_WM_GrabInput'
objs/engine/client/input.o: In function `CInput::MouseModeRelative()':
input.cpp:(.text+0x1bf): undefined reference to `SDL_WM_GrabInput'
objs/engine/client/sound.o: In function `CSound::Shutdown()':
sound.cpp:(.text+0x545): undefined reference to `SDL_CloseAudio'
sound.cpp:(.text+0x54f): undefined reference to `SDL_QuitSubSystem'
objs/engine/client/sound.o: In function `CSound::Init()':
sound.cpp:(.text+0x60e): undefined reference to `SDL_InitSubSystem'
sound.cpp:(.text+0x65b): undefined reference to `SDL_OpenAudio'
sound.cpp:(.text+0x6a8): undefined reference to `SDL_PauseAudio'
sound.cpp:(.text+0x6c5): undefined reference to `SDL_GetError'
sound.cpp:(.text+0x6e8): undefined reference to `SDL_GetError'
objs/engine/client/text.o: In function `CTextRender::Init()':
text.cpp:(.text._ZN11CTextRender4InitEv[_ZN11CTextRender4InitEv]+0x1d): undefined reference to `FT_Init_FreeType'
objs/engine/client/text.o: In function `CTextRender::LoadFont(char const*)':
text.cpp:(.text._ZN11CTextRender8LoadFontEPKc[_ZN11CTextRender8LoadFontEPKc]+0x55): undefined reference to `FT_New_Face'
objs/engine/client/text.o: In function `CTextRender::TextEx(CTextCursor*, char const*, int)':
text.cpp:(.text._ZN11CTextRender6TextExEP11CTextCursorPKci[_ZN11CTextRender6TextExEP11CTextCursorPKci]+0x17d): undefined reference to `FT_Set_Pixel_Sizes'
text.cpp:(.text._ZN11CTextRender6TextExEP11CTextCursorPKci[_ZN11CTextRender6TextExEP11CTextCursorPKci]+0x1b0): undefined reference to `FT_Get_First_Char'
text.cpp:(.text._ZN11CTextRender6TextExEP11CTextCursorPKci[_ZN11CTextRender6TextExEP11CTextCursorPKci]+0x1d6): undefined reference to `FT_Load_Glyph'
text.cpp:(.text._ZN11CTextRender6TextExEP11CTextCursorPKci[_ZN11CTextRender6TextExEP11CTextCursorPKci]+0x210): undefined reference to `FT_Get_Next_Char'
text.cpp:(.text._ZN11CTextRender6TextExEP11CTextCursorPKci[_ZN11CTextRender6TextExEP11CTextCursorPKci]+0x3d7): undefined reference to `FT_Set_Pixel_Sizes'
text.cpp:(.text._ZN11CTextRender6TextExEP11CTextCursorPKci[_ZN11CTextRender6TextExEP11CTextCursorPKci]+0x794): undefined reference to `FT_Set_Pixel_Sizes'
text.cpp:(.text._ZN11CTextRender6TextExEP11CTextCursorPKci[_ZN11CTextRender6TextExEP11CTextCursorPKci]+0x7aa): undefined reference to `FT_Load_Char'
text.cpp:(.text._ZN11CTextRender6TextExEP11CTextCursorPKci[_ZN11CTextRender6TextExEP11CTextCursorPKci]+0xb86): undefined reference to `FT_Get_Kerning'
objs/engine/client/backend_sdl.o: In function `CGraphicsBackend_SDL_OpenGL::WindowActive()':
backend_sdl.cpp:(.text+0x125): undefined reference to `SDL_GetAppState'
objs/engine/client/backend_sdl.o: In function `CGraphicsBackend_SDL_OpenGL::WindowOpen()':
backend_sdl.cpp:(.text+0x145): undefined reference to `SDL_GetAppState'
objs/engine/client/backend_sdl.o: In function `CGraphicsBackend_SDL_OpenGL::Init(char const*, int*, int*, int, int, int*, int*)':
backend_sdl.cpp:(.text+0x1f8): undefined reference to `SDL_WasInit'
backend_sdl.cpp:(.text+0x206): undefined reference to `SDL_InitSubSystem'
backend_sdl.cpp:(.text+0x213): undefined reference to `SDL_GetVideoInfo'
backend_sdl.cpp:(.text+0x224): undefined reference to `SDL_EventState'
backend_sdl.cpp:(.text+0x2df): undefined reference to `SDL_GL_SetAttribute'
backend_sdl.cpp:(.text+0x2eb): undefined reference to `SDL_GL_SetAttribute'
backend_sdl.cpp:(.text+0x2fa): undefined reference to `SDL_GL_SetAttribute'
backend_sdl.cpp:(.text+0x30b): undefined reference to `SDL_GL_SetAttribute'
backend_sdl.cpp:(.text+0x316): undefined reference to `SDL_WM_SetCaption'
backend_sdl.cpp:(.text+0x328): undefined reference to `SDL_SetVideoMode'
backend_sdl.cpp:(.text+0x33c): undefined reference to `SDL_ShowCursor'
backend_sdl.cpp:(.text+0x533): undefined reference to `SDL_GL_SetAttribute'
backend_sdl.cpp:(.text+0x541): undefined reference to `SDL_GL_SetAttribute'
backend_sdl.cpp:(.text+0x54b): undefined reference to `SDL_GetError'
backend_sdl.cpp:(.text+0x56b): undefined reference to `SDL_GetError'
objs/engine/client/backend_sdl.o: In function `CGraphicsBackend_SDL_OpenGL::Shutdown()':
backend_sdl.cpp:(.text+0x694): undefined reference to `SDL_QuitSubSystem'
objs/engine/client/backend_sdl.o: In function `CCommandProcessorFragment_SDL::Cmd_VideoModes(CCommandBuffer::SCommand_VideoModes const*)':
backend_sdl.cpp:(.text+0x181c): undefined reference to `SDL_ListModes'
objs/engine/client/backend_sdl.o: In function `CGraphicsBackend_SDL_OpenGL::Minimize()':
backend_sdl.cpp:(.text+0x111): undefined reference to `SDL_WM_IconifyWindow'
collect2: error: ld returned 1 exit status
bam: 'teeworlds' error 256
bam: error: a build step failed
I'm a god.