On 18/03/2025 5:35 pm, Roger Pau Monne wrote: > It's unclear why -N is being used in the first place. It was added by > commit 40828c657dd0c back in 2004 without any justification. > > When building a PE image it's actually detrimental to forcefully set the > .text section as writable. The GNU LD man page contains the following > warning regarding the -N option: > >> Note: Although a writable text section is allowed for PE-COFF targets, it >> does not conform to the format specification published by Microsoft. > Remove the usage of -N uniformly on all architectures, assuming that the > addition was simply done as a copy and paste of the original x86 linking > rune. > > Signed-off-by: Roger Pau Monné <roger....@citrix.com>
-N has been stripped out of other parts of x86 too (hvmloader, notably), and clearly isn't intended to be used in combination with a linker script. Reviewed-by: Andrew Cooper <andrew.coop...@citrix.com>