This War of Mine

This War of Mine

檢視統計資料:
TK 2015 年 4 月 29 日 下午 1:04
[WORKAROUND]: lib32 glibc incompatibility (Arch Linux and Related)
After being several times disappointed with the fact that the developers still have not bothered recompiling against latest glibc and knowing that a downgrade makes this game work I decided to spend a few minutes working out which parts of lib32 glibc this game actually needs.

I ran
$ objdump -x -j.dynamic This\ War\ of\ Mine

And I got:
This War of Mine: file format elf32-i386 This War of Mine architecture: i386, flags 0x00000112: EXEC_P, HAS_SYMS, D_PAGED start address 0x08071baf Program Header: PHDR off 0x00000034 vaddr 0x08047034 paddr 0x08047034 align 2**2 filesz 0x00000140 memsz 0x00000140 flags r-x STACK off 0x00001000 vaddr 0x00000000 paddr 0x00000000 align 2**4 filesz 0x00000000 memsz 0x00000000 flags rw- LOAD off 0x00000000 vaddr 0x08047000 paddr 0x08047000 align 2**12 filesz 0x00001000 memsz 0x00001000 flags rw- DYNAMIC off 0x00000174 vaddr 0x08047174 paddr 0x08047174 align 2**2 filesz 0x00000138 memsz 0x00000138 flags rw- LOAD off 0x00001000 vaddr 0x08048000 paddr 0x08048000 align 2**12 filesz 0x008c220e memsz 0x008c220e flags r-x NOTE off 0x00001168 vaddr 0x08048168 paddr 0x08048168 align 2**2 filesz 0x00000044 memsz 0x00000044 flags r-- INTERP off 0x00003468 vaddr 0x0804a468 paddr 0x0804a468 align 2**0 filesz 0x00000013 memsz 0x00000013 flags r-- EH_FRAME off 0x007a01cc vaddr 0x087e71cc paddr 0x087e71cc align 2**2 filesz 0x0002cb74 memsz 0x0002cb74 flags r-- LOAD off 0x008c37d4 vaddr 0x0890b7d4 paddr 0x0890b7d4 align 2**12 filesz 0x00003404 memsz 0x000b4978 flags rw- RELRO off 0x008c37d4 vaddr 0x0890b7d4 paddr 0x0890b7d4 align 2**0 filesz 0x0000082c memsz 0x0000082c flags r-- Dynamic Section: RUNPATH $ORIGIN NEEDED libOpenAL.so NEEDED libsteam_api.so NEEDED libGL.so.1 NEEDED libX11.so.6 NEEDED libpthread.so.0 NEEDED librt.so.1 NEEDED libstdc++.so.6 NEEDED libm.so.6 NEEDED libgcc_s.so.1 NEEDED libc.so.6 INIT 0x0804c3e0 FINI 0x086d56d4 INIT_ARRAY 0x0890b7d4 INIT_ARRAYSZ 0x000006f0 FINI_ARRAY 0x0890bec4 FINI_ARRAYSZ 0x00000004 GNU_HASH 0x0804a374 STRTAB 0x080472ac SYMTAB 0x08048b04 STRSZ 0x00001857 SYMENT 0x00000010 DEBUG 0x00000000 PLTGOT 0x0890c000 PLTRELSZ 0x00000b58 PLTREL 0x00000011 JMPREL 0x0804b888 REL 0x0804b820 RELSZ 0x00000068 RELENT 0x00000008 VERNEED 0x0804b670 VERNEEDNUM 0x00000006 VERSYM 0x0804b360 Version References: required from librt.so.1: 0x0d696912 0x00 16 GLIBC_2.2 required from libpthread.so.0: 0x06969192 0x00 22 GLIBC_2.12 0x0d696912 0x00 20 GLIBC_2.2 0x0d696911 0x00 11 GLIBC_2.1 0x0d696910 0x00 09 GLIBC_2.0 required from libgcc_s.so.1: 0x0b792650 0x00 17 GCC_3.0 0x0d696910 0x00 06 GLIBC_2.0 required from libc.so.6: 0x0d696911 0x00 21 GLIBC_2.1 0x09691f73 0x00 19 GLIBC_2.1.3 0x06969191 0x00 14 GLIBC_2.11 0x0d696914 0x00 13 GLIBC_2.4 0x09691974 0x00 12 GLIBC_2.3.4 0x0d696913 0x00 10 GLIBC_2.3 0x0d696912 0x00 08 GLIBC_2.2 0x0d696910 0x00 04 GLIBC_2.0 required from libm.so.6: 0x0d696910 0x00 07 GLIBC_2.0 0x0d696911 0x00 03 GLIBC_2.1 required from libstdc++.so.6: 0x02297f89 0x00 18 GLIBCXX_3.4.9 0x0297f861 0x00 15 GLIBCXX_3.4.11 0x056bafd3 0x00 05 CXXABI_1.3 0x08922974 0x00 02 GLIBCXX_3.4 Sections: Idx Name Size VMA LMA File off Algn 0 .dynamic 00000138 08047174 08047174 00000174 2**2 CONTENTS, ALLOC, LOAD, DATA SYMBOL TABLE: 08047174 l d .dynamic 00000000 .dynamic 0890becc l O .dynamic 00000000 _DYNAMIC

