retroarch-standalone-service/Makefile
graysky 8c5d854a36 back to user.slice
It seems that as long as the Kodi menu is used to call a shutdown or reboot,
the services will allow the application to gracefully exit including saving
settings, uptime etc.  This will only NOT occur if the user calls the box to
shutdown or reboot via a call to systemctl for the reasons cited in previous
commits.

While not optimal, it is consistent with the same thing happening if others
users are logged into the box, working, and a sysadmin calls the systemctl
to reboot.  The result is users will lose work/data.

Going back to the user.slice is better for USB mounts, and for pulseaudio
sessions as well.
2021-01-03 21:15:41 -05:00

38 lines
1.2 KiB
Makefile

PN = kodi-standalone-service
PREFIX ?= /usr
INITDIR = $(PREFIX)/lib/systemd/system
USERDIR = $(PREFIX)/lib/sysusers.d
TMPFDIR = $(PREFIX)/lib/tmpfiles.d
RM = rm
INSTALL = install -p
INSTALL_DIR = $(INSTALL) -d
INSTALL_PROGRAM = $(INSTALL) -m755
INSTALL_DATA = $(INSTALL) -m644
common/$(PN):
@echo -e '\033[1;32mNothing to be done.\033[0m'
@echo -e '\033[1;32mJust run make install as root.\033[0m'
install-init:
$(INSTALL_DIR) "$(DESTDIR)$(INITDIR)"
$(INSTALL_DIR) "$(DESTDIR)$(USERDIR)"
$(INSTALL_DIR) "$(DESTDIR)$(TMPFDIR)"
$(INSTALL_DATA) init/kodi-gbm.service "$(DESTDIR)$(INITDIR)/kodi-gbm.service"
$(INSTALL_DATA) init/kodi-wayland.service "$(DESTDIR)$(INITDIR)/kodi-wayland.service"
$(INSTALL_DATA) init/kodi-x11.service "$(DESTDIR)$(INITDIR)/kodi-x11.service"
$(INSTALL_DATA) init/tmpfiles.conf "$(DESTDIR)$(TMPFDIR)/kodi-standalone.conf"
$(INSTALL_DATA) init/sysusers.conf "$(DESTDIR)$(USERDIR)/kodi-standalone.conf"
uninstall:
$(RM) "$(DESTDIR)$(INITDIR)/kodi-gbm.service"
$(RM) "$(DESTDIR)$(INITDIR)/kodi-wayland.service"
$(RM) "$(DESTDIR)$(INITDIR)/kodi-x11.service"
$(RM) "$(DESTDIR)$(TMPFDIR)/kodi-standalone.conf"
$(RM) "$(DESTDIR)$(USERDIR)/kodi-standalone.conf"
install: install-init
.PHONY: install-init uninstall