[dpdk-dev,v10,1/4] Remove ABI requirement for external library builds.

Message ID 1449496140-11758-2-git-send-email-remy.horton@intel.com (mailing list archive)
State Accepted, archived
Headers

Commit Message

Remy Horton Dec. 7, 2015, 1:48 p.m. UTC
  Signed-off-by: Andrew G. Harvey <agh@cisco.com>
---
 mk/rte.extlib.mk | 2 ++
 mk/rte.lib.mk    | 6 ++++++
 2 files changed, 8 insertions(+)
  

Patch

diff --git a/mk/rte.extlib.mk b/mk/rte.extlib.mk
index ba066bc..4d459e4 100644
--- a/mk/rte.extlib.mk
+++ b/mk/rte.extlib.mk
@@ -31,6 +31,8 @@ 
 
 MAKEFLAGS += --no-print-directory
 
+EXTLIB_BUILD := 1
+
 # we must create the output dir first and recall the same Makefile
 # from this directory
 ifeq ($(NOT_FIRST_CALL),)
diff --git a/mk/rte.lib.mk b/mk/rte.lib.mk
index 1f1b6e1..02734e3 100644
--- a/mk/rte.lib.mk
+++ b/mk/rte.lib.mk
@@ -40,11 +40,13 @@  VPATH += $(SRCDIR)
 
 ifeq ($(CONFIG_RTE_BUILD_SHARED_LIB),y)
 LIB := $(patsubst %.a,%.so.$(LIBABIVER),$(LIB))
+ifndef EXTLIB_BUILD
 ifeq ($(CONFIG_RTE_NEXT_ABI),y)
 LIB := $(LIB).1
 endif
 CPU_LDFLAGS += --version-script=$(SRCDIR)/$(EXPORT_MAP)
 endif
+endif
 
 
 _BUILD = $(LIB)
@@ -175,12 +177,16 @@  $(RTE_OUTPUT)/lib/$(LIB): $(LIB)
 	@[ -d $(RTE_OUTPUT)/lib ] || mkdir -p $(RTE_OUTPUT)/lib
 	$(Q)cp -f $(LIB) $(RTE_OUTPUT)/lib
 ifeq ($(CONFIG_RTE_BUILD_SHARED_LIB),y)
+ifdef EXTLIB_BUILD
+	$(Q)ln -s -f $< $(basename $@)
+else
 ifeq ($(CONFIG_RTE_NEXT_ABI),y)
 	$(Q)ln -s -f $< $(basename $(basename $@))
 else
 	$(Q)ln -s -f $< $(basename $@)
 endif
 endif
+endif
 
 #
 # Clean all generated files