All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] u-boot-tools: Improve build preparation
@ 2018-11-27 19:12 ` Alexey Brodkin
  0 siblings, 0 replies; 14+ messages in thread
From: Alexey Brodkin @ 2018-11-27 19:12 UTC (permalink / raw)
  To: linux-snps-arc

Even though we're not going to build here real U-Boot binary
it is still required to "configure" U-Boot to get get to the
tools building.

We used to use "sandbox_defconfig" for that purpose but
since U-Boot v2018.11 it started to cause problems [1] due to [2].

So to have less dependencies let's create super minimalistic
configuration which is good enough to allow us to run "make tools".

[1] http://errors.yoctoproject.org/Errors/Details/202185/
[2] http://git.denx.de/?p=u-boot.git;a=commitdiff;h=a4958a71017fb142542f977c843c5fce769fc6ea

Signed-off-by: Alexey Brodkin <abrodkin at synopsys.com>
Cc: Richard Purdie <richard.purdie at linuxfoundation.org>
Cc: Otavio Salvador <otavio at ossystems.com.br>
Cc: Martin Jansa <martin.jansa at gmail.com>
Cc: Andrea Galbusera <gizero at gmail.com>
Cc: Ross Burton <ross.burton at intel.com>
Cc: Tom Rini <trini at konsulko.com>
Cc: Marek Vasut <marex at denx.de>
---
 meta/recipes-bsp/u-boot/u-boot-tools_2018.11.bb | 13 +++++--------
 1 file changed, 5 insertions(+), 8 deletions(-)

diff --git a/meta/recipes-bsp/u-boot/u-boot-tools_2018.11.bb b/meta/recipes-bsp/u-boot/u-boot-tools_2018.11.bb
index 127c4c15d1..d1cfea05f5 100644
--- a/meta/recipes-bsp/u-boot/u-boot-tools_2018.11.bb
+++ b/meta/recipes-bsp/u-boot/u-boot-tools_2018.11.bb
@@ -18,14 +18,11 @@ EXTRA_OEMAKE_class-native = 'CC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" H
 EXTRA_OEMAKE_class-nativesdk = 'CROSS_COMPILE="${HOST_PREFIX}" CC="${CC} ${CFLAGS} ${LDFLAGS}" HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" STRIP=true V=1'
 
 do_compile () {
-	oe_runmake sandbox_defconfig
-
-	# Disable CONFIG_CMD_LICENSE, license.h is not used by tools and
-	# generating it requires bin2header tool, which for target build
-	# is built with target tools and thus cannot be executed on host.
-	sed -i "s/CONFIG_CMD_LICENSE=.*/# CONFIG_CMD_LICENSE is not set/" .config
-
-	oe_runmake cross_tools NO_SDL=1
+	# Create the simplest configuration which is just enough
+	# to get to the building of tools.
+	echo "CONFIG_SYS_TEXT_BASE=0" > .config
+	oe_runmake olddefconfig
+	oe_runmake cross_tools
 }
 
 do_install () {
-- 
2.16.2

^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH] u-boot-tools: Improve build preparation
@ 2018-11-27 19:12 ` Alexey Brodkin
  0 siblings, 0 replies; 14+ messages in thread
From: Alexey Brodkin @ 2018-11-27 19:12 UTC (permalink / raw)
  To: openembedded-core
  Cc: Marek Vasut, Tom Rini, Otavio Salvador, Alexey Brodkin, linux-snps-arc

Even though we're not going to build here real U-Boot binary
it is still required to "configure" U-Boot to get get to the
tools building.

We used to use "sandbox_defconfig" for that purpose but
since U-Boot v2018.11 it started to cause problems [1] due to [2].

So to have less dependencies let's create super minimalistic
configuration which is good enough to allow us to run "make tools".

[1] http://errors.yoctoproject.org/Errors/Details/202185/
[2] http://git.denx.de/?p=u-boot.git;a=commitdiff;h=a4958a71017fb142542f977c843c5fce769fc6ea

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
Cc: Richard Purdie <richard.purdie@linuxfoundation.org>
Cc: Otavio Salvador <otavio@ossystems.com.br>
Cc: Martin Jansa <martin.jansa@gmail.com>
Cc: Andrea Galbusera <gizero@gmail.com>
Cc: Ross Burton <ross.burton@intel.com>
Cc: Tom Rini <trini@konsulko.com>
Cc: Marek Vasut <marex@denx.de>
---
 meta/recipes-bsp/u-boot/u-boot-tools_2018.11.bb | 13 +++++--------
 1 file changed, 5 insertions(+), 8 deletions(-)

diff --git a/meta/recipes-bsp/u-boot/u-boot-tools_2018.11.bb b/meta/recipes-bsp/u-boot/u-boot-tools_2018.11.bb
index 127c4c15d1..d1cfea05f5 100644
--- a/meta/recipes-bsp/u-boot/u-boot-tools_2018.11.bb
+++ b/meta/recipes-bsp/u-boot/u-boot-tools_2018.11.bb
@@ -18,14 +18,11 @@ EXTRA_OEMAKE_class-native = 'CC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" H
 EXTRA_OEMAKE_class-nativesdk = 'CROSS_COMPILE="${HOST_PREFIX}" CC="${CC} ${CFLAGS} ${LDFLAGS}" HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" STRIP=true V=1'
 
 do_compile () {
-	oe_runmake sandbox_defconfig
-
-	# Disable CONFIG_CMD_LICENSE, license.h is not used by tools and
-	# generating it requires bin2header tool, which for target build
-	# is built with target tools and thus cannot be executed on host.
-	sed -i "s/CONFIG_CMD_LICENSE=.*/# CONFIG_CMD_LICENSE is not set/" .config
-
-	oe_runmake cross_tools NO_SDL=1
+	# Create the simplest configuration which is just enough
+	# to get to the building of tools.
+	echo "CONFIG_SYS_TEXT_BASE=0" > .config
+	oe_runmake olddefconfig
+	oe_runmake cross_tools
 }
 
 do_install () {
-- 
2.16.2



^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [OE-core] [PATCH] u-boot-tools: Improve build preparation
  2018-11-27 19:12 ` Alexey Brodkin
@ 2018-11-27 19:30   ` Otavio Salvador
  -1 siblings, 0 replies; 14+ messages in thread
From: Otavio Salvador @ 2018-11-27 19:30 UTC (permalink / raw)
  To: linux-snps-arc

On Tue, Nov 27, 2018 at 5:13 PM Alexey Brodkin
<alexey.brodkin@synopsys.com> wrote:
> Even though we're not going to build here real U-Boot binary
> it is still required to "configure" U-Boot to get get to the
> tools building.
>
> We used to use "sandbox_defconfig" for that purpose but
> since U-Boot v2018.11 it started to cause problems [1] due to [2].
>
> So to have less dependencies let's create super minimalistic
> configuration which is good enough to allow us to run "make tools".
>
> [1] http://errors.yoctoproject.org/Errors/Details/202185/
> [2] http://git.denx.de/?p=u-boot.git;a=commitdiff;h=a4958a71017fb142542f977c843c5fce769fc6ea
>
> Signed-off-by: Alexey Brodkin <abrodkin at synopsys.com>

To allow extended use, we need to enable CONFIG_FIT_SIGNATURE
otherwise we won't have the support.

See:

# MXSImage needs LibSSL
ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_ARMADA_38X)$(CONFIG_ARMADA_39X)$(CONFIG_FIT_SIGNATURE),)
HOSTLOADLIBES_mkimage += \
        $(shell pkg-config --libs libssl libcrypto 2> /dev/null ||
echo "-lssl -lcrypto")

