CFLAGS += -DPROX_MAX_LOG_LVL=$(log)
endif
+# When ipv4 packet is de-encalpusled from ipv6 packet, genaerate IP checksum.
+ifeq ($(GEN_DECAP_IPV6_TO_IPV4_CKSUM),y)
+CFLAGS += -DGEN_DECAP_IPV6_TO_IPV4_CKSUM
+endif
+
# override any use-case/enviroment specific choices regarding crc and
# always use the sw implementation
ifeq ($(crc),soft)
SRCS-y += handle_genl4.c
SRCS-y += handle_ipv6_tunnel.c
SRCS-y += handle_read.c
-SRCS-$(call rte_ver_GE,17,2,0,16) += handle_esp.c
+ifeq ($(call rte_ver_LT,17,8,0,0),y)
+ifeq ($(call rte_ver_GE,17,2,0,16),y)
+SRCS-$(CONFIG_RTE_LIBRTE_PMD_AESNI_MB) += handle_esp.c
+ifneq ($(CONFIG_RTE_LIBRTE_PMD_AESNI_MB),y)
+$(warning "Building w/o IPSEC support")
+endif
+endif
+endif
SRCS-y += handle_cgnat.c
SRCS-y += handle_nat.c
SRCS-y += handle_dump.c