fix test dependencies

This commit is contained in:
Motiejus Jakštys 2021-04-02 06:31:47 +03:00
parent f1a50d8b38
commit f577eb81ae
2 changed files with 4 additions and 3 deletions

View File

@ -46,7 +46,7 @@ mj-msc-full.pdf: mj-msc.pdf version.tex $(ARCHIVABLES)
done
mv .tmp-$@ $@
test-figures.pdf: layer2img.py tests.sql
test-figures.pdf: layer2img.py .faux_test
python ./layer2img.py --group1-table=figures --group1-arrows=yes --outfile=$@
.faux_test: tests.sql wm.sql .faux.db

View File

@ -1,9 +1,10 @@
#!/bin/bash
set -euo pipefail
dir=$(mktemp -d)
src=${1:-mj-msc.pdf}
dst=${2:-mj-msc-full.pdf}
src=${1:-mj-msc-full.pdf}
dst=${2:-mj-msc.pdf}
echo "Extracting $src to $dir/" && pdfdetach -saveall -o "$dir" "$src"
chmod a+x "$dir/db"
echo "Generating $dir/$dst ..."
make -j $(nproc) -C "$dir" "$dst" &> "$dir/make.log" || {
echo "Generation failed. Log extract:" && tail -20 "$dir/make.log"