Posted December 09, 2016
I recently switched to AMD GPU and Mesa open driver for OpenGL, and tried starting Shadow Warrior. It failed. I run it as follows to get better output:
LIBGL_DEBUG=verbose ./start.sh
Here is the key error from the output:
Running Shadow Warrior (2013)
...
libGL: pci id for fd <...>, driver radeonsi
libGL: OpenDriver: trying /usr/lib/i386-linux-gnu/dri/tls/radeonsi_dri.so
libGL: OpenDriver: trying /usr/lib/i386-linux-gnu/dri/radeonsi_dri.so
libGL: dlopen /usr/lib/i386-linux-gnu/dri/radeonsi_dri.so failed (/opt/games/shadow_warrior/lib/libstdc++.so.6: version `CXXABI_1.3.8' not found (required by /usr/lib/i386-linux-gnu/dri/radeonsi_dri.so))
Problem is in libstdc++.so.6.0.19 shipped with the game (which is loaded with LD_LIBRARY_PATH).
I checked objdump for CXXABI. See relevant parts below:
objdump -x libstdc++.so.6.0.19
....
22 0x00 0x056bafd3 CXXABI_1.3
23 0x00 0x0bafd171 CXXABI_1.3.1
CXXABI_1.3
24 0x00 0x0bafd172 CXXABI_1.3.2
CXXABI_1.3.1
25 0x00 0x0bafd173 CXXABI_1.3.3
CXXABI_1.3.2
26 0x00 0x0bafd174 CXXABI_1.3.4
CXXABI_1.3.3
27 0x00 0x0bafd175 CXXABI_1.3.5
CXXABI_1.3.4
28 0x00 0x0bafd176 CXXABI_1.3.6
CXXABI_1.3.5
29 0x00 0x0bafd177 CXXABI_1.3.7
CXXABI_1.3.6
30 0x00 0x06bc6f71 CXXABI_TM_1
....
objdump -x /usr/lib/i386-linux-gnu/dri/radeonsi_dri.so
....
required from libstdc++.so.6:
0x0bafd178 0x00 32 CXXABI_1.3.8
0x0297f871 0x00 28 GLIBCXX_3.4.21
0x0297f868 0x00 27 GLIBCXX_3.4.18
0x0bafd179 0x00 16 CXXABI_1.3.9
0x0297f865 0x00 14 GLIBCXX_3.4.15
0x056bafd3 0x00 06 CXXABI_1.3
0x08922974 0x00 05 GLIBCXX_3.4
0x0297f870 0x00 04 GLIBCXX_3.4.20
....
Note CXXABI_1.3.8, which is not available in libstdc++.so.6.0.19 shipped with the game.
A workaround for it is to remove / rename the whole lib directory that comes with the game. This way it will use system libs and things work OK.
Please fix it by bundling newer libraries. Or may be don't bundle such stuff as libstdc++ altogether. It doesn't end well.
LIBGL_DEBUG=verbose ./start.sh
Here is the key error from the output:
Running Shadow Warrior (2013)
...
libGL: pci id for fd <...>, driver radeonsi
libGL: OpenDriver: trying /usr/lib/i386-linux-gnu/dri/tls/radeonsi_dri.so
libGL: OpenDriver: trying /usr/lib/i386-linux-gnu/dri/radeonsi_dri.so
libGL: dlopen /usr/lib/i386-linux-gnu/dri/radeonsi_dri.so failed (/opt/games/shadow_warrior/lib/libstdc++.so.6: version `CXXABI_1.3.8' not found (required by /usr/lib/i386-linux-gnu/dri/radeonsi_dri.so))
Problem is in libstdc++.so.6.0.19 shipped with the game (which is loaded with LD_LIBRARY_PATH).
I checked objdump for CXXABI. See relevant parts below:
objdump -x libstdc++.so.6.0.19
....
22 0x00 0x056bafd3 CXXABI_1.3
23 0x00 0x0bafd171 CXXABI_1.3.1
CXXABI_1.3
24 0x00 0x0bafd172 CXXABI_1.3.2
CXXABI_1.3.1
25 0x00 0x0bafd173 CXXABI_1.3.3
CXXABI_1.3.2
26 0x00 0x0bafd174 CXXABI_1.3.4
CXXABI_1.3.3
27 0x00 0x0bafd175 CXXABI_1.3.5
CXXABI_1.3.4
28 0x00 0x0bafd176 CXXABI_1.3.6
CXXABI_1.3.5
29 0x00 0x0bafd177 CXXABI_1.3.7
CXXABI_1.3.6
30 0x00 0x06bc6f71 CXXABI_TM_1
....
objdump -x /usr/lib/i386-linux-gnu/dri/radeonsi_dri.so
....
required from libstdc++.so.6:
0x0bafd178 0x00 32 CXXABI_1.3.8
0x0297f871 0x00 28 GLIBCXX_3.4.21
0x0297f868 0x00 27 GLIBCXX_3.4.18
0x0bafd179 0x00 16 CXXABI_1.3.9
0x0297f865 0x00 14 GLIBCXX_3.4.15
0x056bafd3 0x00 06 CXXABI_1.3
0x08922974 0x00 05 GLIBCXX_3.4
0x0297f870 0x00 04 GLIBCXX_3.4.20
....
Note CXXABI_1.3.8, which is not available in libstdc++.so.6.0.19 shipped with the game.
A workaround for it is to remove / rename the whole lib directory that comes with the game. This way it will use system libs and things work OK.
Please fix it by bundling newer libraries. Or may be don't bundle such stuff as libstdc++ altogether. It doesn't end well.
Post edited December 13, 2016 by shmerl