From patchwork Tue Nov 6 22:21:33 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 993952 X-Patchwork-Delegate: sjg@chromium.org Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.denx.de (client-ip=81.169.180.215; helo=lists.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=chromium.org Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 42qPR52CMjz9sBh for ; Wed, 7 Nov 2018 09:31:29 +1100 (AEDT) Received: by lists.denx.de (Postfix, from userid 105) id 0391AC221D2; Tue, 6 Nov 2018 22:27:37 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=RCVD_IN_DNSWL_BLOCKED, RCVD_IN_MSPIKE_H2 autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id 6024AC22780; Tue, 6 Nov 2018 22:23:41 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 4EFEAC2278C; Tue, 6 Nov 2018 22:22:48 +0000 (UTC) Received: from mail-qk1-f201.google.com (mail-qk1-f201.google.com [209.85.222.201]) by lists.denx.de (Postfix) with ESMTPS id 6FCEDC22671 for ; Tue, 6 Nov 2018 22:22:44 +0000 (UTC) Received: by mail-qk1-f201.google.com with SMTP id m63-v6so28361428qkb.9 for ; Tue, 06 Nov 2018 14:22:44 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:in-reply-to:message-id:mime-version :references:subject:from:to:cc; bh=nAaCaWCpxgNagDyDDS6n6kL0oCV9x1/qXB3QLicSd7I=; b=MR1niZunY7ujzGRYRomEJbyY5Lh2zZMZm632VRmHe5p5M6akZOtFfwj9XDGTAaTI05 ukwoJZGhn436ykvtQ9p/KwVTZi86grDmx/jmA3wJDLvojnQGFS3tdt1linryI5oxoyOZ fbgljwHWCFuJh3huU+rS5KHiOCSfybAAqYg/s373rZeSqL8M9pezmr+Fewhv6GpyTTco RVjPGjEXqu6TDGpYeD2Zu8Oa0hNeVwuFiEak2dddl+0kgPjvudfSo1xBTuiXl4uiyfOI epBzvLfZw5TTmHZ8NkoqM/vm+UZj5DCmKzYA+RfUdjgtwHGEtttrtnfQfN5saHR5V8Ri 1LbA== X-Gm-Message-State: AGRZ1gLQYOb65b+Xl80oc53rcjEPmAtlRUd4+MIluILMhCNuZWK3oe3g ZIB7YVJWK54hgEiNPU27FnocUVg= X-Google-Smtp-Source: AJdET5d6L8M+u3If8wqU0Tvw3hZlhOwoz8y5nn50rNzpAFpXOtOeXO8yuV4qBFIFa28ZPmLMKqwzhfw= X-Received: by 2002:ac8:3870:: with SMTP id r45mr4385583qtb.1.1541542963354; Tue, 06 Nov 2018 14:22:43 -0800 (PST) Date: Tue, 6 Nov 2018 15:21:33 -0700 In-Reply-To: <20181106222142.94537-1-sjg@chromium.org> Message-Id: <20181106222142.94537-17-sjg@chromium.org> Mime-Version: 1.0 References: <20181106222142.94537-1-sjg@chromium.org> X-Mailer: git-send-email 2.19.1.930.g4563a0d9d0-goog From: Simon Glass To: U-Boot Mailing List Subject: [U-Boot] [PATCH 16/25] binman: Set the pathname correctly for ELF files X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" At present, stripped files don't have the right pathname which means that blob compression cannot be used. Fix this. Signed-off-by: Simon Glass Signed-off-by: Simon Glass --- tools/binman/etype/u_boot_elf.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tools/binman/etype/u_boot_elf.py b/tools/binman/etype/u_boot_elf.py index 134b6cc15b4..f83860dc0a8 100644 --- a/tools/binman/etype/u_boot_elf.py +++ b/tools/binman/etype/u_boot_elf.py @@ -30,9 +30,8 @@ class Entry_u_boot_elf(Entry_blob): out_fname = tools.GetOutputFilename('%s.stripped' % uniq) tools.WriteFile(out_fname, tools.ReadFile(self._pathname)) tools.Run('strip', out_fname) - self.SetContents(tools.ReadFile(out_fname)) - else: - self.SetContents(tools.ReadFile(self._pathname)) + self._pathname = out_fname + Entry_blob.ReadBlobContents(self) return True def GetDefaultFilename(self):