patches for DPDK stable branches
 help / color / mirror / Atom feed
* [dpdk-stable] [PATCH] devtools: fix example build with old pkg-config
@ 2019-11-15 10:35 Ferruh Yigit
  2019-11-15 10:41 ` Bruce Richardson
       [not found] ` <20191115151700.64354-1-bruce.richardson@intel.com>
  0 siblings, 2 replies; 4+ messages in thread
From: Ferruh Yigit @ 2019-11-15 10:35 UTC (permalink / raw)
  To: Thomas Monjalon; +Cc: dev, stable, Bruce Richardson

The old version of the pkg-config [1] doesn't support '-define-prefix'
and '--path' arguments which is causing failure building the
examples [2].

Added checks for pkg-config arguments support and build examples only
if they are supported.

[1]
CentOS Linux release 7.7.1908 (Core)
pkg-config version 0.27.1

[2]
 ## Building cmdline
Unknown option --define-prefix
gmake: Entering directory
`...ild-x86-default/install-root/usr/local/share/dpdk/examples/cmdline'
rm -f build/cmdline build/cmdline-static build/cmdline-shared
test -d build && rmdir -p build || true
Unknown option --define-prefix
Unknown option --define-prefix
gcc -O3  main.c commands.c parse_obj_list.c -o build/cmdline-shared
main.c:14:28: fatal error: cmdline_rdline.h: No such file or directory
 #include <cmdline_rdline.h>

Fixes: 7f80a2102bbb ("devtools: test pkg-config file")
Cc: stable@dpdk.org

Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
Cc: Bruce Richardson <bruce.richardson@intel.com>
---
 devtools/test-meson-builds.sh | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)

diff --git a/devtools/test-meson-builds.sh b/devtools/test-meson-builds.sh
index 08e83eb5c..09ab3967b 100755
--- a/devtools/test-meson-builds.sh
+++ b/devtools/test-meson-builds.sh
@@ -133,7 +133,10 @@ load_env cc
 pc_file=$(find $DESTDIR -name libdpdk.pc)
 export PKG_CONFIG_PATH=$(dirname $pc_file):$PKG_CONFIG_PATH
 
-for example in cmdline helloworld l2fwd l3fwd skeleton timer; do
-	echo "## Building $example"
-	$MAKE -C $DESTDIR/usr/local/share/dpdk/examples/$example clean all
-done
+# Ckeck pkg-config parameter support for old versions
+if pkg-config --define-prefix --path libdpdk >/dev/null 2>&1; then
+	for example in cmdline helloworld l2fwd l3fwd skeleton timer; do
+		echo "## Building $example"
+		$MAKE -C $DESTDIR/usr/local/share/dpdk/examples/$example clean all
+	done
+fi
-- 
2.21.0


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [dpdk-stable] [PATCH] devtools: fix example build with old pkg-config
  2019-11-15 10:35 [dpdk-stable] [PATCH] devtools: fix example build with old pkg-config Ferruh Yigit
@ 2019-11-15 10:41 ` Bruce Richardson
       [not found] ` <20191115151700.64354-1-bruce.richardson@intel.com>
  1 sibling, 0 replies; 4+ messages in thread
From: Bruce Richardson @ 2019-11-15 10:41 UTC (permalink / raw)
  To: Ferruh Yigit; +Cc: Thomas Monjalon, dev, stable

On Fri, Nov 15, 2019 at 10:35:25AM +0000, Ferruh Yigit wrote:
> The old version of the pkg-config [1] doesn't support '-define-prefix'
> and '--path' arguments which is causing failure building the
> examples [2].
> 

Yes for the define-prefix option, no for the path one.

The define-prefix argument is indeed necessary to have a properly working
pkg-config to get cflags/ldflags in this case, so we need to skip the tests
without it. However, the path parameter is only used to properly track the
dependencies of the build to enable rebuilding if the pkg-config file
itself changes. Therefore, having no output from pkg-config --path won't
cause the build to fail, so it's more an optional flag.

/Bruce

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [dpdk-stable] [PATCH v2 1/2] devtools: fix example builds with older pkg-config
       [not found] ` <20191115151700.64354-1-bruce.richardson@intel.com>
@ 2019-11-15 15:16   ` Bruce Richardson
  2019-11-15 15:17   ` [dpdk-stable] [PATCH v2 2/2] examples: suppress errors for missing pkg-config path flag Bruce Richardson
  1 sibling, 0 replies; 4+ messages in thread
From: Bruce Richardson @ 2019-11-15 15:16 UTC (permalink / raw)
  To: dev; +Cc: ferruh.yigit, Bruce Richardson, stable

