From owner-freebsd-ppc@freebsd.org Tue May 12 18:23:12 2020 Return-Path: Delivered-To: freebsd-ppc@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 52A822F72D0 for ; Tue, 12 May 2020 18:23:12 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from freefall.freebsd.org (freefall.freebsd.org [96.47.72.132]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "freefall.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 49M5lN1Yb3z4cP3 for ; Tue, 12 May 2020 18:23:12 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: by freefall.freebsd.org (Postfix) id 2EF0C1CBF; Tue, 12 May 2020 18:23:12 +0000 (UTC) Delivered-To: powerpc@localmail.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits)) (Client CN "mx1.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by freefall.freebsd.org (Postfix) with ESMTPS id 10C861D38 for ; Tue, 12 May 2020 18:23:12 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 49M5lM5xTrz4cP2 for ; Tue, 12 May 2020 18:23:11 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id C763FC642 for ; Tue, 12 May 2020 18:23:11 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 04CINBUb039179 for ; Tue, 12 May 2020 18:23:11 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 04CINBtn039174 for powerpc@FreeBSD.org; Tue, 12 May 2020 18:23:11 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: powerpc@FreeBSD.org Subject: [Bug 246419] security/nss: fix build on powerpc64 elfv1 Date: Tue, 12 May 2020 18:23:10 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Ports & Packages X-Bugzilla-Component: Individual Port(s) X-Bugzilla-Version: Latest X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Many People X-Bugzilla-Who: pkubaj@FreeBSD.org X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: gecko@FreeBSD.org X-Bugzilla-Flags: maintainer-feedback? merge-quarterly? X-Bugzilla-Changed-Fields: attachments.isobsolete flagtypes.name attachments.created Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 May 2020 18:23:12 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D246419 Piotr Kubaj changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #214418|0 |1 is obsolete| | Attachment #214418|maintainer-approval?(gecko@ | Flags|FreeBSD.org) | Attachment #214420| |maintainer-approval?(gecko@ Flags| |FreeBSD.org) --- Comment #3 from Piotr Kubaj --- Created attachment 214420 --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=3D214420&action= =3Dedit v3 More correct solution. The previous patch worked, but sha512-p8 wasn't included in the final binary because USE_PPC_CRYPTO is disabled. sha512-p8 was just built, but not used earlier. This is why all tests passed. The problem with it is that the assembly is tailored to little-endian and w= on't work on big-endian. However, there is a proper script to generate sha512-p8= for big-endian, both elfv1 and elfv2. There is also a variant for 32-bit powerp= c. Ideally, this script should run always, but upstream seems to have forgotten that and just put the generated sha512-p8 to the source. This patch takes c= are of running this script. Also, since USE_PPC_CRYPTO works on big-endian, put an option to enable tha= t. It will use VSX, which is available on POWER8 and newer. I made it availabl= e on 32 bits as well, just in case someone on VSX-capable machine wants to run 32-bit chroot or jail. --=20 You are receiving this mail because: You are on the CC list for the bug.=