X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=examples%2Fip_pipeline%2FMakefile;h=96f492a5ea97261293292cd3ef2b92de36771e5c;hb=cf38bcd7763fa4cf6347a93a6193e00205404275;hp=d25e39a46406f9ad81a5e5d823436f8cbd46caff;hpb=fda34680eb9abf53872bde66e119f4c0288fd62f;p=dpdk.git diff --git a/examples/ip_pipeline/Makefile b/examples/ip_pipeline/Makefile index d25e39a464..96f492a5ea 100644 --- a/examples/ip_pipeline/Makefile +++ b/examples/ip_pipeline/Makefile @@ -39,7 +39,15 @@ CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk) LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk) LDFLAGS_STATIC = $(shell $(PKGCONF) --static --libs libdpdk) -CFLAGS += -I. +ifeq ($(MAKECMDGOALS),static) +# check for broken pkg-config +ifeq ($(shell echo $(LDFLAGS_STATIC) | grep 'whole-archive.*l:lib.*no-whole-archive'),) +$(warning "pkg-config output list does not contain drivers between 'whole-archive'/'no-whole-archive' flags.") +$(error "Cannot generate statically-linked binaries with this version of pkg-config") +endif +endif + +CFLAGS += -I. -DALLOW_EXPERIMENTAL_API -D_GNU_SOURCE OBJS := $(patsubst %.c,build/%.o,$(SRCS-y))