ptitSeb / box64

Box64 - Linux Userspace x86_64 Emulator with a twist, targeted at ARM64 Linux devices
https://box86.org
MIT License
3.94k stars 290 forks source link

Rise of the Tomb Raider #21

Open Heasterian opened 3 years ago

Heasterian commented 3 years ago

Game at this moment crashes with:

Box64 with Dynarec v0.1.3 56f6ad8 built on Jul  4 2021 16:37:33
Using default BOX64_LD_LIBRARY_PATH: ./:lib/:lib64/:x86_64/:bin64/:libs64/
Using default BOX64_PATH: ./:bin/
Counted 58 Env var
BOX64 try to Preload libgtk3-nocsd.so.0 
Looking for ./bin/RiseOfTheTombRaider
Using emulated lib/libgtk3-nocsd.so.0
Using native(wrapped) libdl.so.2
Using native(wrapped) libpthread.so.0
Using native(wrapped) libc.so.6
Using native(wrapped) ld-linux-x86-64.so.2
Using native(wrapped) librt.so.1
Using native(wrapped) libz.so.1
Using native(wrapped) libcurl.so.4
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libssl.so.44
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libcrypto.so.42
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libSDL2-2.0.7.so
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libSDL2_image-2.0.1.so
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libcef.so
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libpdf.so
Using native(wrapped) libvorbis.so.0
Using native(wrapped) libfreetype.so.6
Using native(wrapped) libfontconfig.so.1
Using native(wrapped) libdbus-1.so.3
Using native(wrapped) libm.so.6
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libgomp.so.1
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libgobject-2.0.so.0
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libglib-2.0.so.0
Using native(wrapped) libpangocairo-1.0.so.0
Using native(wrapped) libpango-1.0.so.0
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libffi.so.6
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libpcre.so.3
Using native(wrapped) libcairo.so.2
Using native(wrapped) libX11.so.6
Using native(wrapped) libXi.so.6
Using native(wrapped) libXext.so.6
Using native(wrapped) libxcb.so.1
Using native(wrapped) libXau.so.6
Using native(wrapped) libXdmcp.so.6
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libnss3.so
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libnssutil3.so
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libsmime3.so
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libplc4.so
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libnspr4.so
Using native(wrapped) libXcomposite.so.1
Using native(wrapped) libasound.so.2
Using native(wrapped) libXdamage.so.1
Using native(wrapped) libXfixes.so.3
Using native(wrapped) libXtst.so.6
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libgconf-2.so.4
Using native(wrapped) libXcursor.so.1
Using native(wrapped) libXrender.so.1
Using native(wrapped) libXrandr.so.2
Using native(wrapped) libexpat.so.1
Using native(wrapped) libcups.so.2
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libcap.so.2
Using emulated /usr/lib/x86_64-linux-gnu/libstdc++.so.6
Using emulated /usr/lib/x86_64-linux-gnu/libgcc_s.so.1
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libplds4.so
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libgio-2.0.so.0
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libgthread-2.0.so.0
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libgmodule-2.0.so.0
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libdbus-glib-1.so.2
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libmount.so.1
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libselinux.so.1
Using native(wrapped) libresolv.so.2
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libblkid.so.1
Using native(wrapped) libuuid.so.1
RiseOfTheTombRaider: crash reporter initialised with path "/home/heasterian/.local/share/feral-interactive/Rise of the Tomb Raider/crashes"
Using emulated /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libnvidia-ml.so
Error: Global Symbol __ctype_b not found, cannot apply R_X86_64_GLOB_DAT @0x7edea19e10 ((nil)) in /home/heasterian/Downloads/Rise of the Tomb Raider/bin/../lib/libnvidia-ml.so
Using native(wrapped) libXinerama.so.1
Using native(wrapped) libXss.so.1
Using native(wrapped) libXxf86vm.so.1
Using native(wrapped) libGL.so.1
Using native(wrapped) libpulse-simple.so.0
Using native(wrapped) libpulse.so.0
SDL2 initialised [built against 2.0.7, running with 2.0.7]
Error: PltResolver: Symbol ptrace(ver 4: ptrace@GLIBC_2.2.5) not found, cannot apply R_X86_64_JUMP_SLOT 0x32bfa88 (0x40dac6) in ./bin/RiseOfTheTombRaider
Library libpulse.so.0 (0x8929d010) needs 0x891685d0, but it was not found. Ignoring.
Library libXext.so.6 (0x8035d2e0) needs 0x857e81b0, but it was not found. Ignoring.
Library libXext.so.6 (0x8035d2e0) needs 0x857de870, but it was not found. Ignoring.
Library libX11.so.6 (0x80357320) needs 0x857e81b0, but it was not found. Ignoring.
Library libX11.so.6 (0x80357320) needs 0x857de870, but it was not found. Ignoring.
Library libc.so.6 (0x7fa29910) needs 0x84202150, but it was not found. Ignoring.
Library libpthread.so.0 (0x7fa296e0) needs 0x84202150, but it was not found. Ignoring.
Library libdl.so.2 (0x7fa293d0) needs 0x84202150, but it was not found. Ignoring.
Stop waiting for remaining thread 9743
Stop waiting for remaining thread 9744
Error: Unsupported Syscall 0x38h (56)
Heasterian commented 3 years ago

