From: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH 1/2] package/pkg-generic.mk: simplify step_pkg_size
Date: Wed, 26 Feb 2020 20:43:43 +0100 [thread overview]
Message-ID: <20200226194345.1087529-2-thomas.petazzoni@bootlin.com> (raw)
In-Reply-To: <20200226194345.1087529-1-thomas.petazzoni@bootlin.com>
Use the same trick in step_pkg_size as the one used in check_bin_arch:
factorize the two $(filter ...) calls into one, checking in one step
the step and whether it's the beginning or end of the step.
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
---
package/pkg-generic.mk | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/package/pkg-generic.mk b/package/pkg-generic.mk
index f4f525f41a..6687ac9198 100644
--- a/package/pkg-generic.mk
+++ b/package/pkg-generic.mk
@@ -95,12 +95,12 @@ define step_pkg_size_inner
endef
define step_pkg_size
- $(if $(filter install-target,$(2)),\
- $(if $(filter end,$(1)),$(call step_pkg_size_inner,$(3),$(TARGET_DIR))))
- $(if $(filter install-staging,$(2)),\
- $(if $(filter end,$(1)),$(call step_pkg_size_inner,$(3),$(STAGING_DIR),-staging)))
- $(if $(filter install-host,$(2)),\
- $(if $(filter end,$(1)),$(call step_pkg_size_inner,$(3),$(HOST_DIR),-host)))
+ $(if $(filter end-install-target,$(1)-$(2)),\
+ $(call step_pkg_size_inner,$(3),$(TARGET_DIR)))
+ $(if $(filter end-install-staging,$(1)-$(2)),\
+ $(call step_pkg_size_inner,$(3),$(STAGING_DIR),-staging))
+ $(if $(filter end-install-host,$(1)-$(2)),\
+ $(call step_pkg_size_inner,$(3),$(HOST_DIR),-host))
endef
GLOBAL_INSTRUMENTATION_HOOKS += step_pkg_size
--
2.24.1
next prev parent reply other threads:[~2020-02-26 19:43 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-26 19:43 [Buildroot] [PATCH 0/2] Fix file listing logic for top-level parallel build Thomas Petazzoni
2020-02-26 19:43 ` Thomas Petazzoni [this message]
2020-02-27 21:51 ` [Buildroot] [PATCH 1/2] package/pkg-generic.mk: simplify step_pkg_size Peter Korsgaard
2020-02-27 21:55 ` Thomas Petazzoni
2020-02-27 22:32 ` Peter Korsgaard
2020-02-26 19:43 ` [Buildroot] [PATCH 2/2] package/pkg-generic: make file list logic parallel build compatible Thomas Petazzoni
2020-02-27 22:04 ` Peter Korsgaard
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200226194345.1087529-2-thomas.petazzoni@bootlin.com \
--to=thomas.petazzoni@bootlin.com \
--cc=buildroot@busybox.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.