On macOS, /usr/bin/gcc is clang, and so doesn't have
the -Wno-error=stringop-overflow flag that was added
for gcc 12.
Update the GNUmakefile for DevicePath to skip setting
that on macOS.

Signed-off-by: Rebecca Cran <rebe...@bsdio.com>
---
 BaseTools/Source/C/DevicePath/GNUmakefile | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/BaseTools/Source/C/DevicePath/GNUmakefile 
b/BaseTools/Source/C/DevicePath/GNUmakefile
index c217674345b1..17f213879e82 100644
--- a/BaseTools/Source/C/DevicePath/GNUmakefile
+++ b/BaseTools/Source/C/DevicePath/GNUmakefile
@@ -16,10 +16,12 @@ include $(MAKEROOT)/Makefiles/app.makefile
 GCCVERSION = $(shell gcc -dumpversion | awk -F'.' '{print $$1}')
 ifneq ("$(GCCVERSION)", "5")
 ifneq ($(CXX), llvm)
+ifneq ($(DARWIN),Darwin)
 # gcc 12 trips over device path handling
 BUILD_CFLAGS += -Wno-error=stringop-overflow
 endif
 endif
+endif
 
 LIBS = -lCommon
 ifeq ($(CYGWIN), CYGWIN)
-- 
2.30.1 (Apple Git-130)



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#92827): https://edk2.groups.io/g/devel/message/92827
Mute This Topic: https://groups.io/mt/93261668/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Reply via email to