From owner-freebsd-toolchain@FreeBSD.ORG Fri Apr 3 21:15:54 2015 Return-Path: Delivered-To: freebsd-toolchain@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id BCC02F6D; Fri, 3 Apr 2015 21:15:54 +0000 (UTC) Received: from mail-pa0-x229.google.com (mail-pa0-x229.google.com [IPv6:2607:f8b0:400e:c03::229]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 8A02F34C; Fri, 3 Apr 2015 21:15:54 +0000 (UTC) Received: by paboj16 with SMTP id oj16so46081373pab.0; Fri, 03 Apr 2015 14:15:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=content-type:mime-version:subject:from:in-reply-to:date:cc :message-id:references:to; bh=eU9JKpqjPlPw8Rhvo8CLy8mfCN5+WpatSehfspsNDKw=; b=jdsBgEYAc04YbI+O4RNkbeRCOwjUoOmWA76uiFx3rDaqvDS68ZARf4RdmWLMqE94W0 eKI9RTzXgjc/Z4bSuHB37wjTzkg43XLS/qnWffCzqUmTiHX3L9JczKlND1B8+3YaHoop 00MYpfmyda99PG/9PxyutXh5HRfYY/nhEfSNc1fRvy1ZQMJra4LC9LIh1WssfgQe+SWU 090npIydJtF1dlF8whVo2FpMAoyQDZ0B1NQuqchc5p3UJKpnZ9HFKnZlyjH19ttJmjTS TI0CRx8l5I6U2Sja0eJKapjyXy6tsINO1LDxmIlu2ehS1hDqIfB8MzXGObOvOSnOd8WA vqEA== X-Received: by 10.67.22.72 with SMTP id hq8mr7426901pad.154.1428095754023; Fri, 03 Apr 2015 14:15:54 -0700 (PDT) Received: from ?IPv6:2601:8:ab80:7d6:c0f7:599f:1bc7:96bd? ([2601:8:ab80:7d6:c0f7:599f:1bc7:96bd]) by mx.google.com with ESMTPSA id nn6sm8723141pdb.79.2015.04.03.14.15.52 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 03 Apr 2015 14:15:53 -0700 (PDT) Content-Type: multipart/signed; boundary="Apple-Mail=_2A31875E-D891-44B3-AC52-7782582485AE"; protocol="application/pgp-signature"; micalg=pgp-sha512 Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\)) Subject: Re: Failed to build rescue with gcc 4.9 From: Garrett Cooper In-Reply-To: <04452C2A-FB67-465B-AE33-44ED2109672E@bsdimp.com> Date: Fri, 3 Apr 2015 14:15:50 -0700 Message-Id: <73C7F494-54BD-4E83-B2AD-882D8C3FF11A@gmail.com> References: <2D2191D4-DB6F-4889-9CA9-DFEE495D8302@bsdimp.com> <04452C2A-FB67-465B-AE33-44ED2109672E@bsdimp.com> To: Warner Losh X-Mailer: Apple Mail (2.1878.6) Cc: "freebsd-testing@freebsd.org" , FreeBSD Toolchain X-BeenThere: freebsd-toolchain@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Maintenance of FreeBSD's integrated toolchain List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 03 Apr 2015 21:15:54 -0000 --Apple-Mail=_2A31875E-D891-44B3-AC52-7782582485AE Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=windows-1252 On Apr 3, 2015, at 14:10, Warner Losh wrote: >>=20 >> On Apr 3, 2015, at 2:39 PM, Ed Maste wrote: >>=20 >> On 3 April 2015 at 13:02, Warner Losh wrote: >>> That shows that something in the list is needed. Likely only = crunchhide. >>>=20 >>> It doesn=92t tell us why we need it, or when we started needing it, = or what >>> other conditions we might need it. This information is critical to = document >>> so we know when we can stop doing it in the future. I=92m extremely = reluctant >>> to commit this until we know these details. >>=20 >> Yes, it's crunchide. It was broken prior to r277259: >>=20 >> | crunchide: Correct 64-bit section header offset >> | >> | For 64-bit binaries the Elf_Ehdr e_shoff is at offset 40, not = 44. >> | Instead of using an incorrect hardcoded offset, let the compiler >> | figure it out for us with offsetof(). >> | >> | Differential Revision: https://reviews.freebsd.org/D1543 >>=20 >> It's not completely clear to me why we did not encounter this before; >> a comment before the erroneous write states: >>=20 >> /* >> * update the offset of section header table in elf >> * header if needed. >> */ >>=20 >> so I presume something about the object file created by gcc 4.9 = causes >> this code to be executed, while builds using the in-tree compiler did >> not. >=20 > Ah Yes! I remember now! We should find the FreeBSD version at that = date > and either build it when we=92re cross compiling, or rebuild it when = we=92re > bootstrapping. >=20 > Thanks for finding this Ed. These numbers need to be bumped by 1, but here they are (this also = wasn=92t backported to stable/8 or stable/9 AFAICT). Cheers! head: $ svn cat -r r277259 ^/head/sys/sys/param.h | grep = '#define.*__FreeBSD_version' | awk '{ print $3 }=92 1100054 stable/10: $ svn cat -r 277557 ^/stable/10/sys/sys/param.h | grep = '#define.*__FreeBSD_version' | awk '{ print $3 }' 1001506 --Apple-Mail=_2A31875E-D891-44B3-AC52-7782582485AE Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQEcBAEBCgAGBQJVHwMGAAoJEMZr5QU6S73eWZgH/1Jq6wWZ0fS60AmdWgsU9vc7 woAGbiKKWOX7jm/A1Yo8fIg3C00szKBrdOIMN4G9ZGFZg85jfnQwDZHTMPupyRRd lt4XPMNhC2+FW1t+SCe7zTvlFTN1LBnvc20oxEON9MVGHefYMEdMh+gC7DY2fjJs xpCssUGKRKB2JPVs1UzfV+V31QxnKSjAggqd43lr/D82bzrJ7QUKzg3R4252U8IL YW8XE0w/ig5g6twjosrQPon88yPLDnUo6YFHCcDAhjwvCTRAD9Lu0sT9JTAdAYzN dJ9yNQw+CnDwC8faBzLYG6W86jwP9kfSJTnI23iM+xCFSBX/r4ipB0k+Mm5Xwlo= =xRe1 -----END PGP SIGNATURE----- --Apple-Mail=_2A31875E-D891-44B3-AC52-7782582485AE--