File ovmf.BUILD_CFLAGS.patch of Package qemu

From: Olaf Hering <olaf@aepfle.de>
Date: Fri, 7 Apr 2023 22:20:47 +0000
Subject: BUILD_CFLAGS

Signed-off-by: Olaf Hering <olaf@aepfle.de>
---
 BaseTools/Source/C/Makefiles/header.makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/BaseTools/Source/C/Makefiles/header.makefile
+++ b/BaseTools/Source/C/Makefiles/header.makefile
@@ -95,25 +95,25 @@ ifeq ($(DARWIN),Darwin)
 CFLAGS = -MD -fshort-wchar -fno-strict-aliasing -Wall -Werror \
 -Wno-deprecated-declarations -Wno-self-assign -Wno-unused-result -nostdlib -g
 else
 ifneq ($(CLANG),)
 CFLAGS = -MD -fshort-wchar -fno-strict-aliasing -fwrapv \
 -fno-delete-null-pointer-checks -Wall -Werror \
 -Wno-deprecated-declarations -Wno-self-assign \
 -Wno-unused-result -nostdlib -g
 else
 CFLAGS = -MD -fshort-wchar -fno-strict-aliasing -fwrapv \
 -fno-delete-null-pointer-checks -Wall -Werror \
 -Wno-deprecated-declarations -Wno-stringop-truncation -Wno-restrict \
--Wno-unused-result -nostdlib -g
+-Wno-unused-result -nostdlib -g -fPIE
 endif
 endif
 ifneq ($(CLANG),)
 LDFLAGS =
 CXXFLAGS = -Wno-deprecated-register -Wno-unused-result -std=c++14
 else
 LDFLAGS =
 CXXFLAGS = -Wno-unused-result
 endif
 ifeq ($(HOST_ARCH), IA32)
 #
 # Snow Leopard  is a 32-bit and 64-bit environment. uname -m returns i386, but gcc defaults
openSUSE Build Service is sponsored by