From a69d74c842a0f55ffa1408fa058138ac9637a0c6 Mon Sep 17 00:00:00 2001 From: Nicolas Dechesne Date: Fri, 18 Sep 2020 10:14:14 +0200 Subject: sphinx: report errors when dependencies are not met To build the Sphinx documentation, we have the following dependencies: * sphinx * sphinx_rtd_theme * pyyaml If any of these dependencies are missing, we might end up with some cryptic error messages. This patch adds better error reporting when dependencies are not met. (From yocto-docs rev: 19df8d1ec56dc2ecb44122288cc53e84237fab69) Signed-off-by: Nicolas Dechesne Signed-off-by: Richard Purdie --- documentation/Makefile.sphinx | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'documentation/Makefile.sphinx') diff --git a/documentation/Makefile.sphinx b/documentation/Makefile.sphinx index c663c29540..c9518558bb 100644 --- a/documentation/Makefile.sphinx +++ b/documentation/Makefile.sphinx @@ -9,6 +9,10 @@ SOURCEDIR = . BUILDDIR = _build DESTDIR = final +ifeq ($(shell if which $(SPHINXBUILD) >/dev/null 2>&1; then echo 1; else echo 0; fi),0) +$(error "The '$(SPHINXBUILD)' command was not found. Make sure you have Sphinx installed") +endif + # Put it first so that "make" without argument is like "make help". help: @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) -- cgit v1.2.3-54-g00ecf