The few things to immediately jump out at me were:
NEEDED libpthread.so.0 NEEDED librt.so.1 NEEDED libc.so.6

And, lo and behold,
LD_PRELOAD=../libpthread.so.0:../librt.so.1:../libc.so.6 ./This\ War\ of\ Mine
gets me a working game. At least at first glance.

TL;DR
So, if you want to get this game working without downgrading, find and extract your lib32-glibc-2.20-6 package (probably in /var/cache/pacman/pkg/ if you've not cleaned the cache recently) grab libpthread.so.0, librt.so.1, and libc.so.6 (Arch packages are designed to be applied over your filesystem, this means that libraries can be found in ./usr/lib within the extracted package.) and shove them in the root of This War of Mine. The game _should_ run.

In case this does not work, it has been suggested by the user "sam.garathor" that putting the shared objects (*.so.*) in the lib folder within the root folder of the game as opposed to just the root might work.

If you do not have the old package version needed for this fix, you can probably build it from a modified PKGBUILD or you can attempt to locate the correct version in the "Arch Rollback Machine" repositories, more information about ARM can be found here:

https://wiki.archlinux.org/index.php/Arch_Rollback_Machine
最後修改者:TK; 2015 年 5 月 14 日 下午 12:15
< >
目前顯示第 1-10 則留言,共 10
rustydrd 2015 年 5 月 8 日 下午 4:35 
Worked for me (with one slight adjustment)! Thanks a bunch! Here is what I did in detail:

http://steamcommunity.com/app/282070/discussions/0/610573751159186268/#c613957600534194492

However, I had to copy the files to a different destination than is described here.
Angry Penguin 2015 年 5 月 9 日 下午 2:38 
I have hope this solution can works on Ubuntu 15.04 x64. Tomorow I should check this and give a know.

BTW. thanks for a good solution.
最後修改者:Angry Penguin; 2015 年 5 月 9 日 下午 2:39
JoZ3 2015 年 5 月 12 日 下午 2:31 
Thanks for the tip, unfortunately for my Manjaro x64 with Catalyst drivers did not work :(
最後修改者:JoZ3; 2015 年 5 月 12 日 下午 2:31
TK 2015 年 5 月 14 日 下午 12:20 
引用自 Linux JoZ3
Thanks for the tip, unfortunately for my Manjaro x64 with Catalyst drivers did not work :(

It's possible you might need an older libgl or some other older package, or you could try the solution provided by sam.garathor.

You can also experiment with reverting to older package versions until the game starts working (package versions contianing the listed libraries, read the pacman manpage to figure out which libraries are provided by which packages). Once you manage to get a working game, take a look at all the libraries the downgraded packages provide, experiment with different combinations until you find the minimum working solution, compare the libraries provided by the packages you're left with, with the libraries listed above (the ones in the objdump output) and then form your own solution around that.
Ramblurr 2015 年 6 月 18 日 下午 12:55 
For people on Fedora (Fedora 22 here), here's what you should do:

1. Locate your favorite Fedora mirror and wget /fedora/linux/updates/21/i386/g/glibc-2.20-8.fc21.i686.rpm
2. Extract the rpm using a GUI tool or:

mkdir glibc-2.20-8.fc21.i686 && cd glibc-2.20-8.fc21.i686
rpm2cpio glibc-2.20-8.fc21.i686.rpm | cpio -idmv
3. Copy the libs you need

cp ./lib/i686/nosegneg/libpthread-2.20.so ~/.steam/steam/SteamApps/common/This\ War\ of\ Mine
cp ./glibc-2.20-8.fc21.i686/lib/libc-2.20.so ~/.steam/steam/SteamApps/common/This\ War\ of\ Mine
cp ./glibc-2.20-8.fc21.i686/lib/librt-2.20.so ~/.steam/steam/SteamApps/common/This\ War\ of\ Mine
4. Run the game
cd ~/.steam/steam/SteamApps/common/This\ War\ of\ Mine
LD_PRELOAD=ibpthread-2.20.so:librt-2.20.so:libc-2.20.so ./This\ War\ of\ Mine

Frankly, it is ridiculous we have to do this to play a game we spent money on. But, at least it works and major props to the devs for releasing on Linux. This game rocks.
最後修改者:Ramblurr; 2015 年 6 月 18 日 下午 12:56
gibblets 2015 年 6 月 20 日 上午 12:29 
Same issue here. Would love an official fix going forward. Shouldn't this kind of thing be included in the Steam Runtime if necessary?
Wanheda 2015 年 7 月 6 日 下午 7:18 
引用自 Ramblurr
For people on Fedora (Fedora 22 here), here's what you should do:

1. Locate your favorite Fedora mirror and wget /fedora/linux/updates/21/i386/g/glibc-2.20-8.fc21.i686.rpm
2. Extract the rpm using a GUI tool or:

mkdir glibc-2.20-8.fc21.i686 && cd glibc-2.20-8.fc21.i686
rpm2cpio glibc-2.20-8.fc21.i686.rpm | cpio -idmv
3. Copy the libs you need

cp ./lib/i686/nosegneg/libpthread-2.20.so ~/.steam/steam/SteamApps/common/This\ War\ of\ Mine
cp ./glibc-2.20-8.fc21.i686/lib/libc-2.20.so ~/.steam/steam/SteamApps/common/This\ War\ of\ Mine
cp ./glibc-2.20-8.fc21.i686/lib/librt-2.20.so ~/.steam/steam/SteamApps/common/This\ War\ of\ Mine
4. Run the game
cd ~/.steam/steam/SteamApps/common/This\ War\ of\ Mine
LD_PRELOAD=ibpthread-2.20.so:librt-2.20.so:libc-2.20.so ./This\ War\ of\ Mine

Frankly, it is ridiculous we have to do this to play a game we spent money on. But, at least it works and major props to the devs for releasing on Linux. This game rocks.

Rocking post. Thanks. Note there is a typo in the LD_PRELOAD statement, you need a leading L there if you're copy-pasting, that might get you.
Asturio 2016 年 11 月 27 日 上午 1:39 
Just want to register here, that I bought the game yesterday, and I'm still having the problem. The game freezes in the load-screen. Running Debian 8 (Jessie). And tried to run on Windows 10, and there are no text in the game.
[GD]Krom 2016 年 11 月 28 日 下午 1:00 
Had a problem with loading the wrong arch for one of the games binaries.
In the end, it was my fault, because I f*cked up my ldconfig by setting all kinds of paths to my LD_LIBRARY_PATH.
What I then did was to remove almost everything from the LD_LIBRARY_PATH and added proper conf files to /etc/ld.conf.so.d/. After that a "sudo ldconfig" and the error was gone.

What you want to have is the path to the libraries steam delivers.
For me, on Ubuntu, it's this one:
/home/myusername/.local/share/Steam/ubuntu12_32/steam-runtime/i386/usr/lib/i386-linux-gnu

I added that path to a new file /etc/ld.conf.d/i386-steam.conf, as described above. The system then can deliver the required binaries, either 64bit or 32bit. At least for me ;p

Edit:
Hm, okay. Looks like the game does not use the steam libraries, but my own ones, which seem to be compatible with this game. I'm on Xubuntu 16.10 using amdgpupro drivers. Sorry. :|
最後修改者:[GD]Krom; 2016 年 11 月 28 日 下午 1:04
Asturio 2016 年 11 月 29 日 下午 2:13 
Just tried today swiching from the fglrx driver to the open source radeon driver. This fixed the problem for me. The problem was not the glibc, but the X-Driver. I think the driver from AMD doesn't support some features the game needs.
< >
目前顯示第 1-10 則留言,共 10
每頁顯示: 1530 50

張貼日期: 2015 年 4 月 29 日 下午 1:04
回覆: 10