Not all versions of pkg-config in distros have support for the
--define-prefix flag [1], causing errors when building examples manually or
with test-meson-builds.sh script [2].

For the former case, we need to remove the hard-coded use of the flag in
the Makefiles.

For the latter case, the flag is necessary for builds to succeed, so we
skip the tests when it's not present, passing it as part of the pkg-config
command if it is supported.

[1]
CentOS Linux release 7.7.1908 (Core)
pkg-config version 0.27.1

[2]
 ## Building cmdline
Unknown option --define-prefix
gmake: Entering directory
`...ild-x86-default/install-root/usr/local/share/dpdk/examples/cmdline'
rm -f build/cmdline build/cmdline-static build/cmdline-shared
test -d build && rmdir -p build || true
Unknown option --define-prefix
Unknown option --define-prefix
gcc -O3  main.c commands.c parse_obj_list.c -o build/cmdline-shared
main.c:14:28: fatal error: cmdline_rdline.h: No such file or directory

Fixes: ca9268529d2b ("examples: support relocated DPDK install")
Fixes: 7f80a2102bbb ("devtools: test pkg-config file")
Cc: stable@dpdk.org

Reported-by: Ferruh Yigit <ferruh.yigit@intel.com>
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
---
 devtools/test-meson-builds.sh           | 12 ++++++++----
 examples/bbdev_app/Makefile             |  2 +-
 examples/bond/Makefile                  |  2 +-
 examples/cmdline/Makefile               |  2 +-
 examples/distributor/Makefile           |  2 +-
 examples/eventdev_pipeline/Makefile     |  2 +-
 examples/fips_validation/Makefile       |  2 +-
 examples/flow_classify/Makefile         |  2 +-
 examples/flow_filtering/Makefile        |  2 +-
 examples/helloworld/Makefile            |  2 +-
 examples/ioat/Makefile                  | 10 ++++++----
 examples/ip_fragmentation/Makefile      |  2 +-
 examples/ip_pipeline/Makefile           |  2 +-
 examples/ip_reassembly/Makefile         |  2 +-
 examples/ipsec-secgw/Makefile           |  2 +-
 examples/ipv4_multicast/Makefile        |  2 +-
 examples/kni/Makefile                   |  2 +-
 examples/l2fwd-cat/Makefile             |  2 +-
 examples/l2fwd-crypto/Makefile          |  2 +-
 examples/l2fwd-event/Makefile           |  2 +-
 examples/l2fwd-jobstats/Makefile        |  2 +-
 examples/l2fwd-keepalive/Makefile       |  2 +-
 examples/l2fwd/Makefile                 |  2 +-
 examples/l3fwd-acl/Makefile             |  2 +-
 examples/l3fwd-power/Makefile           |  2 +-
 examples/l3fwd/Makefile                 |  2 +-
 examples/link_status_interrupt/Makefile |  2 +-
 examples/ntb/Makefile                   | 10 ++++++----
 examples/packet_ordering/Makefile       |  2 +-
 examples/ptpclient/Makefile             |  2 +-
 examples/qos_meter/Makefile             |  2 +-
 examples/qos_sched/Makefile             |  2 +-
 examples/rxtx_callbacks/Makefile        |  2 +-
 examples/service_cores/Makefile         |  2 +-
 examples/skeleton/Makefile              |  2 +-
 examples/tep_termination/Makefile       |  2 +-
 examples/timer/Makefile                 |  2 +-
 examples/vdpa/Makefile                  |  2 +-
 examples/vhost/Makefile                 |  2 +-
 examples/vhost_blk/Makefile             | 10 ++++++----
 examples/vhost_crypto/Makefile          |  2 +-
 examples/vmdq/Makefile                  |  2 +-
 examples/vmdq_dcb/Makefile              |  2 +-
 43 files changed, 65 insertions(+), 55 deletions(-)

diff --git a/devtools/test-meson-builds.sh b/devtools/test-meson-builds.sh
index 08e83eb5c..e3a5a5d51 100755
--- a/devtools/test-meson-builds.sh
+++ b/devtools/test-meson-builds.sh
@@ -133,7 +133,11 @@ load_env cc
 pc_file=$(find $DESTDIR -name libdpdk.pc)
 export PKG_CONFIG_PATH=$(dirname $pc_file):$PKG_CONFIG_PATH
 
-for example in cmdline helloworld l2fwd l3fwd skeleton timer; do
-	echo "## Building $example"
-	$MAKE -C $DESTDIR/usr/local/share/dpdk/examples/$example clean all
-done
+# if pkg-config defines the necessary flags, test building some examples
+if pkg-config --define-prefix libdpdk >/dev/null 2>&1; then
+	export PKGCONF="pkg-config --define-prefix"
+	for example in cmdline helloworld l2fwd l3fwd skeleton timer; do
+		echo "## Building $example"
+		$MAKE -C $DESTDIR/usr/local/share/dpdk/examples/$example clean all
+	done
+fi
diff --git a/examples/bbdev_app/Makefile b/examples/bbdev_app/Makefile
index 715c521a9..033f5aada 100644
--- a/examples/bbdev_app/Makefile
+++ b/examples/bbdev_app/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/bond/Makefile b/examples/bond/Makefile
index 0229b31bb..3f1ae1b6f 100644
--- a/examples/bond/Makefile
+++ b/examples/bond/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 LDFLAGS += -lrte_pmd_bond
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/cmdline/Makefile b/examples/cmdline/Makefile
index c1852080a..f362a2afb 100644
--- a/examples/cmdline/Makefile
+++ b/examples/cmdline/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/distributor/Makefile b/examples/distributor/Makefile
index bac8d5578..ac804da34 100644
--- a/examples/distributor/Makefile
+++ b/examples/distributor/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/eventdev_pipeline/Makefile b/examples/eventdev_pipeline/Makefile
index 205145853..9a6250b85 100644
--- a/examples/eventdev_pipeline/Makefile
+++ b/examples/eventdev_pipeline/Makefile
@@ -19,7 +19,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/fips_validation/Makefile b/examples/fips_validation/Makefile
index 9485daf7a..da5c8f6e7 100644
--- a/examples/fips_validation/Makefile
+++ b/examples/fips_validation/Makefile
@@ -26,7 +26,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/flow_classify/Makefile b/examples/flow_classify/Makefile
index 4c23e5c6d..0b41ac4eb 100644
--- a/examples/flow_classify/Makefile
+++ b/examples/flow_classify/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/flow_filtering/Makefile b/examples/flow_filtering/Makefile
index a63a75555..1d5ab739c 100644
--- a/examples/flow_filtering/Makefile
+++ b/examples/flow_filtering/Makefile
@@ -15,7 +15,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/helloworld/Makefile b/examples/helloworld/Makefile
index 403afa050..267f90b4e 100644
--- a/examples/helloworld/Makefile
+++ b/examples/helloworld/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/ioat/Makefile b/examples/ioat/Makefile
index 2a4d1da2d..ad4c63e31 100644
--- a/examples/ioat/Makefile
+++ b/examples/ioat/Makefile
@@ -17,10 +17,12 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PC_FILE := $(shell pkg-config --path libdpdk)
-CFLAGS += -O3 $(shell pkg-config --cflags libdpdk)
-LDFLAGS_SHARED = $(shell pkg-config --libs libdpdk)
-LDFLAGS_STATIC = -Wl,-Bstatic $(shell pkg-config --static --libs libdpdk)
+PKGCONF ?= pkg-config
+
+PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
+LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
+LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
 
 build/$(APP)-shared: $(SRCS-y) Makefile $(PC_FILE) | build
 	$(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS) $(LDFLAGS_SHARED)
diff --git a/examples/ip_fragmentation/Makefile b/examples/ip_fragmentation/Makefile
index 6af25a02e..1d1396211 100644
--- a/examples/ip_fragmentation/Makefile
+++ b/examples/ip_fragmentation/Makefile
@@ -18,7 +18,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/ip_pipeline/Makefile b/examples/ip_pipeline/Makefile
index cf10d7180..77d37cc40 100644
--- a/examples/ip_pipeline/Makefile
+++ b/examples/ip_pipeline/Makefile
@@ -30,7 +30,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/ip_reassembly/Makefile b/examples/ip_reassembly/Makefile
index 0b1a904e0..3d7fac195 100644
--- a/examples/ip_reassembly/Makefile
+++ b/examples/ip_reassembly/Makefile
@@ -18,7 +18,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/ipsec-secgw/Makefile b/examples/ipsec-secgw/Makefile
index 851123be5..1c2b944d6 100644
--- a/examples/ipsec-secgw/Makefile
+++ b/examples/ipsec-secgw/Makefile
@@ -28,7 +28,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/ipv4_multicast/Makefile b/examples/ipv4_multicast/Makefile
index 5f8a67dd4..5f9d73881 100644
--- a/examples/ipv4_multicast/Makefile
+++ b/examples/ipv4_multicast/Makefile
@@ -18,7 +18,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/kni/Makefile b/examples/kni/Makefile
index 5dc8118e3..fbe0097cf 100644
--- a/examples/kni/Makefile
+++ b/examples/kni/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/l2fwd-cat/Makefile b/examples/l2fwd-cat/Makefile
index c1960d6d3..86e56a1e7 100644
--- a/examples/l2fwd-cat/Makefile
+++ b/examples/l2fwd-cat/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/l2fwd-crypto/Makefile b/examples/l2fwd-crypto/Makefile
index 29fd530b4..ecfbab1f5 100644
--- a/examples/l2fwd-crypto/Makefile
+++ b/examples/l2fwd-crypto/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/l2fwd-event/Makefile b/examples/l2fwd-event/Makefile
index 6f4176882..04e6796a6 100644
--- a/examples/l2fwd-event/Makefile
+++ b/examples/l2fwd-event/Makefile
@@ -23,7 +23,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/l2fwd-jobstats/Makefile b/examples/l2fwd-jobstats/Makefile
index 729a39e93..0882c2697 100644
--- a/examples/l2fwd-jobstats/Makefile
+++ b/examples/l2fwd-jobstats/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/l2fwd-keepalive/Makefile b/examples/l2fwd-keepalive/Makefile
index 37de27a6f..68e467426 100644
--- a/examples/l2fwd-keepalive/Makefile
+++ b/examples/l2fwd-keepalive/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 LDFLAGS += -pthread -lrt
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/l2fwd/Makefile b/examples/l2fwd/Makefile
index 9c506844e..97af55a50 100644
--- a/examples/l2fwd/Makefile
+++ b/examples/l2fwd/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/l3fwd-acl/Makefile b/examples/l3fwd-acl/Makefile
index e2c989f71..7fcf1e7a6 100644
--- a/examples/l3fwd-acl/Makefile
+++ b/examples/l3fwd-acl/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/l3fwd-power/Makefile b/examples/l3fwd-power/Makefile
index 98248f462..de5d15cb7 100644
--- a/examples/l3fwd-power/Makefile
+++ b/examples/l3fwd-power/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/l3fwd/Makefile b/examples/l3fwd/Makefile
index c55f5c288..042eae92b 100644
--- a/examples/l3fwd/Makefile
+++ b/examples/l3fwd/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/link_status_interrupt/Makefile b/examples/link_status_interrupt/Makefile
index 97e5a14a8..3d55aa1ac 100644
--- a/examples/link_status_interrupt/Makefile
+++ b/examples/link_status_interrupt/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/ntb/Makefile b/examples/ntb/Makefile
index 5ddd9b95f..7927f44ac 100644
--- a/examples/ntb/Makefile
+++ b/examples/ntb/Makefile
@@ -18,13 +18,15 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
+PKGCONF ?= pkg-config
+
 CFLAGS += -D_FILE_OFFSET_BITS=64
 LDFLAGS += -pthread
 
-PC_FILE := $(shell pkg-config --path libdpdk)
-CFLAGS += -O3 $(shell pkg-config --cflags libdpdk)
-LDFLAGS_SHARED = $(shell pkg-config --libs libdpdk)
-LDFLAGS_STATIC = -Wl,-Bstatic $(shell pkg-config --static --libs libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
+LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
+LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
 
 build/$(APP)-shared: $(SRCS-y) Makefile $(PC_FILE) | build
 	$(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS) $(LDFLAGS_SHARED)
diff --git a/examples/packet_ordering/Makefile b/examples/packet_ordering/Makefile
index 51acaf7eb..b04a39399 100644
--- a/examples/packet_ordering/Makefile
+++ b/examples/packet_ordering/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/ptpclient/Makefile b/examples/ptpclient/Makefile
index 89e2bacbd..0f8390b68 100644
--- a/examples/ptpclient/Makefile
+++ b/examples/ptpclient/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/qos_meter/Makefile b/examples/qos_meter/Makefile
index e5217cf7c..4a9b628b8 100644
--- a/examples/qos_meter/Makefile
+++ b/examples/qos_meter/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/qos_sched/Makefile b/examples/qos_sched/Makefile
index ce2d25371..5737ad652 100644
--- a/examples/qos_sched/Makefile
+++ b/examples/qos_sched/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/rxtx_callbacks/Makefile b/examples/rxtx_callbacks/Makefile
index edd5b52cd..0f126692a 100644
--- a/examples/rxtx_callbacks/Makefile
+++ b/examples/rxtx_callbacks/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/service_cores/Makefile b/examples/service_cores/Makefile
index abbb7aed2..6fecedc54 100644
--- a/examples/service_cores/Makefile
+++ b/examples/service_cores/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/skeleton/Makefile b/examples/skeleton/Makefile
index c5ac26029..fdc458c91 100644
--- a/examples/skeleton/Makefile
+++ b/examples/skeleton/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/tep_termination/Makefile b/examples/tep_termination/Makefile
index 31165bd92..57af4e7cc 100644
--- a/examples/tep_termination/Makefile
+++ b/examples/tep_termination/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 LDFLAGS += -pthread
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/timer/Makefile b/examples/timer/Makefile
index a86178355..21f05918c 100644
--- a/examples/timer/Makefile
+++ b/examples/timer/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/vdpa/Makefile b/examples/vdpa/Makefile
index 2ac991a4b..68d088f22 100644
--- a/examples/vdpa/Makefile
+++ b/examples/vdpa/Makefile
@@ -18,7 +18,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/vhost/Makefile b/examples/vhost/Makefile
index f84b7f017..fcb864d0e 100644
--- a/examples/vhost/Makefile
+++ b/examples/vhost/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 LDFLAGS += -pthread
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/vhost_blk/Makefile b/examples/vhost_blk/Makefile
index a10a90071..af2a3f87b 100644
--- a/examples/vhost_blk/Makefile
+++ b/examples/vhost_blk/Makefile
@@ -18,12 +18,14 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
+PKGCONF ?= pkg-config
+
 LDFLAGS += -pthread
 
-PC_FILE := $(shell pkg-config --path libdpdk)
-CFLAGS += -O3 $(shell pkg-config --cflags libdpdk)
-LDFLAGS_SHARED = $(shell pkg-config --libs libdpdk)
-LDFLAGS_STATIC = -Wl,-Bstatic $(shell pkg-config --static --libs libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
+LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
+LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
 
 CFLAGS += -DALLOW_EXPERIMENTAL_API
 
diff --git a/examples/vhost_crypto/Makefile b/examples/vhost_crypto/Makefile
index a9e1c4d3a..43e2e3244 100644
--- a/examples/vhost_crypto/Makefile
+++ b/examples/vhost_crypto/Makefile
@@ -18,7 +18,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/vmdq/Makefile b/examples/vmdq/Makefile
index 1557ee86b..e0f1e4c40 100644
--- a/examples/vmdq/Makefile
+++ b/examples/vmdq/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
diff --git a/examples/vmdq_dcb/Makefile b/examples/vmdq_dcb/Makefile
index 391096cfb..def515872 100644
--- a/examples/vmdq_dcb/Makefile
+++ b/examples/vmdq_dcb/Makefile
@@ -17,7 +17,7 @@ shared: build/$(APP)-shared
 static: build/$(APP)-static
 	ln -sf $(APP)-static build/$(APP)
 
-PKGCONF=pkg-config --define-prefix
+PKGCONF ?= pkg-config
 
 PC_FILE := $(shell $(PKGCONF) --path libdpdk)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
-- 
2.21.0


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [dpdk-stable] [PATCH v2 2/2] examples: suppress errors for missing pkg-config path flag
       [not found] ` <20191115151700.64354-1-bruce.richardson@intel.com>
  2019-11-15 15:16   ` [dpdk-stable] [PATCH v2 1/2] devtools: fix example builds with older pkg-config Bruce Richardson
@ 2019-11-15 15:17   ` Bruce Richardson
  1 sibling, 0 replies; 4+ messages in thread