If you do that, we can likely rely on this and avoid some extra tools
packages (for example on meta-freescale).

-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854          Mobile: +1 (347) 903-9750

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] u-boot-tools: Improve build preparation
@ 2018-11-27 19:30   ` Otavio Salvador
  0 siblings, 0 replies; 14+ messages in thread
From: Otavio Salvador @ 2018-11-27 19:30 UTC (permalink / raw)
  To: Alexey Brodkin
  Cc: Marek Vasut, Tom Rini, linux-snps-arc, Otavio Salvador,
	Patches and discussions about the oe-core layer

On Tue, Nov 27, 2018 at 5:13 PM Alexey Brodkin
<alexey.brodkin@synopsys.com> wrote:
> Even though we're not going to build here real U-Boot binary
> it is still required to "configure" U-Boot to get get to the
> tools building.
>
> We used to use "sandbox_defconfig" for that purpose but
> since U-Boot v2018.11 it started to cause problems [1] due to [2].
>
> So to have less dependencies let's create super minimalistic
> configuration which is good enough to allow us to run "make tools".
>
> [1] http://errors.yoctoproject.org/Errors/Details/202185/
> [2] http://git.denx.de/?p=u-boot.git;a=commitdiff;h=a4958a71017fb142542f977c843c5fce769fc6ea
>
> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>

To allow extended use, we need to enable CONFIG_FIT_SIGNATURE
otherwise we won't have the support.

See:

# MXSImage needs LibSSL
ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_ARMADA_38X)$(CONFIG_ARMADA_39X)$(CONFIG_FIT_SIGNATURE),)
HOSTLOADLIBES_mkimage += \
        $(shell pkg-config --libs libssl libcrypto 2> /dev/null ||
echo "-lssl -lcrypto")

If you do that, we can likely rely on this and avoid some extra tools
packages (for example on meta-freescale).

-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854          Mobile: +1 (347) 903-9750


^ permalink raw reply	[flat|nested] 14+ messages in thread

* [OE-core] [PATCH] u-boot-tools: Improve build preparation
  2018-11-27 19:30   ` Otavio Salvador
@ 2018-11-27 19:52     ` Otavio Salvador
  -1 siblings, 0 replies; 14+ messages in thread
From: Otavio Salvador @ 2018-11-27 19:52 UTC (permalink / raw)
  To: linux-snps-arc

On Tue, Nov 27, 2018@5:30 PM Otavio Salvador <otavio@ossystems.com.br> wrote:
>
> On Tue, Nov 27, 2018 at 5:13 PM Alexey Brodkin
> <alexey.brodkin@synopsys.com> wrote:
> > Even though we're not going to build here real U-Boot binary
> > it is still required to "configure" U-Boot to get get to the
> > tools building.
> >
> > We used to use "sandbox_defconfig" for that purpose but
> > since U-Boot v2018.11 it started to cause problems [1] due to [2].
> >
> > So to have less dependencies let's create super minimalistic
> > configuration which is good enough to allow us to run "make tools".
> >
> > [1] http://errors.yoctoproject.org/Errors/Details/202185/
> > [2] http://git.denx.de/?p=u-boot.git;a=commitdiff;h=a4958a71017fb142542f977c843c5fce769fc6ea
> >
> > Signed-off-by: Alexey Brodkin <abrodkin at synopsys.com>
>
> To allow extended use, we need to enable CONFIG_FIT_SIGNATURE
> otherwise we won't have the support.
>
> See:
>
> # MXSImage needs LibSSL
> ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_ARMADA_38X)$(CONFIG_ARMADA_39X)$(CONFIG_FIT_SIGNATURE),)
> HOSTLOADLIBES_mkimage += \
>         $(shell pkg-config --libs libssl libcrypto 2> /dev/null ||
> echo "-lssl -lcrypto")
>
> If you do that, we can likely rely on this and avoid some extra tools
> packages (for example on meta-freescale).

Looking at this, I am wondering if folowing wouldn't be a generic
solution capable of upstreaming:

diff --git a/configs/nativetools_defconfig b/configs/nativetools_defconfig
new file mode 100644
index 0000000000..be69bdf43a
--- /dev/null
+++ b/configs/nativetools_defconfig
@@ -0,0 +1,3 @@
+CONFIG_SYS_TEXT_BASE=0
+CONFIG_FIT=y
+CONFIG_FIT_SIGNATURE=y
diff --git a/tools/Makefile b/tools/Makefile
index 3c0521f655..e916d0cebb 100644
--- a/tools/Makefile
+++ b/tools/Makefile
@@ -124,7 +124,7 @@ fit_info-objs   := $(dumpimage-mkimage-objs) fit_info.o
 fit_check_sign-objs   := $(dumpimage-mkimage-objs) fit_check_sign.o
 file2include-objs := file2include.o

-ifneq ($(CONFIG_MX23)$(CONFIG_MX28),)
+ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_FIT_SIGNATURE),)
 # Add CONFIG_MXS into host CFLAGS, so we can check whether or not register
 # the mxsimage support within tools/mxsimage.c .
 HOSTCFLAGS_mxsimage.o += -DCONFIG_MXS


-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854          Mobile: +1 (347) 903-9750

^ permalink raw reply related	[flat|nested] 14+ messages in thread

* Re: [PATCH] u-boot-tools: Improve build preparation
@ 2018-11-27 19:52     ` Otavio Salvador
  0 siblings, 0 replies; 14+ messages in thread
