doc: make: adjust Makefile
Adjust Makefile according to latest CMake changes. Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
This commit is contained in:
parent
5fe1694ec9
commit
0d0b0ce10e
3
.github/workflows/doc-build.yml
vendored
3
.github/workflows/doc-build.yml
vendored
|
@ -54,8 +54,7 @@ jobs:
|
|||
|
||||
- name: build-docs
|
||||
run: |
|
||||
source zephyr-env.sh
|
||||
SPHINXOPTS="-q -W -j auto" make -C doc htmldocs
|
||||
SPHINXOPTS="-q -W -j auto" make -C doc html
|
||||
tar cvf htmldocs.tar --directory=./doc/_build html
|
||||
|
||||
- name: upload-build
|
||||
|
|
29
doc/Makefile
29
doc/Makefile
|
@ -1,30 +1,31 @@
|
|||
#
|
||||
# Top level makefile for documentation build
|
||||
#
|
||||
# ------------------------------------------------------------------------------
|
||||
# Makefile for documentation build
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
BUILDDIR ?= _build
|
||||
DOC_TAG ?= development
|
||||
SPHINXOPTS ?= -j auto
|
||||
KCONFIG_TURBO_MODE ?= 0
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# Documentation targets
|
||||
# ---------------------------------------------------------------------------
|
||||
|
||||
.PHONY: clean htmldocs htmldocs-fast pdfdocs doxygen
|
||||
.PHONY: configure clean html html-fast latex pdf doxygen
|
||||
|
||||
htmldocs-fast:
|
||||
${MAKE} htmldocs KCONFIG_TURBO_MODE=1
|
||||
html-fast:
|
||||
${MAKE} html KCONFIG_TURBO_MODE=1
|
||||
|
||||
htmldocs pdfdocs doxygen: configure
|
||||
cmake --build ${BUILDDIR} -- $@ # -v # VERBOSE=1
|
||||
html latex pdf doxygen: configure
|
||||
cmake --build ${BUILDDIR} --target $@
|
||||
|
||||
# Run CMake every time cause it's quick and re-configures TURBO_MODE if
|
||||
# needed
|
||||
.PHONY: configure
|
||||
configure:
|
||||
cmake -GNinja -B${BUILDDIR} -S. -DDOC_TAG=${DOC_TAG} \
|
||||
cmake \
|
||||
-GNinja \
|
||||
-B${BUILDDIR} \
|
||||
-S. \
|
||||
-DDOC_TAG=${DOC_TAG} \
|
||||
-DSPHINXOPTS="${SPHINXOPTS}" \
|
||||
-DKCONFIG_TURBO_MODE=${KCONFIG_TURBO_MODE}
|
||||
|
||||
clean:
|
||||
rm -rf ${BUILDDIR}
|
||||
cmake --build ${BUILDDIR} --target clean
|
||||
|
|
Loading…
Reference in a new issue