1 # SPDX-License-Identifier: BSD-3-Clause
2 # Copyright(c) 2014-2018 Chelsio Communications.
5 include $(RTE_SDK)/mk/rte.vars.mk
10 LIB = librte_pmd_cxgbe.a
13 CFLAGS += $(WERROR_FLAGS)
15 EXPORT_MAP := rte_pmd_cxgbe_version.map
20 # CFLAGS for gcc/clang
22 ifeq ($(CONFIG_RTE_TOOLCHAIN_GCC),y)
23 ifeq ($(shell test $(GCC_VERSION) -ge 44 && echo 1), 1)
24 CFLAGS += -Wno-deprecated
28 LDLIBS += -lrte_eal -lrte_mbuf -lrte_mempool -lrte_ring
29 LDLIBS += -lrte_ethdev -lrte_net -lrte_kvargs
30 LDLIBS += -lrte_bus_pci
33 # Add extra flags for base driver files (also known as shared code)
34 # to disable warnings in them
36 BASE_DRIVER_OBJS=$(sort $(patsubst %.c,%.o,$(notdir $(wildcard $(SRCDIR)/base/*.c))))
37 $(foreach obj, $(BASE_DRIVER_OBJS), $(eval CFLAGS_$(obj)+=$(CFLAGS_BASE_DRIVER)))
39 VPATH += $(SRCDIR)/base
43 # all source are stored in SRCS-y
45 SRCS-$(CONFIG_RTE_LIBRTE_CXGBE_PMD) += cxgbe_ethdev.c
46 SRCS-$(CONFIG_RTE_LIBRTE_CXGBE_PMD) += cxgbevf_ethdev.c
47 SRCS-$(CONFIG_RTE_LIBRTE_CXGBE_PMD) += cxgbe_main.c
48 SRCS-$(CONFIG_RTE_LIBRTE_CXGBE_PMD) += cxgbevf_main.c
49 SRCS-$(CONFIG_RTE_LIBRTE_CXGBE_PMD) += sge.c
50 SRCS-$(CONFIG_RTE_LIBRTE_CXGBE_PMD) += cxgbe_filter.c
51 SRCS-$(CONFIG_RTE_LIBRTE_CXGBE_PMD) += cxgbe_flow.c
52 SRCS-$(CONFIG_RTE_LIBRTE_CXGBE_PMD) += t4_hw.c
53 SRCS-$(CONFIG_RTE_LIBRTE_CXGBE_PMD) += clip_tbl.c
54 SRCS-$(CONFIG_RTE_LIBRTE_CXGBE_PMD) += mps_tcam.c
55 SRCS-$(CONFIG_RTE_LIBRTE_CXGBE_PMD) += l2t.c
56 SRCS-$(CONFIG_RTE_LIBRTE_CXGBE_PMD) += t4vf_hw.c
58 include $(RTE_SDK)/mk/rte.lib.mk