Comments (14)
Whoops, merged first. Let us know if a second change is needed.
from gamemode.
Just as a quick hack check, if you set export CFLAGS="$CFLAGS -D_GNU_SOURCE
before running meson + compile, does it build then?
from gamemode.
Yes, it worked. Thanks!
from gamemode.
OK ty I'll poke around and see where it is we need this
from gamemode.
@aly199 can you check with my patch there to see if that fixes your issue? Then we know whether it needs closing when that's merged. Thanks.
from gamemode.
Easily usable patch: https://patch-diff.githubusercontent.com/raw/FeralInteractive/gamemode/pull/5.patch
from gamemode.
Or master now. :P
from gamemode.
Hey, it did compile without issues with the patch. But now it seems to have a problem during install with systemd:
alex@nb ~/Downloads/gamemode $ ./bootstrap.sh
- meson --prefix=/usr build -Dwith-systemd-user-unit-dir=/etc/systemd/user
The Meson build system
Version: 0.40.1
Source dir: /home/alex/Downloads/gamemode
Build dir: /home/alex/Downloads/gamemode/build
Build type: native build
Project name: gamemode
Native c compiler: cc (gcc 5.4.0)
Build machine cpu family: x86_64
Build machine cpu: x86_64
Found pkg-config: /usr/bin/pkg-config (0.29.1)
Native dependency libsystemd found: YES 229
Dependency threads found: YES
Library dl found: YES
Configuring config.h using configuration
Submodule 'subprojects/inih' (https://github.com/FeralInteractive/inih.git) registered for path 'inih'
Cloning into 'subprojects/inih'...
remote: Counting objects: 341, done.
remote: Compressing objects: 100% (3/3), done.
remote: Total 341 (delta 0), reused 2 (delta 0), pack-reused 338
Receiving objects: 100% (341/341), 63.05 KiB | 0 bytes/s, done.
Resolving deltas: 100% (202/202), done.
Checking connectivity... done.
Submodule path 'inih': checked out '745ada6724038cde32ff6390b32426cbdd5e532b'
Executing subproject inih.
Project name: inih
Native c compiler: cc (gcc 5.4.0)
Build targets in project: 3
Subproject inih finished.
Configuring gamemoded.service using configuration
Configuring com.feralinteractive.GameMode.policy using configuration
Message:
Build configuration:
====================
prefix: /usr
bindir: /usr/bin
datadir: /usr/share
libdir: /usr/lib/x86_64-linux-gnu
libexecdir: /usr/libexec
includedir: /usr/include
systemd user unit directory: /etc/systemd/user
PolKit Action Directory: /usr/share/polkit-1/actions
Options:
========
daemon: true
examples: true
systemd: true
Build targets in project: 7
- cd build
- ninja
[20/20] Linking target daemon/gamemoded - set +x
Install to /usr? [Yy] y - sudo ninja install
[sudo] password for alex:
[0/1] Installing files.
Installing lib/libgamemode.so to /usr/lib/x86_64-linux-gnu/libgamemode.so
Installing lib/libgamemodeauto.so to /usr/lib/x86_64-linux-gnu/libgamemodeauto.so
Installing daemon/gamemoded to /usr/bin/gamemoded
Installing daemon/cpugovctl to /usr/libexec/cpugovctl
Installing gamemode_client.h to /usr/include/
Installing /home/alex/Downloads/gamemode/data/gamemoded.1 to /usr/share/man/man1
Installing /home/alex/Downloads/gamemode/build/data/gamemoded.service to /etc/systemd/user
Installing /home/alex/Downloads/gamemode/build/data/com.feralinteractive.GameMode.policy to /usr/share/polkit-1/actions - set +x
Enable and run the daemon? [Yy] y - systemctl --user daemon-reload
- systemctl --user enable gamemoded
Created symlink from /home/alex/.config/systemd/user/default.target.wants/gamemoded.service to /etc/systemd/user/gamemoded.service. - systemctl --user start gamemoded
Failed to start gamemoded.service: Unit dbus.socket not found.
from gamemode.
BTW, I'm on Mint 18.2.
from gamemode.
What version of systemd is Mint using? And is this an older Ubuntu spin that uses upstart still or .. ?
from gamemode.
alex@nb ~/Downloads/gamemode $ systemd --version
systemd 229
+PAM +AUDIT +SELINUX +IMA +APPARMOR +SMACK +SYSVINIT +UTMP +LIBCRYPTSETUP +GCRYPT +GNUTLS +ACL +XZ -LZ4 +SECCOMP +BLKID +ELFUTILS +KMOD -IDN
from gamemode.
I think is more of a "Ubuntu 16.04" problem. I am on Kde Neon 5.12.4, which is based on 16.04.
$ systemd --version
systemd 229
+PAM +AUDIT +SELINUX +IMA +APPARMOR +SMACK +SYSVINIT +UTMP +LIBCRYPTSETUP +GCRYPT +GNUTLS +ACL +XZ -LZ4 +SECCOMP +BLKID +ELFUTILS +KMOD -IDN
$ sudo apt install meson libsystemd-dev pkg-config ninja-build
[sudo] password for raitaro:
Reading package lists... Done
Building dependency tree
Reading state information... Done
pkg-config is already the newest version (0.29.1-0ubuntu1).
pkg-config set to manually installed.
Starting pkgProblemResolver with broken count: 0
Starting 2 pkgProblemResolver with broken count: 0
Done
The following NEW packages will be installed:
libsystemd-dev meson ninja-build
0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
Need to get 443 kB of archives.
After this operation, 2,148 kB of additional disk space will be used.
Do you want to continue? [Y/n]
Get:1 http://ro.archive.ubuntu.com/ubuntu xenial-updates/main amd64 libsystemd-dev amd64 229-4ubuntu21.2 [158 kB]
Get:2 http://archive.neon.kde.org/user xenial/main amd64 ninja-build amd64 1.7.1-1~xenial1+16.04+xenial+build3 [91.6 kB]
Get:3 http://archive.neon.kde.org/user xenial/main amd64 meson all 0.42.1-1~xenial1+16.04+xenial+build1 [193 kB]
Fetched 443 kB in 0s (1,029 kB/s)
Selecting previously unselected package libsystemd-dev:amd64.
(Reading database ... 328830 files and directories currently installed.)
Preparing to unpack .../libsystemd-dev_229-4ubuntu21.2_amd64.deb ...
Unpacking libsystemd-dev:amd64 (229-4ubuntu21.2) ...
Selecting previously unselected package ninja-build.
Preparing to unpack .../ninja-build_1.7.1-1~xenial1+16.04+xenial+build3_amd64.deb ...
Unpacking ninja-build (1.7.1-1~xenial1+16.04+xenial+build3) ...
Selecting previously unselected package meson.
Preparing to unpack .../meson_0.42.1-1~xenial1+16.04+xenial+build1_all.deb ...
Unpacking meson (0.42.1-1~xenial1+16.04+xenial+build1) ...
Processing triggers for man-db (2.7.5-1) ...
Setting up libsystemd-dev:amd64 (229-4ubuntu21.2) ...
Setting up ninja-build (1.7.1-1~xenial1+16.04+xenial+build3) ...
Setting up meson (0.42.1-1~xenial1+16.04+xenial+build1) ...
./bootstrap.sh
+ meson --prefix=/usr build -Dwith-systemd-user-unit-dir=/etc/systemd/user
The Meson build system
Version: 0.42.1
Source dir: /home/raitaro/github/gamemode-1.0
Build dir: /home/raitaro/github/gamemode-1.0/build
Build type: native build
Project name: gamemode
Native C compiler: cc (gcc 4.9.3)
Build machine cpu family: x86_64
Build machine cpu: x86_64
Found pkg-config: /usr/bin/pkg-config (0.29.1)
Native dependency libsystemd found: YES 229
Dependency threads found: YES
Library dl found: YES
Configuring config.h using configuration
Cloning into 'inih'...
remote: Counting objects: 341, done.
remote: Compressing objects: 100% (3/3), done.
remote: Total 341 (delta 0), reused 2 (delta 0), pack-reused 338
Receiving objects: 100% (341/341), 63.05 KiB | 57.00 KiB/s, done.
Resolving deltas: 100% (202/202), done.
Checking connectivity... done.
Executing subproject inih.
Project name: inih
Native C compiler: cc (gcc 4.9.3)
Build targets in project: 3
Subproject inih finished.
Configuring gamemoded.service using configuration
Configuring com.feralinteractive.GameMode.policy using configuration
Message:
Build configuration:
====================
prefix: /usr
bindir: /usr/bin
datadir: /usr/share
libdir: /usr/lib/x86_64-linux-gnu
libexecdir: /usr/libexec
includedir: /usr/include
systemd user unit directory: /etc/systemd/user
PolKit Action Directory: /usr/share/polkit-1/actions
Options:
========
daemon: true
examples: true
systemd: true
Build targets in project: 7
+ cd build
+ ninja
[2/20] Compiling C object 'lib/gamemode@sha/client_impl.c.o'.
FAILED: lib/gamemode@sha/client_impl.c.o
cc -Ilib/gamemode@sha -Ilib -I../lib -fdiagnostics-color=always -pipe -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -std=c11 -O0 -g -fstack-protector -Wall -pedantic -Wstrict-prototypes -Wundef -fno-common -Werror-implicit-function-declaration -Wformat -Wformat-security -Werror=format-security -Wconversion -Wunused-variable -Wunreachable-code -W -fPIC -MMD -MQ 'lib/gamemode@sha/client_impl.c.o' -MF 'lib/gamemode@sha/client_impl.c.o.d' -o 'lib/gamemode@sha/client_impl.c.o' -c ../lib/client_impl.c
In file included from /usr/include/systemd/sd-bus.h:28:0,
from ../lib/client_impl.c:36:
/usr/include/systemd/sd-event.h:72:67: error: unknown type name ‘siginfo_t’
typedef int (*sd_event_child_handler_t)(sd_event_source *s, const siginfo_t *si, void *userdata);
^
[3/20] Compiling C object 'daemon/gamemoded@exe/dbus_messaging.c.o'.
FAILED: daemon/gamemoded@exe/dbus_messaging.c.o
cc -Idaemon/gamemoded@exe -Idaemon -I../daemon -I. -I../ -Isubprojects/inih -I../subprojects/inih -fdiagnostics-color=always -pipe -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -std=c11 -O0 -g -fstack-protector -Wall -pedantic -Wstrict-prototypes -Wundef -fno-common -Werror-implicit-function-declaration -Wformat -Wformat-security -Werror=format-security -Wconversion -Wunused-variable -Wunreachable-code -W -pthread -MMD -MQ 'daemon/gamemoded@exe/dbus_messaging.c.o' -MF 'daemon/gamemoded@exe/dbus_messaging.c.o.d' -o 'daemon/gamemoded@exe/dbus_messaging.c.o' -c ../daemon/dbus_messaging.c
In file included from /usr/include/systemd/sd-bus.h:28:0,
from ../daemon/dbus_messaging.c:40:
/usr/include/systemd/sd-event.h:72:67: error: unknown type name ‘siginfo_t’
typedef int (*sd_event_child_handler_t)(sd_event_source *s, const siginfo_t *si, void *userdata);
^
../daemon/dbus_messaging.c:106:4: warning: missing initializer for field ‘signature’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("RegisterGame", "i", "i", method_register_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:40:
/usr/include/systemd/sd-bus-vtable.h:66:37: note: ‘signature’ declared here
const char *signature;
^
../daemon/dbus_messaging.c:106:4: warning: missing initializer for field ‘result’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("RegisterGame", "i", "i", method_register_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:40:
/usr/include/systemd/sd-bus-vtable.h:67:37: note: ‘result’ declared here
const char *result;
^
../daemon/dbus_messaging.c:106:4: warning: missing initializer for field ‘handler’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("RegisterGame", "i", "i", method_register_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:40:
/usr/include/systemd/sd-bus-vtable.h:68:50: note: ‘handler’ declared here
sd_bus_message_handler_t handler;
^
../daemon/dbus_messaging.c:106:4: warning: missing initializer for field ‘offset’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("RegisterGame", "i", "i", method_register_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:40:
/usr/include/systemd/sd-bus-vtable.h:69:32: note: ‘offset’ declared here
size_t offset;
^
../daemon/dbus_messaging.c:107:4: warning: missing initializer for field ‘signature’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("UnregisterGame", "i", "i", method_unregister_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:40:
/usr/include/systemd/sd-bus-vtable.h:66:37: note: ‘signature’ declared here
const char *signature;
^
../daemon/dbus_messaging.c:107:4: warning: missing initializer for field ‘result’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("UnregisterGame", "i", "i", method_unregister_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:40:
/usr/include/systemd/sd-bus-vtable.h:67:37: note: ‘result’ declared here
const char *result;
^
../daemon/dbus_messaging.c:107:4: warning: missing initializer for field ‘handler’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("UnregisterGame", "i", "i", method_unregister_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:40:
/usr/include/systemd/sd-bus-vtable.h:68:50: note: ‘handler’ declared here
sd_bus_message_handler_t handler;
^
../daemon/dbus_messaging.c:107:4: warning: missing initializer for field ‘offset’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("UnregisterGame", "i", "i", method_unregister_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:40:
/usr/include/systemd/sd-bus-vtable.h:69:32: note: ‘offset’ declared here
size_t offset;
^
[10/20] Compiling C object 'daemon/gamemoded@exe/gamemode.c.o'.
../daemon/gamemode.c:73:1: warning: missing braces around initializer [-Wmissing-braces]
static GameModeContext instance = { 0 };
^
../daemon/gamemode.c:73:1: warning: (near initialization for ‘instance.rwlock’) [-Wmissing-braces]
../daemon/gamemode.c:73:1: warning: missing initializer for field ‘refcount’ of ‘GameModeContext’ [-Wmissing-field-initializers]
../daemon/gamemode.c:57:14: note: ‘refcount’ declared here
_Atomic int refcount; /**<Allow cycling the game mode */
^
[11/20] Compiling C object 'daemon/gamemoded@exe/daemon_config.c.o'.
ninja: build stopped: subcommand failed.
I also tried again. Idk, maybe LaTeX made me consider that running something twice may compile it right.
./bootstrap.sh
+ meson --prefix=/usr build -Dwith-systemd-user-unit-dir=/etc/systemd/user
Trying to run Meson on a build directory that has already been configured.
If you want to build it, just run your build command (e.g. ninja) inside the
build directory. Meson will autodetect any changes in your setup and regenerate
itself as required. Though it shouldn't be necessary, running ninja reconfigure
will force Meson to regenerate the build files.
If you want to change option values, use meson configure instead.
+ cd build
+ ninja
[4/11] Compiling C object 'lib/gamemode@sha/client_impl.c.o'.
FAILED: lib/gamemode@sha/client_impl.c.o
cc -Ilib/gamemode@sha -Ilib -I../lib -fdiagnostics-color=always -pipe -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -std=c11 -O0 -g -fstack-protector -Wall -pedantic -Wstrict-prototypes -Wundef -fno-common -Werror-implicit-function-declaration -Wformat -Wformat-security -Werror=format-security -Wconversion -Wunused-variable -Wunreachable-code -W -fPIC -MMD -MQ 'lib/gamemode@sha/client_impl.c.o' -MF 'lib/gamemode@sha/client_impl.c.o.d' -o 'lib/gamemode@sha/client_impl.c.o' -c ../lib/client_impl.c
In file included from /usr/include/systemd/sd-bus.h:28:0,
from ../lib/client_impl.c:36:
/usr/include/systemd/sd-event.h:72:67: error: unknown type name ‘siginfo_t’
typedef int (*sd_event_child_handler_t)(sd_event_source *s, const siginfo_t *si, void *userdata);
^
[5/11] Compiling C object 'daemon/gamemoded@exe/dbus_messaging.c.o'.
FAILED: daemon/gamemoded@exe/dbus_messaging.c.o
cc -Idaemon/gamemoded@exe -Idaemon -I../daemon -I. -I../ -Isubprojects/inih -I../subprojects/inih -fdiagnostics-color=always -pipe -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -std=c11 -O0 -g -fstack-protector -Wall -pedantic -Wstrict-prototypes -Wundef -fno-common -Werror-implicit-function-declaration -Wformat -Wformat-security -Werror=format-security -Wconversion -Wunused-variable -Wunreachable-code -W -pthread -MMD -MQ 'daemon/gamemoded@exe/dbus_messaging.c.o' -MF 'daemon/gamemoded@exe/dbus_messaging.c.o.d' -o 'daemon/gamemoded@exe/dbus_messaging.c.o' -c ../daemon/dbus_messaging.c
In file included from /usr/include/systemd/sd-bus.h:28:0,
from ../daemon/dbus_messaging.c:40:
/usr/include/systemd/sd-event.h:72:67: error: unknown type name ‘siginfo_t’
typedef int (*sd_event_child_handler_t)(sd_event_source *s, const siginfo_t *si, void *userdata);
^
../daemon/dbus_messaging.c:106:4: warning: missing initializer for field ‘signature’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("RegisterGame", "i", "i", method_register_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:40:
/usr/include/systemd/sd-bus-vtable.h:66:37: note: ‘signature’ declared here
const char *signature;
^
../daemon/dbus_messaging.c:106:4: warning: missing initializer for field ‘result’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("RegisterGame", "i", "i", method_register_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:40:
/usr/include/systemd/sd-bus-vtable.h:67:37: note: ‘result’ declared here
const char *result;
^
../daemon/dbus_messaging.c:106:4: warning: missing initializer for field ‘handler’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("RegisterGame", "i", "i", method_register_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:40:
/usr/include/systemd/sd-bus-vtable.h:68:50: note: ‘handler’ declared here
sd_bus_message_handler_t handler;
^
../daemon/dbus_messaging.c:106:4: warning: missing initializer for field ‘offset’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("RegisterGame", "i", "i", method_register_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:40:
/usr/include/systemd/sd-bus-vtable.h:69:32: note: ‘offset’ declared here
size_t offset;
^
../daemon/dbus_messaging.c:107:4: warning: missing initializer for field ‘signature’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("UnregisterGame", "i", "i", method_unregister_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:40:
/usr/include/systemd/sd-bus-vtable.h:66:37: note: ‘signature’ declared here
const char *signature;
^
../daemon/dbus_messaging.c:107:4: warning: missing initializer for field ‘result’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("UnregisterGame", "i", "i", method_unregister_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:40:
/usr/include/systemd/sd-bus-vtable.h:67:37: note: ‘result’ declared here
const char *result;
^
../daemon/dbus_messaging.c:107:4: warning: missing initializer for field ‘handler’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("UnregisterGame", "i", "i", method_unregister_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:40:
/usr/include/systemd/sd-bus-vtable.h:68:50: note: ‘handler’ declared here
sd_bus_message_handler_t handler;
^
../daemon/dbus_messaging.c:107:4: warning: missing initializer for field ‘offset’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("UnregisterGame", "i", "i", method_unregister_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:40:
/usr/include/systemd/sd-bus-vtable.h:69:32: note: ‘offset’ declared here
size_t offset;
^
[7/11] Compiling C object 'example/example@exe/main.c.o'.
ninja: build stopped: subcommand failed.
So after this I used git clone instead of wget to get the most recent code. Now it worked.
/bootstrap.sh
+ meson --prefix=/usr build -Dwith-systemd-user-unit-dir=/etc/systemd/user
The Meson build system
Version: 0.42.1
Source dir: /home/raitaro/github/gamemode
Build dir: /home/raitaro/github/gamemode/build
Build type: native build
Project name: gamemode
Native C compiler: cc (gcc 4.9.3)
Build machine cpu family: x86_64
Build machine cpu: x86_64
Found pkg-config: /usr/bin/pkg-config (0.29.1)
Native dependency libsystemd found: YES 229
Dependency threads found: YES
Library dl found: YES
Configuring config.h using configuration
Submodule 'subprojects/inih' (https://github.com/FeralInteractive/inih.git) registered for path 'inih'
Cloning into 'subprojects/inih'...
remote: Counting objects: 341, done.
remote: Compressing objects: 100% (3/3), done.
remote: Total 341 (delta 0), reused 2 (delta 0), pack-reused 338
Receiving objects: 100% (341/341), 63.05 KiB | 110.00 KiB/s, done.
Resolving deltas: 100% (202/202), done.
Checking connectivity... done.
Submodule path 'inih': checked out '745ada6724038cde32ff6390b32426cbdd5e532b'
Executing subproject inih.
Project name: inih
Native C compiler: cc (gcc 4.9.3)
Build targets in project: 3
Subproject inih finished.
Configuring gamemoded.service using configuration
Configuring com.feralinteractive.GameMode.policy using configuration
Message:
Build configuration:
====================
prefix: /usr
bindir: /usr/bin
datadir: /usr/share
libdir: /usr/lib/x86_64-linux-gnu
libexecdir: /usr/libexec
includedir: /usr/include
systemd user unit directory: /etc/systemd/user
PolKit Action Directory: /usr/share/polkit-1/actions
Options:
========
daemon: true
examples: true
systemd: true
Build targets in project: 7
+ cd build
+ ninja
[7/20] Compiling C object 'daemon/gamemoded@exe/gamemode.c.o'.
../daemon/gamemode.c:73:1: warning: missing braces around initializer [-Wmissing-braces]
static GameModeContext instance = { 0 };
^
../daemon/gamemode.c:73:1: warning: (near initialization for ‘instance.rwlock’) [-Wmissing-braces]
../daemon/gamemode.c:73:1: warning: missing initializer for field ‘refcount’ of ‘GameModeContext’ [-Wmissing-field-initializers]
../daemon/gamemode.c:57:14: note: ‘refcount’ declared here
_Atomic int refcount; /**<Allow cycling the game mode */
^
[8/20] Compiling C object 'daemon/gamemoded@exe/dbus_messaging.c.o'.
../daemon/dbus_messaging.c:108:4: warning: missing initializer for field ‘signature’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("RegisterGame", "i", "i", method_register_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:42:
/usr/include/systemd/sd-bus-vtable.h:66:37: note: ‘signature’ declared here
const char *signature;
^
../daemon/dbus_messaging.c:108:4: warning: missing initializer for field ‘result’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("RegisterGame", "i", "i", method_register_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:42:
/usr/include/systemd/sd-bus-vtable.h:67:37: note: ‘result’ declared here
const char *result;
^
../daemon/dbus_messaging.c:108:4: warning: missing initializer for field ‘handler’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("RegisterGame", "i", "i", method_register_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:42:
/usr/include/systemd/sd-bus-vtable.h:68:50: note: ‘handler’ declared here
sd_bus_message_handler_t handler;
^
../daemon/dbus_messaging.c:108:4: warning: missing initializer for field ‘offset’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("RegisterGame", "i", "i", method_register_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:42:
/usr/include/systemd/sd-bus-vtable.h:69:32: note: ‘offset’ declared here
size_t offset;
^
../daemon/dbus_messaging.c:109:4: warning: missing initializer for field ‘signature’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("UnregisterGame", "i", "i", method_unregister_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:42:
/usr/include/systemd/sd-bus-vtable.h:66:37: note: ‘signature’ declared here
const char *signature;
^
../daemon/dbus_messaging.c:109:4: warning: missing initializer for field ‘result’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("UnregisterGame", "i", "i", method_unregister_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:42:
/usr/include/systemd/sd-bus-vtable.h:67:37: note: ‘result’ declared here
const char *result;
^
../daemon/dbus_messaging.c:109:4: warning: missing initializer for field ‘handler’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("UnregisterGame", "i", "i", method_unregister_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:42:
/usr/include/systemd/sd-bus-vtable.h:68:50: note: ‘handler’ declared here
sd_bus_message_handler_t handler;
^
../daemon/dbus_messaging.c:109:4: warning: missing initializer for field ‘offset’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("UnregisterGame", "i", "i", method_unregister_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:42:
/usr/include/systemd/sd-bus-vtable.h:69:32: note: ‘offset’ declared here
size_t offset;
^
[20/20] Linking target example/example.
+ set +x
Install to /usr? [Yy] Y
+ sudo ninja install
[0/1] Installing files.
Installing lib/libgamemode.so to /usr/lib/x86_64-linux-gnu/libgamemode.so
Installing lib/libgamemodeauto.so to /usr/lib/x86_64-linux-gnu/libgamemodeauto.so
Installing daemon/gamemoded to /usr/bin/gamemoded
Installing daemon/cpugovctl to /usr/libexec/cpugovctl
Installing gamemode_client.h to /usr/include/
Installing /home/raitaro/github/gamemode/data/gamemoded.1 to /usr/share/man/man1
Installing /home/raitaro/github/gamemode/build/data/gamemoded.service to /etc/systemd/user
Installing /home/raitaro/github/gamemode/build/data/com.feralinteractive.GameMode.policy to /usr/share/polkit-1/actions
+ set +x
Enable and run the daemon? [Yy] Y
+ systemctl --user daemon-reload
+ systemctl --user enable gamemoded
Created symlink from /home/raitaro/.config/systemd/user/default.target.wants/gamemoded.service to /etc/systemd/user/gamemoded.service.
+ systemctl --user start gamemoded
Failed to start gamemoded.service: Unit dbus.socket not found.
Unfortunately it seems that there is an issue though:
LD_PRELOAD=/usr/\$LIB/libgamemodeauto.so dolphin
gamemodeauto: Could not call method on bus: No route to host
from gamemode.
In reference of #8:
apt-get install dbus-user-session
Now I get this:
$ ./bootstrap.sh
+ meson --prefix=/usr build -Dwith-systemd-user-unit-dir=/etc/systemd/user
The Meson build system
Version: 0.42.1
Source dir: /home/raitaro/github/gamemode
Build dir: /home/raitaro/github/gamemode/build
Build type: native build
Project name: gamemode
Native C compiler: cc (gcc 4.9.3)
Build machine cpu family: x86_64
Build machine cpu: x86_64
Found pkg-config: /usr/bin/pkg-config (0.29.1)
Native dependency libsystemd found: YES 229
Dependency threads found: YES
Library dl found: YES
Configuring config.h using configuration
Submodule 'subprojects/inih' (https://github.com/FeralInteractive/inih.git) registered for path 'inih'
Cloning into 'subprojects/inih'...
remote: Counting objects: 341, done.
remote: Compressing objects: 100% (3/3), done.
remote: Total 341 (delta 0), reused 2 (delta 0), pack-reused 338
Receiving objects: 100% (341/341), 63.05 KiB | 109.00 KiB/s, done.
Resolving deltas: 100% (202/202), done.
Checking connectivity... done.
Submodule path 'inih': checked out '745ada6724038cde32ff6390b32426cbdd5e532b'
Executing subproject inih.
Project name: inih
Native C compiler: cc (gcc 4.9.3)
Build targets in project: 3
Subproject inih finished.
Configuring gamemoded.service using configuration
Configuring com.feralinteractive.GameMode.policy using configuration
Message:
Build configuration:
====================
prefix: /usr
bindir: /usr/bin
datadir: /usr/share
libdir: /usr/lib/x86_64-linux-gnu
libexecdir: /usr/libexec
includedir: /usr/include
systemd user unit directory: /etc/systemd/user
PolKit Action Directory: /usr/share/polkit-1/actions
Options:
========
daemon: true
examples: true
systemd: true
Build targets in project: 7
+ cd build
+ ninja
[9/20] Compiling C object 'daemon/gamemoded@exe/dbus_messaging.c.o'.
../daemon/dbus_messaging.c:108:4: warning: missing initializer for field ‘signature’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("RegisterGame", "i", "i", method_register_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:42:
/usr/include/systemd/sd-bus-vtable.h:66:37: note: ‘signature’ declared here
const char *signature;
^
../daemon/dbus_messaging.c:108:4: warning: missing initializer for field ‘result’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("RegisterGame", "i", "i", method_register_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:42:
/usr/include/systemd/sd-bus-vtable.h:67:37: note: ‘result’ declared here
const char *result;
^
../daemon/dbus_messaging.c:108:4: warning: missing initializer for field ‘handler’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("RegisterGame", "i", "i", method_register_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:42:
/usr/include/systemd/sd-bus-vtable.h:68:50: note: ‘handler’ declared here
sd_bus_message_handler_t handler;
^
../daemon/dbus_messaging.c:108:4: warning: missing initializer for field ‘offset’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("RegisterGame", "i", "i", method_register_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:42:
/usr/include/systemd/sd-bus-vtable.h:69:32: note: ‘offset’ declared here
size_t offset;
^
../daemon/dbus_messaging.c:109:4: warning: missing initializer for field ‘signature’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("UnregisterGame", "i", "i", method_unregister_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:42:
/usr/include/systemd/sd-bus-vtable.h:66:37: note: ‘signature’ declared here
const char *signature;
^
../daemon/dbus_messaging.c:109:4: warning: missing initializer for field ‘result’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("UnregisterGame", "i", "i", method_unregister_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:42:
/usr/include/systemd/sd-bus-vtable.h:67:37: note: ‘result’ declared here
const char *result;
^
../daemon/dbus_messaging.c:109:4: warning: missing initializer for field ‘handler’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("UnregisterGame", "i", "i", method_unregister_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:42:
/usr/include/systemd/sd-bus-vtable.h:68:50: note: ‘handler’ declared here
sd_bus_message_handler_t handler;
^
../daemon/dbus_messaging.c:109:4: warning: missing initializer for field ‘offset’ of ‘struct <anonymous>’ [-Wmissing-field-initializers]
SD_BUS_METHOD("UnregisterGame", "i", "i", method_unregister_game, SD_BUS_VTABLE_UNPRIVILEGED),
^
In file included from /usr/include/systemd/sd-bus.h:111:0,
from ../daemon/dbus_messaging.c:42:
/usr/include/systemd/sd-bus-vtable.h:69:32: note: ‘offset’ declared here
size_t offset;
^
[14/20] Compiling C object 'daemon/gamemoded@exe/gamemode.c.o'.
../daemon/gamemode.c:73:1: warning: missing braces around initializer [-Wmissing-braces]
static GameModeContext instance = { 0 };
^
../daemon/gamemode.c:73:1: warning: (near initialization for ‘instance.rwlock’) [-Wmissing-braces]
../daemon/gamemode.c:73:1: warning: missing initializer for field ‘refcount’ of ‘GameModeContext’ [-Wmissing-field-initializers]
../daemon/gamemode.c:57:14: note: ‘refcount’ declared here
_Atomic int refcount; /**<Allow cycling the game mode */
^
[20/20] Linking target daemon/gamemoded.
+ set +x
Install to /usr? [Yy] y
+ sudo ninja install
[0/1] Installing files.
Installing lib/libgamemode.so to /usr/lib/x86_64-linux-gnu/libgamemode.so
Installing lib/libgamemodeauto.so to /usr/lib/x86_64-linux-gnu/libgamemodeauto.so
Installing daemon/gamemoded to /usr/bin/gamemoded
Installing daemon/cpugovctl to /usr/libexec/cpugovctl
Installing gamemode_client.h to /usr/include/
Installing /home/raitaro/github/gamemode/data/gamemoded.1 to /usr/share/man/man1
Installing /home/raitaro/github/gamemode/build/data/gamemoded.service to /etc/systemd/user
Installing /home/raitaro/github/gamemode/build/data/com.feralinteractive.GameMode.policy to /usr/share/polkit-1/actions
+ set +x
Enable and run the daemon? [Yy] y
+ systemctl --user daemon-reload
+ systemctl --user enable gamemoded
+ systemctl --user start gamemoded
+ systemctl --user status gamemoded
● gamemoded.service - gamemoded
Loaded: loaded (/etc/systemd/user/gamemoded.service; enabled; vendor preset: enabled)
Active: active (running) since Sat 2018-04-14 18:29:24 EEST; 3min 4s ago
Main PID: 20709 (gamemoded)
CGroup: /user.slice/user-1000.slice/[email protected]/gamemoded.service
└─20709 /usr/bin/gamemoded -l
Apr 14 18:29:24 PC systemd[31022]: Starting gamemoded...
Apr 14 18:29:24 PC /usr/bin/gamemoded[20709]: Note: No config file found [gamemode.ini] in working directory or in [/usr/share/gamemode/]
Apr 14 18:29:24 PC /usr/bin/gamemoded[20709]: governor is set to [powersave]
Apr 14 18:29:24 PC /usr/bin/gamemoded[20709]: Successfully initialised bus with name [com.feralinteractive.GameMode]...
Apr 14 18:29:24 PC systemd[31022]: Started gamemoded.
Apr 14 18:32:29 PC systemd[31022]: Started gamemoded.
So I pretty much ended up with the issue in #14... (konsole starts though)
$ LD_PRELOAD=/usr/\$LIB/libgamemodeauto.so konsole
gamemodeauto: Could not call method on bus: No route to host
$ systemctl --user status gamemoded
● gamemoded.service - gamemoded
Loaded: loaded (/etc/systemd/user/gamemoded.service; enabled; vendor preset: enabled)
Active: active (running) since Sat 2018-04-14 18:29:24 EEST; 8min ago
Main PID: 20709 (gamemoded)
CGroup: /user.slice/user-1000.slice/[email protected]/gamemoded.service
└─20709 /usr/bin/gamemoded -l
Apr 14 18:29:24 PC systemd[31022]: Starting gamemoded...
Apr 14 18:29:24 PC /usr/bin/gamemoded[20709]: Note: No config file found [gamemode.ini] in working directory or in [/usr/share/gamemode/]
Apr 14 18:29:24 PC /usr/bin/gamemoded[20709]: governor is set to [powersave]
Apr 14 18:29:24 PC /usr/bin/gamemoded[20709]: Successfully initialised bus with name [com.feralinteractive.GameMode]...
Apr 14 18:29:24 PC systemd[31022]: Started gamemoded.
Apr 14 18:32:29 PC systemd[31022]: Started gamemoded.
from gamemode.
@mdiluz The patch ebe4165 fixed the issue I think in ubuntu 16.04 and the gang.
LD_PRELOAD=/usr/\$LIB/libgamemodeauto.so konsole
^C
from gamemode.
Related Issues (20)
- gamemoderun steam fails HOT 1
- Nit: tests fail after update to appstream 1.0.2
- Gamemoderun cannot take effect on real game processes in steam HOT 2
- Can't set amd_peformance_level HOT 3
- Shouldn't "renice" be enabled by default? HOT 7
- [Request] Create a new release HOT 2
- does not works with steam or umu-launcher HOT 1
- Add current user to gamemode group during installation
- Custom script or other settings from inside the home directory HOT 1
- Gamemode fails test with prime-run
- Another "object 'libgamemodeauto.so.0' from LD_PRELOAD cannot be preloaded (cannot open shared object file)" error
- Add documentation on how to integrate gamemode in a game.
- .
- mangohud says gamemode is off HOT 4
- Gamemoded -t has errors HOT 2
- Wait for custom script to exit before starting any game-related processes.
- gamemode hangs when running jedi surivior HOT 1
- Gpu device never parsed? HOT 1
- Add option to set AMDGPU pp_power_profile_mode in gamemode
- CODE VEIN crashes when run with gamemode
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gamemode.