common/ non-cmd: Augment CONFIG_COMMANDS tests with defined(CONFIG_CMD_*).
This is a compatibility step that allows both the older form
and the new form to co-exist for a while until the older can
be removed entirely.
All transformations are of the form:
Before:
#if (CONFIG_COMMANDS & CFG_CMD_AUTOSCRIPT)
After:
#if (CONFIG_COMMANDS & CFG_CMD_AUTOSCRIPT) || defined(CONFIG_CMD_AUTOSCRIPT)
Signed-off-by: Jon Loeliger <jdl@freescale.com>
diff --git a/common/command.c b/common/command.c
index e917975..f8bd16b 100644
--- a/common/command.c
+++ b/common/command.c
@@ -42,7 +42,7 @@
NULL
);
-#if (CONFIG_COMMANDS & CFG_CMD_ECHO)
+#if (CONFIG_COMMANDS & CFG_CMD_ECHO) || defined(CONFIG_CMD_ECHO)
int
do_echo (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
@@ -409,7 +409,7 @@
{
install_auto_complete_handler("printenv", var_complete);
install_auto_complete_handler("setenv", var_complete);
-#if (CONFIG_COMMANDS & CFG_CMD_RUN)
+#if (CONFIG_COMMANDS & CFG_CMD_RUN) || defined(CONFIG_CMD_RUN)
install_auto_complete_handler("run", var_complete);
#endif
}