From: Otavio Salvador @ 2018-11-27 19:52 UTC (permalink / raw)
  To: Otavio Salvador
  Cc: Marek Vasut, Tom Rini, Alexey Brodkin, linux-snps-arc,
	Patches and discussions about the oe-core layer

On Tue, Nov 27, 2018 at 5:30 PM Otavio Salvador <otavio@ossystems.com.br> wrote:
>
> On Tue, Nov 27, 2018 at 5:13 PM Alexey Brodkin
> <alexey.brodkin@synopsys.com> wrote:
> > Even though we're not going to build here real U-Boot binary
> > it is still required to "configure" U-Boot to get get to the
> > tools building.
> >
> > We used to use "sandbox_defconfig" for that purpose but
> > since U-Boot v2018.11 it started to cause problems [1] due to [2].
> >
> > So to have less dependencies let's create super minimalistic
> > configuration which is good enough to allow us to run "make tools".
> >
> > [1] http://errors.yoctoproject.org/Errors/Details/202185/
> > [2] http://git.denx.de/?p=u-boot.git;a=commitdiff;h=a4958a71017fb142542f977c843c5fce769fc6ea
> >
> > Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
>
> To allow extended use, we need to enable CONFIG_FIT_SIGNATURE
> otherwise we won't have the support.
>
> See:
>
> # MXSImage needs LibSSL
> ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_ARMADA_38X)$(CONFIG_ARMADA_39X)$(CONFIG_FIT_SIGNATURE),)
> HOSTLOADLIBES_mkimage += \
>         $(shell pkg-config --libs libssl libcrypto 2> /dev/null ||
> echo "-lssl -lcrypto")
>
> If you do that, we can likely rely on this and avoid some extra tools
> packages (for example on meta-freescale).

Looking at this, I am wondering if folowing wouldn't be a generic
solution capable of upstreaming:

diff --git a/configs/nativetools_defconfig b/configs/nativetools_defconfig
new file mode 100644
index 0000000000..be69bdf43a
--- /dev/null
+++ b/configs/nativetools_defconfig
@@ -0,0 +1,3 @@
+CONFIG_SYS_TEXT_BASE=0
+CONFIG_FIT=y
+CONFIG_FIT_SIGNATURE=y
diff --git a/tools/Makefile b/tools/Makefile
index 3c0521f655..e916d0cebb 100644
--- a/tools/Makefile
+++ b/tools/Makefile
@@ -124,7 +124,7 @@ fit_info-objs   := $(dumpimage-mkimage-objs) fit_info.o
 fit_check_sign-objs   := $(dumpimage-mkimage-objs) fit_check_sign.o
 file2include-objs := file2include.o

-ifneq ($(CONFIG_MX23)$(CONFIG_MX28),)
+ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_FIT_SIGNATURE),)
 # Add CONFIG_MXS into host CFLAGS, so we can check whether or not register
 # the mxsimage support within tools/mxsimage.c .
 HOSTCFLAGS_mxsimage.o += -DCONFIG_MXS


-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854          Mobile: +1 (347) 903-9750


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [OE-core] [PATCH] u-boot-tools: Improve build preparation
  2018-11-27 19:52     ` Otavio Salvador
@ 2018-11-27 20:21       ` Otavio Salvador
  -1 siblings, 0 replies; 14+ messages in thread
From: Otavio Salvador @ 2018-11-27 20:21 UTC (permalink / raw)
  To: linux-snps-arc

Hello all,

On Tue, Nov 27, 2018@5:52 PM Otavio Salvador <otavio@ossystems.com.br> wrote:
...
> Looking at this, I am wondering if folowing wouldn't be a generic
> solution capable of upstreaming:

I posted the proposed patch to U-Boot mailing list as RFC so we can
see what their feedback is about this approach.

-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854          Mobile: +1 (347) 903-9750

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] u-boot-tools: Improve build preparation
@ 2018-11-27 20:21       ` Otavio Salvador
  0 siblings, 0 replies; 14+ messages in thread
From: Otavio Salvador @ 2018-11-27 20:21 UTC (permalink / raw)
  To: Otavio Salvador
  Cc: Marek Vasut, Tom Rini, Alexey Brodkin, linux-snps-arc,
	Patches and discussions about the oe-core layer

Hello all,

On Tue, Nov 27, 2018 at 5:52 PM Otavio Salvador <otavio@ossystems.com.br> wrote:
...
> Looking at this, I am wondering if folowing wouldn't be a generic
> solution capable of upstreaming:

I posted the proposed patch to U-Boot mailing list as RFC so we can
see what their feedback is about this approach.

-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854          Mobile: +1 (347) 903-9750


^ permalink raw reply	[flat|nested] 14+ messages in thread

* [OE-core] [PATCH] u-boot-tools: Improve build preparation
  2018-11-27 19:52     ` Otavio Salvador
