From mboxrd@z Thu Jan 1 00:00:00 1970 From: Scott Wood Date: Thu, 03 Dec 2009 11:49:26 -0600 Subject: [U-Boot] [PATCH v2] makefiles: fixes for building build tools In-Reply-To: <200912030826.59587.sr@denx.de> References: <20091105004141.GB925@loki.buserror.net> <20091202215903.210004C025@gemini.denx.de> <200912030826.59587.sr@denx.de> Message-ID: <4B17FA26.3060203@freescale.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Stefan Roese wrote: > Hi Scott, > > On Wednesday 02 December 2009 22:59:03 Wolfgang Denk wrote: >>> config.mk | 34 ++++++++++++- >>> rules.mk | 13 ++++- >>> tools/Makefile | 121 >>> +++++++++++++--------------------------------- >>> tools/easylogo/Makefile | 9 ++- >>> tools/gdb/Makefile | 15 ++---- >>> tools/imls/Makefile | 29 ++++------- >>> 6 files changed, 98 insertions(+), 123 deletions(-) >> Applied to "next". Thanks. > > This patch causes some problems, at least on 4xx platforms (others as well I > suspect): > > [stefan at stefan-desktop u-boot (next)]$ ./MAKEALL kilauea > Configuring for kilauea board... > /usr/bin/ld: crc32.o: Relocations in generic ELF (EM: 20) > /usr/bin/ld: crc32.o: Relocations in generic ELF (EM: 20) > /usr/bin/ld: crc32.o: Relocations in generic ELF (EM: 20) > /usr/bin/ld: crc32.o: Relocations in generic ELF (EM: 20) > /usr/bin/ld: crc32.o: Relocations in generic ELF (EM: 20) > /usr/bin/ld: crc32.o: Relocations in generic ELF (EM: 20) > /usr/bin/ld: crc32.o: Relocations in generic ELF (EM: 20) > crc32.o: could not read symbols: File in wrong format > collect2: ld returned 1 exit status > > > This is on "next" with ELDK 4.2. Scott, do you have any ideas what's going > wrong here? I don't see that here -- instead, I get this, with or without this patch: $ CROSS_COMPILE=powerpc-linux- ./MAKEALL kilauea Configuring for kilauea board... powerpc-linux-ld: u-boot: section `.text' can't be allocated in segment 0 powerpc-linux-ld: final link failed: Bad value make: *** [u-boot] Error 1 This is with binutils 2.18. Do I need to upgrade? Git bisect says: 4649913ea5f440d756d150a6fdf2fb2e8ecb75fd is the first bad commit commit 4649913ea5f440d756d150a6fdf2fb2e8ecb75fd Author: Stefan Roese Date: Tue Oct 27 16:11:26 2009 +0100 ppc4xx: Add common ppc4xx linker script This linker script can be used by all PPC4xx platforms. It works for PPC405 and PPC440 platforms. Boards which need a board specific linker script can override this default linker script in board/*/config.mk. Signed-off-by: Stefan Roese Can you post a full boot log of your error? I'm guessing host crc32.o is getting linked into target code or vice versa, though I don't see why that would happen only on 4xx. One should be tools/crc32.o and the other should be lib_generic/crc32.o. -Scott