Skip to content

Commit f650bc0

Browse files
committed
Linux: fix regression on Suse builds, move if check inside old init / userdel section
git-svn-id: https://svn.code.sf.net/p/davmail/code/trunk@4070 3d1905a2-6b24-0410-a738-b14d5a86fcbd
1 parent 16b84b5 commit f650bc0

1 file changed

Lines changed: 4 additions & 6 deletions

File tree

davmail.spec

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,6 @@ BuildRequires: ant-unbound
3838
BuildRequires: java-1.8.0-openjdk-devel
3939
%endif
4040

41-
%if 0%{?is_opensuse} || 0%{?suse_version}
42-
BuildRequires: java-21-openjdk-devel
43-
%endif
44-
4541
# compile with JavaFX on Fedora and latest Suse
4642
%if 0%{?fedora} > 38 || 0%{?suse_version} >= 01699
4743
BuildRequires: openjfx
@@ -199,9 +195,9 @@ fi
199195
%endif
200196
%endif
201197

202-
if [ "$1" = "0" ]; then
203198
%if %systemd_support
204199
%else
200+
if [ "$1" = "0" ]; then
205201
/sbin/service davmail stop > /dev/null 2>&1 || :
206202
/bin/rm -f /var/lib/davmail/pid > /dev/null 2>&1 || :
207203
%{?stop_on_removal:
@@ -212,15 +208,17 @@ if [ "$1" = "0" ]; then
212208
/sbin/chkconfig davmail off
213209
/sbin/chkconfig --del davmail
214210
}
211+
fi
215212
%endif
216213

217214
%if !%systemd_macros
215+
if [ "$1" = "0" ]; then
218216
/usr/sbin/userdel davmail
219217
if getent group davmail >/dev/null 2>&1; then
220218
/usr/sbin/groupdel davmail
221219
fi
222-
%endif
223220
fi
221+
%endif
224222

225223
%postun
226224
%if %systemd_macros

0 commit comments

Comments
 (0)