dev.dpdk.org archive mirror
 help / color / mirror / Atom feed
From: Thomas Monjalon <thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>
To: dev-VfR2kkLFssw@public.gmane.org
Subject: [PATCH 2/3] mk: forbid multiple definitions
Date: Wed, 17 Dec 2014 22:59:17 +0100	[thread overview]
Message-ID: <1418853558-2445-3-git-send-email-thomas.monjalon@6wind.com> (raw)
In-Reply-To: <1418853558-2445-1-git-send-email-thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>

The option "-z muldefs" was set only if not using ld directly.
By the way, this option seems to be a useless hack introduced
with shared and combined libraries support (e25e4d7ef16b8aa84de).
The clean approach is to remove it.

Signed-off-by: Thomas Monjalon <thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>
---
 mk/rte.lib.mk      | 5 ++---
 mk/rte.sharelib.mk | 3 +--
 2 files changed, 3 insertions(+), 5 deletions(-)

diff --git a/mk/rte.lib.mk b/mk/rte.lib.mk
index d83e808..a67c129 100644
--- a/mk/rte.lib.mk
+++ b/mk/rte.lib.mk
@@ -62,7 +62,6 @@ exe2cmd = $(strip $(call dotfile,$(patsubst %,%.cmd,$(1))))
 ifeq ($(LINK_USING_CC),1)
 # Override the definition of LD here, since we're linking with CC
 LD := $(CC) $(CPU_CFLAGS)
-LD_MULDEFS := $(call linkerprefix,-z$(comma)muldefs)
 CPU_LDFLAGS := $(call linkerprefix,$(CPU_LDFLAGS))
 endif
 
@@ -75,7 +74,7 @@ O_TO_A_DO = @set -e; \
 	$(O_TO_A) && \
 	echo $(O_TO_A_CMD) > $(call exe2cmd,$(@))
 
-O_TO_S = $(LD) $(CPU_LDFLAGS) $(LD_MULDEFS) -shared $(OBJS-y) -o $(LIB)
+O_TO_S = $(LD) $(CPU_LDFLAGS) -shared $(OBJS-y) -o $(LIB)
 O_TO_S_STR = $(subst ','\'',$(O_TO_S)) #'# fix syntax highlight
 O_TO_S_DISP = $(if $(V),"$(O_TO_S_STR)","  LD $(@)")
 O_TO_S_DO = @set -e; \
@@ -91,7 +90,7 @@ O_TO_C_DO = @set -e; \
 	$(lib_dir) \
 	$(copy_obj)
 else
-O_TO_C = $(LD) $(LD_MULDEFS) -shared $(OBJS-y) -o $(LIB_ONE)
+O_TO_C = $(LD) -shared $(OBJS-y) -o $(LIB_ONE)
 O_TO_C_STR = $(subst ','\'',$(O_TO_C)) #'# fix syntax highlight
 O_TO_C_DISP = $(if $(V),"$(O_TO_C_STR)","  LD_C $(@)")
 O_TO_C_DO = @set -e; \
diff --git a/mk/rte.sharelib.mk b/mk/rte.sharelib.mk
index d0ec12a..d0cc7e3 100644
--- a/mk/rte.sharelib.mk
+++ b/mk/rte.sharelib.mk
@@ -50,11 +50,10 @@ OBJS = $(wildcard $(RTE_OUTPUT)/build/lib/*.o)
 ifeq ($(LINK_USING_CC),1)
 # Override the definition of LD here, since we're linking with CC
 LD := $(CC) $(CPU_CFLAGS)
-LD_MULDEFS := $(call linkerprefix,-z$(comma)muldefs)
 CPU_LDFLAGS := $(call linkerprefix,$(CPU_LDFLAGS))
 endif
 
-O_TO_S = $(LD) $(CPU_LDFLAGS) $(LD_MULDEFS) -shared $(OBJS) \
+O_TO_S = $(LD) $(CPU_LDFLAGS) -shared $(OBJS) \
 	-o $(RTE_OUTPUT)/lib/$(LIB_ONE)
 O_TO_S_STR = $(subst ','\'',$(O_TO_S)) #'# fix syntax highlight
 O_TO_S_DISP = $(if $(V),"$(O_TO_S_STR)","  LD $(@)")
-- 
2.1.3

  parent reply	other threads:[~2014-12-17 21:59 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-23 15:35 [PATCH] mk: link combined lib using CC Sergio Gonzalez Monroy
     [not found] ` <1414078550-692-1-git-send-email-sergio.gonzalez.monroy-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2014-10-28 11:45   ` De Lara Guarch, Pablo
     [not found]     ` <E115CCD9D858EF4F90C690B0DCB4D89722637456-kPTMFJFq+rEMvF1YICWikbfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2014-10-28 14:51       ` Sergio Gonzalez Monroy
     [not found]         ` <20141028145123.GA24266-IWE99D/oH1/+pXziaqXtF9h3ngVCH38I@public.gmane.org>
2014-10-28 15:33           ` Thomas Monjalon
2014-10-28 15:39             ` Sergio Gonzalez Monroy
2014-10-28 15:48   ` [PATCH v2] mk: link combined shared " Sergio Gonzalez Monroy
     [not found]     ` <1414511329-3948-1-git-send-email-sergio.gonzalez.monroy-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2014-10-28 16:09       ` De Lara Guarch, Pablo
2014-12-16 18:48       ` Thomas Monjalon
2014-12-16 23:42         ` Thomas Monjalon
2014-12-17 10:41           ` Gonzalez Monroy, Sergio
     [not found]             ` <91383E96CE459D47BCE92EFBF5CE73B004F0B593-kPTMFJFq+rFwl47ZQwxUxrfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2014-12-17 14:01               ` Thomas Monjalon
2014-12-17 18:49                 ` Thomas Monjalon
2014-12-17 21:59                   ` [PATCH 0/3] mk: fix link options Thomas Monjalon
     [not found]                     ` <1418853558-2445-1-git-send-email-thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>
2014-12-17 21:59                       ` [PATCH 1/3] mk: fix link examples to combined library Thomas Monjalon
2014-12-17 21:59                       ` Thomas Monjalon [this message]
2014-12-17 21:59                       ` [PATCH 3/3] mk: fix link with CC Thomas Monjalon
2014-12-17 23:35                       ` [PATCH 0/3] mk: fix link options Thomas Monjalon

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1418853558-2445-3-git-send-email-thomas.monjalon@6wind.com \
    --to=thomas.monjalon-pdr9zngts4eavxtiumwx3w@public.gmane.org \
    --cc=dev-VfR2kkLFssw@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).