From: Bruce Richardson @ 2019-11-15 15:17 UTC (permalink / raw)
  To: dev; +Cc: ferruh.yigit, Bruce Richardson, stable

Some versions of pkg-config don't support the --path flag, which is not a
fatal error when building the apps. Without the flag, the makefile just
cannot track the .pc file of DPDK as a dependency of the build. Therefore,
we can ignore the error and suppress it by redirecting to /dev/null the
stderr from that call to pkg-config.

Fixes: 22119c4591a0 ("examples: use pkg-config in makefiles")
Cc: stable@dpdk.org

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
---
 examples/bbdev_app/Makefile             | 2 +-
 examples/bond/Makefile                  | 2 +-
 examples/cmdline/Makefile               | 2 +-
 examples/distributor/Makefile           | 2 +-
 examples/eventdev_pipeline/Makefile     | 2 +-
 examples/fips_validation/Makefile       | 2 +-
 examples/flow_classify/Makefile         | 2 +-
 examples/flow_filtering/Makefile        | 2 +-
 examples/helloworld/Makefile            | 2 +-
 examples/ioat/Makefile                  | 2 +-
 examples/ip_fragmentation/Makefile      | 2 +-
 examples/ip_pipeline/Makefile           | 2 +-
 examples/ip_reassembly/Makefile         | 2 +-
 examples/ipsec-secgw/Makefile           | 2 +-
 examples/ipv4_multicast/Makefile        | 2 +-
 examples/kni/Makefile                   | 2 +-
 examples/l2fwd-cat/Makefile             | 2 +-
 examples/l2fwd-crypto/Makefile          | 2 +-
 examples/l2fwd-event/Makefile           | 2 +-
 examples/l2fwd-jobstats/Makefile        | 2 +-
 examples/l2fwd-keepalive/Makefile       | 2 +-
 examples/l2fwd/Makefile                 | 2 +-
 examples/l3fwd-acl/Makefile             | 2 +-
 examples/l3fwd-power/Makefile           | 2 +-
 examples/l3fwd/Makefile                 | 2 +-
 examples/link_status_interrupt/Makefile | 2 +-
 examples/ntb/Makefile                   | 2 +-
 examples/packet_ordering/Makefile       | 2 +-
 examples/ptpclient/Makefile             | 2 +-
 examples/qos_meter/Makefile             | 2 +-
 examples/qos_sched/Makefile             | 2 +-
 examples/rxtx_callbacks/Makefile        | 2 +-
 examples/service_cores/Makefile         | 2 +-
 examples/skeleton/Makefile              | 2 +-
 examples/tep_termination/Makefile       | 2 +-
 examples/timer/Makefile                 | 2 +-
 examples/vdpa/Makefile                  | 2 +-
 examples/vhost/Makefile                 | 2 +-
 examples/vhost_blk/Makefile             | 2 +-
 examples/vhost_crypto/Makefile          | 2 +-
 examples/vmdq/Makefile                  | 2 +-
 examples/vmdq_dcb/Makefile              | 2 +-
 42 files changed, 42 insertions(+), 42 deletions(-)

