Skip to content

Commit 4d79f02

Browse files
committed
metadata/code: Add explicit dependency on core spec latex build for aux file
1 parent 9d3d01e commit 4d79f02

File tree

3 files changed

+12
-4
lines changed

3 files changed

+12
-4
lines changed

.github/workflows/ci-spec.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,7 @@ jobs:
7272

7373
build-code-metadata-spec:
7474
runs-on: ubuntu-latest
75+
needs: [build-core-spec]
7576
steps:
7677
- name: Checkout repo
7778
uses: actions/checkout@v2

document/metadata/code/Makefile

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -255,23 +255,30 @@ epub3:
255255
@echo
256256
@echo "Build finished. The epub3 file is in $(BUILDDIR)/epub3."
257257

258+
259+
.PHONY: latex-core-aux
260+
latex-core-aux:
261+
(cd ../../core; make BUILDDIR=$(BUILDDIR) latexpdf)
262+
mkdir -p $(BUILDDIR)/latex
263+
cp ../../core/$(BUILDDIR)/latex/WebAssembly.aux $(BUILDDIR)/latex/
264+
258265
.PHONY: latex
259-
latex:
266+
latex: latex-core-aux
260267
$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
261268
@echo
262269
@echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex."
263270
@echo "Run \`make' in that directory to run these through (pdf)latex" \
264271
"(use \`make latexpdf' here to do that automatically)."
265272

266273
.PHONY: latexpdf
267-
latexpdf:
274+
latexpdf: latex-core-aux
268275
$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
269276
@echo "Running LaTeX files through pdflatex..."
270277
$(MAKE) -C $(BUILDDIR)/latex LATEXMKOPTS=" </dev/null" all-pdf >$(BUILDDIR)/latex/LOG 2>&1 || cat $(BUILDDIR)/latex/LOG
271278
@echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex."
272279

273280
.PHONY: latexpdfja
274-
latexpdfja:
281+
latexpdfja: latex-core-aux
275282
$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
276283
@echo "Running LaTeX files through platex and dvipdfmx..."
277284
$(MAKE) -C $(BUILDDIR)/latex all-pdf-ja

document/metadata/code/conf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,7 @@
296296

297297
# Additional stuff for the LaTeX preamble.
298298
# Don't type-set cross references with emphasis.
299-
'preamble': '\\renewcommand\\sphinxcrossref[1]{#1}\n\\externaldocument[Core-]{'+core_dir+'/_build/latex/WebAssembly}[https://webassembly.github.io//'+repo+'/core/_download/WebAssembly.pdf]\n',
299+
'preamble': '\\renewcommand\\sphinxcrossref[1]{#1}\n\\externaldocument[Core-]{WebAssembly}[https://webassembly.github.io//'+repo+'/core/_download/WebAssembly.pdf]\n',
300300

301301
# Latex figure (float) alignment
302302
'figure_align': 'htbp',

0 commit comments

Comments
 (0)