common/cmd_ximg.c: add ifdef protection for gzip uncompression
authorMatthew McClintock <msm@freescale.com>
Tue, 24 May 2011 05:48:26 +0000 (05:48 +0000)
committerWolfgang Denk <wd@denx.de>
Tue, 26 Jul 2011 12:11:21 +0000 (14:11 +0200)
Print a message if we do not have the ability to uncompress a gzip
image. Before, u-boot would just assume the routines were available

Signed-off-by: Matthew McClintock <msm@freescale.com>
common/cmd_ximg.c

index dceb975498beef93c2941afcbeacf5ba6a204ec2..850188eeae4e12c5dff9265c3435890f18fa0b79 100644 (file)
@@ -215,6 +215,7 @@ do_imgextract(cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[])
                        memmove ((char *) dest, (char *)data, len);
 #endif /* CONFIG_HW_WATCHDOG || CONFIG_WATCHDOG */
                        break;
+#ifdef CONFIG_GZIP
                case IH_COMP_GZIP:
                        printf ("   Uncompressing part %d ... ", part);
                        if (gunzip ((void *) dest, unc_len,
@@ -223,6 +224,7 @@ do_imgextract(cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[])
                                return 1;
                        }
                        break;
+#endif
 #if defined(CONFIG_BZIP2)
                case IH_COMP_BZIP2:
                        {