| 1 | Taken from: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=906414.
|
| 2 |
|
| 3 | Author: Lukas Schwaighofer <[email protected]>
|
| 4 | Description: Strip the .note.gnu.property section for the mbr. This section is
|
| 5 | added since binutils Debian version 2.31.1-2 and causes mbr.bin to grow in
|
| 6 | size beyond what can fit into the master boot record.
|
| 7 | ---
|
| 8 | mbr/i386/mbr.ld | 1 +
|
| 9 | mbr/x86_64/mbr.ld | 1 +
|
| 10 | 2 files changed, 2 insertions(+)
|
| 11 |
|
| 12 | diff --git a/mbr/i386/mbr.ld b/mbr/i386/mbr.ld
|
| 13 | index d14ba80..5368346 100644
|
| 14 | |
| 15 | |
| 16 | @@ -70,4 +70,5 @@ SECTIONS
|
| 17 | .debug_typenames 0 : { *(.debug_typenames) }
|
| 18 | .debug_varnames 0 : { *(.debug_varnames) }
|
| 19 | /DISCARD/ : { *(.note.GNU-stack) }
|
| 20 | + /DISCARD/ : { *(.note.gnu.property) }
|
| 21 | }
|
| 22 | diff --git a/mbr/x86_64/mbr.ld b/mbr/x86_64/mbr.ld
|
| 23 | index ae27d49..b8c0d89 100644
|
| 24 | |
| 25 | |
| 26 | @@ -69,4 +69,5 @@ SECTIONS
|
| 27 | .debug_typenames 0 : { *(.debug_typenames) }
|
| 28 | .debug_varnames 0 : { *(.debug_varnames) }
|
| 29 | /DISCARD/ : { *(.note.GNU-stack) }
|
| 30 | + /DISCARD/ : { *(.note.gnu.property) }
|
| 31 | }
|