From mboxrd@z Thu Jan 1 00:00:00 1970 From: Shinya Kuribayashi Date: Mon, 11 Jan 2010 11:00:14 +0900 Subject: [U-Boot] [PATCH 2/2] MIPS: lib_mips/board.c: Fix undefined "getenv_IPaddr" build error In-Reply-To: <4B4A8367.8060206@pobox.com> References: <4B4A8367.8060206@pobox.com> Message-ID: <4B4A862E.2000400@pobox.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de In the commit 6ac59c55 (net: pull CONFIG checks out of source and into makefile), net/net.o is changed to be built-in only when CONFIG_CMD_NET is enabled, while lib_mips/board.c has a reference to "getenv_IPaddr() left as-is. And now Micronas VCT Platinum AVC board builds (vct_platinumavc*_config) failed as follows, because they don't have ethernet support and disable CONFIG_CMD_NET option: lib_mips/libmips.a(board.o): In function `board_init_r': board.c:(.text+0x2e4): undefined reference to `getenv_IPaddr' make: *** [u-boot] Error 1 VCT Platinum AVC is the only MIPS target who doesn't have CONFIG_CMD_NET and suffer from this issue at this moment. Signed-off-by: Shinya Kuribayashi --- Note that arm/avr32/i386/m68k/nios/nios2/ppc/sparc have the same issue, while blackfin/microblaze/sh don't. lib_mips/board.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/lib_mips/board.c b/lib_mips/board.c index b2d113e..5c35884 100644 --- a/lib_mips/board.c +++ b/lib_mips/board.c @@ -370,8 +370,10 @@ void board_init_r (gd_t *id, ulong dest_addr) /* relocate environment function pointers etc. */ env_relocate(); +#ifdef CONFIG_CMD_NET /* IP Address */ bd->bi_ip_addr = getenv_IPaddr("ipaddr"); +#endif #if defined(CONFIG_PCI) /* -- 1.6.6