From e59d26fc1924b59c3ca8cec58b0b7b2898aa7609 Mon Sep 17 00:00:00 2001 From: Joel Sherrill Date: Wed, 15 Oct 2014 14:23:30 -0500 Subject: [PATCH] libbsp/powerpc/shared/uboot_getenv.c: Fix warnings --- c/src/lib/libbsp/powerpc/shared/uboot_getenv.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/c/src/lib/libbsp/powerpc/shared/uboot_getenv.c b/c/src/lib/libbsp/powerpc/shared/uboot_getenv.c index 912560193c..43ef4af81b 100644 --- a/c/src/lib/libbsp/powerpc/shared/uboot_getenv.c +++ b/c/src/lib/libbsp/powerpc/shared/uboot_getenv.c @@ -7,9 +7,16 @@ * http://www.rtems.org/license/LICENSE. */ +#include + +/* + * If the BSP variant does not have UBoot, then disable all contents + * of this file. + */ +#if defined(HAS_UBOOT) + #include #include -#include /* Assumed to be provided by BSP */ extern const uint8_t *uboot_environment; @@ -64,4 +71,4 @@ const char *bsp_uboot_getenv( return NULL; } - +#endif /* defined(HAS_UBOOT) */