@ 2018-11-27 20:49       ` Alexey Brodkin
  -1 siblings, 0 replies; 14+ messages in thread
From: Alexey Brodkin @ 2018-11-27 20:49 UTC (permalink / raw)
  To: linux-snps-arc

Hi Otavio,

On Tue, 2018-11-27@17:52 -0200, Otavio Salvador wrote:
> On Tue, Nov 27, 2018@5:30 PM Otavio Salvador <otavio@ossystems.com.br> wrote:
> > On Tue, Nov 27, 2018 at 5:13 PM Alexey Brodkin
> > <alexey.brodkin@synopsys.com> wrote:
> > > Even though we're not going to build here real U-Boot binary
> > > it is still required to "configure" U-Boot to get get to the
> > > tools building.
> > > 
> > > We used to use "sandbox_defconfig" for that purpose but
> > > since U-Boot v2018.11 it started to cause problems [1] due to [2].
> > > 
> > > So to have less dependencies let's create super minimalistic
> > > configuration which is good enough to allow us to run "make tools".
> > > 
> > > [1] 
> > > https://urldefense.proofpoint.com/v2/url?u=http-3A__errors.yoctoproject.org_Errors_Details_202185_&d=DwIBaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=lqdeeSSEes0GFDDl656eViXO7breS55ytWkhpk5R81I&m=6GBkAGgxs4IOh0rJ4joj36Xukb_msE_tdIIJQXh8Gbg&s=vuvAMfkM9WIKHek7mwuwSjWKKpUcKJ-zCcKypEfxCuw&e=
> > > [2] 
> > > https://urldefense.proofpoint.com/v2/url?u=http-3A__git.denx.de_-3Fp-3Du-2Dboot.git-3Ba-3Dcommitdiff-3Bh-3Da4958a71017fb142542f977c843c5fce769fc6ea&d=DwIBaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=lqdeeSSEes0GFDDl656eViXO7breS55ytWkhpk5R81I&m=6GBkAGgxs4IOh0rJ4joj36Xukb_msE_tdIIJQXh8Gbg&s=GN4U6Of_hi-W_5CEu3RvRUIVEjgaNwnK8CarkwIly4Y&e=
> > > 
> > > Signed-off-by: Alexey Brodkin <abrodkin at synopsys.com>
> > 
> > To allow extended use, we need to enable CONFIG_FIT_SIGNATURE
> > otherwise we won't have the support.
> > 
> > See:
> > 
> > # MXSImage needs LibSSL
> > ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_ARMADA_38X)$(CONFIG_ARMADA_39X)$(CONFIG_FIT_SIGNATURE),)
> > HOSTLOADLIBES_mkimage += \
> >         $(shell pkg-config --libs libssl libcrypto 2> /dev/null ||
> > echo "-lssl -lcrypto")
> > 
> > If you do that, we can likely rely on this and avoid some extra tools
> > packages (for example on meta-freescale).
> 
> Looking at this, I am wondering if folowing wouldn't be a generic
> solution capable of upstreaming:
> 
> diff --git a/configs/nativetools_defconfig b/configs/nativetools_defconfig
> new file mode 100644
> index 0000000000..be69bdf43a
> --- /dev/null
> +++ b/configs/nativetools_defconfig
> @@ -0,0 +1,3 @@
> +CONFIG_SYS_TEXT_BASE=0
> +CONFIG_FIT=y
> +CONFIG_FIT_SIGNATURE=y
> diff --git a/tools/Makefile b/tools/Makefile
> index 3c0521f655..e916d0cebb 100644
> --- a/tools/Makefile
> +++ b/tools/Makefile
> @@ -124,7 +124,7 @@ fit_info-objs   := $(dumpimage-mkimage-objs) fit_info.o
>  fit_check_sign-objs   := $(dumpimage-mkimage-objs) fit_check_sign.o
>  file2include-objs := file2include.o
> 
> -ifneq ($(CONFIG_MX23)$(CONFIG_MX28),)
> +ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_FIT_SIGNATURE),)
>  # Add CONFIG_MXS into host CFLAGS, so we can check whether or not register
>  # the mxsimage support within tools/mxsimage.c .
>  HOSTCFLAGS_mxsimage.o += -DCONFIG_MXS

So do you think there's a room for improvement in my patch for OE?
Or before we get a missing part for tools/Makefile there's nothing more
to be done in OE?

-Alexey

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] u-boot-tools: Improve build preparation
@ 2018-11-27 20:49       ` Alexey Brodkin
  0 siblings, 0 replies; 14+ messages in thread
From: Alexey Brodkin @ 2018-11-27 20:49 UTC (permalink / raw)
  To: otavio.salvador
  Cc: marex, trini, otavio, alexey.brodkin, openembedded-core, linux-snps-arc

Hi Otavio,

On Tue, 2018-11-27 at 17:52 -0200, Otavio Salvador wrote:
> On Tue, Nov 27, 2018 at 5:30 PM Otavio Salvador <otavio@ossystems.com.br> wrote:
> > On Tue, Nov 27, 2018 at 5:13 PM Alexey Brodkin
> > <alexey.brodkin@synopsys.com> wrote:
> > > Even though we're not going to build here real U-Boot binary
> > > it is still required to "configure" U-Boot to get get to the
> > > tools building.
> > > 
> > > We used to use "sandbox_defconfig" for that purpose but
> > > since U-Boot v2018.11 it started to cause problems [1] due to [2].
> > > 
> > > So to have less dependencies let's create super minimalistic
> > > configuration which is good enough to allow us to run "make tools".
> > > 
> > > [1] 
> > > https://urldefense.proofpoint.com/v2/url?u=http-3A__errors.yoctoproject.org_Errors_Details_202185_&d=DwIBaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=lqdeeSSEes0GFDDl656eViXO7breS55ytWkhpk5R81I&m=6GBkAGgxs4IOh0rJ4joj36Xukb_msE_tdIIJQXh8Gbg&s=vuvAMfkM9WIKHek7mwuwSjWKKpUcKJ-zCcKypEfxCuw&e=
> > > [2] 
> > > https://urldefense.proofpoint.com/v2/url?u=http-3A__git.denx.de_-3Fp-3Du-2Dboot.git-3Ba-3Dcommitdiff-3Bh-3Da4958a71017fb142542f977c843c5fce769fc6ea&d=DwIBaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=lqdeeSSEes0GFDDl656eViXO7breS55ytWkhpk5R81I&m=6GBkAGgxs4IOh0rJ4joj36Xukb_msE_tdIIJQXh8Gbg&s=GN4U6Of_hi-W_5CEu3RvRUIVEjgaNwnK8CarkwIly4Y&e=
> > > 
> > > Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
> > 
> > To allow extended use, we need to enable CONFIG_FIT_SIGNATURE
> > otherwise we won't have the support.
> > 
> > See:
> > 
> > # MXSImage needs LibSSL
> > ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_ARMADA_38X)$(CONFIG_ARMADA_39X)$(CONFIG_FIT_SIGNATURE),)
> > HOSTLOADLIBES_mkimage += \
> >         $(shell pkg-config --libs libssl libcrypto 2> /dev/null ||
> > echo "-lssl -lcrypto")
> > 
> > If you do that, we can likely rely on this and avoid some extra tools
> > packages (for example on meta-freescale).
> 
> Looking at this, I am wondering if folowing wouldn't be a generic
> solution capable of upstreaming:
> 
> diff --git a/configs/nativetools_defconfig b/configs/nativetools_defconfig
> new file mode 100644
> index 0000000000..be69bdf43a
> --- /dev/null
> +++ b/configs/nativetools_defconfig
> @@ -0,0 +1,3 @@
> +CONFIG_SYS_TEXT_BASE=0
> +CONFIG_FIT=y
> +CONFIG_FIT_SIGNATURE=y
> diff --git a/tools/Makefile b/tools/Makefile
> index 3c0521f655..e916d0cebb 100644
> --- a/tools/Makefile
> +++ b/tools/Makefile
> @@ -124,7 +124,7 @@ fit_info-objs   := $(dumpimage-mkimage-objs) fit_info.o
>  fit_check_sign-objs   := $(dumpimage-mkimage-objs) fit_check_sign.o
>  file2include-objs := file2include.o
> 
> -ifneq ($(CONFIG_MX23)$(CONFIG_MX28),)
> +ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_FIT_SIGNATURE),)
>  # Add CONFIG_MXS into host CFLAGS, so we can check whether or not register
>  # the mxsimage support within tools/mxsimage.c .
>  HOSTCFLAGS_mxsimage.o += -DCONFIG_MXS

So do you think there's a room for improvement in my patch for OE?
Or before we get a missing part for tools/Makefile there's nothing more
to be done in OE?

-Alexey

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [OE-core] [PATCH] u-boot-tools: Improve build preparation
  2018-11-27 20:49       ` Alexey Brodkin
@ 2018-11-28 10:58         ` Otavio Salvador
  -1 siblings, 0 replies; 14+ messages in thread
From: Otavio Salvador @ 2018-11-28 10:58 UTC (permalink / raw)
  To: linux-snps-arc

On Tue, Nov 27, 2018 at 6:49 PM Alexey Brodkin
<alexey.brodkin@synopsys.com> wrote:
> On Tue, 2018-11-27@17:52 -0200, Otavio Salvador wrote:
> > On Tue, Nov 27, 2018@5:30 PM Otavio Salvador <otavio@ossystems.com.br> wrote:
> > > On Tue, Nov 27, 2018 at 5:13 PM Alexey Brodkin
> > > <alexey.brodkin@synopsys.com> wrote:
> > > > Even though we're not going to build here real U-Boot binary
> > > > it is still required to "configure" U-Boot to get get to the
> > > > tools building.
> > > >
> > > > We used to use "sandbox_defconfig" for that purpose but
> > > > since U-Boot v2018.11 it started to cause problems [1] due to [2].
> > > >
> > > > So to have less dependencies let's create super minimalistic
> > > > configuration which is good enough to allow us to run "make tools".
> > > >
> > > > [1]
> > > > https://urldefense.proofpoint.com/v2/url?u=http-3A__errors.yoctoproject.org_Errors_Details_202185_&d=DwIBaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=lqdeeSSEes0GFDDl656eViXO7breS55ytWkhpk5R81I&m=6GBkAGgxs4IOh0rJ4joj36Xukb_msE_tdIIJQXh8Gbg&s=vuvAMfkM9WIKHek7mwuwSjWKKpUcKJ-zCcKypEfxCuw&e=
> > > > [2]
> > > > https://urldefense.proofpoint.com/v2/url?u=http-3A__git.denx.de_-3Fp-3Du-2Dboot.git-3Ba-3Dcommitdiff-3Bh-3Da4958a71017fb142542f977c843c5fce769fc6ea&d=DwIBaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=lqdeeSSEes0GFDDl656eViXO7breS55ytWkhpk5R81I&m=6GBkAGgxs4IOh0rJ4joj36Xukb_msE_tdIIJQXh8Gbg&s=GN4U6Of_hi-W_5CEu3RvRUIVEjgaNwnK8CarkwIly4Y&e=
> > > >
> > > > Signed-off-by: Alexey Brodkin <abrodkin at synopsys.com>
> > >
> > > To allow extended use, we need to enable CONFIG_FIT_SIGNATURE
> > > otherwise we won't have the support.
> > >
> > > See:
> > >
> > > # MXSImage needs LibSSL
> > > ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_ARMADA_38X)$(CONFIG_ARMADA_39X)$(CONFIG_FIT_SIGNATURE),)
> > > HOSTLOADLIBES_mkimage += \
> > >         $(shell pkg-config --libs libssl libcrypto 2> /dev/null ||
> > > echo "-lssl -lcrypto")
> > >
> > > If you do that, we can likely rely on this and avoid some extra tools
> > > packages (for example on meta-freescale).
> >
> > Looking at this, I am wondering if folowing wouldn't be a generic
> > solution capable of upstreaming:
> >
> > diff --git a/configs/nativetools_defconfig b/configs/nativetools_defconfig
> > new file mode 100644
> > index 0000000000..be69bdf43a
> > --- /dev/null
> > +++ b/configs/nativetools_defconfig
> > @@ -0,0 +1,3 @@
> > +CONFIG_SYS_TEXT_BASE=0
> > +CONFIG_FIT=y
> > +CONFIG_FIT_SIGNATURE=y
> > diff --git a/tools/Makefile b/tools/Makefile
> > index 3c0521f655..e916d0cebb 100644
> > --- a/tools/Makefile
> > +++ b/tools/Makefile
> > @@ -124,7 +124,7 @@ fit_info-objs   := $(dumpimage-mkimage-objs) fit_info.o
> >  fit_check_sign-objs   := $(dumpimage-mkimage-objs) fit_check_sign.o
> >  file2include-objs := file2include.o
> >
> > -ifneq ($(CONFIG_MX23)$(CONFIG_MX28),)
> > +ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_FIT_SIGNATURE),)
> >  # Add CONFIG_MXS into host CFLAGS, so we can check whether or not register
> >  # the mxsimage support within tools/mxsimage.c .
> >  HOSTCFLAGS_mxsimage.o += -DCONFIG_MXS
>
> So do you think there's a room for improvement in my patch for OE?
> Or before we get a missing part for tools/Makefile there's nothing more
> to be done in OE?

You could use this attached patch (marking as Pending as it is still
RFC). It allow us to drop or 'mxsboot' recipe on meta-freescale, for
example.

-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854          Mobile: +1 (347) 903-9750

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] u-boot-tools: Improve build preparation
@ 2018-11-28 10:58         ` Otavio Salvador
  0 siblings, 0 replies; 14+ messages in thread
From: Otavio Salvador @ 2018-11-28 10:58 UTC (permalink / raw)
  To: Alexey Brodkin
  Cc: Marek Vasut, Tom Rini, linux-snps-arc, Otavio Salvador,
	Patches and discussions about the oe-core layer

On Tue, Nov 27, 2018 at 6:49 PM Alexey Brodkin
<alexey.brodkin@synopsys.com> wrote:
> On Tue, 2018-11-27 at 17:52 -0200, Otavio Salvador wrote:
> > On Tue, Nov 27, 2018 at 5:30 PM Otavio Salvador <otavio@ossystems.com.br> wrote:
> > > On Tue, Nov 27, 2018 at 5:13 PM Alexey Brodkin
> > > <alexey.brodkin@synopsys.com> wrote:
> > > > Even though we're not going to build here real U-Boot binary
> > > > it is still required to "configure" U-Boot to get get to the
> > > > tools building.
> > > >
> > > > We used to use "sandbox_defconfig" for that purpose but
> > > > since U-Boot v2018.11 it started to cause problems [1] due to [2].
> > > >
> > > > So to have less dependencies let's create super minimalistic
> > > > configuration which is good enough to allow us to run "make tools".
> > > >
> > > > [1]
> > > > https://urldefense.proofpoint.com/v2/url?u=http-3A__errors.yoctoproject.org_Errors_Details_202185_&d=DwIBaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=lqdeeSSEes0GFDDl656eViXO7breS55ytWkhpk5R81I&m=6GBkAGgxs4IOh0rJ4joj36Xukb_msE_tdIIJQXh8Gbg&s=vuvAMfkM9WIKHek7mwuwSjWKKpUcKJ-zCcKypEfxCuw&e=
> > > > [2]
> > > > https://urldefense.proofpoint.com/v2/url?u=http-3A__git.denx.de_-3Fp-3Du-2Dboot.git-3Ba-3Dcommitdiff-3Bh-3Da4958a71017fb142542f977c843c5fce769fc6ea&d=DwIBaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=lqdeeSSEes0GFDDl656eViXO7breS55ytWkhpk5R81I&m=6GBkAGgxs4IOh0rJ4joj36Xukb_msE_tdIIJQXh8Gbg&s=GN4U6Of_hi-W_5CEu3RvRUIVEjgaNwnK8CarkwIly4Y&e=
> > > >
> > > > Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
> > >
> > > To allow extended use, we need to enable CONFIG_FIT_SIGNATURE
> > > otherwise we won't have the support.
> > >
> > > See:
> > >
> > > # MXSImage needs LibSSL
> > > ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_ARMADA_38X)$(CONFIG_ARMADA_39X)$(CONFIG_FIT_SIGNATURE),)
> > > HOSTLOADLIBES_mkimage += \
> > >         $(shell pkg-config --libs libssl libcrypto 2> /dev/null ||
> > > echo "-lssl -lcrypto")
> > >
> > > If you do that, we can likely rely on this and avoid some extra tools
> > > packages (for example on meta-freescale).
> >
> > Looking at this, I am wondering if folowing wouldn't be a generic
> > solution capable of upstreaming:
> >
> > diff --git a/configs/nativetools_defconfig b/configs/nativetools_defconfig
> > new file mode 100644
> > index 0000000000..be69bdf43a
> > --- /dev/null
> > +++ b/configs/nativetools_defconfig
> > @@ -0,0 +1,3 @@
> > +CONFIG_SYS_TEXT_BASE=0
> > +CONFIG_FIT=y
> > +CONFIG_FIT_SIGNATURE=y
> > diff --git a/tools/Makefile b/tools/Makefile
> > index 3c0521f655..e916d0cebb 100644
> > --- a/tools/Makefile
> > +++ b/tools/Makefile
> > @@ -124,7 +124,7 @@ fit_info-objs   := $(dumpimage-mkimage-objs) fit_info.o
> >  fit_check_sign-objs   := $(dumpimage-mkimage-objs) fit_check_sign.o
> >  file2include-objs := file2include.o
> >
> > -ifneq ($(CONFIG_MX23)$(CONFIG_MX28),)
> > +ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_FIT_SIGNATURE),)
> >  # Add CONFIG_MXS into host CFLAGS, so we can check whether or not register
> >  # the mxsimage support within tools/mxsimage.c .
> >  HOSTCFLAGS_mxsimage.o += -DCONFIG_MXS
>
> So do you think there's a room for improvement in my patch for OE?
> Or before we get a missing part for tools/Makefile there's nothing more
> to be done in OE?

You could use this attached patch (marking as Pending as it is still
RFC). It allow us to drop or 'mxsboot' recipe on meta-freescale, for
example.

-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854          Mobile: +1 (347) 903-9750


^ permalink raw reply	[flat|nested] 14+ messages in thread

* [OE-core] [PATCH] u-boot-tools: Improve build preparation
  2018-11-28 10:58         ` Otavio Salvador
