From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: Re: [PATCH] mk: fix app linking for combined libs Date: Mon, 01 Dec 2014 11:35:05 +0100 Message-ID: <1505529.uMfnAuRVUN@xps13> References: <1414078604-1090-1-git-send-email-sergio.gonzalez.monroy@intel.com> <6592533.mQvpkUAhuR@xps13> <91383E96CE459D47BCE92EFBF5CE73B004EF7321@IRSMSX108.ger.corp.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Cc: dev-VfR2kkLFssw@public.gmane.org To: "Gonzalez Monroy, Sergio" Return-path: In-Reply-To: <91383E96CE459D47BCE92EFBF5CE73B004EF7321-kPTMFJFq+rEMvF1YICWikbfspsVTdybXVpNB7YpNyf8@public.gmane.org> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces-VfR2kkLFssw@public.gmane.org Sender: "dev" 2014-12-01 09:57, Gonzalez Monroy, Sergio: > > From: Thomas Monjalon [mailto:thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.org] > > 2014-10-23 16:36, Sergio Gonzalez Monroy: > > > Building combined shared libraries results in applications being > > > linked against separeted/individual and combined libs altogether. > > > > > > Link only against combined lib when the config option is enabled. > > > > > > Signed-off-by: Sergio Gonzalez Monroy > > [...] > > > --- a/mk/rte.app.mk > > > +++ b/mk/rte.app.mk > > > @@ -217,6 +217,12 @@ endif > > > > > > endif # plugins > > > > > > +ifeq ($(RTE_BUILD_COMBINE_LIBS),y) > > > +LDLIBS = --whole-archive > > > > You are resetting LDLIBS here. > > It's not easy to read and probably not desired. > > I think it would be better to explicitly disable separated libs in this case. > > > Yes, I am resetting LDLIBS so we just link against the combined lib instead of all the previous separated libs. > I am not sure I understand what you mean with 'disable separated libs in this case'. By "disable separated libs", I mean enclose the LDLIBS lines for separated libs with ifneq ($(RTE_BUILD_COMBINE_LIBS),y) Using ifeq is more explicit than inserting LDLIBS= in the middle of LDLIBS+= lines. Do you agree? -- Thomas