[U-Boot] [PATCH 25/25] cmd_mem: Move conditional compilation to Makefile

Jean-Christophe PLAGNIOL-VILLARD plagnioj at jcrosoft.com
Sun Aug 31 03:39:14 CEST 2008


Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj at jcrosoft.com>
---
 common/Makefile  |    2 +-
 common/cmd_mem.c |    6 ------
 2 files changed, 1 insertions(+), 7 deletions(-)

diff --git a/common/Makefile b/common/Makefile
index 00e9551..c4a11de 100644
--- a/common/Makefile
+++ b/common/Makefile
@@ -111,7 +111,7 @@ COBJS-$(CONFIG_CMD_LICENSE) += cmd_license.o
 COBJS-y += cmd_load.o
 COBJS-$(CONFIG_LOGBUFFER) += cmd_log.o
 COBJS-$(CONFIG_ID_EEPROM) += cmd_mac.o
-COBJS-y += cmd_mem.o
+COBJS-$(CONFIG_CMD_MEMORY) += cmd_mem.o
 COBJS-$(CONFIG_CMD_MFSL) += cmd_mfsl.o
 COBJS-$(CONFIG_MII)$(CONFIG_CMD_MII) += miiphyutil.o
 COBJS-$(CONFIG_CMD_MII) += cmd_mii.o
diff --git a/common/cmd_mem.c b/common/cmd_mem.c
index c17cae7..07b08fb 100644
--- a/common/cmd_mem.c
+++ b/common/cmd_mem.c
@@ -37,8 +37,6 @@
 #endif
 #include <watchdog.h>
 
-#if defined(CONFIG_CMD_MEMORY)
-
 #ifdef	CMD_MEM_DEBUG
 #define	PRINTF(fmt,args...)	printf (fmt ,##args)
 #else
@@ -1198,7 +1196,6 @@ int do_unzip ( cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
 
 
 /**************************************************/
-#if defined(CONFIG_CMD_MEMORY)
 U_BOOT_CMD(
 	md,	3,	1,	do_mem_md,
 	"md	- memory display\n",
@@ -1307,6 +1304,3 @@ U_BOOT_CMD(
 	"srcaddr dstaddr [dstsize]\n"
 );
 #endif /* CONFIG_CMD_UNZIP */
-
-#endif
-#endif
-- 
1.5.6.3



More information about the U-Boot mailing list