Commit 16a36d2c authored by Federico Vaga's avatar Federico Vaga

doc: split sphix makefile from our Makefile

Signed-off-by: Federico Vaga's avatarFederico Vaga <federico.vaga@cern.ch>
parent b030a962
......@@ -11,26 +11,15 @@ SPHINXBUILD = sphinx-build
SOURCEDIR = .
BUILDDIR = _build
CHEBY ?= cheby
CHEBY_FILES := spec_base_regs.cheby
CHEBY_DOC_FILES := $(CHEBY_FILES:.cheby=.rst)
# Put it first so that "make" without argument is like "make help".
#Put it first so that "make" without argument is like "make help".
help:
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
.PHONY: clean help cheby_doc
.PHONY: help Makefile
# Catch-all target: route all unknown targets to Sphinx using the new
#Catch-all target: route all unknown targets to Sphinx using the new
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
%: cheby_doc
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
vpath %.cheby ../hdl/rtl
cheby_doc: $(CHEBY_DOC_FILES)
$(CHEBY_DOC_FILES): %.rst: %.cheby
$(CHEBY) -i $< --gen-doc --doc rest > $@
clean:
@rm -f $(CHEBY_DOC_FILES)
%: Makefile
@$(MAKE) -f Makefile.dependencies $@
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
# SPDX-FileCopyrightText: 2020 CERN (home.cern)
#
# SPDX-License-Identifier: CC-BY-SA-4.0+
CHEBY ?= cheby
CHEBY_FILES := spec_base_regs.cheby
CHEBY_DOC_FILES := $(CHEBY_FILES:.cheby=.rst)
all: cheby_doc
vpath %.cheby ../hdl/rtl
cheby_doc: $(CHEBY_DOC_FILES)
$(CHEBY_DOC_FILES): %.rst: %.cheby
$(CHEBY) -i $< --gen-doc --doc rest > $@
clean:
@rm -f $(CHEBY_DOC_FILES)
# Whatever sphinx target, build the cheby doc
%: cheby_doc
@echo > /dev/null
.PHONY: all cheby_doc clean
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment