u-boot.lists.denx.de archive mirror
 help / color / mirror / Atom feed
From: "Pali Rohár" <pali@kernel.org>
To: Andre Przywara <andre.przywara@arm.com>,
	Samuel Holland <samuel@sholland.org>,
	Alexandru Gagniuc <mr.nuke.me@gmail.com>,
	Stefan Roese <sr@denx.de>
Cc: u-boot@lists.denx.de
Subject: [RFC PATCH] tools: kwbimage: Allow to disable compilation of kwbimage on non-mvebu platforms
Date: Thu, 21 Oct 2021 11:33:04 +0200	[thread overview]
Message-ID: <20211021093304.25399-1-pali@kernel.org> (raw)

kwbimage depends on libcrypto. 32-bit mvebu platforms (except Orion and
Discovery, which are not in mach-mvebu) require kwimage for building SPL.

Some users want to compile u-boot tools without libcrypto.

Therefore add a new symbol CONFIG_TOOLS_KWBIMAGE which controls compilation
of kwbimage and define correct dependences between mvebu, kwbimage and
libcrypto targets.

This allows disabling of kwbimage compilation on non-mvebu platforms.

Signed-off-by: Pali Rohár <pali@kernel.org>
---
 arch/arm/mach-mvebu/Kconfig | 1 +
 tools/Kconfig               | 5 +++++
 tools/Makefile              | 5 ++++-
 3 files changed, 10 insertions(+), 1 deletion(-)

diff --git a/arch/arm/mach-mvebu/Kconfig b/arch/arm/mach-mvebu/Kconfig
index 54dff9986b41..1ccbccea1dda 100644
--- a/arch/arm/mach-mvebu/Kconfig
+++ b/arch/arm/mach-mvebu/Kconfig
@@ -15,6 +15,7 @@ config ARMADA_32BIT
 	select SPL_SIMPLE_BUS if SPL
 	select SUPPORT_SPL
 	select TRANSLATION_OFFSET
+	select TOOLS_KWBIMAGE if SPL
 
 config ARMADA_64BIT
 	bool
diff --git a/tools/Kconfig b/tools/Kconfig
index 91ce8ae3e516..40866c5713d9 100644
--- a/tools/Kconfig
+++ b/tools/Kconfig
@@ -25,6 +25,11 @@ config TOOLS_LIBCRYPTO
 	  This selection does not affect target features, such as runtime FIT
 	  signature verification.
 
+config TOOLS_KWBIMAGE
+	bool "Enable kwbimage support in host tools"
+	default y
+	depends on TOOLS_LIBCRYPTO
+
 config TOOLS_FIT
 	def_bool y
 	help
diff --git a/tools/Makefile b/tools/Makefile
index 75d8fe71d668..08f1f5a51fb3 100644
--- a/tools/Makefile
+++ b/tools/Makefile
@@ -118,7 +118,6 @@ dumpimage-mkimage-objs := aisimage.o \
 			imximage.o \
 			imx8image.o \
 			imx8mimage.o \
-			kwbimage.o \
 			lib/md5.o \
 			lpc32xximage.o \
 			mxsimage.o \
@@ -150,6 +149,10 @@ dumpimage-mkimage-objs := aisimage.o \
 			$(RSA_OBJS-y) \
 			$(AES_OBJS-y)
 
+ifdef CONFIG_TOOLS_KWBIMAGE
+dumpimage-mkimage-objs += kwbimage.o
+endif
+
 dumpimage-objs := $(dumpimage-mkimage-objs) dumpimage.o
 mkimage-objs   := $(dumpimage-mkimage-objs) mkimage.o
 fit_info-objs   := $(dumpimage-mkimage-objs) fit_info.o
-- 
2.20.1


             reply	other threads:[~2021-10-21  9:34 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-21  9:33 Pali Rohár [this message]
2021-10-22  1:48 ` Samuel Holland
2021-10-22  8:11   ` Pali Rohár
2021-11-30 15:50 ` Alexander Dahl
2021-12-07 20:48   ` Pali Rohár
2021-11-30 16:06 ` Alexander Dahl

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=20211021093304.25399-1-pali@kernel.org \
    --to=pali@kernel.org \
    --cc=andre.przywara@arm.com \
    --cc=mr.nuke.me@gmail.com \
    --cc=samuel@sholland.org \
    --cc=sr@denx.de \
    --cc=u-boot@lists.denx.de \
    --subject='Re: [RFC PATCH] tools: kwbimage: Allow to disable compilation of kwbimage on non-mvebu platforms' \
    /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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).