Commit 5f24a23c authored by paul luse's avatar paul luse Committed by Ben Walker
Browse files

dpdkbuild: stop building ipsec library with make



In early development of crypto we built the lirbary using
dpdkbuild/Makefile but later due to a DPDK change we needed
to move to a newer version of the ipsec library that is now
built and installed in pkgdep.sh btu we never removed it
from the makefile.

This patch removes the extra building of the ipsec module.

Change-Id: I367618440074d952ff13c6e2098fc3a572cc785e
Signed-off-by: default avatarpaul luse <paul.e.luse@intel.com>
Reviewed-on: https://review.gerrithub.io/429519


Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: default avatarDarek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: default avatarJim Harris <james.r.harris@intel.com>
Reviewed-by: default avatarBen Walker <benjamin.walker@intel.com>
parent ae45b7ec
Loading
Loading
Loading
Loading
+3 −17
Original line number Diff line number Diff line
@@ -42,9 +42,6 @@ CRYPTO_ENABLED=n

ifeq ($(CONFIG_CRYPTO),y)
ifeq ($(TARGET_MACHINE),x86_64)
ifneq ($(wildcard $(SPDK_ROOT_DIR)/intel-ipsec-mb/README),)
INTEL_IPSEC_MB_LIB=$(SPDK_ROOT_DIR)/intel-ipsec-mb/libIPSec_MB.a
IPSEC_MB_CFLAGS = -fPIC
CRYPTO_ENABLED = y
DPDK_OPTS += CONFIG_RTE_LIBRTE_PMD_AESNI_MB=y
DPDK_OPTS += CONFIG_RTE_LIBRTE_CRYPTODEV=y
@@ -58,7 +55,6 @@ DPDK_OPTS += CONFIG_RTE_EAL_IGB_UIO=n
endif
endif
endif
endif

ifeq ($(CRYPTO_ENABLED),n)
DPDK_OPTS += CONFIG_RTE_EAL_IGB_UIO=n
@@ -87,17 +83,14 @@ endif

ifeq ($(CC_TYPE),clang)
DPDK_CONFIG := $(DPDK_CONFIG)-clang
IPSEC_CC := clang
else
DPDK_CONFIG := $(DPDK_CONFIG)-gcc
IPSEC_CC := gcc
endif

DPDK_CFLAGS = -fPIC

ifeq ($(CONFIG_DEBUG),y)
DPDK_CFLAGS += -O0 -g
IPSEC_OPTS += DEBUG=y
endif

ifeq ($(CONFIG_WERROR),y)
@@ -114,20 +107,13 @@ endif
# Allow users to specify EXTRA_DPDK_CFLAGS if they want to build DPDK using unsupported compiler versions
DPDK_CFLAGS += $(EXTRA_DPDK_CFLAGS)

$(SPDK_ROOT_DIR)/dpdk/build: $(INTEL_IPSEC_MB_LIB)
$(SPDK_ROOT_DIR)/dpdk/build:
	$(Q)$(MAKE) -C $(SPDK_ROOT_DIR)/dpdk config T=$(DPDK_CONFIG) $(DPDK_OPTS)

all: $(SPDK_ROOT_DIR)/dpdk/build $(INTEL_IPSEC_MB_LIB)
all: $(SPDK_ROOT_DIR)/dpdk/build
	$(Q)$(MAKE) -C $(SPDK_ROOT_DIR)/dpdk/build EXTRA_CFLAGS="$(DPDK_CFLAGS)" MAKEFLAGS="T=$(DPDK_CONFIG) -j$(NPROC)" $(DPDK_OPTS)

ifeq ($(CONFIG_CRYPTO),y)
$(SPDK_ROOT_DIR)/intel-ipsec-mb/libIPSec_MB.a:
	$(Q)$(MAKE) -C $(SPDK_ROOT_DIR)/intel-ipsec-mb EXTRA_CFLAGS="$(IPSEC_MB_CFLAGS)" $(IPSEC_OPTS) MAKEFLAGS="j$(NPROC)" CC=$(IPSEC_CC)
endif

clean:
	$(Q)rm -rf $(SPDK_ROOT_DIR)/dpdk/build; \
	rm -rf $(SPDK_ROOT_DIR)/intel-ipsec-mb/obj/*; \
	rm -rf $(SPDK_ROOT_DIR)/intel-ipsec-mb/libIPSec_MB.a
	$(Q)rm -rf $(SPDK_ROOT_DIR)/dpdk/build

install: all
+4 −3
Original line number Diff line number Diff line
@@ -87,9 +87,6 @@ DPDK_LIB_LIST += rte_kvargs
endif

DPDK_LIB = $(DPDK_LIB_LIST:%=$(DPDK_ABS_DIR)/lib/lib%$(DPDK_LIB_EXT))
ifeq ($(CONFIG_CRYPTO),y)
DPDK_LIB += $(SPDK_ROOT_DIR)/intel-ipsec-mb/libIPSec_MB.a
endif

# SPDK memory registration requires experimental (deprecated) rte_memory API for DPDK 18.05
ENV_CFLAGS = $(DPDK_INC) -Wno-deprecated-declarations
@@ -98,6 +95,10 @@ ENV_DPDK_FILE = $(call spdk_lib_list_to_static_libs,env_dpdk)
ENV_LIBS = $(ENV_DPDK_FILE) $(DPDK_LIB)
ENV_LINKER_ARGS = $(ENV_DPDK_FILE) -Wl,--whole-archive $(DPDK_LIB) -Wl,--no-whole-archive

ifeq ($(CONFIG_CRYPTO),y)
ENV_LINKER_ARGS += -lIPSec_MB
endif

ifneq (,$(wildcard $(DPDK_INC_DIR)/rte_config.h))
ifneq (,$(shell grep -e "define RTE_LIBRTE_VHOST_NUMA 1" -e "define RTE_EAL_NUMA_AWARE_HUGEPAGES 1" $(DPDK_INC_DIR)/rte_config.h))
ENV_LINKER_ARGS += -lnuma