summaryrefslogtreecommitdiff
path: root/Makefile
blob: 1f8da01d31e7db3b13fd9ffc996dc7c2a5930b2a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
ELBERFELDER_CHAPTERS=$(wildcard elberfelder-bibel/chapters/*/*.html)
ELBERFELDER_CHAPTERS_XML=$(ELBERFELDER_CHAPTERS:.html=.xml)

MENGE_CHAPTERS=$(wildcard menge-bibel/chapters/*/*.html)
MENGE_CHAPTERS_XML=$(MENGE_CHAPTERS:.html=.xml)

all: elberfelder2006.zip menge.zip

%.xml: %.html convert.sed convert.xsl
	./convert.sed "$<" | xsltproc --encoding utf-8 --html convert.xsl - > "$@"

elberfelder2006.xml: $(ELBERFELDER_CHAPTERS_XML)
	./concat.sh elberfelder-bibel "Elberfelder 2006" > $@
	xmllint --noout --schema zef2005.xsd $@

menge.xml: $(MENGE_CHAPTERS_XML)
	./concat.sh menge-bibel "Menge-Bibel2" > $@
	xmllint --noout --schema zef2005.xsd $@ || (mv $@ $@.fail; exit 1)

%.zip: %.xml
	zip $@ $<

clean:
	rm -f $(ELBERFELDER_CHAPTERS_XML) $(MENGE_CHAPTERS_XML)
	rm -f elberfelder2006.{xml,zip} menge.{xml,zip}