source: branches/2.06/documentation/Makefile @ 326

Last change on this file since 326 was 326, checked in by bcornec, 14 years ago

Build process fo documentation

File size: 1.4 KB
Line 
1TARGET=mondorescue-howto
2SRC=$(shell ls *.sgml)
3DSL=$(TARGET).dsl
4IMAGES=$(shell ls images/*.png)
5
6all: $(TARGET).ps $(TARGET).pdf $(TARGET)/index.html $(TARGET).txt $(TARGET).html
7       
8$(TARGET).tex: $(SRC) $(IMAGES) $(DSL)
9    openjade -t tex -d $(TARGET).dsl'#print' -o $(TARGET).tex $(TARGET).sgml
10
11$(TARGET).txt: $(TARGET).html
12    lynx -dump -force_html $(TARGET).html > $(TARGET).txt
13
14$(TARGET).ps: $(TARGET).tex
15    hugelatex --interaction nonstopmode -fmt=jadetex -mltex $(TARGET).tex
16    hugelatex --interaction nonstopmode -fmt=jadetex -mltex $(TARGET).tex
17    hugelatex --interaction nonstopmode -fmt=jadetex -mltex $(TARGET).tex
18    mv $(TARGET).tex.dvi $(TARGET).dvi
19    dvips -o $(TARGET).ps $(TARGET).dvi
20
21$(TARGET)/index.html: $(SRC) $(DSL) $(IMAGES)
22    mkdir -p $(TARGET)
23    cd $(TARGET)
24    openjade -t sgml -d ../$(TARGET).dsl'#html' ../$(TARGET).sgml
25    cd ..
26
27$(TARGET).html: $(SRC) $(DSL) $(IMAGES)
28    openjade -t sgml -d ../$(TARGET).dsl'#txt' ../$(TARGET).sgml
29   
30$(TARGET)pdf.tex: $(SRC) $(IMAGES) $(DSL)
31    openjade -t tex -d $(TARGET).dsl'#pdf' -o $(TARGET)pdf.tex $(TARGET).sgml
32
33$(TARGET).pdf: $(TARGET)pdf.tex
34    hugepdflatex --interaction nonstopmode -fmt=pdfjadetex -mltex $(TARGET)pdf.tex
35    hugepdflatex --interaction nonstopmode -fmt=pdfjadetex -mltex $(TARGET)pdf.tex
36    hugepdflatex --interaction nonstopmode -fmt=pdfjadetex -mltex $(TARGET)pdf.tex
37    mv $(TARGET)pdf.tex.pdf $(TARGET).pdf
38
39clean: 
40    rm -fr $(TARGET).{aux,log,out,tex,dvi,pdf,ps,txt} $(TARGET)
Note: See TracBrowser for help on using the repository browser.