Skip to content

Commit

Permalink
Makefile: adding support for build / runtime output for PDF books.
Browse files Browse the repository at this point in the history
  • Loading branch information
gusthoff committed Feb 20, 2021
1 parent 77cc430 commit b1f3f83
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion frontend/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ SPHINXBUILD = sphinx-build
SPHINXPROJ = learnadacorecom
SPHINXCONF = sphinx
BUILDDIR = dist
TEST_DRIVER = PYTHONPATH="$PYTHONPATH:sphinx" python3 tests/compile_blocks.py -B $(BUILDDIR)/test_output
SRC_TEST_DIR = $(BUILDDIR)/test_output
TEST_DRIVER = PYTHONPATH="$PYTHONPATH:sphinx:../backend" python3 tests/compile_blocks.py --keep_files -B $(SRC_TEST_DIR)

MKFILE_PATH := $(abspath $(lastword $(MAKEFILE_LIST)))
MKFILE_DIR := $(dir $(MKFILE_PATH))
Expand Down Expand Up @@ -162,6 +163,7 @@ $(BOOKS):
@mkdir -p $(BUILDDIR)/pdf_books/$(SPHINX_DIR)
@export SPHINX_TITLE="$(SPHINX_TITLE)"; \
export SPHINX_AUTHOR="$(SPHINX_AUTHOR)"; \
export SRC_TEST_DIR="$(SRC_TEST_DIR)"; \
$(SPHINXBUILD) -M latexpdf $@ \
"$(BUILDDIR)" $(SPHINXOPTS) $(O) -v -c "$(SPHINXCONF)"
@mv $(BUILDDIR)/latex/learnadacorecom.pdf $(BUILDDIR)/pdf_books/$(SPHINX_DIR)/$(SPHINX_PDF)
Expand Down

0 comments on commit b1f3f83

Please sign in to comment.