aboutsummaryrefslogtreecommitdiffstats
path: root/operational-plans/Makefile
diff options
context:
space:
mode:
authorGustav Eek <gustav.eek@fripost.org>2020-05-26 18:09:06 +0200
committerGustav Eek <gustav.eek@fripost.org>2020-05-26 18:09:06 +0200
commit5c0fabe2d01d9ac55c06f4d848b54573349a91e7 (patch)
treee4744d1265dfe7c9ae1a1b429613882fc9e9121d /operational-plans/Makefile
parent4ae2ba1d854ce4797f8034652391d1a2a133ade0 (diff)
Annual 2020. Makefile modified
Diffstat (limited to 'operational-plans/Makefile')
-rw-r--r--operational-plans/Makefile19
1 files changed, 13 insertions, 6 deletions
diff --git a/operational-plans/Makefile b/operational-plans/Makefile
index 7c71e5c..c65065c 100644
--- a/operational-plans/Makefile
+++ b/operational-plans/Makefile
@@ -1,4 +1,4 @@
-ALL = \
+PDF = \
operational-plan-2020 \
operational-plan-2019 \
operational-plan-2018 \
@@ -6,12 +6,18 @@ ALL = \
operational-plan-2013 \
operational-plan-2012 \
+TEX = \
+ operational-policy-2018_ \
+ operational-policy-2018__ \
+
+ALL = \
+ $(addsuffix .pdf, $(PDF)) \
+ $(addsuffix .tex, $(TEX)) \
+
common-makefile = ../resources/Makefile-common
all: $(ALL)
-$(ALL): %: %.pdf
-
# General cases
%.pdf: %.main.tex %._.tex
@@ -25,7 +31,7 @@ $(ALL): %: %.pdf
%.pdf: %.main.tex %.tex ../preamble/preamble.tex
latex_count=5 ;\
latex_log=$$(echo $< | sed 's/.tex/.log/') ;\
- pdflatex $< ;\
+
while egrep -s 'Rerun (LaTeX|to get cross-references right)' $$latex_log && [ $$latex_count -gt 0 ] ;\
do echo "Rerunning latex...." ; pdflatex $< ;\
latex_count=`expr $$latex_count - 1`;\
@@ -36,9 +42,10 @@ $(ALL): %: %.pdf
operational-plan-2018.main.tex: operational-policy-2018_.tex
touch $@
-operational-policy-2018_.tex: ../by-laws/operational-policy-2018.tex
+%_.tex: ../by-laws/%.tex
sed -e 's/\\\(.*\)section *{/\\sub\1section\*{/g' < $< > $@
-
+%__.tex: ../by-laws/%.tex
+ sed -e 's/\\\(.*\)section *{/\\subsub\1section\*{/g' < $< > $@
send:
make -f $(common-makefile) send SEND_FILES="$(ALL)"