service file: allow for waybar installed in different prefix (#458)

service file: allow for waybar installed in different prefix
This commit is contained in:
Alex 2019-09-10 11:56:20 +02:00 committed by GitHub
commit b6cb02ce85
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 3 deletions

View File

@ -66,8 +66,13 @@ systemd = dependency('systemd', required: get_option('systemd'))
if systemd.found() if systemd.found()
user_units_dir = systemd.get_pkgconfig_variable('systemduserunitdir') user_units_dir = systemd.get_pkgconfig_variable('systemduserunitdir')
install_data('./resources/waybar.service',
install_dir: user_units_dir) configure_file(
configuration: config,
input: './resources/waybar.service.in',
output: '@BASENAME@',
install_dir: user_units_dir
)
endif endif
src_files = files( src_files = files(

View File

@ -6,7 +6,7 @@ PartOf=wayland-session.target
[Service] [Service]
Type=dbus Type=dbus
BusName=fr.arouillard.waybar BusName=fr.arouillard.waybar
ExecStart=/usr/bin/waybar ExecStart=@prefix@/bin/waybar
[Install] [Install]
WantedBy=wayland-session.target WantedBy=wayland-session.target