My cross-compiled version of Minetest crashes on Windows

User avatar
YuGiOhJCJ
Member
 
Posts: 34
Joined: Sat Jan 23, 2016 07:41
GitHub: YuGiOhJCJ
IRC: YuGiOhJCJ
In-game: YuGiOhJCJ

My cross-compiled version of Minetest crashes on Windows

by YuGiOhJCJ » Mon Mar 21, 2016 17:10

Hello,

On Linux, I have cross-compiled Minetest for Windows.
On Windows, when I run this version of Minetest, I got a crash:
Image

This is what my debugger says:
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
Z:\Documents and Settings\yugiohjcj\Desktop\usr\i686-w64-mingw32\games\minetest-0.
4.13\bin>gdb minetest.exe
GNU gdb (GDB) 7.11
Copyright (C) 2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i686-w64-mingw32".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from minetest.exe...done.
(gdb) run
Starting program: Z:\Documents and Settings\yugiohjcj\Desktop\usr\i686-w64-mingw32
\games\minetest-0.4.13\bin\minetest.exe
[New Thread 3864.0xf1c]

Program received signal SIGSEGV, Segmentation fault.
0x00000000 in ?? ()
(gdb) bt
#0  0x00000000 in ?? ()
#1  0x00992a85 in _GLOBAL__sub_I__ZN3irr3gui10CGUITTFont9c_libraryE ()
#2  0x008598c0 in irr::core::array<unsigned short, irr::core::irrAllocator<unsig
ned short> >::reallocate(unsigned int, bool) [clone .part.165] ()
#3  0x00000080 in ?? ()
#4  0x00000003 in ?? ()
#5  0x0000ffff in ?? ()
#6  0x000000b8 in ?? ()
#7  0x00000000 in ?? ()
(gdb) quit
A debugging session is active.

        Inferior 1 [process 3864] will be killed.

Quit anyway? (y or n) y


This backtrace is not clear to me but maybe there is a problem about irrlicht and fonts, isn't it?

Hopefully, on Windows, the official binaries of Minetest work well.
I had the idea to remove one by one the DLLs of this official working version of Minetest letting Windows using my DLLs that I have cross-compiled on Linux for Windows in order to see if one of my DLLs could be the reason of the crash.
In fact, I try to reproduce the crash with the official Minetest binary and my DLLs.

I was able to remove progressively all the DLLs of the "bin" directory but freetype6.dll, libleveldb.dll, libstdc++-6.dll and zlibwapi.dll.
Indeed, I can't remove freetype6.dll because mine is named libfreetype-6.dll and so freetype6.dll is not found:
Image
Also, I can't remove libleveldb.dll because it is a library that I was not able to cross-compile so I don't have it and if I remove it, libleveldb.dll is not found:
Image
If I can't remove libstdc++-6.dll, it is because I get this error:
Image
And if I can't remove zlibwapi.dll, it is because I get this error:
Image
So, I was not able to test all my DLLs but a lot of them.

An interesting thing, is that now that I am using my DLLs, I can see this output while I am running the official Minetest binary:
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
Z:\Documents and Settings\yugiohjcj\Desktop\downloads\software\Minetest\minetest-0
.4.13-win32\bin>minetest.exe
2016-03-21 16:15:40: ERROR[main]: Irrlicht: Compression mode not supported.
2016-03-21 16:15:40: ERROR[main]: Irrlicht: Error: Could not load built-in Font.
 Did you compile without the BMP loader?


I have probably forgot an option when I cross-compiled irrlicht.

Anyway, do you see why my cross-compiled version of Minetest crashes on Windows?

Thank you.
Best regards.

Programs used:
  • i686-w64-mingw32-binutils-2.26
  • i686-w64-mingw32-curl-7.44.0
  • i686-w64-mingw32-expat-2.1.0
  • i686-w64-mingw32-freetype-2.4.10
  • i686-w64-mingw32-gcc-5.3.0
  • i686-w64-mingw32-gdb-7.11
  • i686-w64-mingw32-gettext-0.19.7
  • i686-w64-mingw32-irrlicht-1.8.1
  • i686-w64-mingw32-libiconv-1.14
  • i686-w64-mingw32-libogg-1.3.2
  • i686-w64-mingw32-libvorbis-1.3.5
  • i686-w64-mingw32-lua-5.1.5
  • i686-w64-mingw32-luajit-2.0.4
  • i686-w64-mingw32-minetest-0.4.13
  • i686-w64-mingw32-mingw-w64-crt-4.0.5
  • i686-w64-mingw32-mingw-w64-headers-4.0.5
  • i686-w64-mingw32-openal-soft-1.17.2
  • i686-w64-mingw32-sqlite-3.8.11.1
  • i686-w64-mingw32-zlib-1.2.8
  • i686-w64-mingw32-zlibwapi-1.2.8
Last edited by YuGiOhJCJ on Fri May 13, 2016 00:33, edited 1 time in total.
 

User avatar
YuGiOhJCJ
Member
 
Posts: 34
Joined: Sat Jan 23, 2016 07:41
GitHub: YuGiOhJCJ
IRC: YuGiOhJCJ
In-game: YuGiOhJCJ

Re: My cross-compiled version of Minetest crashes on Windows

by YuGiOhJCJ » Tue Mar 29, 2016 18:14

I have rebuilt/upgraded these programs:
  • i686-w64-mingw32-irrlicht-1.8.3
  • i686-w64-mingw32-minetest-0.4.13

Minetest is now built in debug mode so I can see a better trace:
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
Z:\Documents and Settings\yugiohjcj\Desktop>gdb minetest
GNU gdb (GDB) 7.11
Copyright (C) 2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i686-w64-mingw32".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from minetest...done.
(gdb) run
Starting program: Z:\Documents and Settings\yugiohjcj\Desktop\usr\i686-w64-mingw32
\games\minetest-0.4.13\bin\minetest.exe
[New Thread 2612.0xa3c]

Program received signal SIGSEGV, Segmentation fault.
0x00000000 in ?? ()
(gdb) bt
#0  0x00000000 in ?? ()
#1  0x0076b747 in __static_initialization_and_destruction_0 (
    __initialize_p=1, __priority=65535)
    at /usr/i686-w64-mingw32/include/c++/5.3.0/iostream:74
#2  0x0076b79c in _GLOBAL__sub_I__ZN3irr3gui10CGUITTFont9c_libraryE ()
    at /tmp/build/minetest-0.4.13/src/cguittfont/CGUITTFont.cpp:1175
#3  0x0076c09a in __do_global_ctors () at crt/gccmain.c:44
#4  0x0076c0ec in __main () at crt/gccmain.c:58
#5  0x004013b6 in __tmainCRTStartup () at crt/crtexe.c:324
#6  0x757d1793 in KERNEL32!BaseThreadInitThunk ()
   from C:\Windows\system32\kernel32.dll
#7  0x776fc206 in ntdll!RtlCreateMemoryZone ()
   from C:\Windows\SYSTEM32\ntdll.dll
#8  0x776fc1df in ntdll!RtlCreateMemoryZone ()
   from C:\Windows\SYSTEM32\ntdll.dll
#9  0x00000000 in ?? ()
(gdb) quit
A debugging session is active.

        Inferior 1 [process 2612] will be killed.

Quit anyway? (y or n) y


Can you guess something by reading this backtrace?
 


Return to Minetest Problems

Who is online

Users browsing this forum: No registered users and 9 guests

cron