@ 2018-11-28 10:59           ` Otavio Salvador
  -1 siblings, 0 replies; 14+ messages in thread
From: Otavio Salvador @ 2018-11-28 10:59 UTC (permalink / raw)
  To: linux-snps-arc

On Wed, Nov 28, 2018@8:58 AM Otavio Salvador <otavio@ossystems.com.br> wrote:
> On Tue, Nov 27, 2018 at 6:49 PM Alexey Brodkin
> <alexey.brodkin@synopsys.com> wrote:
> > On Tue, 2018-11-27@17:52 -0200, Otavio Salvador wrote:
> > > On Tue, Nov 27, 2018@5:30 PM Otavio Salvador <otavio@ossystems.com.br> wrote:
> > > > On Tue, Nov 27, 2018 at 5:13 PM Alexey Brodkin
> > > > <alexey.brodkin@synopsys.com> wrote:
> > > > > Even though we're not going to build here real U-Boot binary
> > > > > it is still required to "configure" U-Boot to get get to the
> > > > > tools building.
> > > > >
> > > > > We used to use "sandbox_defconfig" for that purpose but
> > > > > since U-Boot v2018.11 it started to cause problems [1] due to [2].
> > > > >
> > > > > So to have less dependencies let's create super minimalistic
> > > > > configuration which is good enough to allow us to run "make tools".
> > > > >
> > > > > [1]
> > > > > https://urldefense.proofpoint.com/v2/url?u=http-3A__errors.yoctoproject.org_Errors_Details_202185_&d=DwIBaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=lqdeeSSEes0GFDDl656eViXO7breS55ytWkhpk5R81I&m=6GBkAGgxs4IOh0rJ4joj36Xukb_msE_tdIIJQXh8Gbg&s=vuvAMfkM9WIKHek7mwuwSjWKKpUcKJ-zCcKypEfxCuw&e=
> > > > > [2]
> > > > > https://urldefense.proofpoint.com/v2/url?u=http-3A__git.denx.de_-3Fp-3Du-2Dboot.git-3Ba-3Dcommitdiff-3Bh-3Da4958a71017fb142542f977c843c5fce769fc6ea&d=DwIBaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=lqdeeSSEes0GFDDl656eViXO7breS55ytWkhpk5R81I&m=6GBkAGgxs4IOh0rJ4joj36Xukb_msE_tdIIJQXh8Gbg&s=GN4U6Of_hi-W_5CEu3RvRUIVEjgaNwnK8CarkwIly4Y&e=
> > > > >
> > > > > Signed-off-by: Alexey Brodkin <abrodkin at synopsys.com>
> > > >
> > > > To allow extended use, we need to enable CONFIG_FIT_SIGNATURE
> > > > otherwise we won't have the support.
> > > >
> > > > See:
> > > >
> > > > # MXSImage needs LibSSL
> > > > ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_ARMADA_38X)$(CONFIG_ARMADA_39X)$(CONFIG_FIT_SIGNATURE),)
> > > > HOSTLOADLIBES_mkimage += \
> > > >         $(shell pkg-config --libs libssl libcrypto 2> /dev/null ||
> > > > echo "-lssl -lcrypto")
> > > >
> > > > If you do that, we can likely rely on this and avoid some extra tools
> > > > packages (for example on meta-freescale).
> > >
> > > Looking at this, I am wondering if folowing wouldn't be a generic
> > > solution capable of upstreaming:
> > >
> > > diff --git a/configs/nativetools_defconfig b/configs/nativetools_defconfig
> > > new file mode 100644
> > > index 0000000000..be69bdf43a
> > > --- /dev/null
> > > +++ b/configs/nativetools_defconfig
> > > @@ -0,0 +1,3 @@
> > > +CONFIG_SYS_TEXT_BASE=0
> > > +CONFIG_FIT=y
> > > +CONFIG_FIT_SIGNATURE=y
> > > diff --git a/tools/Makefile b/tools/Makefile
> > > index 3c0521f655..e916d0cebb 100644
> > > --- a/tools/Makefile
> > > +++ b/tools/Makefile
> > > @@ -124,7 +124,7 @@ fit_info-objs   := $(dumpimage-mkimage-objs) fit_info.o
> > >  fit_check_sign-objs   := $(dumpimage-mkimage-objs) fit_check_sign.o
> > >  file2include-objs := file2include.o
> > >
> > > -ifneq ($(CONFIG_MX23)$(CONFIG_MX28),)
> > > +ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_FIT_SIGNATURE),)
> > >  # Add CONFIG_MXS into host CFLAGS, so we can check whether or not register
> > >  # the mxsimage support within tools/mxsimage.c .
> > >  HOSTCFLAGS_mxsimage.o += -DCONFIG_MXS
> >
> > So do you think there's a room for improvement in my patch for OE?
> > Or before we get a missing part for tools/Makefile there's nothing more
> > to be done in OE?
>
> You could use this attached patch (marking as Pending as it is still
> RFC). It allow us to drop or 'mxsboot' recipe on meta-freescale, for
> example.

Now... with patch...

-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854          Mobile: +1 (347) 903-9750
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-tools-add-a-generic-config-for-native-tools-building.patch
Type: text/x-patch
Size: 1952 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-snps-arc/attachments/20181128/c20e040d/attachment.bin>

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] u-boot-tools: Improve build preparation
@ 2018-11-28 10:59           ` Otavio Salvador
  0 siblings, 0 replies; 14+ messages in thread
From: Otavio Salvador @ 2018-11-28 10:59 UTC (permalink / raw)
  To: Otavio Salvador
  Cc: Marek Vasut, Tom Rini, Alexey Brodkin, linux-snps-arc,
	Patches and discussions about the oe-core layer

