Skip to content

Commit 79c5ebb

Browse files
committed
rpm: use /usr/etc/security instead of /etc/security on openSUSE
QubesOS/qubes-issues#6567
1 parent f909c50 commit 79c5ebb

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

misc/Makefile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ BINDIR ?= /usr/bin
22
DATADIR ?= /usr/share
33
SYSLIBDIR ?= /lib
44
LIBDIR ?= /usr/lib
5+
ETCSECURITYDIR ?= /etc/security
56
QUBESLIBDIR := $(LIBDIR)/qubes
67
UDEVRULESDIR := $(SYSLIBDIR)/udev/rules.d
78
QUBESDATADIR := $(DATADIR)/qubes
@@ -52,7 +53,7 @@ install:
5253
install -m 0755 -d $(DESTDIR)/etc/xdg/xfce4/xfconf/xfce-perchannel-xml
5354
install -m 0644 -t $(DESTDIR)/etc/xdg/xfce4/xfconf/xfce-perchannel-xml xfce4-notifyd.xml
5455
install -m 0644 -t $(DESTDIR)/etc/xdg/xfce4/xfconf/xfce-perchannel-xml displays.xml
55-
install -m 0644 -D -t $(DESTDIR)/etc/security/limits.d 90-qubes-core.conf
56+
install -m 0644 -D -t $(DESTDIR)$(ETCSECURITYDIR)/limits.d 90-qubes-core.conf
5657
install -m 0644 -D -t $(DESTDIR)/usr/lib/sysctl.d 20-qubes-core.conf
5758

5859
marker-vm: marker-vm.in

rpm_spec/core-agent.spec.in

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -490,6 +490,10 @@ usermod -L root
490490

491491
%install
492492

493+
%if 0%{?is_opensuse}
494+
export ETCSECURITYDIR=/usr/etc/security
495+
%endif
496+
493497
make install-vm PYTHON=%{__python3} "DESTDIR=$RPM_BUILD_ROOT" SYSTEM_DROPIN_DIR=%{_unitdir} SYSLIBDIR=/usr/lib ENABLE_SELINUX=%with_selinux
494498
make -C app-menu DESTDIR=$RPM_BUILD_ROOT install
495499
make -C boot DESTDIR=$RPM_BUILD_ROOT install
@@ -985,7 +989,11 @@ rm -f %{name}-%{version}
985989
%config(noreplace) /etc/dconf/db/local.d/dpi
986990
%config(noreplace) /etc/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-notifyd.xml
987991
%config(noreplace) /etc/xdg/xfce4/xfconf/xfce-perchannel-xml/displays.xml
992+
%if 0%{?is_opensuse}
993+
%config(noreplace) /usr/etc/security/limits.d/90-qubes-core.conf
994+
%else
988995
%config(noreplace) /etc/security/limits.d/90-qubes-core.conf
996+
%endif
989997
/usr/lib/sysctl.d/20-qubes-core.conf
990998
%_udevrulesdir/50-qubes-mem-hotplug.rules
991999
%_unitdir/[email protected]/90-session-stop-timeout.conf

0 commit comments

Comments
 (0)