From mboxrd@z Thu Jan 1 00:00:00 1970 From: =?ISO-8859-1?Q?Andreas_Bie=DFmann?= Date: Wed, 11 Dec 2013 11:05:27 +0100 Subject: [U-Boot] Some M68K boards are depending the specific order of libraries In-Reply-To: <20131211183226.BE5B.AA925319@jp.panasonic.com> References: <20131211183226.BE5B.AA925319@jp.panasonic.com> Message-ID: <52A838E7.2060908@gmail.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Dear Masahiro Yamada, On 12/11/2013 10:32 AM, Masahiro Yamada wrote: > And then, build again > $ make cobra5272 CROSS_COMPILE=m68k-linux- > <> > arch/m68k/cpu/mcf52x2/start.o: In function `_start': > /home/yamada/workspace/u-boot-org/arch/m68k/cpu/mcf52x2/start.S:201:(.text+0x448): relocation truncated to fit: R_68K_PC16 against symbol `cpu_init_f' defined in .text.cpu_init_f section in arch/m68k/cpu/mcf52x2/built-in.o > /home/yamada/workspace/u-boot-org/arch/m68k/cpu/mcf52x2/start.S:202:(.text+0x44c): relocation truncated to fit: R_68K_PC16 against symbol `board_init_f' defined in .text.board_init_f section in arch/m68k/lib/built-in.o > arch/m68k/cpu/mcf52x2/start.o: In function `_exc_handler': > /home/yamada/workspace/u-boot-org/arch/m68k/cpu/mcf52x2/start.S:300:(.text+0x4da): relocation truncated to fit: R_68K_PC16 against symbol `exc_handler' defined in .text.exc_handler section in arch/m68k/lib/built-in.o > arch/m68k/cpu/mcf52x2/start.o: In function `_int_handler': > /home/yamada/workspace/u-boot-org/arch/m68k/cpu/mcf52x2/start.S:308:(.text+0x4fc): relocation truncated to fit: R_68K_PC16 against symbol `int_handler' defined in .text.int_handler section in arch/m68k/lib/built-in.o > make[1]: *** [u-boot] Error 1 > make[1]: Leaving directory `/home/yamada/workspace/u-boot-org' > make: *** [cobra5272] Error 2 > > > > The build will fail with error messages > " relocation truncated to fit: R_68K_PC16 against symbol" > > What is this error? It is a linker error stating that the specific call (for example 'bsr cpu_init_f' @start.S:201) will not work cause (and this is guessing) the PC relative jump with 16 bit offset can not work cause the symbol cpu_init_f is to far away. I had similiar issue in linux kernel for avr32 these days. I found a work around, please read https://lkml.org/lkml/2013/10/24/156 to understand it. Best regards Andreas Bie?mann