From: Bruce Richardson <bruce.richardson@intel.com>
To: dev@dpdk.org
Cc: david.marchand@redhat.com,
Bruce Richardson <bruce.richardson@intel.com>,
stable@dpdk.org
Subject: [dpdk-stable] [PATCH v4 2/4] examples/l2fwd-keepalive: skip build when no librt
Date: Thu, 12 Nov 2020 09:41:40 +0000 [thread overview]
Message-ID: <20201112094142.1781861-3-bruce.richardson@intel.com> (raw)
In-Reply-To: <20201112094142.1781861-1-bruce.richardson@intel.com>
When librt is not present on a system, processing the meson.build file
for this example application causes an error. Make the library
non-mandatory and just mark the example as unbuildable if it is
not present.
Fixes: 89f0711f9ddf ("examples: build some samples with meson")
Cc: stable@dpdk.org
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
---
examples/l2fwd-keepalive/meson.build | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/examples/l2fwd-keepalive/meson.build b/examples/l2fwd-keepalive/meson.build
index d678a8ddd..a56d67967 100644
--- a/examples/l2fwd-keepalive/meson.build
+++ b/examples/l2fwd-keepalive/meson.build
@@ -7,7 +7,13 @@
# DPDK instance, use 'make'
allow_experimental_apis = true
-ext_deps += cc.find_library('rt')
+librt = cc.find_library('rt', required: false)
+if not librt.found()
+ build = false
+ subdir_done()
+endif
+
+ext_deps += librt
deps += 'timer'
sources = files(
'main.c', 'shm.c'
--
2.25.1
prev parent reply other threads:[~2020-11-12 9:42 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-10 17:08 [dpdk-stable] [PATCH] install: fix flattening of examples directory Bruce Richardson
2020-11-10 17:09 ` Bruce Richardson
2020-11-10 17:14 ` David Marchand
2020-11-10 17:33 ` David Marchand
2020-11-10 17:42 ` Bruce Richardson
2020-11-11 15:56 ` [dpdk-stable] [PATCH v2 1/2] examples: fix flattening directory layout on install Bruce Richardson
2020-11-11 17:48 ` [dpdk-stable] [PATCH v3 1/4] " Bruce Richardson
2020-11-11 17:48 ` [dpdk-stable] [PATCH v3 2/4] examples/l2fwd-keepalive: skip build when no librt Bruce Richardson
[not found] ` <20201112094142.1781861-1-bruce.richardson@intel.com>
2020-11-12 9:41 ` [dpdk-stable] [PATCH v4 1/4] examples: fix flattening directory layout on install Bruce Richardson
2020-11-12 9:41 ` Bruce Richardson [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20201112094142.1781861-3-bruce.richardson@intel.com \
--to=bruce.richardson@intel.com \
--cc=david.marchand@redhat.com \
--cc=dev@dpdk.org \
--cc=stable@dpdk.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).