diff --git a/examples/bbdev_app/Makefile b/examples/bbdev_app/Makefile
index 033f5aada..ead3f016b 100644
--- a/examples/bbdev_app/Makefile
+++ b/examples/bbdev_app/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/bond/Makefile b/examples/bond/Makefile
index 3f1ae1b6f..2030ca410 100644
--- a/examples/bond/Makefile
+++ b/examples/bond/Makefile
@@ -21,7 +21,7 @@ LDFLAGS += -lrte_pmd_bond
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/cmdline/Makefile b/examples/cmdline/Makefile
index f362a2afb..0b6b54540 100644
--- a/examples/cmdline/Makefile
+++ b/examples/cmdline/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/distributor/Makefile b/examples/distributor/Makefile
index ac804da34..4192d8a4a 100644
--- a/examples/distributor/Makefile
+++ b/examples/distributor/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/eventdev_pipeline/Makefile b/examples/eventdev_pipeline/Makefile
index 9a6250b85..96cd24437 100644
--- a/examples/eventdev_pipeline/Makefile
+++ b/examples/eventdev_pipeline/Makefile
@@ -21,7 +21,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/fips_validation/Makefile b/examples/fips_validation/Makefile
index da5c8f6e7..1385e8cc8 100644
--- a/examples/fips_validation/Makefile
+++ b/examples/fips_validation/Makefile
@@ -28,7 +28,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/flow_classify/Makefile b/examples/flow_classify/Makefile
index 0b41ac4eb..6864941b3 100644
--- a/examples/flow_classify/Makefile
+++ b/examples/flow_classify/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/flow_filtering/Makefile b/examples/flow_filtering/Makefile
index 1d5ab739c..6c51c0b7a 100644
--- a/examples/flow_filtering/Makefile
+++ b/examples/flow_filtering/Makefile
@@ -17,7 +17,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/helloworld/Makefile b/examples/helloworld/Makefile
index 267f90b4e..16d82b02f 100644
--- a/examples/helloworld/Makefile
+++ b/examples/helloworld/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/ioat/Makefile b/examples/ioat/Makefile
index ad4c63e31..ef63f5d68 100644
--- a/examples/ioat/Makefile
+++ b/examples/ioat/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/ip_fragmentation/Makefile b/examples/ip_fragmentation/Makefile
index 1d1396211..ede0c4f02 100644
--- a/examples/ip_fragmentation/Makefile
+++ b/examples/ip_fragmentation/Makefile
@@ -20,7 +20,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/ip_pipeline/Makefile b/examples/ip_pipeline/Makefile
index 77d37cc40..3a0193818 100644
--- a/examples/ip_pipeline/Makefile
+++ b/examples/ip_pipeline/Makefile
@@ -32,7 +32,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/ip_reassembly/Makefile b/examples/ip_reassembly/Makefile
index 3d7fac195..3f2888b33 100644
--- a/examples/ip_reassembly/Makefile
+++ b/examples/ip_reassembly/Makefile
@@ -20,7 +20,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/ipsec-secgw/Makefile b/examples/ipsec-secgw/Makefile
index 1c2b944d6..a4977f61f 100644
--- a/examples/ipsec-secgw/Makefile
+++ b/examples/ipsec-secgw/Makefile
@@ -30,7 +30,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/ipv4_multicast/Makefile b/examples/ipv4_multicast/Makefile
index 5f9d73881..92d3db0f4 100644
--- a/examples/ipv4_multicast/Makefile
+++ b/examples/ipv4_multicast/Makefile
@@ -20,7 +20,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/kni/Makefile b/examples/kni/Makefile
index fbe0097cf..c7ca96d8a 100644
--- a/examples/kni/Makefile
+++ b/examples/kni/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 CFLAGS += -DALLOW_EXPERIMENTAL_API
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
diff --git a/examples/l2fwd-cat/Makefile b/examples/l2fwd-cat/Makefile
index 86e56a1e7..b0e53c37e 100644
--- a/examples/l2fwd-cat/Makefile
+++ b/examples/l2fwd-cat/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/l2fwd-crypto/Makefile b/examples/l2fwd-crypto/Makefile
index ecfbab1f5..2f1405a72 100644
--- a/examples/l2fwd-crypto/Makefile
+++ b/examples/l2fwd-crypto/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/l2fwd-event/Makefile b/examples/l2fwd-event/Makefile
index 04e6796a6..4cdae36f1 100644
--- a/examples/l2fwd-event/Makefile
+++ b/examples/l2fwd-event/Makefile
@@ -25,7 +25,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/l2fwd-jobstats/Makefile b/examples/l2fwd-jobstats/Makefile
index 0882c2697..73c91faa8 100644
--- a/examples/l2fwd-jobstats/Makefile
+++ b/examples/l2fwd-jobstats/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/l2fwd-keepalive/Makefile b/examples/l2fwd-keepalive/Makefile
index 68e467426..94d1e58bb 100644
--- a/examples/l2fwd-keepalive/Makefile
+++ b/examples/l2fwd-keepalive/Makefile
@@ -21,7 +21,7 @@ LDFLAGS += -pthread -lrt
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/l2fwd/Makefile b/examples/l2fwd/Makefile
index 97af55a50..8b7b26cb9 100644
--- a/examples/l2fwd/Makefile
+++ b/examples/l2fwd/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 # Add flag to allow experimental API as l2fwd uses rte_ethdev_set_ptype API
 CFLAGS += -DALLOW_EXPERIMENTAL_API
