blob: 7fbdb637f4d778ab11236f36ed0b5811b8e786e9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
https://mail.gnu.org/archive/html/qemu-devel/2025-02/msg04327.html
From eca5286f01652fd5801ba89b7752a7895620a852 Mon Sep 17 00:00:00 2001
Message-ID: <eca5286f01652fd5801ba89b7752a7895620a852.1740071281.git.sam@gentoo.org>
From: Sam James <sam@gentoo.org>
Date: Thu, 20 Feb 2025 17:05:59 +0000
Subject: [PATCH] optionrom: pass -Wl,--no-error-rwx-segments
If GNU Binutils is configured with --enable-error-rwx-segments=yes, one
gets the following for optionrom:
```
.../bin/ld: error: pvh.img has a LOAD segment with RWX permissions
.../bin/ld: final link faile
```
Pass -Wl,--no-error-rwx-segments to suppress that.
--- a/pc-bios/optionrom/Makefile
+++ b/pc-bios/optionrom/Makefile
@@ -37,6 +37,7 @@ config-cc.mak: Makefile
-include config-cc.mak
override LDFLAGS = -nostdlib -Wl,--build-id=none,-T,$(SRC_DIR)/flat.lds,-m,elf_i386
+override LDFLAGS += -Wl,--no-error-rwx-segments
pvh.img: pvh.o pvh_main.o
base-commit: 40efe733e10cc00e4fb4f9f5790a28e744e63c62
--
2.48.1
|