* [ptxdist] [PATCH v1 1/2] pre/barebox: only use <PKG>_VERSION to build the URL
@ 2019-06-05 14:51 Roland Hieber
2019-06-05 14:51 ` [ptxdist] [PATCH v1 2/2] pre/barebox: barebox-opts doesn't need any parameters Roland Hieber
0 siblings, 1 reply; 4+ messages in thread
From: Roland Hieber @ 2019-06-05 14:51 UTC (permalink / raw)
To: ptxdist; +Cc: Roland Hieber
When adding another barebox package to a BSP, e.g. named barebox-foo,
the BAREBOX_FOO variable will contain "barebox-foo-$(VERSION)". This
variable is used to build BAREBOX_DIR, BAREBOX_SOURCE, and
BAREBOX_FOO_URL.
We must to keep the customized package postfix in the build
directory, but in the latter case, the -foo postfix is transferred
into the URL, which will lead to errors while downloading the source.
We actually only need the barebox version to download the source
tarball, so use a static "barebox-" string to build the barebox/url
macro and also the BAREBOX_FOO_SOURCE variable in the package template,
so the same tarball isn't downloaded multiple times with different
names.
Signed-off-by: Roland Hieber <rhi@pengutronix.de>
---
rules/pre/barebox.make | 2 +-
rules/templates/template-barebox-make | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/rules/pre/barebox.make b/rules/pre/barebox.make
index 09fb400b72b2..7875442cf935 100644
--- a/rules/pre/barebox.make
+++ b/rules/pre/barebox.make
@@ -15,14 +15,14 @@ barebox/opts = \
HOSTCC=$(HOSTCC) \
ARCH=$(PTXCONF_BAREBOX_ARCH_STRING) \
CROSS_COMPILE=$(BOOTLOADER_CROSS_COMPILE)
barebox-opts = \
$(call barebox/opts,$(strip $(1)))
barebox/url = \
- http://www.barebox.org/download/$($(1)).$($(1)_SUFFIX)
+ http://www.barebox.org/download/barebox-$($(1)_VERSION).$($(1)_SUFFIX)
barebox-url = \
$(call barebox/url,$(strip $(1)))
# vim: syntax=make
diff --git a/rules/templates/template-barebox-make b/rules/templates/template-barebox-make
index 282de8846022..7493b849b6ab 100644
--- a/rules/templates/template-barebox-make
+++ b/rules/templates/template-barebox-make
@@ -19,17 +19,17 @@ PACKAGES-$(PTXCONF_BAREBOX_@PACKAGE@) += barebox-@package@
BAREBOX_@PACKAGE@_VERSION := @VERSION@
BAREBOX_@PACKAGE@_MD5 :=
BAREBOX_@PACKAGE@ := barebox-$(BAREBOX_@PACKAGE@_VERSION)
BAREBOX_@PACKAGE@_SUFFIX := tar.bz2
BAREBOX_@PACKAGE@_DIR := $(BUILDDIR)/barebox-@package@-$(BAREBOX_@PACKAGE@_VERSION)
BAREBOX_@PACKAGE@_CONFIG := $(call ptx/in-platformconfigdir, barebox-@package@.config.$(BAREBOX_@PACKAGE@_VERSION))
BAREBOX_@PACKAGE@_LICENSE := GPL-2.0-only
BAREBOX_@PACKAGE@_URL := $(call barebox-url, BAREBOX_@PACKAGE@)
-BAREBOX_@PACKAGE@_SOURCE := $(SRCDIR)/$(BAREBOX_@PACKAGE@).$(BAREBOX_@PACKAGE@_SUFFIX)
+BAREBOX_@PACKAGE@_SOURCE := $(SRCDIR)/barebox-$(BAREBOX_@PACKAGE@_VERSION).$(BAREBOX_@PACKAGE@_SUFFIX)
# ----------------------------------------------------------------------------
# Prepare
# ----------------------------------------------------------------------------
# use host pkg-config for host tools
BAREBOX_@PACKAGE@_PATH := PATH=$(HOST_PATH)
--
2.20.1
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 4+ messages in thread
* [ptxdist] [PATCH v1 2/2] pre/barebox: barebox-opts doesn't need any parameters
2019-06-05 14:51 [ptxdist] [PATCH v1 1/2] pre/barebox: only use <PKG>_VERSION to build the URL Roland Hieber
@ 2019-06-05 14:51 ` Roland Hieber
2019-06-14 7:14 ` Michael Olbrich
0 siblings, 1 reply; 4+ messages in thread
From: Roland Hieber @ 2019-06-05 14:51 UTC (permalink / raw)
To: ptxdist; +Cc: Roland Hieber
$(1) is never used in the barebox/opts macro, so barebox-opts doesn't
need to pass it around.
Also adjust the package template accordingly.
Signed-off-by: Roland Hieber <rhi@pengutronix.de>
---
rules/pre/barebox.make | 2 +-
rules/templates/template-barebox-make | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/rules/pre/barebox.make b/rules/pre/barebox.make
index 7875442cf935..bc7fe4340f87 100644
--- a/rules/pre/barebox.make
+++ b/rules/pre/barebox.make
@@ -12,17 +12,17 @@
barebox/opts = \
$(PARALLELMFLAGS) \
V=$(PTXDIST_VERBOSE) \
HOSTCC=$(HOSTCC) \
ARCH=$(PTXCONF_BAREBOX_ARCH_STRING) \
CROSS_COMPILE=$(BOOTLOADER_CROSS_COMPILE)
barebox-opts = \
- $(call barebox/opts,$(strip $(1)))
+ $(call barebox/opts)
barebox/url = \
http://www.barebox.org/download/barebox-$($(1)_VERSION).$($(1)_SUFFIX)
barebox-url = \
$(call barebox/url,$(strip $(1)))
# vim: syntax=make
diff --git a/rules/templates/template-barebox-make b/rules/templates/template-barebox-make
index 7493b849b6ab..4ada3c20bf00 100644
--- a/rules/templates/template-barebox-make
+++ b/rules/templates/template-barebox-make
@@ -36,17 +36,17 @@ BAREBOX_@PACKAGE@_PATH := PATH=$(HOST_PATH)
BAREBOX_@PACKAGE@_WRAPPER_BLACKLIST := \
TARGET_HARDEN_STACKCLASH \
TARGET_HARDEN_RELRO \
TARGET_HARDEN_BINDNOW \
TARGET_HARDEN_PIE \
TARGET_DEBUG \
TARGET_BUILD_ID
-BAREBOX_@PACKAGE@_CONF_OPT := $(call barebox-opts, BAREBOX_@PACKAGE@)
+BAREBOX_@PACKAGE@_CONF_OPT := $(call barebox-opts)
BAREBOX_@PACKAGE@_MAKE_OPT := $(BAREBOX_@PACKAGE@_CONF_OPT)
BAREBOX_@PACKAGE@_IMAGES := @image@
BAREBOX_@PACKAGE@_IMAGES := $(addprefix $(BAREBOX_@PACKAGE@_DIR)/,$(BAREBOX_@PACKAGE@_IMAGES))
ifdef PTXCONF_BAREBOX_@PACKAGE@
$(BAREBOX_@PACKAGE@_CONFIG):
@echo
--
2.20.1
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [ptxdist] [PATCH v1 2/2] pre/barebox: barebox-opts doesn't need any parameters
2019-06-05 14:51 ` [ptxdist] [PATCH v1 2/2] pre/barebox: barebox-opts doesn't need any parameters Roland Hieber
@ 2019-06-14 7:14 ` Michael Olbrich
2019-06-14 8:27 ` Roland Hieber
0 siblings, 1 reply; 4+ messages in thread
From: Michael Olbrich @ 2019-06-14 7:14 UTC (permalink / raw)
To: ptxdist
On Wed, Jun 05, 2019 at 04:51:40PM +0200, Roland Hieber wrote:
> $(1) is never used in the barebox/opts macro, so barebox-opts doesn't
> need to pass it around.
>
> Also adjust the package template accordingly.
>
> Signed-off-by: Roland Hieber <rhi@pengutronix.de>
I'd like to keep this for now. I have vague plans for out-of-tree builds to
make it possible to share the same git tree via local-src. When that
happens, the argument will be needed.
Michael
> ---
> rules/pre/barebox.make | 2 +-
> rules/templates/template-barebox-make | 2 +-
> 2 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/rules/pre/barebox.make b/rules/pre/barebox.make
> index 7875442cf935..bc7fe4340f87 100644
> --- a/rules/pre/barebox.make
> +++ b/rules/pre/barebox.make
> @@ -12,17 +12,17 @@
> barebox/opts = \
> $(PARALLELMFLAGS) \
> V=$(PTXDIST_VERBOSE) \
> HOSTCC=$(HOSTCC) \
> ARCH=$(PTXCONF_BAREBOX_ARCH_STRING) \
> CROSS_COMPILE=$(BOOTLOADER_CROSS_COMPILE)
>
> barebox-opts = \
> - $(call barebox/opts,$(strip $(1)))
> + $(call barebox/opts)
>
> barebox/url = \
> http://www.barebox.org/download/barebox-$($(1)_VERSION).$($(1)_SUFFIX)
>
> barebox-url = \
> $(call barebox/url,$(strip $(1)))
>
> # vim: syntax=make
> diff --git a/rules/templates/template-barebox-make b/rules/templates/template-barebox-make
> index 7493b849b6ab..4ada3c20bf00 100644
> --- a/rules/templates/template-barebox-make
> +++ b/rules/templates/template-barebox-make
> @@ -36,17 +36,17 @@ BAREBOX_@PACKAGE@_PATH := PATH=$(HOST_PATH)
> BAREBOX_@PACKAGE@_WRAPPER_BLACKLIST := \
> TARGET_HARDEN_STACKCLASH \
> TARGET_HARDEN_RELRO \
> TARGET_HARDEN_BINDNOW \
> TARGET_HARDEN_PIE \
> TARGET_DEBUG \
> TARGET_BUILD_ID
>
> -BAREBOX_@PACKAGE@_CONF_OPT := $(call barebox-opts, BAREBOX_@PACKAGE@)
> +BAREBOX_@PACKAGE@_CONF_OPT := $(call barebox-opts)
> BAREBOX_@PACKAGE@_MAKE_OPT := $(BAREBOX_@PACKAGE@_CONF_OPT)
>
> BAREBOX_@PACKAGE@_IMAGES := @image@
> BAREBOX_@PACKAGE@_IMAGES := $(addprefix $(BAREBOX_@PACKAGE@_DIR)/,$(BAREBOX_@PACKAGE@_IMAGES))
>
> ifdef PTXCONF_BAREBOX_@PACKAGE@
> $(BAREBOX_@PACKAGE@_CONFIG):
> @echo
> --
> 2.20.1
>
>
> _______________________________________________
> ptxdist mailing list
> ptxdist@pengutronix.de
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [ptxdist] [PATCH v1 2/2] pre/barebox: barebox-opts doesn't need any parameters
2019-06-14 7:14 ` Michael Olbrich
@ 2019-06-14 8:27 ` Roland Hieber
0 siblings, 0 replies; 4+ messages in thread
From: Roland Hieber @ 2019-06-14 8:27 UTC (permalink / raw)
To: ptxdist
On Fri, Jun 14, 2019 at 09:14:17AM +0200, Michael Olbrich wrote:
> On Wed, Jun 05, 2019 at 04:51:40PM +0200, Roland Hieber wrote:
> > $(1) is never used in the barebox/opts macro, so barebox-opts doesn't
> > need to pass it around.
> >
> > Also adjust the package template accordingly.
> >
> > Signed-off-by: Roland Hieber <rhi@pengutronix.de>
>
> I'd like to keep this for now. I have vague plans for out-of-tree builds to
> make it possible to share the same git tree via local-src. When that
> happens, the argument will be needed.
OK, no problem then, just drop this one.
- Roland
--
Roland Hieber | r.hieber@pengutronix.de |
Pengutronix e.K. | https://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim | Phone: +49-5121-206917-5086 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2019-06-14 8:27 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-06-05 14:51 [ptxdist] [PATCH v1 1/2] pre/barebox: only use <PKG>_VERSION to build the URL Roland Hieber
2019-06-05 14:51 ` [ptxdist] [PATCH v1 2/2] pre/barebox: barebox-opts doesn't need any parameters Roland Hieber
2019-06-14 7:14 ` Michael Olbrich
2019-06-14 8:27 ` Roland Hieber
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox