Blame SOURCES/0063-Work-around-autoconf-existing-in-the-world.patch

4e0e09
From 1b35f9a4b396f21139ab64de0510aa829548682d Mon Sep 17 00:00:00 2001
4e0e09
From: Peter Jones <pjones@redhat.com>
4e0e09
Date: Mon, 13 Jan 2020 16:27:42 -0500
4e0e09
Subject: [PATCH 63/63] Work around autoconf existing in the world.
4e0e09
4e0e09
Long long ago, autoconf added a variable called to pass linker flags to
4e0e09
the compiler.  For some misguided reason, they prefixed it with LD (the
4e0e09
linker) instead of "CC" (the compiler).  Now people unquestioningly
4e0e09
complain if you use that name a more reasonable way, so we're stuck with
4e0e09
names that are counter-descriptive.  You just can't win, the well is too
4e0e09
full of poison.
4e0e09
4e0e09
Resolves github issue #142.
4e0e09
4e0e09
Signed-off-by: Peter Jones <pjones@redhat.com>
4e0e09
---
4e0e09
 src/include/defaults.mk | 16 ++++++++--------
4e0e09
 1 file changed, 8 insertions(+), 8 deletions(-)
4e0e09
4e0e09
diff --git a/src/include/defaults.mk b/src/include/defaults.mk
4e0e09
index 8a784d00be3..781587b4215 100644
4e0e09
--- a/src/include/defaults.mk
4e0e09
+++ b/src/include/defaults.mk
4e0e09
@@ -40,21 +40,21 @@ override CFLAGS = $(_CFLAGS) \
4e0e09
 		  -fvisibility=hidden \
4e0e09
 		  $(call family,CFLAGS) \
4e0e09
 		  $(call pkg-config-cflags)
4e0e09
-LDFLAGS_CLANG ?= --fatal-warnings -pie -z relro
4e0e09
+LDFLAGS_CLANG ?= -Wl,--fatal-warnings,-pie,-z,relro
4e0e09
 LDFLAGS ?=
4e0e09
 override _LDFLAGS := $(LDFLAGS)
4e0e09
 override LDFLAGS = $(_LDFLAGS) \
4e0e09
-		   --add-needed \
4e0e09
-		   --build-id \
4e0e09
-		   --no-allow-shlib-undefined \
4e0e09
-		   --no-undefined-version \
4e0e09
-		   -z now \
4e0e09
-		   -z muldefs \
4e0e09
+		   -Wl,--add-needed \
4e0e09
+		   -Wl,--build-id \
4e0e09
+		   -Wl,--no-allow-shlib-undefined \
4e0e09
+		   -Wl,--no-undefined-version \
4e0e09
+		   -Wl,-z,now \
4e0e09
+		   -Wl,-z,muldefs \
4e0e09
 		   $(call family,LDFLAGS)
4e0e09
 CCLDFLAGS ?=
4e0e09
 override _CCLDFLAGS := $(CCLDFLAGS)
4e0e09
 override CCLDFLAGS = $(CFLAGS) -L. $(_CCLDFLAGS) \
4e0e09
-		     $(call add-prefix,-Wl,$(LDFLAGS)) \
4e0e09
+		     $(LDFLAGS) \
4e0e09
 		     $(call pkg-config-ccldflags)
4e0e09
 HOST_ARCH=$(shell uname -m)
4e0e09
 ifneq ($(HOST_ARCH),ia64)
4e0e09
-- 
4e0e09
2.26.2
4e0e09