There are another missing syscalls.

Using emulated /home/heasterian/Downloads/Rise/bin/../lib/libgamemode.so
Error: Unsupported libc Syscall 0x1B2 (434)
free(): invalid size
Error: Unsupported Syscall 0x38h (56)
Heasterian commented 3 years ago

Now in hangs on:

Error: unimplemented option 20219 in curl_easy_setopt
Error: PltResolver: Symbol curl_multi_wait(ver 3: curl_multi_wait@CURL_OPENSSL_4) not found, cannot apply R_X86_64_JUMP_SLOT 0x32c02b0 (0x40eb16) in /home/heasterian/Downloads/Rise/bin/RiseOfTheTombRaider
Using native(wrapped) libudev.so.1
Heasterian commented 3 years ago

Hmmm... Is this caused by this syscall missing or SIGSEGV?

Using emulated /home/heasterian/Downloads/Rise/bin/../lib/libpng12.so.0
Warning, jumping to a no-block address (nil) from 0x90e06324 (db=0x7e80566600, x64addr=0x19af473)
30309|SIGSEGV @0x648cd66c (???(/usr/local/bin/box64/0x648cd66c)) (x64pc=0x1/???:"???", rsp=0x7e87a27f48, stack=0x7e87828000:0x7e87a28000 own=0x7e87828000 fp=0x905614e8), for accessing (nil) (code=1/prot=0), db=(nil)((nil):(nil)/(nil):(nil)/???:clean, hash:0/0) handler=0x23af100
30309|Double SIGSEGV (code=1, pc=0x648cd66c, addr=(nil))!
Library libpulse.so.0 (0x8abbfa40) needs 0x8ac15b30, but it was not found. Ignoring.
Library libstdc++.so.6 (0x81f2dc10) needs 0x8c4d6f50, but it was not found. Ignoring.
Library libXext.so.6 (0x81e86510) needs 0x87393340, but it was not found. Ignoring.
Library libXext.so.6 (0x81e86510) needs 0x8728b060, but it was not found. Ignoring.
Library libX11.so.6 (0x81e834b0) needs 0x87393340, but it was not found. Ignoring.
Library libX11.so.6 (0x81e834b0) needs 0x8728b060, but it was not found. Ignoring.
Library libc.so.6 (0x8154c0e0) needs 0x8e42e950, but it was not found. Ignoring.
Library libc.so.6 (0x8154c0e0) needs 0x8c4d6f50, but it was not found. Ignoring.
Library libc.so.6 (0x8154c0e0) needs 0x8abe7ac0, but it was not found. Ignoring.
Library libc.so.6 (0x8154c0e0) needs 0x85cb4310, but it was not found. Ignoring.
Library libm.so.6 (0x81d9c090) needs 0x8e42e950, but it was not found. Ignoring.
Library libdbus-1.so.3 (0x81d96550) needs 0x8abe7ac0, but it was not found. Ignoring.
Library libpthread.so.0 (0x816bcb60) needs 0x85cb4310, but it was not found. Ignoring.
Library libz.so.1 (0x8155c120) needs 0x8e42e950, but it was not found. Ignoring.
Library libdl.so.2 (0x8155aed0) needs 0x85cb4310, but it was not found. Ignoring.
Stop waiting for remaining thread 30298
Stop waiting for remaining thread 30301
Stop waiting for remaining thread 30303
Error: Unsupported Syscall 0x38h (56)
ptitSeb commented 3 years ago

The Segfault is caused by a jump to a NULL function pointer (the Warning). The syscall is just an atempt to use the "clone" syscall to call gdb... Use BOX64_DLSYM_ERROR=1 to check if there is any missing symbol with some dlsym(...) calls

Heasterian commented 3 years ago

Looks like some OpenGL symbols are pointing to nill. I'll put whole log here. Rise.txt

Heasterian commented 3 years ago

Rise2.txt

Heasterian commented 3 years ago

Ok, it fixed SIGSEGV soo... Another symbol and same syscall as earlier.

Error: PltResolver: Symbol euidaccess(ver 4: euidaccess@GLIBC_2.2.5) not found, cannot apply R_X86_64_JUMP_SLOT 0x32c05e8 (0x40f186) in /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/RiseOfTheTombRaider
malloc(): memory corruption
Error: Unsupported Syscall 0x38h (56)
Heasterian commented 3 years ago

Ok, so now it's a bit weird. After libpng looks like It's crashes due to issues with chromium. Than tried to launch again without sandbox, reported one missing opcode and hang after loading nss libs without crashing.

