# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+CFLAGS += -DALLOW_EXPERIMENTAL_API
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
CFLAGS += $(WERROR_FLAGS)
include $(RTE_SDK)/mk/rte.extapp.mk
+
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
endif
include $(RTE_SDK)/mk/rte.extapp.mk
+
+endif
# all source are stored in SRCS-y
SRCS-y := main.c commands.c parse_obj_list.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
CFLAGS_parse_obj_list.o := -D_GNU_SOURCE
include $(RTE_SDK)/mk/rte.extapp.mk
+
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
EXTRA_CFLAGS += -O3 -Wfatal-errors
include $(RTE_SDK)/mk/rte.extapp.mk
+
+endif
SRCS-y += pipeline_worker_generic.c
SRCS-y += pipeline_worker_tx.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+CFLAGS += -DALLOW_EXPERIMENTAL_API
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
CFLAGS += $(WERROR_FLAGS)
include $(RTE_SDK)/mk/rte.extapp.mk
+
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
CFLAGS += $(WERROR_FLAGS)
include $(RTE_SDK)/mk/rte.extapp.mk
+
+endif
# all source are stored in SRCS-y
SRCS-y := flow_classify.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+CFLAGS += -DALLOW_EXPERIMENTAL_API
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
endif
include $(RTE_SDK)/mk/rte.extapp.mk
+
+endif
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
CFLAGS += $(WERROR_FLAGS)
include $(RTE_SDK)/mk/rte.extapp.mk
+
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
CFLAGS += $(WERROR_FLAGS)
include $(RTE_SDK)/mk/rte.extapp.mk
+
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
endif
include $(RTE_SDK)/mk/rte.extapp.mk
+
+endif
# binary name
APP = ip_pipeline
-VPATH += $(SRCDIR)/pipeline
-
# all source are stored in SRCS-y
SRCS-y := main.c
SRCS-y += config_parse.c
SRCS-y += pipeline_routing_be.c
SRCS-y += pipeline_routing.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+VPATH += pipeline
+CFLAGS += -I. -I./pipeline/
+
+OBJS := $(patsubst %.c,build/%.o,$(SRCS-y))
+
+build/%.o: %.c Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) -c $< -o $@
+
+build/$(APP): $(OBJS)
+ $(CC) $(OBJS) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP) build/*.o
+ rmdir --ignore-fail-on-non-empty build
+
+else
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
+VPATH += $(SRCDIR)/pipeline
+
# Default target, can be overridden by command line or environment
RTE_TARGET ?= x86_64-native-linuxapp-gcc
CFLAGS += $(WERROR_FLAGS) -Wno-error=unused-function -Wno-error=unused-variable
include $(RTE_SDK)/mk/rte.extapp.mk
+
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
endif
include $(RTE_SDK)/mk/rte.extapp.mk
+
+endif
SRCS-y += rt.c
SRCS-y += ipsec-secgw.c
+CFLAGS += -gdwarf-2
+
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+CFLAGS += -DALLOW_EXPERIMENTAL_API
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
endif
include $(RTE_SDK)/mk/rte.extapp.mk
+
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
endif
include $(RTE_SDK)/mk/rte.extapp.mk
+
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
CFLAGS += $(WERROR_FLAGS)
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := l2fwd-cat.c cat.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+CFLAGS += -D_GNU_SOURCE
+LDFLAGS += -lpqos
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
LDLIBS += -lpqos
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
CFLAGS += $(WERROR_FLAGS)
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
CFLAGS += $(WERROR_FLAGS)
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := main.c shm.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+LDFLAGS += -lrt
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
LDFLAGS += -lrt
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
CFLAGS += $(WERROR_FLAGS)
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
endif
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
include $(RTE_SDK)/mk/rte.extapp.mk
endif
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
endif
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := main.c l3fwd_lpm.c l3fwd_em.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
CFLAGS += $(WERROR_FLAGS)
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
CFLAGS += $(WERROR_FLAGS)
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := main.c config.c init.c runtime.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
endif
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
CFLAGS += $(WERROR_FLAGS)
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := ptpclient.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
endif
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := main.c rte_policer.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
endif
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := main.c args.c init.c app_thread.c cfg_file.c cmdline.c stats.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
include $(RTE_SDK)/mk/rte.extapp.mk
endif
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
EXTRA_CFLAGS += -O3 -g -Wfatal-errors
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+CFLAGS += -DALLOW_EXPERIMENTAL_API
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
endif
include $(RTE_SDK)/mk/rte.extapp.mk
+
+endif
# all source are stored in SRCS-y
SRCS-y := basicfwd.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
EXTRA_CFLAGS += -O3 -g -Wfatal-errors
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := main.c vxlan_setup.c vxlan.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
CFLAGS += -D_GNU_SOURCE
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
endif
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := main.c virtio_net.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
include $(RTE_SDK)/mk/rte.extapp.mk
endif
+endif
# all source are stored in SRCS-y
SRCS-y := scsi.c vhost_scsi.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+CFLAGS += -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
all:
else
-CFLAGS += -O2 -D_FILE_OFFSET_BITS=64
+CFLAGS += -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64
+CFLAGS += -O2
CFLAGS += $(WERROR_FLAGS)
-CFLAGS += -D_GNU_SOURCE
include $(RTE_SDK)/mk/rte.extapp.mk
endif
+endif
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2010-2014 Intel Corporation
-# binary name
-APP = vm_power_mgr
-
-# all source are stored in SRCS-y
-SRCS-y := main.c vm_power_cli.c power_manager.c channel_manager.c
-SRCS-y += channel_monitor.c
-
ifneq ($(shell pkg-config --atleast-version=0.9.3 libvirt; echo $$?), 0)
$(error vm_power_manager requires libvirt >= 0.9.3)
else
include $(RTE_SDK)/mk/rte.vars.mk
+# binary name
+APP = vm_power_mgr
+
+# all source are stored in SRCS-y
+SRCS-y := main.c vm_power_cli.c power_manager.c channel_manager.c
+SRCS-y += channel_monitor.c
+
CFLAGS += -O3 -I$(RTE_SDK)/lib/librte_power/
CFLAGS += $(WERROR_FLAGS)
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
EXTRA_CFLAGS += -O3
include $(RTE_SDK)/mk/rte.extapp.mk
+endif
# all source are stored in SRCS-y
SRCS-y := main.c
+# Build using pkg-config variables if possible
+$(shell pkg-config --exists libdpdk)
+ifeq ($(.SHELLSTATUS),0)
+
+PC_FILE := $(shell pkg-config --path libdpdk)
+CFLAGS += $(shell pkg-config --cflags libdpdk)
+LDFLAGS += $(shell pkg-config --libs libdpdk)
+
+build/$(APP): $(SRCS-y) Makefile $(PC_FILE) | build
+ $(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS)
+
+build:
+ @mkdir -p $@
+
+.PHONY: clean
+clean:
+ rm -f build/$(APP)
+ rmdir --ignore-fail-on-non-empty build
+
+else # Build using legacy build system
+
ifeq ($(RTE_SDK),)
$(error "Please define RTE_SDK environment variable")
endif
EXTRA_CFLAGS += -O3 -g
include $(RTE_SDK)/mk/rte.extapp.mk
+endif