From: Bruce Richardson <bruce.richardson@intel.com>
To: david.marchand@redhat.com
Cc: dev@dpdk.org, Bruce Richardson <bruce.richardson@intel.com>
Subject: [dpdk-dev] [PATCH 2/2] doc: pass "werror" setting through to doc build
Date: Fri, 17 Jan 2020 10:48:20 +0000 [thread overview]
Message-ID: <20200117104820.71403-2-bruce.richardson@intel.com> (raw)
In-Reply-To: <20200117104820.71403-1-bruce.richardson@intel.com>
When werror is set for the build, we should pass that flag through to
sphinx so that it can flag warnings as errors too.
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
---
buildtools/call-sphinx-build.py | 5 ++---
doc/guides/meson.build | 4 ++++
2 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/buildtools/call-sphinx-build.py b/buildtools/call-sphinx-build.py
index 85c9e0156..fc4e9d040 100755
--- a/buildtools/call-sphinx-build.py
+++ b/buildtools/call-sphinx-build.py
@@ -9,12 +9,11 @@
from subprocess import run, PIPE, STDOUT
from distutils.version import StrictVersion
-(sphinx, src, dst) = sys.argv[1:] # assign parameters to variables
+(*sphinx_cmd, src, dst) = sys.argv[1:] # assign parameters to variables
# for sphinx version >= 1.7 add parallelism using "-j auto"
-ver = run([sphinx, '--version'], stdout=PIPE,
+ver = run(sphinx_cmd + ['--version'], stdout=PIPE,
stderr=STDOUT).stdout.decode().split()[-1]
-sphinx_cmd = [sphinx]
if StrictVersion(ver) >= StrictVersion('1.7'):
sphinx_cmd += ['-j', 'auto']
diff --git a/doc/guides/meson.build b/doc/guides/meson.build
index 732e7ad3a..5a2b854e8 100644
--- a/doc/guides/meson.build
+++ b/doc/guides/meson.build
@@ -7,6 +7,10 @@ if not sphinx.found()
subdir_done()
endif
+if get_option('werror')
+ sphinx = [sphinx, '-W']
+endif
+
htmldir = join_paths(get_option('datadir'), 'doc', 'dpdk')
html_guides = custom_target('html_guides',
input: files('index.rst'),
--
2.20.1
next prev parent reply other threads:[~2020-01-17 10:51 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-01-17 10:48 [dpdk-dev] [PATCH 1/2] doc: fix doc build when sphinx reports version to stderr Bruce Richardson
2020-01-17 10:48 ` Bruce Richardson [this message]
2020-01-17 13:16 ` [dpdk-dev] [PATCH 2/2] doc: pass "werror" setting through to doc build Aaron Conole
2020-01-17 13:25 ` Bruce Richardson
2020-01-17 13:34 ` Aaron Conole
2020-01-17 17:42 ` Bruce Richardson
2020-01-17 17:59 ` Aaron Conole
2020-06-22 14:00 ` [dpdk-dev] [PATCH v2] doc: fix doc build when sphinx reports version to stderr Bruce Richardson
2020-06-22 14:09 ` Power, Ciara
2020-06-22 14:20 ` David Marchand
2020-07-30 23:00 ` Thomas Monjalon
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=20200117104820.71403-2-bruce.richardson@intel.com \
--to=bruce.richardson@intel.com \
--cc=david.marchand@redhat.com \
--cc=dev@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).