On 01.04.2025 15:26, Roger Pau Monné wrote: > nxcompat should be enabled by default I think? I can of course make > it explicit by adding to the PE link command line.
--nxcompat wasn't the default originally, then was made the default for MinGW (and by mistake for everything else as well), then it being the default was undone for Cygwin. I've meanwhile submitted a patch to undo it for everything that isn't MinGW [1]. I simply don't think the linker is in the position to declare that every binary is NX-compatible. It's the programmers who have to determine that. With the flag not being honored everywhere one also can't simply test an EFI binary on a couple of hosts, at least as long as the EFI implementation there is a black box. So yes, we will need to pass --nxcompat explicitly in any event. Jan [1] https://sourceware.org/pipermail/binutils/2025-April/140422.html