commit:     466c34fd3e7836a9b180dcf320023596a1df0567
Author:     Mike Gilbert <floppym <AT> gentoo <DOT> org>
AuthorDate: Thu Nov  5 18:38:01 2020 +0000
Commit:     Mike Gilbert <floppym <AT> gentoo <DOT> org>
CommitDate: Thu Nov  5 18:38:01 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=466c34fd

net-misc/openssh: disable utmp and wtmp on musl

Closes: https://bugs.gentoo.org/753230
Signed-off-by: Mike Gilbert <floppym <AT> gentoo.org>

 net-misc/openssh/openssh-8.4_p1-r2.ebuild | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)

diff --git a/net-misc/openssh/openssh-8.4_p1-r2.ebuild 
b/net-misc/openssh/openssh-8.4_p1-r2.ebuild
index 09691782910..4122763052b 100644
--- a/net-misc/openssh/openssh-8.4_p1-r2.ebuild
+++ b/net-misc/openssh/openssh-8.4_p1-r2.ebuild
@@ -320,8 +320,16 @@ src_configure() {
                $(use_with !elibc_Cygwin hardening) #659210
        )
 
-       # stackprotect is broken on musl x86 and ppc
-       use elibc_musl && ( use x86 || use ppc ) && myconf+=( 
--without-stackprotect )
+       if use elibc_musl; then
+               # stackprotect is broken on musl x86 and ppc
+               if use x86 || use ppc; then
+                       myconf+=( --without-stackprotect )
+               fi
+
+               # musl defines bogus values for UTMP_FILE and WTMP_FILE
+               # https://bugs.gentoo.org/753230
+               myconf+=( --disable-utmp --disable-wtmp )
+       fi
 
        # The seccomp sandbox is broken on x32, so use the older method for 
now. #553748
        use amd64 && [[ ${ABI} == "x32" ]] && myconf+=( --with-sandbox=rlimit )

Reply via email to