ToME: the Tales of Maj'Eyal

Everything about ToME
It is currently Sat Jul 20, 2019 5:37 am

All times are UTC

Post new topic Reply to topic  [ 3 posts ] 
Author Message
PostPosted: Sat Jun 02, 2012 1:21 am 
Low Yeek

Joined: Tue Jan 10, 2012 6:32 pm
Posts: 5
Hello all,

I've been attempting to compile the latest SVN version on my 64bit Archlinux box. The good news is that I've managed to compile a binary that seems to execute, however, launching the binary just gives a black screen. I followed the posts on the wiki/forum for editing premake4.lua and te4core.lua, which now look like this:

--- premake4.lua   (revision 5176)
+++ premake4.lua   (working copy)
@@ -18,7 +18,8 @@
-      "/opt/SDL-2.0/include/SDL2/",
+      "/usr/include/SDL2",
+      "/usr/include/SDL",
    if _OPTIONS.lua == "default" then includedirs{"src/lua"}

--- build/te4core.lua   (revision 5176)
+++ build/te4core.lua   (working copy)
@@ -57,8 +57,8 @@
    configuration "linux"
-      libdirs {"/opt/SDL-2.0/lib/"}
-      links { "dl", "SDL2", "SDL2_ttf", "SDL2_image", "png", "openal", "vorbisfile", "GL", "GLU", "m", "pthread" }
+      libdirs {"/usr/lib/"}
+      links { "dl", "SDL2", "SDL_ttf", "SDL2_image", "png", "openal", "vorbisfile", "GL", "GLU", "m", "pthread" }
       defines { [[TENGINE_HOME_PATH='".t-engine"']], 'SELFEXE_LINUX' }
    configuration {"Debug"}

Combined with SDL-hg, SDL_image-hg, and SDL2_ttf from the core Arch repo, this appears to build without error, and as you can see, ldd finds all the libraries:

$ make clean && premake4 clean && premake4 gmake && make
<snip long output>
$ ldd ./t-engine =>  (0x00007fff2d479000) => /usr/lib/ (0x00007fbca6deb000) => /lib/ (0x00007fbca6af6000) => /lib/ (0x00007fbca68f2000) => /usr/lib/ (0x00007fbca662a000) => /usr/lib/ (0x00007fbca6423000) => /usr/lib/ (0x00007fbca6205000) => /usr/lib/ (0x00007fbca5fd8000) => /usr/lib/ (0x00007fbca5d81000) => /usr/lib/ (0x00007fbca5b78000) => /usr/lib/ (0x00007fbca591a000) => /usr/lib/ (0x00007fbca56ad000) => /lib/ (0x00007fbca5491000) => /lib/ (0x00007fbca50f0000)
   /lib/ (0x00007fbca7017000) => /usr/lib/ (0x00007fbca4e51000) => /usr/lib/ (0x00007fbca4c3b000) => /usr/lib/ (0x00007fbca4a2b000) => /usr/lib/ (0x00007fbca4791000) => /lib/ (0x00007fbca4589000) => /usr/lib/ (0x00007fbca435c000) => /usr/lib/ (0x00007fbca4156000) => /usr/lib/ (0x00007fbca3f31000) => /usr/lib/ (0x00007fbca3d1e000) => /usr/lib/ (0x00007fbca3b1b000) => /usr/lib/ (0x00007fbca3914000) => /usr/lib/ (0x00007fbca3712000) => /usr/lib/ (0x00007fbca33d9000) => /usr/lib/ (0x00007fbca31c3000) => /usr/lib/ (0x00007fbca2fa5000) => /usr/lib/ (0x00007fbca2d9f000) => /usr/lib/ (0x00007fbca2b94000) => /usr/lib/ (0x00007fbca2890000) => /usr/lib/ (0x00007fbca267b000) => /usr/lib/ (0x00007fbca2477000) => /usr/lib/ (0x00007fbca2271000)

So far so good. However, when I launch t-engine, it just hangs with a black screen. The cmdline shows:

$ ./t-engine
[CPU] Detected 8 CPUs
OpenAL device available: OpenAL Soft (default OpenAL Soft)
Available video driver: x11
Available video driver: dummy
NO SELFEXE: bootstrapping from CWD
WARNING: No bootstrap code found, defaulting to working directory for engine code!
Creating particles thread 0
[DO RESIZE] 800x600 (0)
OpenGL max texture size: 8192
OpenGL max texture size: 8192
===fbo 1
Running lua loader code...
move 0 x 37
resize 1916 x 1039
[DO RESIZE] 1916x1039 (0)
OpenGL max texture size: 8192

If I strace it, I can see this repeated hundreds of times per second:

recvfrom(6, 0x1493cb4, 4096, 0, 0, 0)   = -1 EAGAIN (Resource temporarily unavailable)
select(7, [6], NULL, NULL, {0, 0})      = 0 (Timeout)

I'm sure I'm missing something obvious, and it feels like I've *almost* succeeded. Where am I going wrong? I can easily add SDL_ttf-hg as well, but I didn't think a font engine would break the entire display.

Thanks in advance

PostPosted: Fri Aug 31, 2012 12:59 am 

Joined: Fri Aug 31, 2012 12:55 am
Posts: 2
Bump for the question.
I have the same error: black screen and nothing more.

[ENGINE] Switching to turn based
Loading savefile    /save//
Loading savefile    /save/player/
Make wait background texture 2 : 1280x900 (2048, 1024)
Lua Error: /engine/Module.lua:392: attempt to index local 'bkgs' (a nil value)
   At [C]:-1 __index
   At /engine/Module.lua:392
   At [C]:-1 enable
   At /engine/Module.lua:384 loadScreen
   At /engine/Module.lua:541 instanciate
   At /engine/utils.lua:1843 showMainMenu
   At /engine/init.lua:124
   At [C]:-1 dofile
   At /loader/init.lua:183
move 1 x 22
resize 1280 x 900
[DO RESIZE] 1280x900 (0)
OpenGL max texture size: 8192
move 1 x 52

PostPosted: Wed Oct 24, 2012 2:30 pm 

Joined: Wed Oct 24, 2012 8:02 am
Posts: 4
gwmngilfen, this is in no way connected with SDL. I get the same error and it turns out that I had lua already installed in system - too old lua. I just remove it, clean/recompile source and everything run smoothly.

May be developers can propose better solution, because now I do not have lua at all...

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC

Who is online

Users browsing this forum: No registered users and 1 guest

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group