[-- Attachment #1: Type: text/plain, Size: 3894 bytes --]

On Wed, Nov 28, 2018 at 8:58 AM Otavio Salvador <otavio@ossystems.com.br> wrote:
> On Tue, Nov 27, 2018 at 6:49 PM Alexey Brodkin
> <alexey.brodkin@synopsys.com> wrote:
> > On Tue, 2018-11-27 at 17:52 -0200, Otavio Salvador wrote:
> > > On Tue, Nov 27, 2018 at 5:30 PM Otavio Salvador <otavio@ossystems.com.br> wrote:
> > > > On Tue, Nov 27, 2018 at 5:13 PM Alexey Brodkin
> > > > <alexey.brodkin@synopsys.com> wrote:
> > > > > Even though we're not going to build here real U-Boot binary
> > > > > it is still required to "configure" U-Boot to get get to the
> > > > > tools building.
> > > > >
> > > > > We used to use "sandbox_defconfig" for that purpose but
> > > > > since U-Boot v2018.11 it started to cause problems [1] due to [2].
> > > > >
> > > > > So to have less dependencies let's create super minimalistic
> > > > > configuration which is good enough to allow us to run "make tools".
> > > > >
> > > > > [1]
> > > > > https://urldefense.proofpoint.com/v2/url?u=http-3A__errors.yoctoproject.org_Errors_Details_202185_&d=DwIBaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=lqdeeSSEes0GFDDl656eViXO7breS55ytWkhpk5R81I&m=6GBkAGgxs4IOh0rJ4joj36Xukb_msE_tdIIJQXh8Gbg&s=vuvAMfkM9WIKHek7mwuwSjWKKpUcKJ-zCcKypEfxCuw&e=
> > > > > [2]
> > > > > https://urldefense.proofpoint.com/v2/url?u=http-3A__git.denx.de_-3Fp-3Du-2Dboot.git-3Ba-3Dcommitdiff-3Bh-3Da4958a71017fb142542f977c843c5fce769fc6ea&d=DwIBaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=lqdeeSSEes0GFDDl656eViXO7breS55ytWkhpk5R81I&m=6GBkAGgxs4IOh0rJ4joj36Xukb_msE_tdIIJQXh8Gbg&s=GN4U6Of_hi-W_5CEu3RvRUIVEjgaNwnK8CarkwIly4Y&e=
> > > > >
> > > > > Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
> > > >
> > > > To allow extended use, we need to enable CONFIG_FIT_SIGNATURE
> > > > otherwise we won't have the support.
> > > >
> > > > See:
> > > >
> > > > # MXSImage needs LibSSL
> > > > ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_ARMADA_38X)$(CONFIG_ARMADA_39X)$(CONFIG_FIT_SIGNATURE),)
> > > > HOSTLOADLIBES_mkimage += \
> > > >         $(shell pkg-config --libs libssl libcrypto 2> /dev/null ||
> > > > echo "-lssl -lcrypto")
> > > >
> > > > If you do that, we can likely rely on this and avoid some extra tools
> > > > packages (for example on meta-freescale).
> > >
> > > Looking at this, I am wondering if folowing wouldn't be a generic
> > > solution capable of upstreaming:
> > >
> > > diff --git a/configs/nativetools_defconfig b/configs/nativetools_defconfig
> > > new file mode 100644
> > > index 0000000000..be69bdf43a
> > > --- /dev/null
> > > +++ b/configs/nativetools_defconfig
> > > @@ -0,0 +1,3 @@
> > > +CONFIG_SYS_TEXT_BASE=0
> > > +CONFIG_FIT=y
> > > +CONFIG_FIT_SIGNATURE=y
> > > diff --git a/tools/Makefile b/tools/Makefile
> > > index 3c0521f655..e916d0cebb 100644
> > > --- a/tools/Makefile
> > > +++ b/tools/Makefile
> > > @@ -124,7 +124,7 @@ fit_info-objs   := $(dumpimage-mkimage-objs) fit_info.o
> > >  fit_check_sign-objs   := $(dumpimage-mkimage-objs) fit_check_sign.o
> > >  file2include-objs := file2include.o
> > >
> > > -ifneq ($(CONFIG_MX23)$(CONFIG_MX28),)
> > > +ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_FIT_SIGNATURE),)
> > >  # Add CONFIG_MXS into host CFLAGS, so we can check whether or not register
> > >  # the mxsimage support within tools/mxsimage.c .
> > >  HOSTCFLAGS_mxsimage.o += -DCONFIG_MXS
> >
> > So do you think there's a room for improvement in my patch for OE?
> > Or before we get a missing part for tools/Makefile there's nothing more
> > to be done in OE?
>
> You could use this attached patch (marking as Pending as it is still
> RFC). It allow us to drop or 'mxsboot' recipe on meta-freescale, for
> example.

Now... with patch...

-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854          Mobile: +1 (347) 903-9750

[-- Attachment #2: 0001-tools-add-a-generic-config-for-native-tools-building.patch --]
[-- Type: text/x-patch, Size: 1952 bytes --]

From 5731cafd83528f2d79476e6241f22d7f2618a364 Mon Sep 17 00:00:00 2001
From: Otavio Salvador <otavio@ossystems.com.br>
Date: Tue, 27 Nov 2018 18:14:11 -0200
Subject: [PATCH] tools: add a generic config for native tools building
Organization: O.S. Systems Software LTDA.

The motivation for this is to allow distributions to distribute all
possible tools in a generic way, avoiding the need of specific tools
building for each machine.

Especially on OpenEmbedded / Yocto Project ecosystem, it is very
common each BSP to end providing their specific tools when they need
to generate images for some SoC (e.g MX23 / MX28 in meta-freescale
case).

Using this, we can package the tools doing:

$: make tools-only_defconfig
$: make tools-only

Series-to: u-boot
Series-prefix: RFC
Series-cc: Alexey Brodkin <alexey.brodkin@synopsys.com>
Series-cc: Peter Robinson <pbrobinson@gmail.com>

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
---
 configs/tools-only_defconfig | 3 +++
 tools/Makefile               | 2 +-
 2 files changed, 4 insertions(+), 1 deletion(-)
 create mode 100644 configs/tools-only_defconfig

diff --git a/configs/tools-only_defconfig b/configs/tools-only_defconfig
new file mode 100644
index 0000000000..be69bdf43a
--- /dev/null
+++ b/configs/tools-only_defconfig
@@ -0,0 +1,3 @@
+CONFIG_SYS_TEXT_BASE=0
+CONFIG_FIT=y
+CONFIG_FIT_SIGNATURE=y
diff --git a/tools/Makefile b/tools/Makefile
index 3c0521f655..e916d0cebb 100644
--- a/tools/Makefile
+++ b/tools/Makefile
@@ -124,7 +124,7 @@ fit_info-objs   := $(dumpimage-mkimage-objs) fit_info.o
 fit_check_sign-objs   := $(dumpimage-mkimage-objs) fit_check_sign.o
 file2include-objs := file2include.o
 
-ifneq ($(CONFIG_MX23)$(CONFIG_MX28),)
+ifneq ($(CONFIG_MX23)$(CONFIG_MX28)$(CONFIG_FIT_SIGNATURE),)
 # Add CONFIG_MXS into host CFLAGS, so we can check whether or not register
 # the mxsimage support within tools/mxsimage.c .
 HOSTCFLAGS_mxsimage.o += -DCONFIG_MXS
-- 
2.19.2


^ permalink raw reply related	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2018-11-28 10:59 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-11-27 19:12 [PATCH] u-boot-tools: Improve build preparation Alexey Brodkin
2018-11-27 19:12 ` Alexey Brodkin
2018-11-27 19:30 ` [OE-core] " Otavio Salvador
2018-11-27 19:30   ` Otavio Salvador
2018-11-27 19:52   ` [OE-core] " Otavio Salvador
2018-11-27 19:52     ` Otavio Salvador
2018-11-27 20:21     ` [OE-core] " Otavio Salvador
2018-11-27 20:21       ` Otavio Salvador
2018-11-27 20:49     ` [OE-core] " Alexey Brodkin
2018-11-27 20:49       ` Alexey Brodkin
2018-11-28 10:58       ` [OE-core] " Otavio Salvador
2018-11-28 10:58         ` Otavio Salvador
2018-11-28 10:59         ` [OE-core] " Otavio Salvador
2018-11-28 10:59           ` Otavio Salvador

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.