restorecond: Rename restorecond-user.service to restorecond_user.service
PATCH 1/2 restorecond: Rename restorecond-user.service to restorecond_user.service
Make user restorecond systemd service consistent with restorecond_user.conf file used by restorecond -u
---
restorecond/Makefile | 2 +-
restorecond/org.selinux.Restorecond.service | 2 +-
.../{restorecond-user.service => restorecond_user.service} | 0
3 files changed, 2 insertions(+), 2 deletions(-)
rename restorecond/{restorecond-user.service => restorecond_user.service} (100%)restorecond/Makefile +1 -1
@@ -51,7 +51,7 @@ install: all -mkdir -p $(DESTDIR)$(SYSTEMDDIR)/system install -m 644 restorecond.service $(DESTDIR)$(SYSTEMDDIR)/system/ -mkdir -p $(DESTDIR)$(SYSTEMDDIR)/user - install -m 644 restorecond-user.service $(DESTDIR)$(SYSTEMDDIR)/user/ + install -m 644 restorecond_user.service $(DESTDIR)$(SYSTEMDDIR)/user/ relabel: install /sbin/restorecon $(DESTDIR)$(SBINDIR)/restorecond
restorecond/org.selinux.Restorecond.service +1 -1
@@ -1,4 +1,4 @@ [D-BUS Service] Name=org.selinux.Restorecond Exec=/usr/sbin/restorecond -u -SystemdService=restorecond-user.service +SystemdService=restorecond_user.service
restorecond/restorecond_user.service renamed from restorecond/restorecond-user.service +0 -0
Signature · 1 line
2.26.2
PATCH 2/2 restorecond: Use pkg-config to get locations for systemd units
The user systemd service file could be installed in an other location than the system ones. In debian for example, the system files are installed /lib/systemd/system and the user ones in /usr/lib/systemd/user.
--- restorecond/Makefile | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-)
restorecond/Makefile +6 -5
@@ -7,7 +7,8 @@ SBINDIR ?= $(PREFIX)/sbin MANDIR = $(PREFIX)/share/man AUTOSTARTDIR = /etc/xdg/autostart DBUSSERVICEDIR = $(PREFIX)/share/dbus-1/services -SYSTEMDDIR ?= $(PREFIX)/lib/systemd +SYSTEMDSYSTEMUNITDIR ?= $(shell $(PKG_CONFIG) --variable=systemdsystemunitdir systemd) +SYSTEMDUSERUNITDIR ?= $(shell $(PKG_CONFIG) --variable=systemduserunitdir systemd) autostart_DATA = sealertauto.desktop INITDIR ?= /etc/rc.d/init.d
@@ -48,10 +49,10 @@ install: all install -m 644 restorecond.desktop $(DESTDIR)$(AUTOSTARTDIR)/restorecond.desktop -mkdir -p $(DESTDIR)$(DBUSSERVICEDIR) install -m 644 org.selinux.Restorecond.service $(DESTDIR)$(DBUSSERVICEDIR)/org.selinux.Restorecond.service - -mkdir -p $(DESTDIR)$(SYSTEMDDIR)/system - install -m 644 restorecond.service $(DESTDIR)$(SYSTEMDDIR)/system/ - -mkdir -p $(DESTDIR)$(SYSTEMDDIR)/user - install -m 644 restorecond_user.service $(DESTDIR)$(SYSTEMDDIR)/user/ + -mkdir -p $(DESTDIR)$(SYSTEMDSYSTEMUNITDIR) + install -m 644 restorecond.service $(DESTDIR)$(SYSTEMDSYSTEMUNITDIR) + -mkdir -p $(DESTDIR)$(SYSTEMDUSERUNITDIR) + install -m 644 restorecond_user.service $(DESTDIR)$(SYSTEMDUSERUNITDIR) relabel: install /sbin/restorecon $(DESTDIR)$(SBINDIR)/restorecond
Signature · 1 line
2.26.2
Re: [PATCH 2/2] restorecond: Use pkg-config to get locations for systemd units
Quoted 7 lines · Petr Lautrbach
The user systemd service file could be installed in an other location than the system ones. In debian for example, the system files are installed
/lib/systemd/systemand the user ones in/usr/lib/systemd/user.Suggested-by Laurent Bigonville <[email protected]>Signed-off-by Petr Lautrbach <[email protected]>
I confirm the pkg-config commands work on Arch Linux too. By the way, on Debian this patch makes building restorecond now require systemd to be installed (because /usr/share/pkgconfig/systemd.pc is provided by package "systemd"), but I guess this shouldn't be an issue.
For both patches:
You can merge them when you want, or I will do so on Monday. Thanks,
Nicolas
Quoted 36 lines
--- restorecond/Makefile | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-)restorecond/Makefile +6
-6@@ -7,7 +7,8 @@ SBINDIR ?= $(PREFIX)/sbin MANDIR = $(PREFIX)/share/man AUTOSTARTDIR = /etc/xdg/autostart DBUSSERVICEDIR = $(PREFIX)/share/dbus-1/services -SYSTEMDDIR ?= $(PREFIX)/lib/systemd +SYSTEMDSYSTEMUNITDIR ?= $(shell $(PKG_CONFIG) --variable=systemdsystemunitdir systemd) +SYSTEMDUSERUNITDIR ?= $(shell $(PKG_CONFIG) --variable=systemduserunitdir systemd) autostart_DATA = sealertauto.desktop INITDIR ?= /etc/rc.d/init.d@@ -48,10 +49,10 @@ install: all install -m 644 restorecond.desktop $(DESTDIR)$(AUTOSTARTDIR)/restorecond.desktop -mkdir -p $(DESTDIR)$(DBUSSERVICEDIR) install -m 644 org.selinux.Restorecond.service $(DESTDIR)$(DBUSSERVICEDIR)/org.selinux.Restorecond.service - -mkdir -p $(DESTDIR)$(SYSTEMDDIR)/system - install -m 644 restorecond.service $(DESTDIR)$(SYSTEMDDIR)/system/ - -mkdir -p $(DESTDIR)$(SYSTEMDDIR)/user - install -m 644 restorecond_user.service $(DESTDIR)$(SYSTEMDDIR)/user/ + -mkdir -p $(DESTDIR)$(SYSTEMDSYSTEMUNITDIR) + install -m 644 restorecond.service $(DESTDIR)$(SYSTEMDSYSTEMUNITDIR) + -mkdir -p $(DESTDIR)$(SYSTEMDUSERUNITDIR) + install -m 644 restorecond_user.service $(DESTDIR)$(SYSTEMDUSERUNITDIR) relabel: install /sbin/restorecon $(DESTDIR)$(SBINDIR)/restorecond --2.26.2
Re: [PATCH 2/2] restorecond: Use pkg-config to get locations for systemd units
Quoted 14 lines · Nicolas Iooss
Quoted 7 lines · Petr Lautrbach
The user systemd service file could be installed in an other location than the system ones. In debian for example, the system files are installed
/lib/systemd/systemand the user ones in/usr/lib/systemd/user.Suggested-by Laurent Bigonville <[email protected]>Signed-off-by Petr Lautrbach <[email protected]>I confirm the pkg-config commands work on Arch Linux too. By the way, on Debian this patch makes building restorecond now require systemd to be installed (because
/usr/share/pkgconfig/systemd.pcis provided by package "systemd"), but I guess this shouldn't be an issue.
Quoted 7 lines
For both patches:
Acked-by Nicolas Iooss <[email protected]>You can merge them when you want, or I will do so on Monday. Thanks,
Nicolas
Thanks.
Both applied.
Quoted 38 lines
Quoted 37 lines
--- restorecond/Makefile | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-)restorecond/Makefile +6
-6@@ -7,7 +7,8 @@ SBINDIR ?= $(PREFIX)/sbin MANDIR = $(PREFIX)/share/man AUTOSTARTDIR = /etc/xdg/autostart DBUSSERVICEDIR = $(PREFIX)/share/dbus-1/services -SYSTEMDDIR ?= $(PREFIX)/lib/systemd +SYSTEMDSYSTEMUNITDIR ?= $(shell $(PKG_CONFIG) --variable=systemdsystemunitdir systemd) +SYSTEMDUSERUNITDIR ?= $(shell $(PKG_CONFIG) --variable=systemduserunitdir systemd) autostart_DATA = sealertauto.desktop INITDIR ?= /etc/rc.d/init.d@@ -48,10 +49,10 @@ install: all install -m 644 restorecond.desktop $(DESTDIR)$(AUTOSTARTDIR)/restorecond.desktop -mkdir -p $(DESTDIR)$(DBUSSERVICEDIR) install -m 644 org.selinux.Restorecond.service $(DESTDIR)$(DBUSSERVICEDIR)/org.selinux.Restorecond.service - -mkdir -p $(DESTDIR)$(SYSTEMDDIR)/system - install -m 644 restorecond.service $(DESTDIR)$(SYSTEMDDIR)/system/ - -mkdir -p $(DESTDIR)$(SYSTEMDDIR)/user - install -m 644 restorecond_user.service $(DESTDIR)$(SYSTEMDDIR)/user/ + -mkdir -p $(DESTDIR)$(SYSTEMDSYSTEMUNITDIR) + install -m 644 restorecond.service $(DESTDIR)$(SYSTEMDSYSTEMUNITDIR) + -mkdir -p $(DESTDIR)$(SYSTEMDUSERUNITDIR) + install -m 644 restorecond_user.service $(DESTDIR)$(SYSTEMDUSERUNITDIR) relabel: install /sbin/restorecon $(DESTDIR)$(SBINDIR)/restorecond --2.26.2
Signature · 2 lines
() ascii ribbon campaign - against html e-mail /\ www.asciiribbon.org - against proprietary attachments