gamemode
gamemode copied to clipboard
32 bit failed to build on ubuntu 20.04
I've tryied to build 32bit version with an old recipe
`` sudo apt-get install libsystemd-dev:i386 meson libsystemd-dev pkg-config ninja-build git libdbus-1-dev libdbus-1-dev:i386 gcc-multilib
git clone https://github.com/FeralInteractive/gamemode cd gamemode ./bootstrap.sh systemctl --user start gamemoded.service export CFLAGS='-m32' export PKG_CONFIG_PATH='/usr/lib32/pkgconfig' meson build32 -Dwith-daemon=false -Dwith-examples=false -Dwith-systemd=false --prefix=/usr --libdir lib32 sed -i 's/x86_64-linux-gnu/libdbus/i386-linux-gnu/libdbus/g' build32/build.ninja ninja -C build32 ninja -C build32 install sudo` ldconfig
but when I run ninja -C build32
it gives:
ninja: Entering directory `build32' [19/29] Compiling C object 'daemon/f77b12a@@gamemoded@exe/gamemode-ioprio.c.o' ../daemon/gamemode-ioprio.c: In function ‘game_mode_get_ioprio’: ../daemon/gamemode-ioprio.c:63:39: warning: conversion to ‘long unsigned int’ from ‘int’ may change the sign of the result [-Wsign-conversion] 63 | #define IOPRIO_PRIO_DATA(mask) ((mask)&IOPRIO_PRIO_MASK) | ^ ../daemon/gamemode-ioprio.c:104:9: note: in expansion of macro ‘IOPRIO_PRIO_DATA’ 104 | return IOPRIO_PRIO_DATA(ret); | ^~~~~~~~~~~~~~~~ [29/29] Linking target daemon/gamemoded FAILED: daemon/gamemoded cc -o daemon/gamemoded 'daemon/f77b12a@@gamemoded@exe/gamemoded.c.o' 'daemon/f77b12a@@gamemoded@exe/gamemode-context.c.o' 'daemon/f77b12a@@gamemoded@exe/gamemode-ioprio.c.o' 'daemon/f77b12a@@gamemoded@exe/gamemode-sched.c.o' 'daemon/f77b12a@@gamemoded@exe/gamemode-wine.c.o' 'daemon/f77b12a@@gamemoded@exe/gamemode-tests.c.o' 'daemon/f77b12a@@gamemoded@exe/gamemode-gpu.c.o' 'daemon/f77b12a@@gamemoded@exe/gamemode-dbus.c.o' 'daemon/f77b12a@@gamemoded@exe/gamemode-config.c.o' -Wl,--as-needed -Wl,--no-undefined -m32 -Wl,--start-group common/libdaemon-common.a -pthread /lib/x86_64-linux-gnu/libsystemd.so /usr/lib/x86_64-linux-gnu/libinih.so -ldl -Wl,--end-group '-Wl,-rpath,$ORIGIN/../common:/lib/x86_64-linux-gnu:/usr/lib/x86_64-linux-gnu' -Wl,-rpath-link,/home/dikdust/gamemode/build32/common -Wl,-rpath-link,/lib/x86_64-linux-gnu -Wl,-rpath-link,/usr/lib/x86_64-linux-gnu /usr/bin/ld: /lib/x86_64-linux-gnu/libsystemd.so: error adding symbols: file in wrong format collect2: error: ld returned 1 exit status ninja: build stopped: subcommand failed.
With only 64bit installed with apt in lutris enable feral mode is greyed out.
Weird issue, don't know why that is. If you only want 32bit support and don't care about building, you can download the 32bit libs from Debian: https://github.com/FeralInteractive/gamemode/issues/254#issuecomment-643648779
done it but I will continue to obtain ERROR: ld.so: object '/usr/$LIB/libgamemodeauto.so.0' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored. and still lutris enable feral gamemode is greyed out like mentioned in
#254
Maybe I' m missing something ...
library shows in
dikdust@tesla:~$ locate libgamemodeauto.so.0 /usr/lib/i386-linux-gnu/libgamemodeauto.so.0 /usr/lib/i386-linux-gnu/libgamemodeauto.so.0.0.0 /usr/lib/x86_64-linux-gnu/libgamemodeauto.so.0 /usr/lib/x86_64-linux-gnu/libgamemodeauto.so.0.0.
and if I run
gamemoderun |grep LD_PRELOAD I obtain
LD_PRELOAD=/usr/$LIB/libgamemodeauto.so.0
guess something weird with $LIB ?