From nobody Thu Apr 25 14:18:35 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=none (zohomail.com: 192.237.175.120 is neither permitted nor denied by domain of lists.xenproject.org) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=fail(p=none dis=none) header.from=citrix.com ARC-Seal: i=1; a=rsa-sha256; t=1574952767; cv=none; d=zohomail.com; s=zohoarc; b=R/kNiJSk38NFUnpQI1Cm506bKTRAVDcsM5B42vRenl7lAhnOrwbVYlV/27yjTGpMmJZJiaqk4srS/qpnVjTBsfJPWTYdiwr6edp/DpiL2wpmv6lHILFP4gw4Jh/no22gPxt2Zrx93GZDJUKKrXw9FzJ16Z1T0JGuedtHhAcRjq0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1574952767; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To; bh=HGVF+iQj4e7NMxN4peGou+lNZP2mN60Ti3X6lzuDtNs=; b=a8T6BPtgrEZ3jqTtz66Fkufv/HogELRGxTUMmhc8Si/Y4aC9ktewo5xVWNl/zgZ/FMjo1xy+7DMhHeKdOykkhMb6fNxsh0B9KdO+dz4cZSCsqvhEk16SLNkhrZ/EQh2KDwX6Ax81d7o27v9CA80AABcxvsZ0+raPARWW15Lmpfk= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=none (zohomail.com: 192.237.175.120 is neither permitted nor denied by domain of lists.xenproject.org) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1574952767393873.9407318879756; Thu, 28 Nov 2019 06:52:47 -0800 (PST) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1iaL97-0000oN-8a; Thu, 28 Nov 2019 14:51:53 +0000 Received: from all-amaz-eas1.inumbo.com ([34.197.232.57] helo=us1-amaz-eas2.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1iaL95-0000oI-PM for xen-devel@lists.xenproject.org; Thu, 28 Nov 2019 14:51:51 +0000 Received: from esa1.hc3370-68.iphmx.com (unknown [216.71.145.142]) by us1-amaz-eas2.inumbo.com (Halon) with ESMTPS id 953b2b5f-11ee-11ea-a3d3-12813bfff9fa; Thu, 28 Nov 2019 14:51:41 +0000 (UTC) X-Inumbo-ID: 953b2b5f-11ee-11ea-a3d3-12813bfff9fa DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=citrix.com; s=securemail; t=1574952701; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=qSFGDub9dwV2EFLWtKK8KYIfUxh/CZEHhtBfPNddfo0=; b=LTr1krehe4M5esb7URaAENMW2NrhIpZiZs4ZHqh2HW5QMBwSSqPbcdOz jZPH9sT7/JsQ4GKIMmhWR2tI/pagHZb8KwIXixweVyJZYef3nUNkmm7wH 2xX47h1wCPhWx45OkMcOqvRXF5tYGZcZG2I6W9lttyObM7A348QtBOMMK 4=; Authentication-Results: esa1.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none; spf=None smtp.pra=ross.lagerwall@citrix.com; spf=Pass smtp.mailfrom=ross.lagerwall@citrix.com; spf=None smtp.helo=postmaster@mail.citrix.com Received-SPF: none (zohomail.com: 192.237.175.120 is neither permitted nor denied by domain of lists.xenproject.org) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Received-SPF: None (esa1.hc3370-68.iphmx.com: no sender authenticity information available from domain of ross.lagerwall@citrix.com) identity=pra; client-ip=162.221.158.21; receiver=esa1.hc3370-68.iphmx.com; envelope-from="ross.lagerwall@citrix.com"; x-sender="ross.lagerwall@citrix.com"; x-conformance=sidf_compatible Received-SPF: Pass (esa1.hc3370-68.iphmx.com: domain of ross.lagerwall@citrix.com designates 162.221.158.21 as permitted sender) identity=mailfrom; client-ip=162.221.158.21; receiver=esa1.hc3370-68.iphmx.com; envelope-from="ross.lagerwall@citrix.com"; x-sender="ross.lagerwall@citrix.com"; x-conformance=sidf_compatible; x-record-type="v=spf1"; x-record-text="v=spf1 ip4:209.167.231.154 ip4:178.63.86.133 ip4:195.66.111.40/30 ip4:85.115.9.32/28 ip4:199.102.83.4 ip4:192.28.146.160 ip4:192.28.146.107 ip4:216.52.6.88 ip4:216.52.6.188 ip4:162.221.158.21 ip4:162.221.156.83 ip4:168.245.78.127 ~all" Received-SPF: None (esa1.hc3370-68.iphmx.com: no sender authenticity information available from domain of postmaster@mail.citrix.com) identity=helo; client-ip=162.221.158.21; receiver=esa1.hc3370-68.iphmx.com; envelope-from="ross.lagerwall@citrix.com"; x-sender="postmaster@mail.citrix.com"; x-conformance=sidf_compatible IronPort-SDR: lr+2sJexp+jG5hwxQ8JmZLcygHP4f0QAhP+ustAiiB7IAXNypAR1LUccuTKtX3t9EKRlqRoS2W mh8Th0Z1Ir8srDKkhPK4matNwByHxkAtwJoDS9cXo2pUvEQfI4HqrZnVziC2IQSfmVsEuR4Xdn 2W2/Md+NVqKP6m2BDfioLFyHVCsyRpJA3Uc02yXkmw+wgeSFZnSkFOavjOrB+L5l5ZAOXe3XQl aoU4GjFPh2zYUP38MVbjn9QYSS7FY+FIU98Uw7dAKtQVupTSooY6MN9I86hjyFt5nXgq0OTXLU KX4= X-SBRS: 2.7 X-MesageID: 9082639 X-Ironport-Server: esa1.hc3370-68.iphmx.com X-Remote-IP: 162.221.158.21 X-Policy: $RELAYED X-IronPort-AV: E=Sophos;i="5.69,253,1571716800"; d="scan'208";a="9082639" From: Ross Lagerwall To: Date: Thu, 28 Nov 2019 14:51:35 +0000 Message-ID: <20191128145135.11974-1-ross.lagerwall@citrix.com> X-Mailer: git-send-email 2.21.0 MIME-Version: 1.0 Subject: [Xen-devel] [PATCH LP-BUILD_TOOLS] Fix building with updated ENFORCE_UNIQUE_SYMBOLS behaviour X-BeenThere: xen-devel@lists.xenproject.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Cc: Sergey Dyasli , Andrew Cooper , Ross Lagerwall , Jan Beulich , Konrad Rzeszutek Wilk Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) The patch "build: provide option to disambiguate symbol names" changes ENFORCE_UNIQUE_SYMBOLS so that gcc generates output to a temporary file and then objcopy is used to create the final object file. This breaks livepatch-build's interposition of GCC to capture the changed object files so intercept calls to objcopy as well to capture the final object files. While in the area, add a couple of extra object files to be ignored when patching. Signed-off-by: Ross Lagerwall --- With this change, I've built and successfully applied a trivial livepatch with Jan's patch applied and ENFORCE_UNIQUE_SYMBOLS turned on. To be applied at the same time as Jan's patch. livepatch-gcc | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/livepatch-gcc b/livepatch-gcc index 01e4b8c..91333d5 100755 --- a/livepatch-gcc +++ b/livepatch-gcc @@ -26,6 +26,7 @@ declare -a args=3D("$@") keep=3Dno =20 declare -r GCC_RE=3D'gcc.*' +declare -r OBJCOPY_RE=3D'objcopy.*' if [[ "$TOOLCHAINCMD" =3D~ $GCC_RE ]] ; then while [ "$#" -gt 0 ]; do if [ "$1" =3D "-o" ]; then @@ -34,7 +35,9 @@ if [[ "$TOOLCHAINCMD" =3D~ $GCC_RE ]] ; then case "$obj" in version.o|\ debug.o|\ + efi/check.o|\ *.xen-syms.*.o|\ + *.xen.efi.*.o|\ built_in.o|\ prelink.o|\ .*.o) @@ -56,6 +59,25 @@ if [[ "$TOOLCHAINCMD" =3D~ $GCC_RE ]] ; then fi shift done +elif [[ "$TOOLCHAINCMD" =3D~ $OBJCOPY_RE ]] ; then + obj=3D"${!#}" + case "$obj" in + version.o|\ + debug.o|\ + efi/check.o|\ + .*.o) + ;; + *.o) + path=3D"$(pwd)/$(dirname $obj)" + dir=3D"${path#$LIVEPATCH_BUILD_DIR}" + if [ -n "$LIVEPATCH_CAPTURE_DIR" -a -d "$LIVEPATCH_CAPTURE_DIR= " ]; then + echo "$dir/$obj" >> "${LIVEPATCH_CAPTURE_DIR}/changed_objs" + keep=3Dyes + fi + ;; + *) + ;; + esac fi =20 "$TOOLCHAINCMD" "${args[@]}" --=20 2.21.0 _______________________________________________ Xen-devel mailing list Xen-devel@lists.xenproject.org https://lists.xenproject.org/mailman/listinfo/xen-devel