From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.tuxdriver.com (charlotte.tuxdriver.com [70.61.120.58]) by dpdk.org (Postfix) with ESMTP id 21BB75A32 for ; Fri, 2 Jan 2015 20:59:08 +0100 (CET) Received: from hmsreliant.think-freely.org ([2001:470:8:a08:7aac:c0ff:fec2:933b] helo=localhost) by smtp.tuxdriver.com with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.63) (envelope-from ) id 1Y78NE-0004YD-BW; Fri, 02 Jan 2015 14:59:06 -0500 From: Neil Horman To: dev@dpdk.org Date: Fri, 2 Jan 2015 14:58:57 -0500 Message-Id: <1420228737-23247-1-git-send-email-nhorman@tuxdriver.com> X-Mailer: git-send-email 1.9.3 X-Spam-Score: -2.9 (--) X-Spam-Status: No Subject: [dpdk-dev] [PATCH] rte.app.mk: whole-archive should be used with COMBINED_LIB X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 02 Jan 2015 19:59:08 -0000 When building static archives with CONFIG_COMBINED_LIBS, we still need to specify --whole-archive to pull in all the proper constructors. Signed-off-by: Neil Horman Reported-by: Lyn M Tested-by: Lyn M CC: Lyn M CC: Thomas Monjalon --- mk/rte.app.mk | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/mk/rte.app.mk b/mk/rte.app.mk index e1a0dbf..40afb2c 100644 --- a/mk/rte.app.mk +++ b/mk/rte.app.mk @@ -61,6 +61,10 @@ ifeq ($(NO_AUTOLIBS),) LDLIBS += --whole-archive +ifeq ($(CONFIG_RTE_BUILD_COMBINE_LIBS),y) +LDLIBS += -l$(RTE_LIBNAME) +endif + ifeq ($(CONFIG_RTE_BUILD_COMBINE_LIBS),n) ifeq ($(CONFIG_RTE_LIBRTE_DISTRIBUTOR),y) @@ -251,10 +255,6 @@ build: _postbuild exe2cmd = $(strip $(call dotfile,$(patsubst %,%.cmd,$(1)))) -ifeq ($(CONFIG_RTE_BUILD_COMBINE_LIBS),y) -LDLIBS += -l$(RTE_LIBNAME) -endif - ifeq ($(LINK_USING_CC),1) override EXTRA_LDFLAGS := $(call linkerprefix,$(EXTRA_LDFLAGS)) O_TO_EXE = $(CC) $(CFLAGS) $(LDFLAGS_$(@)) \ -- 1.9.3