From patchwork Sun Aug 4 14:40:07 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Yann E. MORIN" X-Patchwork-Id: 1141759 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.137; helo=fraxinus.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=free.fr Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="E4jiZ09l"; dkim-atps=neutral Received: from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 461k8P53xpz9sDB for ; Mon, 5 Aug 2019 00:40:21 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 52C71855DF; Sun, 4 Aug 2019 14:40:19 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id DnZpeSVLRXmN; Sun, 4 Aug 2019 14:40:18 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id BF1D0855FE; Sun, 4 Aug 2019 14:40:18 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id A0D0E1BF405 for ; Sun, 4 Aug 2019 14:40:16 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id 9A890203C5 for ; Sun, 4 Aug 2019 14:40:16 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id tIA7Pbi0Isd3 for ; Sun, 4 Aug 2019 14:40:14 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-wr1-f47.google.com (mail-wr1-f47.google.com [209.85.221.47]) by silver.osuosl.org (Postfix) with ESMTPS id 8710820362 for ; Sun, 4 Aug 2019 14:40:14 +0000 (UTC) Received: by mail-wr1-f47.google.com with SMTP id n9so81973249wru.0 for ; Sun, 04 Aug 2019 07:40:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=J2UN5stPxTXnIMLUmoYLF0n2QBiAqrQVHNiaNgZ7GsU=; b=E4jiZ09lXpWtRO9lBvHWZMxrvF+nrdWQmpWd95XKJ+E1i2BV7g56icgcPoXI2jAtI3 RFUY9FKg15Fj80Pdgu4wxx0TVaA8AZZvEFCfYqJcs4DcYtTo4zAp/omh02QhQiVX+GpF B/LcDp53AmK93Ua8gJE6yY771BzpWo1LqE3wpwI/ZVnfOo2nPP0DbZMO+Du/mm39wk7J n+TtoKXwQPc3+gZud3wO+nTEh74P8shErR5OV4DOVYpWoc/HMdK4binIpy+rn3FHLjsX 4sGQ3ynfsW/QRyCeTgEjATwhf2l/lbDnjQ3zsM3Or63+6Fmu3y3Ud3fhgE8aYYmZmd9F j/Lw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :mime-version:content-transfer-encoding; bh=J2UN5stPxTXnIMLUmoYLF0n2QBiAqrQVHNiaNgZ7GsU=; b=Gx762o5rh3j5dzUUgtXqEd16t2HR2CfPQHB35XnGD5SNjPZKXBXzZ94aZXLOxaYU5D JPzx2+1CE4p/4uFk7qeYl2Xw9QNYT0dPK1jETEYm9hF20lXy4ngK+nz0hQ0fXdls6Bem JBPgA7DdCQdkuqLwlsMk7yV3PUtRbSvMOfloylhALlzLdaEeij1El4i9eLm03w/yLXs6 EaubVrhB+0OQTsbyk9quDtU1t9Yl6taTXEZmaOB4nnKNxSsDaFwWBpT/LI3zUQgj2fVn JvJG8GHi30p0zlhevlikp28KuEfzsjHPkU2pDFmvW9wXcS0Su7PHLWCU5ry+sh1fFkcK dm2A== X-Gm-Message-State: APjAAAVjjk/YS8E0txloR3KW2+DI795Un/mLFyGcWRbonG/s0OVuVDPk 72ZgNkkjtDxNQjFDXGvIg8yJsCnA X-Google-Smtp-Source: APXvYqx0b9HouRAi9EJwbjsZ15wpbp6LOiFsdys0gXSlBGTHA0zxwGhZjeEX3zCkMLnKdDKMD20xqw== X-Received: by 2002:adf:9486:: with SMTP id 6mr127931199wrr.242.1564929612708; Sun, 04 Aug 2019 07:40:12 -0700 (PDT) Received: from scaer.home ([2a01:cb19:8acf:5600:8504:2a7:a8e1:c312]) by smtp.gmail.com with ESMTPSA id v29sm22160954wrv.74.2019.08.04.07.40.11 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Sun, 04 Aug 2019 07:40:12 -0700 (PDT) From: "Yann E. MORIN" To: buildroot@buildroot.org Date: Sun, 4 Aug 2019 16:40:07 +0200 Message-Id: <20190804144007.25052-1-yann.morin.1998@free.fr> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Subject: [Buildroot] [PATCHv2] core: ensure $BIANRES_DIR exist before post-image scripts 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: "Yann E . MORIN" , Brent Generous Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" From: Brent Generous When no filesystem is enabled, the $BINARIES_DIR is not created. Yet, the post-image scripts are still run. When those want to generate an image in there, they may fail as the dirctory does not exist (it did exist before we started applying preparatory changes for top-level parallel build, so scripts got to rely on that assumption). Do in target-post-image as we do in the sdk rule: create the directory before calling the scripts. Signed-off-by: Brent Generous [yann.morin.1998@free.fr: - create the directory before calling the scripts - don't drop the creation in the sdk rule ] Signed-off-by: Yann E. MORIN --- Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index ee382abf15..a941fc8c55 100644 --- a/Makefile +++ b/Makefile @@ -808,8 +808,9 @@ 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) + $(Q)mkdir -p $(BINARIES_DIR) @$(foreach s, $(call qstrip,$(BR2_ROOTFS_POST_IMAGE_SCRIPT)), \ $(call MESSAGE,"Executing post-image script $(s)"); \ $(EXTRA_ENV) $(s) $(BINARIES_DIR) $(call qstrip,$(BR2_ROOTFS_POST_SCRIPT_ARGS))$(sep))