On Mon, Nov 06, 2017 at 07:58:58PM +0100, Ladislav Michl wrote:
> Hi there,
> 
> I just added new platform (at91) to my BSP and configured at91bootstrap
> v3.8.9.
> 
> Problem is that PTXDist-2017.10 produces way too large binary:
> 2099622 at91sam9260ek-dataflashboot-barebox-3.8.9.bin
> while correct size is:
>    2470 at91sam9260ek-dataflashboot-barebox-3.8.9.bin
> 
> Problem turned out to be ld-wrapper script or something it calls.
> Just replacing ld-wrapper in ptxdist-2017.10.0/scripts/wrapper to point
> directly to arm-v5te-linux-gnueabi-ld is enough to solve problem.
> Does anyone clue where to look? Call path is:
> sysroot-host/lib/wrapper in $PATH where
> arm-v5te-linux-gnueabi-ld -> ptxdist-2017.10.0/scripts/wrapper/ld-wrapper

So, ld-wrapper is adding:
--- at91sam9260ek-dataflashboot-barebox-3.8.9.map       2017-11-07 
07:50:28.819011233 +0100
+++ at91sam9260ek-dataflashboot-barebox-3.8.9.map       2017-11-07 
07:47:48.605530524 +0100
@@ -155,6 +155,11 @@
 
                 0x0000000000000000                . = ALIGN (0x4)
 
+.note.gnu.build-id
+                0x0000000000000000       0x24
+ .note.gnu.build-id
+                0x0000000000000000       0x24 linker stubs
+
 .text           0x0000000000200000      0x1a0
                 0x0000000000200000                _stext = .
  *(.text)

Modifying at91bootstrap's Makefile to do --remove-section=.note.gnu.build-id
fixes it.

Are there other options to fix this?

        ladis

_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de

Reply via email to