* [dpdk-dev] [PATCH 0/2] fix issues with Ubuntu 18.04 compilation
@ 2019-07-03 16:39 Bruce Richardson
2019-07-03 16:40 ` [dpdk-dev] [PATCH 1/2] examples: fix pkg-config detection with older make Bruce Richardson
` (2 more replies)
0 siblings, 3 replies; 7+ messages in thread
From: Bruce Richardson @ 2019-07-03 16:39 UTC (permalink / raw)
To: dev; +Cc: Bruce Richardson
This set has two fixes for the build issues on Ubuntu. The first patch
adds in support for older make v4.1, and the second works around a
problem with pkg-config giving an incorrect prefix in some
circumstances.
Bruce Richardson (2):
examples: fix pkg-config detection with older make
buildtools/test-meson-builds: workaround pkg-config issue
devtools/test-meson-builds.sh | 4 +++-
examples/bbdev_app/Makefile | 3 +--
examples/bond/Makefile | 3 +--
examples/cmdline/Makefile | 3 +--
examples/distributor/Makefile | 3 +--
examples/eventdev_pipeline/Makefile | 3 +--
examples/exception_path/Makefile | 3 +--
examples/fips_validation/Makefile | 3 +--
examples/flow_classify/Makefile | 3 +--
examples/flow_filtering/Makefile | 3 +--
examples/helloworld/Makefile | 3 +--
examples/ip_fragmentation/Makefile | 3 +--
examples/ip_pipeline/Makefile | 3 +--
examples/ip_reassembly/Makefile | 3 +--
examples/ipsec-secgw/Makefile | 3 +--
examples/ipv4_multicast/Makefile | 3 +--
examples/kni/Makefile | 3 +--
examples/l2fwd-cat/Makefile | 3 +--
examples/l2fwd-crypto/Makefile | 3 +--
examples/l2fwd-jobstats/Makefile | 3 +--
examples/l2fwd-keepalive/Makefile | 3 +--
examples/l2fwd/Makefile | 3 +--
examples/l3fwd-acl/Makefile | 3 +--
examples/l3fwd-power/Makefile | 3 +--
examples/l3fwd-vf/Makefile | 3 +--
examples/l3fwd/Makefile | 3 +--
examples/link_status_interrupt/Makefile | 3 +--
examples/load_balancer/Makefile | 3 +--
examples/packet_ordering/Makefile | 3 +--
examples/ptpclient/Makefile | 3 +--
examples/qos_meter/Makefile | 3 +--
examples/qos_sched/Makefile | 3 +--
examples/rxtx_callbacks/Makefile | 3 +--
examples/service_cores/Makefile | 3 +--
examples/skeleton/Makefile | 3 +--
examples/tep_termination/Makefile | 3 +--
examples/timer/Makefile | 3 +--
examples/vdpa/Makefile | 3 +--
examples/vhost/Makefile | 3 +--
examples/vhost_crypto/Makefile | 3 +--
examples/vhost_scsi/Makefile | 3 +--
examples/vmdq/Makefile | 3 +--
examples/vmdq_dcb/Makefile | 3 +--
43 files changed, 45 insertions(+), 85 deletions(-)
--
2.21.0
^ permalink raw reply [flat|nested] 7+ messages in thread
* [dpdk-dev] [PATCH 1/2] examples: fix pkg-config detection with older make
2019-07-03 16:39 [dpdk-dev] [PATCH 0/2] fix issues with Ubuntu 18.04 compilation Bruce Richardson
@ 2019-07-03 16:40 ` Bruce Richardson
2019-07-03 16:40 ` [dpdk-dev] [PATCH 2/2] buildtools/test-meson-builds: workaround pkg-config issue Bruce Richardson
2019-07-03 16:49 ` [dpdk-dev] [PATCH 0/2] fix issues with Ubuntu 18.04 compilation Luca Boccassi
2 siblings, 0 replies; 7+ messages in thread
From: Bruce Richardson @ 2019-07-03 16:40 UTC (permalink / raw)
To: dev; +Cc: Bruce Richardson, stable
Make versions before 4.2 did not have support for the .SHELLSTATUS
variable, so use another method to detect shell success.
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 | 3 +--
examples/bond/Makefile | 3 +--
examples/cmdline/Makefile | 3 +--
examples/distributor/Makefile | 3 +--
examples/eventdev_pipeline/Makefile | 3 +--
examples/exception_path/Makefile | 3 +--
examples/fips_validation/Makefile | 3 +--
examples/flow_classify/Makefile | 3 +--
examples/flow_filtering/Makefile | 3 +--
examples/helloworld/Makefile | 3 +--
examples/ip_fragmentation/Makefile | 3 +--
examples/ip_pipeline/Makefile | 3 +--
examples/ip_reassembly/Makefile | 3 +--
examples/ipsec-secgw/Makefile | 3 +--
examples/ipv4_multicast/Makefile | 3 +--
examples/kni/Makefile | 3 +--
examples/l2fwd-cat/Makefile | 3 +--
examples/l2fwd-crypto/Makefile | 3 +--
examples/l2fwd-jobstats/Makefile | 3 +--
examples/l2fwd-keepalive/Makefile | 3 +--
examples/l2fwd/Makefile | 3 +--
examples/l3fwd-acl/Makefile | 3 +--
examples/l3fwd-power/Makefile | 3 +--
examples/l3fwd-vf/Makefile | 3 +--
examples/l3fwd/Makefile | 3 +--
examples/link_status_interrupt/Makefile | 3 +--
examples/load_balancer/Makefile | 3 +--
examples/packet_ordering/Makefile | 3 +--
examples/ptpclient/Makefile | 3 +--
examples/qos_meter/Makefile | 3 +--
examples/qos_sched/Makefile | 3 +--
examples/rxtx_callbacks/Makefile | 3 +--
examples/service_cores/Makefile | 3 +--
examples/skeleton/Makefile | 3 +--
examples/tep_termination/Makefile | 3 +--
examples/timer/Makefile | 3 +--
examples/vdpa/Makefile | 3 +--
examples/vhost/Makefile | 3 +--
examples/vhost_crypto/Makefile | 3 +--
examples/vhost_scsi/Makefile | 3 +--
examples/vmdq/Makefile | 3 +--
examples/vmdq_dcb/Makefile | 3 +--
42 files changed, 42 insertions(+), 84 deletions(-)
diff --git a/examples/bbdev_app/Makefile b/examples/bbdev_app/Makefile
index 2bf97e415..715c521a9 100644
--- a/examples/bbdev_app/Makefile
+++ b/examples/bbdev_app/Makefile
@@ -8,8 +8,7 @@ APP = bbdev
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/bond/Makefile b/examples/bond/Makefile
index 96868f2fc..0229b31bb 100644
--- a/examples/bond/Makefile
+++ b/examples/bond/Makefile
@@ -8,8 +8,7 @@ APP = bond_app
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/cmdline/Makefile b/examples/cmdline/Makefile
index 9b757316f..c1852080a 100644
--- a/examples/cmdline/Makefile
+++ b/examples/cmdline/Makefile
@@ -8,8 +8,7 @@ APP = cmdline
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)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/distributor/Makefile b/examples/distributor/Makefile
index 6aa5e7a9e..bac8d5578 100644
--- a/examples/distributor/Makefile
+++ b/examples/distributor/Makefile
@@ -8,8 +8,7 @@ APP = distributor_app
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/eventdev_pipeline/Makefile b/examples/eventdev_pipeline/Makefile
index 626d56024..205145853 100644
--- a/examples/eventdev_pipeline/Makefile
+++ b/examples/eventdev_pipeline/Makefile
@@ -10,8 +10,7 @@ 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)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/exception_path/Makefile b/examples/exception_path/Makefile
index dc891b3d1..90c7f133a 100644
--- a/examples/exception_path/Makefile
+++ b/examples/exception_path/Makefile
@@ -8,8 +8,7 @@ APP = exception_path
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/fips_validation/Makefile b/examples/fips_validation/Makefile
index f8cbba592..9485daf7a 100644
--- a/examples/fips_validation/Makefile
+++ b/examples/fips_validation/Makefile
@@ -17,8 +17,7 @@ SRCS-y += fips_dev_self_test.c
SRCS-y += main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/flow_classify/Makefile b/examples/flow_classify/Makefile
index aca7772b4..4c23e5c6d 100644
--- a/examples/flow_classify/Makefile
+++ b/examples/flow_classify/Makefile
@@ -8,8 +8,7 @@ APP = flow_classify
SRCS-y := flow_classify.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/flow_filtering/Makefile b/examples/flow_filtering/Makefile
index a64a10a08..a63a75555 100644
--- a/examples/flow_filtering/Makefile
+++ b/examples/flow_filtering/Makefile
@@ -6,8 +6,7 @@ APP = flow
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/helloworld/Makefile b/examples/helloworld/Makefile
index 2ab294091..403afa050 100644
--- a/examples/helloworld/Makefile
+++ b/examples/helloworld/Makefile
@@ -8,8 +8,7 @@ APP = helloworld
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/ip_fragmentation/Makefile b/examples/ip_fragmentation/Makefile
index 63b66ce25..6af25a02e 100644
--- a/examples/ip_fragmentation/Makefile
+++ b/examples/ip_fragmentation/Makefile
@@ -9,8 +9,7 @@ APP = ip_fragmentation
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/ip_pipeline/Makefile b/examples/ip_pipeline/Makefile
index 1553d705d..cf10d7180 100644
--- a/examples/ip_pipeline/Makefile
+++ b/examples/ip_pipeline/Makefile
@@ -21,8 +21,7 @@ SRCS-y += tmgr.c
SRCS-y += cryptodev.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/ip_reassembly/Makefile b/examples/ip_reassembly/Makefile
index 5af5d63bd..0b1a904e0 100644
--- a/examples/ip_reassembly/Makefile
+++ b/examples/ip_reassembly/Makefile
@@ -9,8 +9,7 @@ APP = ip_reassembly
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/ipsec-secgw/Makefile b/examples/ipsec-secgw/Makefile
index 1bfaf3b9a..851123be5 100644
--- a/examples/ipsec-secgw/Makefile
+++ b/examples/ipsec-secgw/Makefile
@@ -19,8 +19,7 @@ SRCS-y += ipsec-secgw.c
CFLAGS += -gdwarf-2
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/ipv4_multicast/Makefile b/examples/ipv4_multicast/Makefile
index a03bfadbf..5f8a67dd4 100644
--- a/examples/ipv4_multicast/Makefile
+++ b/examples/ipv4_multicast/Makefile
@@ -9,8 +9,7 @@ APP = ipv4_multicast
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/kni/Makefile b/examples/kni/Makefile
index 46f592692..5dc8118e3 100644
--- a/examples/kni/Makefile
+++ b/examples/kni/Makefile
@@ -8,8 +8,7 @@ APP = kni
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/l2fwd-cat/Makefile b/examples/l2fwd-cat/Makefile
index e83d406b0..c1960d6d3 100644
--- a/examples/l2fwd-cat/Makefile
+++ b/examples/l2fwd-cat/Makefile
@@ -8,8 +8,7 @@ APP = l2fwd-cat
SRCS-y := l2fwd-cat.c cat.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/l2fwd-crypto/Makefile b/examples/l2fwd-crypto/Makefile
index 87d311193..29fd530b4 100644
--- a/examples/l2fwd-crypto/Makefile
+++ b/examples/l2fwd-crypto/Makefile
@@ -8,8 +8,7 @@ APP = l2fwd-crypto
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/l2fwd-jobstats/Makefile b/examples/l2fwd-jobstats/Makefile
index d63ece8e3..729a39e93 100644
--- a/examples/l2fwd-jobstats/Makefile
+++ b/examples/l2fwd-jobstats/Makefile
@@ -8,8 +8,7 @@ APP = l2fwd-jobstats
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/l2fwd-keepalive/Makefile b/examples/l2fwd-keepalive/Makefile
index 9b92bc238..37de27a6f 100644
--- a/examples/l2fwd-keepalive/Makefile
+++ b/examples/l2fwd-keepalive/Makefile
@@ -8,8 +8,7 @@ APP = l2fwd-keepalive
SRCS-y := main.c shm.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/l2fwd/Makefile b/examples/l2fwd/Makefile
index fb352e1b7..230352093 100644
--- a/examples/l2fwd/Makefile
+++ b/examples/l2fwd/Makefile
@@ -8,8 +8,7 @@ APP = l2fwd
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/l3fwd-acl/Makefile b/examples/l3fwd-acl/Makefile
index d12d3a987..e2c989f71 100644
--- a/examples/l3fwd-acl/Makefile
+++ b/examples/l3fwd-acl/Makefile
@@ -8,8 +8,7 @@ APP = l3fwd-acl
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/l3fwd-power/Makefile b/examples/l3fwd-power/Makefile
index 359f323dc..98248f462 100644
--- a/examples/l3fwd-power/Makefile
+++ b/examples/l3fwd-power/Makefile
@@ -8,8 +8,7 @@ APP = l3fwd-power
SRCS-y := main.c perf_core.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/l3fwd-vf/Makefile b/examples/l3fwd-vf/Makefile
index 892ecf38b..7b186a23c 100644
--- a/examples/l3fwd-vf/Makefile
+++ b/examples/l3fwd-vf/Makefile
@@ -8,8 +8,7 @@ APP = l3fwd-vf
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/l3fwd/Makefile b/examples/l3fwd/Makefile
index 52976880a..c55f5c288 100644
--- a/examples/l3fwd/Makefile
+++ b/examples/l3fwd/Makefile
@@ -8,8 +8,7 @@ APP = l3fwd
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)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/link_status_interrupt/Makefile b/examples/link_status_interrupt/Makefile
index 77774eda7..97e5a14a8 100644
--- a/examples/link_status_interrupt/Makefile
+++ b/examples/link_status_interrupt/Makefile
@@ -8,8 +8,7 @@ APP = link_status_interrupt
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/load_balancer/Makefile b/examples/load_balancer/Makefile
index 09676a57c..caae8a107 100644
--- a/examples/load_balancer/Makefile
+++ b/examples/load_balancer/Makefile
@@ -8,8 +8,7 @@ APP = load_balancer
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)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/packet_ordering/Makefile b/examples/packet_ordering/Makefile
index eb01b2d5b..51acaf7eb 100644
--- a/examples/packet_ordering/Makefile
+++ b/examples/packet_ordering/Makefile
@@ -8,8 +8,7 @@ APP = packet_ordering
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/ptpclient/Makefile b/examples/ptpclient/Makefile
index 019476a7a..89e2bacbd 100644
--- a/examples/ptpclient/Makefile
+++ b/examples/ptpclient/Makefile
@@ -8,8 +8,7 @@ APP = ptpclient
SRCS-y := ptpclient.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/qos_meter/Makefile b/examples/qos_meter/Makefile
index e4d170177..e5217cf7c 100644
--- a/examples/qos_meter/Makefile
+++ b/examples/qos_meter/Makefile
@@ -8,8 +8,7 @@ APP = qos_meter
SRCS-y := main.c rte_policer.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/qos_sched/Makefile b/examples/qos_sched/Makefile
index 0c92c4866..ce2d25371 100644
--- a/examples/qos_sched/Makefile
+++ b/examples/qos_sched/Makefile
@@ -8,8 +8,7 @@ APP = qos_sched
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)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/rxtx_callbacks/Makefile b/examples/rxtx_callbacks/Makefile
index 2ababd2e4..edd5b52cd 100644
--- a/examples/rxtx_callbacks/Makefile
+++ b/examples/rxtx_callbacks/Makefile
@@ -8,8 +8,7 @@ APP = rxtx_callbacks
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/service_cores/Makefile b/examples/service_cores/Makefile
index ae7d6478c..abbb7aed2 100644
--- a/examples/service_cores/Makefile
+++ b/examples/service_cores/Makefile
@@ -8,8 +8,7 @@ APP = service_cores
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/skeleton/Makefile b/examples/skeleton/Makefile
index 68454a558..c5ac26029 100644
--- a/examples/skeleton/Makefile
+++ b/examples/skeleton/Makefile
@@ -8,8 +8,7 @@ APP = basicfwd
SRCS-y := basicfwd.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/tep_termination/Makefile b/examples/tep_termination/Makefile
index be5aa9a64..31165bd92 100644
--- a/examples/tep_termination/Makefile
+++ b/examples/tep_termination/Makefile
@@ -8,8 +8,7 @@ APP = tep_termination
SRCS-y := main.c vxlan_setup.c vxlan.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/timer/Makefile b/examples/timer/Makefile
index d21e4c63c..a86178355 100644
--- a/examples/timer/Makefile
+++ b/examples/timer/Makefile
@@ -8,8 +8,7 @@ APP = timer
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/vdpa/Makefile b/examples/vdpa/Makefile
index 734042380..2ac991a4b 100644
--- a/examples/vdpa/Makefile
+++ b/examples/vdpa/Makefile
@@ -9,8 +9,7 @@ SRCS-y := main.c
CFLAGS += -DALLOW_EXPERIMENTAL_API
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/vhost/Makefile b/examples/vhost/Makefile
index 5e1400678..f84b7f017 100644
--- a/examples/vhost/Makefile
+++ b/examples/vhost/Makefile
@@ -8,8 +8,7 @@ APP = vhost-switch
SRCS-y := main.c virtio_net.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/vhost_crypto/Makefile b/examples/vhost_crypto/Makefile
index e7958b5ba..a9e1c4d3a 100644
--- a/examples/vhost_crypto/Makefile
+++ b/examples/vhost_crypto/Makefile
@@ -9,8 +9,7 @@ SRCS-y := main.c
CFLAGS += -DALLOW_EXPERIMENTAL_API
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/vhost_scsi/Makefile b/examples/vhost_scsi/Makefile
index 3ea37ebc6..c5aec269e 100644
--- a/examples/vhost_scsi/Makefile
+++ b/examples/vhost_scsi/Makefile
@@ -8,8 +8,7 @@ APP = vhost-scsi
SRCS-y := scsi.c vhost_scsi.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/vmdq/Makefile b/examples/vmdq/Makefile
index dc1bc82d0..1557ee86b 100644
--- a/examples/vmdq/Makefile
+++ b/examples/vmdq/Makefile
@@ -8,8 +8,7 @@ APP = vmdq_app
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
diff --git a/examples/vmdq_dcb/Makefile b/examples/vmdq_dcb/Makefile
index a77e78987..391096cfb 100644
--- a/examples/vmdq_dcb/Makefile
+++ b/examples/vmdq_dcb/Makefile
@@ -8,8 +8,7 @@ APP = vmdq_dcb_app
SRCS-y := main.c
# Build using pkg-config variables if possible
-$(shell pkg-config --exists libdpdk)
-ifeq ($(.SHELLSTATUS),0)
+ifeq ($(shell pkg-config --exists libdpdk && echo 0),0)
all: shared
.PHONY: shared static
--
2.21.0
^ permalink raw reply [flat|nested] 7+ messages in thread
* [dpdk-dev] [PATCH 2/2] buildtools/test-meson-builds: workaround pkg-config issue
2019-07-03 16:39 [dpdk-dev] [PATCH 0/2] fix issues with Ubuntu 18.04 compilation Bruce Richardson
2019-07-03 16:40 ` [dpdk-dev] [PATCH 1/2] examples: fix pkg-config detection with older make Bruce Richardson
@ 2019-07-03 16:40 ` Bruce Richardson
2019-07-04 8:39 ` Luca Boccassi
2019-07-03 16:49 ` [dpdk-dev] [PATCH 0/2] fix issues with Ubuntu 18.04 compilation Luca Boccassi
2 siblings, 1 reply; 7+ messages in thread
From: Bruce Richardson @ 2019-07-03 16:40 UTC (permalink / raw)
To: dev; +Cc: Bruce Richardson
With Debian and Ubuntu, the default installation path for the 64-bit
libraries is set to e.g. /usr/local/lib/x86_64-linux-gnu/, compared to
/usr/local/lib64 on Fedora and Redhat distributions. This causes issues
when using "pkg-config --define-prefix" since pkg-config assumes the prefix
to be the grandparent of where the .pc file is. On Ubuntu we then get the
cflags include path as being "/path/to/install-root/usr/local/lib/include"
i.e. with an extra "lib" in the path.
This issue only applies for test installs on Ubuntu and similar distros,
and is not a problem for regular installs since the --define-prefix
parameter would not be passed to pkg-config in those cases.
The workaround for this in our test build script is to explicitly make
"lib" the "libdir" setting for the install, overriding the distro-provided
default.
Fixes: 7f80a2102bbb ("devtools: test pkg-config file")
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
---
devtools/test-meson-builds.sh | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/devtools/test-meson-builds.sh b/devtools/test-meson-builds.sh
index 57d1af47e..7efc590fe 100755
--- a/devtools/test-meson-builds.sh
+++ b/devtools/test-meson-builds.sh
@@ -76,12 +76,14 @@ for c in gcc clang ; do
done
# test compilation with minimal x86 instruction set
+# set the install path for libraries to "lib" explicitly to prevent problems
+# with pkg-config prefixes if installed in "lib/x86_64-linux-gnu" later.
default_machine='nehalem'
ok=$(cc -march=$default_machine -E - < /dev/null > /dev/null 2>&1 || echo false)
if [ "$ok" = "false" ] ; then
default_machine='corei7'
fi
-build build-x86-default -Dmachine=$default_machine $use_shared
+build build-x86-default -Dlibdir=lib -Dmachine=$default_machine $use_shared
# enable cross compilation if gcc cross-compiler is found
c=aarch64-linux-gnu-gcc
--
2.21.0
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [dpdk-dev] [PATCH 0/2] fix issues with Ubuntu 18.04 compilation
2019-07-03 16:39 [dpdk-dev] [PATCH 0/2] fix issues with Ubuntu 18.04 compilation Bruce Richardson
2019-07-03 16:40 ` [dpdk-dev] [PATCH 1/2] examples: fix pkg-config detection with older make Bruce Richardson
2019-07-03 16:40 ` [dpdk-dev] [PATCH 2/2] buildtools/test-meson-builds: workaround pkg-config issue Bruce Richardson
@ 2019-07-03 16:49 ` Luca Boccassi
2019-07-03 21:11 ` Thomas Monjalon
2 siblings, 1 reply; 7+ messages in thread
From: Luca Boccassi @ 2019-07-03 16:49 UTC (permalink / raw)
To: Bruce Richardson, dev
On Wed, 2019-07-03 at 17:39 +0100, Bruce Richardson wrote:
> This set has two fixes for the build issues on Ubuntu. The first
> patch
> adds in support for older make v4.1, and the second works around a
> problem with pkg-config giving an incorrect prefix in some
> circumstances.
>
> Bruce Richardson (2):
> examples: fix pkg-config detection with older make
> buildtools/test-meson-builds: workaround pkg-config issue
>
> devtools/test-meson-builds.sh | 4 +++-
> examples/bbdev_app/Makefile | 3 +--
> examples/bond/Makefile | 3 +--
> examples/cmdline/Makefile | 3 +--
> examples/distributor/Makefile | 3 +--
> examples/eventdev_pipeline/Makefile | 3 +--
> examples/exception_path/Makefile | 3 +--
> examples/fips_validation/Makefile | 3 +--
> examples/flow_classify/Makefile | 3 +--
> examples/flow_filtering/Makefile | 3 +--
> examples/helloworld/Makefile | 3 +--
> examples/ip_fragmentation/Makefile | 3 +--
> examples/ip_pipeline/Makefile | 3 +--
> examples/ip_reassembly/Makefile | 3 +--
> examples/ipsec-secgw/Makefile | 3 +--
> examples/ipv4_multicast/Makefile | 3 +--
> examples/kni/Makefile | 3 +--
> examples/l2fwd-cat/Makefile | 3 +--
> examples/l2fwd-crypto/Makefile | 3 +--
> examples/l2fwd-jobstats/Makefile | 3 +--
> examples/l2fwd-keepalive/Makefile | 3 +--
> examples/l2fwd/Makefile | 3 +--
> examples/l3fwd-acl/Makefile | 3 +--
> examples/l3fwd-power/Makefile | 3 +--
> examples/l3fwd-vf/Makefile | 3 +--
> examples/l3fwd/Makefile | 3 +--
> examples/link_status_interrupt/Makefile | 3 +--
> examples/load_balancer/Makefile | 3 +--
> examples/packet_ordering/Makefile | 3 +--
> examples/ptpclient/Makefile | 3 +--
> examples/qos_meter/Makefile | 3 +--
> examples/qos_sched/Makefile | 3 +--
> examples/rxtx_callbacks/Makefile | 3 +--
> examples/service_cores/Makefile | 3 +--
> examples/skeleton/Makefile | 3 +--
> examples/tep_termination/Makefile | 3 +--
> examples/timer/Makefile | 3 +--
> examples/vdpa/Makefile | 3 +--
> examples/vhost/Makefile | 3 +--
> examples/vhost_crypto/Makefile | 3 +--
> examples/vhost_scsi/Makefile | 3 +--
> examples/vmdq/Makefile | 3 +--
> examples/vmdq_dcb/Makefile | 3 +--
> 43 files changed, 45 insertions(+), 85 deletions(-)
Series-acked-by: Luca Boccassi <bluca@debian.org>
--
Kind regards,
Luca Boccassi
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [dpdk-dev] [PATCH 0/2] fix issues with Ubuntu 18.04 compilation
2019-07-03 16:49 ` [dpdk-dev] [PATCH 0/2] fix issues with Ubuntu 18.04 compilation Luca Boccassi
@ 2019-07-03 21:11 ` Thomas Monjalon
0 siblings, 0 replies; 7+ messages in thread
From: Thomas Monjalon @ 2019-07-03 21:11 UTC (permalink / raw)
To: Bruce Richardson; +Cc: dev, Luca Boccassi
> > Bruce Richardson (2):
> > examples: fix pkg-config detection with older make
> > buildtools/test-meson-builds: workaround pkg-config issue
>
> Series-acked-by: Luca Boccassi <bluca@debian.org>
Applied, thanks
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [dpdk-dev] [PATCH 2/2] buildtools/test-meson-builds: workaround pkg-config issue
2019-07-03 16:40 ` [dpdk-dev] [PATCH 2/2] buildtools/test-meson-builds: workaround pkg-config issue Bruce Richardson
@ 2019-07-04 8:39 ` Luca Boccassi
2019-07-04 9:47 ` Bruce Richardson
0 siblings, 1 reply; 7+ messages in thread
From: Luca Boccassi @ 2019-07-04 8:39 UTC (permalink / raw)
To: Bruce Richardson, dev
On Wed, 2019-07-03 at 17:40 +0100, Bruce Richardson wrote:
> With Debian and Ubuntu, the default installation path for the 64-bit
> libraries is set to e.g. /usr/local/lib/x86_64-linux-gnu/, compared
> to
> /usr/local/lib64 on Fedora and Redhat distributions. This causes
> issues
> when using "pkg-config --define-prefix" since pkg-config assumes the
> prefix
> to be the grandparent of where the .pc file is. On Ubuntu we then get
> the
> cflags include path as being "/path/to/install-
> root/usr/local/lib/include"
> i.e. with an extra "lib" in the path.
>
> This issue only applies for test installs on Ubuntu and similar
> distros,
> and is not a problem for regular installs since the --define-prefix
> parameter would not be passed to pkg-config in those cases.
>
> The workaround for this in our test build script is to explicitly
> make
> "lib" the "libdir" setting for the install, overriding the distro-
> provided
> default.
>
> Fixes: 7f80a2102bbb ("devtools: test pkg-config file")
>
> Signed-off-by: Bruce Richardson <
> bruce.richardson@intel.com
> >
> ---
> devtools/test-meson-builds.sh | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/devtools/test-meson-builds.sh b/devtools/test-meson-
> builds.sh
> index 57d1af47e..7efc590fe 100755
> --- a/devtools/test-meson-builds.sh
> +++ b/devtools/test-meson-builds.sh
> @@ -76,12 +76,14 @@ for c in gcc clang ; do
> done
>
> # test compilation with minimal x86 instruction set
> +# set the install path for libraries to "lib" explicitly to prevent
> problems
> +# with pkg-config prefixes if installed in "lib/x86_64-linux-gnu"
> later.
> default_machine='nehalem'
> ok=$(cc -march=$default_machine -E - < /dev/null > /dev/null 2>&1 ||
> echo false)
> if [ "$ok" = "false" ] ; then
> default_machine='corei7'
> fi
> -build build-x86-default -Dmachine=$default_machine $use_shared
> +build build-x86-default -Dlibdir=lib -Dmachine=$default_machine
> $use_shared
>
> # enable cross compilation if gcc cross-compiler is found
> c=aarch64-linux-gnu-gcc
I have sent a patch upstream to pkg-config to fix the issue, as it
should really support the multiarch layout:
https://gitlab.freedesktop.org/pkg-config/pkg-config/merge_requests/4
--
Kind regards,
Luca Boccassi
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [dpdk-dev] [PATCH 2/2] buildtools/test-meson-builds: workaround pkg-config issue
2019-07-04 8:39 ` Luca Boccassi
@ 2019-07-04 9:47 ` Bruce Richardson
0 siblings, 0 replies; 7+ messages in thread
From: Bruce Richardson @ 2019-07-04 9:47 UTC (permalink / raw)
To: Luca Boccassi; +Cc: dev
On Thu, Jul 04, 2019 at 09:39:32AM +0100, Luca Boccassi wrote:
> On Wed, 2019-07-03 at 17:40 +0100, Bruce Richardson wrote:
> > With Debian and Ubuntu, the default installation path for the 64-bit
> > libraries is set to e.g. /usr/local/lib/x86_64-linux-gnu/, compared
> > to
> > /usr/local/lib64 on Fedora and Redhat distributions. This causes
> > issues
> > when using "pkg-config --define-prefix" since pkg-config assumes the
> > prefix
> > to be the grandparent of where the .pc file is. On Ubuntu we then get
> > the
> > cflags include path as being "/path/to/install-
> > root/usr/local/lib/include"
> > i.e. with an extra "lib" in the path.
> >
> > This issue only applies for test installs on Ubuntu and similar
> > distros,
> > and is not a problem for regular installs since the --define-prefix
> > parameter would not be passed to pkg-config in those cases.
> >
> > The workaround for this in our test build script is to explicitly
> > make
> > "lib" the "libdir" setting for the install, overriding the distro-
> > provided
> > default.
> >
> > Fixes: 7f80a2102bbb ("devtools: test pkg-config file")
> >
> > Signed-off-by: Bruce Richardson <
> > bruce.richardson@intel.com
> > >
> > ---
> > devtools/test-meson-builds.sh | 4 +++-
> > 1 file changed, 3 insertions(+), 1 deletion(-)
> >
> > diff --git a/devtools/test-meson-builds.sh b/devtools/test-meson-
> > builds.sh
> > index 57d1af47e..7efc590fe 100755
> > --- a/devtools/test-meson-builds.sh
> > +++ b/devtools/test-meson-builds.sh
> > @@ -76,12 +76,14 @@ for c in gcc clang ; do
> > done
> >
> > # test compilation with minimal x86 instruction set
> > +# set the install path for libraries to "lib" explicitly to prevent
> > problems
> > +# with pkg-config prefixes if installed in "lib/x86_64-linux-gnu"
> > later.
> > default_machine='nehalem'
> > ok=$(cc -march=$default_machine -E - < /dev/null > /dev/null 2>&1 ||
> > echo false)
> > if [ "$ok" = "false" ] ; then
> > default_machine='corei7'
> > fi
> > -build build-x86-default -Dmachine=$default_machine $use_shared
> > +build build-x86-default -Dlibdir=lib -Dmachine=$default_machine
> > $use_shared
> >
> > # enable cross compilation if gcc cross-compiler is found
> > c=aarch64-linux-gnu-gcc
>
> I have sent a patch upstream to pkg-config to fix the issue, as it
> should really support the multiarch layout:
>
> https://gitlab.freedesktop.org/pkg-config/pkg-config/merge_requests/4
Thanks, Luca, good to have that fixed at source. Either way the fix in DPDK
for our testing is harmless and ensures things pass generally.
/Bruce
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2019-07-04 9:47 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-07-03 16:39 [dpdk-dev] [PATCH 0/2] fix issues with Ubuntu 18.04 compilation Bruce Richardson
2019-07-03 16:40 ` [dpdk-dev] [PATCH 1/2] examples: fix pkg-config detection with older make Bruce Richardson
2019-07-03 16:40 ` [dpdk-dev] [PATCH 2/2] buildtools/test-meson-builds: workaround pkg-config issue Bruce Richardson
2019-07-04 8:39 ` Luca Boccassi
2019-07-04 9:47 ` Bruce Richardson
2019-07-03 16:49 ` [dpdk-dev] [PATCH 0/2] fix issues with Ubuntu 18.04 compilation Luca Boccassi
2019-07-03 21:11 ` Thomas Monjalon
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).