Warning: Previous run didn't quit gracefully, attempting to run crash reporter.
[0709/122541:ERROR:browser_main_loop.cc(170)] Running without the SUID sandbox! See https://code.google.com/p/chromium/wiki/LinuxSUIDSandboxDevelopment for more information on developing with the sandbox on.
Box64 with Dynarec v0.1.3 66ed68c built on Jul  9 2021 09:49:42
Using default BOX64_LD_LIBRARY_PATH: ./:lib/:lib64/:x86_64/:bin64/:libs64/
Using default BOX64_PATH: ./:bin/
Counted 79 Env var
BOX64 try to Preload libgtk3-nocsd.so.0 
Looking for /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/RiseOfTheTombRaider
argv[1]="--type=zygote"
argv[2]="--no-sandbox"
argv[3]="--lang=en-US"
argv[4]="--locales-dir-path=/media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/share/cef/locales"
argv[5]="--resources-dir-path=/media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/share/cef"
Error loading needed lib libgtk3-nocsd.so.0
Warning, cannot pre-load a lib
Using native(wrapped) libdl.so.2
Using native(wrapped) libz.so.1
Using native(wrapped) libcurl.so.4
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libssl.so.44
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libcrypto.so.42
Using native(wrapped) libpthread.so.0
Using native(wrapped) librt.so.1
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libSDL2-2.0.7.so
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libSDL2_image-2.0.1.so
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libcef.so
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libpdf.so
Using native(wrapped) libvorbis.so.0
Using native(wrapped) libfreetype.so.6
Using native(wrapped) libfontconfig.so.1
Using native(wrapped) libdbus-1.so.3
Using native(wrapped) libm.so.6
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libgomp.so.1
Using native(wrapped) libc.so.6
Using native(wrapped) ld-linux-x86-64.so.2
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libgobject-2.0.so.0
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libglib-2.0.so.0
Using native(wrapped) libpangocairo-1.0.so.0
Using native(wrapped) libpango-1.0.so.0
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libffi.so.6
Using native(wrapped) libpcre.so.3
Using native(wrapped) libcairo.so.2
Using native(wrapped) libX11.so.6
Using native(wrapped) libXi.so.6
Using native(wrapped) libXext.so.6
Using native(wrapped) libxcb.so.1
Using native(wrapped) libXau.so.6
Using native(wrapped) libXdmcp.so.6
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libnss3.so
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libnssutil3.so
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libsmime3.so
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libplc4.so
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libnspr4.so
Using native(wrapped) libXcomposite.so.1
Using native(wrapped) libasound.so.2
Using native(wrapped) libXdamage.so.1
Using native(wrapped) libXfixes.so.3
Using native(wrapped) libXtst.so.6
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libgconf-2.so.4
Using native(wrapped) libXcursor.so.1
Using native(wrapped) libXrender.so.1
Using native(wrapped) libXrandr.so.2
Using native(wrapped) libexpat.so.1
Using native(wrapped) libcups.so.2
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libcap.so.2
Using emulated /usr/lib/x86_64-linux-gnu/libstdc++.so.6
Using emulated /usr/lib/x86_64-linux-gnu/libgcc_s.so.1
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libplds4.so
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libpci.so.3
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libgio-2.0.so.0
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libgthread-2.0.so.0
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libgmodule-2.0.so.0
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libdbus-glib-1.so.2
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libmount.so.1
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libselinux.so.1
Using native(wrapped) libresolv.so.2
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libblkid.so.1
Using native(wrapped) libuuid.so.1
8580|0x7f822a0328: Unimplemented Opcode (00) F0 48 0F BA 73 38 01 72 ED 48 89 DF E8 E7 FC
RiseOfTheTombRaider: crash reporter initialised with path "/home/heasterian/.local/share/feral-interactive/Rise of the Tomb Raider/crashes"
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libnvidia-ml.so
Error: Global Symbol __ctype_b not found, cannot apply R_X86_64_GLOB_DAT @0x7ec28d5e10 ((nil)) in /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libnvidia-ml.so
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/libffmpegsumo.so
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libsoftokn3.so
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libsqlite3.so.0
Using emulated /media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/../lib/libfreebl3.so
Heasterian commented 3 years ago
[0709/132220:ERROR:nss_util.cc(712)] Error initializing NSS with a persistent database (sql:/media/heasterian/6ccd3ef5-2fe5-4768-8750-05dc9bb6372a/Rise/bin/.pki/nssdb): NSS error code: -8023
[0709/132220:ERROR:nss_util.cc(207)] Error initializing NSS without a persistent database: NSS error code: -8023
[0709/132220:FATAL:nss_util.cc(209)] nss_error=-8023, os_error=0
11165|0x648fda78: Unimplemented Opcode (F9) EE FF FF 17 1F 00 00 71 8D FD FF 54 D3 1B 00
ptitSeb commented 3 years ago

Yes, that NSS error seems to be provoque by an inadequate version of libnss3. I'll try to wrap that lib soon, it seems to be a usefull one.

The Opocde seems like garbage, probably because of the previous error?

Heasterian commented 3 years ago

I guess it's possible, app is trying to run further after this opcode, but crashes anyway reporting broken pipe.

[0709/155905:ERROR:zygote_linux.cc(585)] write: Broken pipe
Heasterian commented 3 years ago

It's now freezing after loading that last lib Rise.txt

rajdakin commented 4 months ago

Is this fixed now?