From patchwork Fri Jul 12 16:10:02 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Brent Generous X-Patchwork-Id: 1131451 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=busybox.net (client-ip=140.211.166.133; helo=hemlock.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=reject dis=none) header.from=impinj.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=impinj.com header.i=@impinj.com header.b="aqYDA2ta"; dkim-atps=neutral Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 45ldNn142hz9s8m for ; Sat, 13 Jul 2019 02:16:31 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id 1F1E4877FF; Fri, 12 Jul 2019 16:16:29 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id SSDskioIERf4; Fri, 12 Jul 2019 16:16:28 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by hemlock.osuosl.org (Postfix) with ESMTP id 73DD787807; Fri, 12 Jul 2019 16:16:28 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by ash.osuosl.org (Postfix) with ESMTP id 8CE5C1BF2CE for ; Fri, 12 Jul 2019 16:16:27 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id 89B1887807 for ; Fri, 12 Jul 2019 16:16:27 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id m8hzs0NrVlF7 for ; Fri, 12 Jul 2019 16:16:26 +0000 (UTC) X-Greylist: delayed 00:06:18 by SQLgrey-1.7.6 Received: from us-smtp-delivery-168.mimecast.com (us-smtp-delivery-168.mimecast.com [63.128.21.168]) by hemlock.osuosl.org (Postfix) with ESMTPS id BCBA9877FF for ; Fri, 12 Jul 2019 16:16:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=impinj.com; s=mimecast20190405; t=1562948185; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=HMLAnMvVBWtb6GuYSY6J/hnGuV70XjVIX3JOGVQYWeQ=; b=aqYDA2tafrf1qP+b6zRqDVa0yhQKRCiUwfkwaUos70wXHUj4lxUAwkU11IAtucK/YiiLj7 FK/gldSwbMgKCEEdF+dGDNKrns85sttgn6ofG6fItq2bfm2CYvdZou94xJj2AleHj5Mcaf MyMuJapVGTRs1apujWpyM0+9FrUgZQI= Received: from NAM03-CO1-obe.outbound.protection.outlook.com (mail-co1nam03lp2050.outbound.protection.outlook.com [104.47.40.50]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-302-CCaJ1iZaP0ybdZBqVF7P_g-1; Fri, 12 Jul 2019 12:10:05 -0400 Received: from MWHPR0601MB3740.namprd06.prod.outlook.com (10.167.236.145) by MWHPR0601MB3657.namprd06.prod.outlook.com (10.167.236.23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2073.10; Fri, 12 Jul 2019 16:10:03 +0000 Received: from MWHPR0601MB3740.namprd06.prod.outlook.com ([fe80::e0c8:dedb:5b5e:91cb]) by MWHPR0601MB3740.namprd06.prod.outlook.com ([fe80::e0c8:dedb:5b5e:91cb%3]) with mapi id 15.20.2073.012; Fri, 12 Jul 2019 16:10:03 +0000 From: Brent Generous To: "buildroot@buildroot.org" Thread-Topic: [PATCH 1/1] Makefile: add $BINARIES_DIR dependency to target-post-image target Thread-Index: AQHVOMxDwf2v0ljphEe+rX6kz7NRFw== Date: Fri, 12 Jul 2019 16:10:02 +0000 Message-ID: <20190712160925.6027-1-bgenerous@impinj.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: BYAPR07CA0091.namprd07.prod.outlook.com (2603:10b6:a03:12b::32) To MWHPR0601MB3740.namprd06.prod.outlook.com (2603:10b6:301:7d::17) x-ms-exchange-messagesentrepresentingtype: 1 x-mailer: git-send-email 2.17.2 x-originating-ip: [216.243.31.162] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 446d1cdd-c543-49ad-09ac-08d706e3656d x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600148)(711020)(4605104)(1401327)(2017052603328)(7193020); SRVR:MWHPR0601MB3657; x-ms-traffictypediagnostic: MWHPR0601MB3657: x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:1468; x-forefront-prvs: 00963989E5 x-forefront-antispam-report: SFV:NSPM; SFS:(10019020)(4636009)(376002)(346002)(39850400004)(396003)(366004)(136003)(189003)(199004)(1730700003)(66066001)(6512007)(14454004)(52116002)(107886003)(1076003)(186003)(26005)(316002)(2906002)(256004)(71200400001)(99286004)(71190400001)(5640700003)(6486002)(6436002)(478600001)(53936002)(2501003)(476003)(2616005)(25786009)(2351001)(486006)(8936002)(36756003)(3846002)(8676002)(6916009)(81156014)(66476007)(66446008)(86362001)(305945005)(386003)(66556008)(6506007)(102836004)(7736002)(50226002)(68736007)(4326008)(5660300002)(64756008)(66946007)(81166006)(6116002); DIR:OUT; SFP:1102; SCL:1; SRVR:MWHPR0601MB3657; H:MWHPR0601MB3740.namprd06.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: Rc2dfkkYs5L3uGtgkcSTCTYim9x44SPmTNpFc33UJOcKCF87gZzLO/vJCf3+YQx4JWrgwoS9C2lQScVTAec7NV8DAdS8Or899AiQY0fPQPKnZ9bys7JyLucgP2p1Ri7SWCdopv8RN7pw+xMHFfK+Zy3oFBeYrlUKpGba3l+qZvioTY8vv7BYl/hZcawYgfUVpR8xeOXEIlKotf5RpiIa7zyipbtZ7EgC14kq6dRzRINyZaRiWiW4jSU+vl3w/GIuy6luyHEqtm89k6eZnsOqZwtx0RnLGaOrkao8tq+Y04cOOEkwvnfEX1zTi5pCw563n7RRQgWoXL1di+l1X11BAdTQ/8Tf7RGA0Oeg43aZQW9jxE5MqVCdTUtPvOtdsw+BilJ3iwkKkDkmRVFgN3hZ9jtbcoPFMDdqzUf26cOiHUs= MIME-Version: 1.0 X-OriginatorOrg: impinj.com X-MS-Exchange-CrossTenant-Network-Message-Id: 446d1cdd-c543-49ad-09ac-08d706e3656d X-MS-Exchange-CrossTenant-originalarrivaltime: 12 Jul 2019 16:10:02.9709 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 6de70f0f-7357-4529-a415-d8cbb7e93e5e X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: bgenerous@impinj.com X-MS-Exchange-Transport-CrossTenantHeadersStamped: MWHPR0601MB3657 X-MC-Unique: CCaJ1iZaP0ybdZBqVF7P_g-1 X-Mimecast-Spam-Score: 0 Subject: [Buildroot] [PATCH 1/1] Makefile: add $BINARIES_DIR dependency to target-post-image target X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Brent Generous Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" Without this dependency, there is no guarantee that the $BINARIES_DIR has been created before this point. This can cause commands that intend to copy a file into $BINARIES_DIR to instead copy to a file named $BINARIES_DIR, causing later commands to create this directory to fail. A comment above the target for $BINARIES_DIR mentions "do NOT list these as dependencies anywhere else". It wasn't clear from the git history why that should be the case. This seems like the correct way to handle the dependency on this directory. Signed-off-by: Brent Generous --- Makefile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Makefile b/Makefile index c98a0ed87e..2ea7220484 100644 --- a/Makefile +++ b/Makefile @@ -606,7 +606,6 @@ BR2_SDK_PREFIX ?= $(GNU_TARGET_NAME)_sdk-buildroot sdk: prepare-sdk $(BR2_TAR_HOST_DEPENDENCY) @$(call MESSAGE,"Generating SDK tarball") $(if $(BR2_SDK_PREFIX),,$(error BR2_SDK_PREFIX can not be empty)) - $(Q)mkdir -p $(BINARIES_DIR) $(TAR) czf "$(BINARIES_DIR)/$(BR2_SDK_PREFIX).tar.gz" \ --owner=0 --group=0 --numeric-owner \ --transform='s#^$(patsubst /%,%,$(HOST_DIR))#$(BR2_SDK_PREFIX)#' \ @@ -810,7 +809,7 @@ endif # merged /usr touch $(TARGET_DIR)/usr .PHONY: target-post-image -target-post-image: $(TARGETS_ROOTFS) target-finalize staging-finalize +target-post-image: $(TARGETS_ROOTFS) target-finalize staging-finalize | $(BINARIES_DIR) @rm -f $(ROOTFS_COMMON_TAR) @$(foreach s, $(call qstrip,$(BR2_ROOTFS_POST_IMAGE_SCRIPT)), \ $(call MESSAGE,"Executing post-image script $(s)"); \