diff --git a/examples/l3fwd-acl/Makefile b/examples/l3fwd-acl/Makefile
index 7fcf1e7a6..d9909584b 100644
--- a/examples/l3fwd-acl/Makefile
+++ b/examples/l3fwd-acl/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/l3fwd-power/Makefile b/examples/l3fwd-power/Makefile
index de5d15cb7..729d49639 100644
--- a/examples/l3fwd-power/Makefile
+++ b/examples/l3fwd-power/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/l3fwd/Makefile b/examples/l3fwd/Makefile
index 042eae92b..b2dbf2607 100644
--- a/examples/l3fwd/Makefile
+++ b/examples/l3fwd/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/link_status_interrupt/Makefile b/examples/link_status_interrupt/Makefile
index 3d55aa1ac..4f02a8901 100644
--- a/examples/link_status_interrupt/Makefile
+++ b/examples/link_status_interrupt/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/ntb/Makefile b/examples/ntb/Makefile
index 7927f44ac..baeba11e8 100644
--- a/examples/ntb/Makefile
+++ b/examples/ntb/Makefile
@@ -23,7 +23,7 @@ PKGCONF ?= pkg-config
 CFLAGS += -D_FILE_OFFSET_BITS=64
 LDFLAGS += -pthread
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/packet_ordering/Makefile b/examples/packet_ordering/Makefile
index b04a39399..261b7f06a 100644
--- a/examples/packet_ordering/Makefile
+++ b/examples/packet_ordering/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/ptpclient/Makefile b/examples/ptpclient/Makefile
index 0f8390b68..82d72b3e3 100644
--- a/examples/ptpclient/Makefile
+++ b/examples/ptpclient/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/qos_meter/Makefile b/examples/qos_meter/Makefile
index 4a9b628b8..7c2bf88a9 100644
--- a/examples/qos_meter/Makefile
+++ b/examples/qos_meter/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/qos_sched/Makefile b/examples/qos_sched/Makefile
index 5737ad652..525061ca0 100644
--- a/examples/qos_sched/Makefile
+++ b/examples/qos_sched/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/rxtx_callbacks/Makefile b/examples/rxtx_callbacks/Makefile
index 0f126692a..584b9fafb 100644
--- a/examples/rxtx_callbacks/Makefile
+++ b/examples/rxtx_callbacks/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/service_cores/Makefile b/examples/service_cores/Makefile
index 6fecedc54..c47055813 100644
--- a/examples/service_cores/Makefile
+++ b/examples/service_cores/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/skeleton/Makefile b/examples/skeleton/Makefile
index fdc458c91..2c29004d7 100644
--- a/examples/skeleton/Makefile
+++ b/examples/skeleton/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/tep_termination/Makefile b/examples/tep_termination/Makefile
index 57af4e7cc..645112498 100644
--- a/examples/tep_termination/Makefile
+++ b/examples/tep_termination/Makefile
@@ -21,7 +21,7 @@ LDFLAGS += -pthread
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/timer/Makefile b/examples/timer/Makefile
index 21f05918c..bf86339ab 100644
--- a/examples/timer/Makefile
+++ b/examples/timer/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/vdpa/Makefile b/examples/vdpa/Makefile
index 68d088f22..6a25497cd 100644
--- a/examples/vdpa/Makefile
+++ b/examples/vdpa/Makefile
@@ -20,7 +20,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/vhost/Makefile b/examples/vhost/Makefile
index fcb864d0e..f2b161541 100644
--- a/examples/vhost/Makefile
+++ b/examples/vhost/Makefile
@@ -21,7 +21,7 @@ LDFLAGS += -pthread
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/vhost_blk/Makefile b/examples/vhost_blk/Makefile
index af2a3f87b..39244320d 100644
--- a/examples/vhost_blk/Makefile
+++ b/examples/vhost_blk/Makefile
@@ -22,7 +22,7 @@ PKGCONF ?= pkg-config
 
 LDFLAGS += -pthread
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/vhost_crypto/Makefile b/examples/vhost_crypto/Makefile
index 43e2e3244..ae8cb81f8 100644
--- a/examples/vhost_crypto/Makefile
+++ b/examples/vhost_crypto/Makefile
@@ -20,7 +20,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/vmdq/Makefile b/examples/vmdq/Makefile
index e0f1e4c40..0767c715a 100644
--- a/examples/vmdq/Makefile
+++ b/examples/vmdq/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
diff --git a/examples/vmdq_dcb/Makefile b/examples/vmdq_dcb/Makefile
index def515872..2a9b04143 100644
--- a/examples/vmdq_dcb/Makefile
+++ b/examples/vmdq_dcb/Makefile
@@ -19,7 +19,7 @@ static: build/$(APP)-static
 
 PKGCONF ?= pkg-config
 
