[U-Boot] [PATCH 3/4] sha1: add dedicated config option

Mike Frysinger vapier at gentoo.org
Wed Nov 4 22:46:35 CET 2009


The sha1 code is currently compiled for everyone, but in reality, it's
only used by the FIT code.  So make it optional just like MD5.

Signed-off-by: Mike Frysinger <vapier at gentoo.org>
---
 include/image.h      |    1 +
 lib_generic/Makefile |    2 +-
 2 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/include/image.h b/include/image.h
index b82f4b9..6474eca 100644
--- a/include/image.h
+++ b/include/image.h
@@ -56,6 +56,7 @@
 #include <libfdt.h>
 #include <fdt_support.h>
 #define CONFIG_MD5		/* FIT images need MD5 support */
+#define CONFIG_SHA1		/* and SHA1 */
 #endif
 
 /*
diff --git a/lib_generic/Makefile b/lib_generic/Makefile
index ae2c282..63b8cca 100644
--- a/lib_generic/Makefile
+++ b/lib_generic/Makefile
@@ -40,7 +40,7 @@ COBJS-$(CONFIG_GZIP) += gunzip.o
 COBJS-$(CONFIG_LMB) += lmb.o
 COBJS-y += ldiv.o
 COBJS-$(CONFIG_MD5) += md5.o
-COBJS-y += sha1.o
+COBJS-$(CONFIG_SHA1) += sha1.o
 COBJS-$(CONFIG_SHA256) += sha256.o
 COBJS-y += string.o
 COBJS-y	+= strmhz.o
-- 
1.6.5.2



More information about the U-Boot mailing list