From: Elan Ruusamäe Date: Wed, 25 Mar 2015 12:34:19 +0000 (+0200) Subject: hack: require openssh-server only if sshd user does not exist X-Git-Tag: auto/th/openssh-6.8p1-5~6 X-Git-Url: http://git.pld-linux.org/gitweb.cgi?a=commitdiff_plain;h=9880a59f756b36e134de49bbf95e5c9615fcf80c;p=packages%2Fopenssh.git hack: require openssh-server only if sshd user does not exist refs 163b394 --- diff --git a/openssh.spec b/openssh.spec index 64a5dd8..fb9293c 100644 --- a/openssh.spec +++ b/openssh.spec @@ -73,7 +73,6 @@ Patch15: %{name}-disable_ldap.patch Patch16: libseccomp-sandbox.patch URL: http://www.openssh.com/portable.html BuildRequires: %{__perl} -%{?with_tests:BuildRequires: %{name}-server} %{?with_audit:BuildRequires: audit-libs-devel} BuildRequires: autoconf >= 2.50 BuildRequires: automake @@ -93,6 +92,9 @@ BuildRequires: sed >= 4.0 # libseccomp based sandbox requires NO_NEW_PRIVS prctl flag %{?with_tests:BuildRequires: uname(release) >= 3.5} BuildRequires: zlib-devel >= 1.2.3 +%if %{with tests} && 0%(id -u sshd 2>/dev/null; echo $?) +BuildRequires: %{name}-server +%endif Requires: zlib >= 1.2.3 %if "%{pld_release}" == "ac" Requires: filesystem >= 2.0-1