-PC_FILE := $(shell $(PKGCONF) --path libdpdk)
+PC_FILE := $(shell $(PKGCONF) --path libdpdk 2>/dev/null)
 CFLAGS += -O3 $(shell $(PKGCONF) --cflags libdpdk)
 LDFLAGS_SHARED = $(shell $(PKGCONF) --libs libdpdk)
 LDFLAGS_STATIC = -Wl,-Bstatic $(shell $(PKGCONF) --static --libs libdpdk)
-- 
2.21.0


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-11-15 15:17 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-15 10:35 [dpdk-stable] [PATCH] devtools: fix example build with old pkg-config Ferruh Yigit
2019-11-15 10:41 ` Bruce Richardson
     [not found] ` <20191115151700.64354-1-bruce.richardson@intel.com>
2019-11-15 15:16   ` [dpdk-stable] [PATCH v2 1/2] devtools: fix example builds with older pkg-config Bruce Richardson
2019-11-15 15:17   ` [dpdk-stable] [PATCH v2 2/2] examples: suppress errors for missing pkg-config path flag Bruce Richardson

patches for DPDK stable branches

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://inbox.dpdk.org/stable/0 stable/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 stable stable/ https://inbox.dpdk.org/stable \
		stable@dpdk.org
	public-inbox-index stable

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://inbox.dpdk.org/inbox.dpdk.stable


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git