source: trunk/SRC/Documentation/xmldoc/makefile @ 420

Last change on this file since 420 was 416, checked in by pinsard, 15 years ago

remove most of wiki pages

  • Property svn:keywords set to Id
File size: 11.5 KB
Line 
1#
2# module
3# ======
4#
5# generation of documentations from XML files (and some IDL files) in HTML and
6# wiki forms
7#
8# FILES
9# =====
10#
11# /Users/fplod/SAXO_DIR_ws/SRC/Documentation/xmldoc/makefile sur aedon.locean-ipsl.upmc.fr
12#
13# EVOLUTIONS
14# ==========
15#
16# $Id$
17#
18# - fplod 20091118T112140Z aedon.locean-ipsl.upmc.fr (Darwin)
19#
20# - fplod 20091118T111913Z aedon.locean-ipsl.upmc.fr (Darwin)
21#
22#   * because of ugly wiki pages, remove all wiki pages except WikiStart
23#     Links are on HTML documents
24#
25# - fplod 20091106T151022Z aedon.locean-ipsl.upmc.fr (Darwin)
26#
27#   * no more titlepage.saxo.xml usage
28#
29# - fplod 20091106T143104Z aedon.locean-ipsl.upmc.fr (Darwin)
30#
31#   * better usage of $<
32#
33# - fplod 2008-04-16T10:06:39Z aedon.locean-ipsl.upmc.fr (Darwin)
34# working on wiki production using
35# http://xmlstar.sourceforge.net/doc/UG/xmlstarlet-ug.html
36# fplod 2008-04-15T15:37:59Z aedon.locean-ipsl.upmc.fr (Darwin)
37# java is not ok now :
38# http://docbook.sourceforge.net/release/xsl/current/html/docbook.xsl; Ligne #53; Colonne #35; XSLT Error (javax.xml.transform.TransformerConfigurationException): javax.xml.transform.TransformerException: javax.xml.transform.TransformerException: Had IO Exception with stylesheet file: keywords.xsl
39# replaced by xsltproc which is now ok for callouts
40# fplod 2008-04-15T08:10:09Z aedon.locean-ipsl.upmc.fr (Darwin)
41# add xml validation using xmlstarlet
42# fplod 2007-06-27T10:07:59Z aedon.locean-ipsl.upmc.fr (Darwin)
43# creation in order to replace makehtml.sh
44#
45PRODUCT = \
46saxo
47
48DIRBASE = \
49./
50
51DIRSRC = \
52$(DIRBASE)
53
54DIRTMP = \
55./
56
57DIRWWW = \
58./
59
60DIRWIKI = \
61./wiki/
62
63.PHONY : \
64all \
65clean \
66dbkcheck \
67help \
68html \
69tracwiki
70
71help :
72        @echo "\$$ make clean"
73        @echo "\$$ make all"
74        @echo "\$$ make dbkcheck"
75        @echo "++ check link"
76        @echo "++ depot html et wiki"
77
78clean :
79        -@rm -f $(DIRTMP)/*_full.xml
80        -@rm -f $(DIRTMP)/err_xmlstarlet_xsd
81        -@rm -f $(DIRTMP)/rowscm.xml
82        -@rm -f $(DIRTMP)/rowskwd.xml
83        -@rm -f $(DIRTMP)/all_plots.xml
84        -@rm -f $(DIRTMP)/getsaxo_sed.xml
85        -@rm -f $(DIRTMP)/firststeps_sed.xml
86
87dbkcheck :
88        @-rm $(DIRTMP)/err_xmlstarlet_xsd 2> /dev/null
89        @for file in $(DIRTMP)/*_full.xml $(DIRTMP)/all_plots.xml; do \
90        xml val --err \
91        --xsd http://www.docbook.org/xml/5.0/xsd/docbook.xsd \
92        $${file} 1>> $(DIRTMP)/err_xmlstarlet_xsd 2>&1; done
93        @echo "check for valid diag for each file in $(DIRTMP)/err_xmlstarlet_xsd"
94
95all : \
96html \
97tracwiki
98
99html : \
100$(DIRWWW)/svnbasiccommands.html \
101$(DIRWWW)/getsaxo.html \
102$(DIRWWW)/websaxo.html \
103$(DIRWWW)/whatsnew.html \
104$(DIRWWW)/updatesaxo.html \
105$(DIRWWW)/whatissaxo.html \
106$(DIRWWW)/faqsaxo.html \
107$(DIRWWW)/infoupdatekwd.html \
108$(DIRWWW)/infoupdatecm.html \
109$(DIRWWW)/mailing.html \
110$(DIRWWW)/tiplink.html \
111$(DIRWWW)/mini_notice.html \
112$(DIRWWW)/firststeps.html \
113$(DIRWWW)/all_plots.html
114
115tracwiki : \
116$(DIRWIKI)/WikiStart
117        @echo "Do not forget to import wiki pages"
118        @echo "\$$ ssh $(PRODUCT)@forge.ipsl.jussieu.fr mkdir -p /tmp/$(PRODUCT)/"
119        @echo "\$$ rsync -av --exclude=".DS_Store" --exclude=".svn" $(DIRWIKI) $(PRODUCT)@forge.ipsl.jussieu.fr:/tmp/$(PRODUCT)/"
120        @echo "\$$ ssh $(PRODUCT)@forge.ipsl.jussieu.fr trac-admin /ipsl/forge/projets/$(PRODUCT)/trac wiki load /tmp/$(PRODUCT)/"
121
122        @echo "\$$ ssh $(PRODUCT)@forge.ipsl.jussieu.fr rmdir -f /tmp/$(PRODUCT)/"
123
124$(DIRWIKI)/WikiStart : \
125$(DIRTMP)/websaxo_full.xml \
126$(DIRSRC)/saxo_tracwiki.xsl \
127$(DIRSRC)/linkwiki.sed
128        @xsltproc \
129        $(DIRSRC)/saxo_tracwiki.xsl \
130        $< | \
131        sed -f $(DIRSRC)/linkwiki.sed | \
132        awk 'sub(/ @star@ $$/,""){printf(" * %s", $$0);next};1' | \
133        sed -e "s+@star@+ *+" \
134        > $@
135
136$(DIRWWW)/websaxo.html : \
137$(DIRTMP)/websaxo_full.xml \
138$(DIRSRC)/saxo_html.xsl \
139$(DIRSRC)/style.css \
140$(DIRSRC)/$(PRODUCT).css
141        @xsltproc \
142        --param html.stylesheet "'style.css $(PRODUCT).css'" \
143        --param css.decoration 1 \
144        --param link.mailto.url "'mailto:saxo-dev_at_forge.ipsl.jussieu.fr'" \
145        --param section.autolabel 1 \
146        --output $@ \
147        $(DIRSRC)/saxo_html.xsl \
148        $<
149
150$(DIRTMP)/websaxo_full.xml : \
151$(DIRSRC)/websaxo.xml
152        @xmllint \
153        --xinclude \
154        --encode utf-8 \
155        --noent \
156        --output $@ \
157        $<
158
159$(DIRWWW)/svnbasiccommands.html : \
160$(DIRTMP)/svnbasiccommands_full.xml \
161$(DIRSRC)/saxo_html.xsl \
162$(DIRSRC)/style.css \
163$(DIRSRC)/$(PRODUCT).css
164        @xsltproc \
165        --param html.stylesheet "'style.css $(PRODUCT).css'" \
166        --param css.decoration 1 \
167        --param link.mailto.url "'mailto:saxo-dev_at_forge.ipsl.jussieu.fr'" \
168        --param section.autolabel 1 \
169        --output $@ \
170        $(DIRSRC)/saxo_html.xsl \
171        $<
172
173$(DIRTMP)/svnbasiccommands_full.xml : \
174$(DIRSRC)/svnbasiccommands.xml
175        @xmllint \
176        --xinclude \
177        --encode utf-8 \
178        --noent \
179        --output $@ \
180        $<
181
182$(DIRWWW)/faqsaxo.html : \
183$(DIRTMP)/faqsaxo_full.xml \
184$(DIRSRC)/saxo_html.xsl \
185$(DIRSRC)/style.css \
186$(DIRSRC)/$(PRODUCT).css
187        @xsltproc \
188        --param html.stylesheet "'style.css $(PRODUCT).css'" \
189        --param css.decoration 1 \
190        --param link.mailto.url "'mailto:saxo-dev_at_forge.ipsl.jussieu.fr'" \
191        --param section.autolabel 1 \
192        --output $@ \
193        $(DIRSRC)/saxo_html.xsl \
194        $<
195
196$(DIRTMP)/faqsaxo_full.xml : \
197$(DIRSRC)/faqsaxo.xml
198        @xmllint \
199        --xinclude \
200        --encode utf-8 \
201        --noent \
202        --output $@ \
203        $<
204
205$(DIRWWW)/getsaxo.html : \
206$(DIRTMP)/getsaxo_full.xml \
207$(DIRSRC)/saxo_html.xsl \
208$(DIRSRC)/style.css \
209$(DIRSRC)/$(PRODUCT).css
210        @xsltproc \
211        --param html.stylesheet "'style.css $(PRODUCT).css'" \
212        --param css.decoration 1 \
213        --param link.mailto.url "'mailto:saxo-dev_at_forge.ipsl.jussieu.fr'" \
214        --param section.autolabel 1 \
215        --output $@ \
216        $(DIRSRC)/saxo_html.xsl \
217        $<
218
219$(DIRTMP)/getsaxo_sed.xml : \
220$(DIRSRC)/getsaxo.xml \
221$(DIRSRC)/getsaxo_pre.sh
222        @$(DIRSRC)/getsaxo_pre.sh
223
224$(DIRTMP)/getsaxo_full.xml : \
225$(DIRTMP)/getsaxo_sed.xml
226        @xmllint \
227        --xinclude \
228        --encode utf-8 \
229        --noent \
230        --output $@ \
231        $<
232
233$(DIRWWW)/firststeps.html : \
234$(DIRTMP)/firststeps_full.xml \
235$(DIRSRC)/saxo_html.xsl \
236$(DIRSRC)/style.css \
237$(DIRSRC)/$(PRODUCT).css
238        @xsltproc \
239        --param html.stylesheet "'style.css $(PRODUCT).css'" \
240        --param css.decoration 1 \
241        --param link.mailto.url "'mailto:saxo-dev_at_forge.ipsl.jussieu.fr'" \
242        --param section.autolabel 1 \
243        --output $@ \
244        $(DIRSRC)/saxo_html.xsl \
245        $<
246
247$(DIRWWW)/all_plots.html : \
248$(DIRTMP)/all_plots.xml \
249$(DIRSRC)/saxo_html.xsl \
250$(DIRSRC)/style.css \
251$(DIRSRC)/$(PRODUCT).css
252        @xsltproc \
253        --param html.stylesheet "'style.css $(PRODUCT).css'" \
254        --param css.decoration 1 \
255        --param link.mailto.url "'mailto:saxo-dev_at_forge.ipsl.jussieu.fr'" \
256        --param section.autolabel 1 \
257        --output $@ \
258        $(DIRSRC)/saxo_html.xsl \
259        $<
260
261
262$(DIRTMP)/all_plots.xml : \
263$(DIRTMP)/firststeps_full.xml \
264$(DIRSRC)/all_plots_docbook.xsl
265        @xsltproc \
266        --output $@ \
267        $(DIRSRC)/all_plots_docbook.xsl \
268        $<
269
270$(DIRTMP)/firststeps_sed.xml : \
271$(DIRSRC)/firststeps_pre.sh \
272$(DIRSRC)/firststeps.xml
273        @$(DIRSRC)/firststeps_pre.sh
274
275$(DIRTMP)/firststeps_full.xml : \
276$(DIRTMP)/firststeps_sed.xml
277        @xmllint \
278        --xinclude \
279        --encode utf-8 \
280        --noent \
281        --output $@ \
282        $<
283
284$(DIRWWW)/mailing.html : \
285$(DIRTMP)/mailing_full.xml \
286$(DIRSRC)/saxo_html.xsl \
287$(DIRSRC)/style.css \
288$(DIRSRC)/$(PRODUCT).css
289        @xsltproc \
290        --param html.stylesheet "'style.css $(PRODUCT).css'" \
291        --param css.decoration 1 \
292        --param link.mailto.url "'mailto:saxo-dev_at_forge.ipsl.jussieu.fr'" \
293        --param section.autolabel 1 \
294        --output $@ \
295        $(DIRSRC)/saxo_html.xsl \
296        $<
297
298$(DIRTMP)/mailing_full.xml : \
299$(DIRSRC)/mailing.xml
300        @xmllint \
301        --xinclude \
302        --encode utf-8 \
303        --noent \
304        --output $@ \
305        $<
306
307$(DIRWWW)/mini_notice.html : \
308$(DIRTMP)/mini_notice_full.xml \
309$(DIRSRC)/saxo_html.xsl \
310$(DIRSRC)/style.css \
311$(DIRSRC)/$(PRODUCT).css
312        @xsltproc \
313        --param html.stylesheet "'style.css $(PRODUCT).css'" \
314        --param css.decoration 1 \
315        --param link.mailto.url "'mailto:saxo-dev_at_forge.ipsl.jussieu.fr'" \
316        --param section.autolabel 1 \
317        --output $@ \
318        $(DIRSRC)/saxo_html.xsl \
319        $<
320
321$(DIRTMP)/mini_notice_full.xml : \
322$(DIRSRC)/mini_notice.xml
323        @xmllint \
324        --xinclude \
325        --encode utf-8 \
326        --noent \
327        --output $@ \
328        $<
329
330$(DIRWWW)/tiplink.html : \
331$(DIRTMP)/tiplink_full.xml \
332$(DIRSRC)/saxo_html.xsl \
333$(DIRSRC)/style.css \
334$(DIRSRC)/$(PRODUCT).css
335        @xsltproc \
336        --param html.stylesheet "'style.css $(PRODUCT).css'" \
337        --param css.decoration 1 \
338        --param link.mailto.url "'mailto:saxo-dev_at_forge.ipsl.jussieu.fr'" \
339        --param section.autolabel 1 \
340        --output $@ \
341        $(DIRSRC)/saxo_html.xsl \
342        $<
343
344$(DIRTMP)/tiplink_full.xml : \
345$(DIRSRC)/tiplink.xml
346        @xmllint \
347        --xinclude \
348        --encode utf-8 \
349        --noent \
350        --output $@ \
351        $<
352
353$(DIRWWW)/infoupdatecm.html : \
354$(DIRTMP)/infoupdatecm_full.xml \
355$(DIRSRC)/saxo_html.xsl \
356$(DIRSRC)/style.css \
357$(DIRSRC)/$(PRODUCT).css
358        @xsltproc \
359        --param html.stylesheet "'style.css $(PRODUCT).css'" \
360        --param css.decoration 1 \
361        --param link.mailto.url "'mailto:saxo-dev_at_forge.ipsl.jussieu.fr'" \
362        --param section.autolabel 1 \
363        --output $@ \
364        $(DIRSRC)/saxo_html.xsl \
365        $<
366
367$(DIRTMP)/infoupdatecm_full.xml : \
368$(DIRSRC)/infoupdatecm.xml \
369$(DIRTMP)/rowscm.xml
370        @xmllint \
371        --xinclude \
372        --encode utf-8 \
373        --noent \
374        --output $@ \
375        $<
376
377$(DIRWWW)/infoupdatekwd.html : \
378$(DIRTMP)/infoupdatekwd_full.xml \
379$(DIRSRC)/saxo_html.xsl \
380$(DIRSRC)/style.css \
381$(DIRSRC)/$(PRODUCT).css
382        @xsltproc \
383        --param html.stylesheet "'style.css $(PRODUCT).css'" \
384        --param css.decoration 1 \
385        --param link.mailto.url "'mailto:saxo-dev_at_forge.ipsl.jussieu.fr'" \
386        --param section.autolabel 1 \
387        --output $@ \
388        $(DIRSRC)/saxo_html.xsl \
389        $<
390
391$(DIRTMP)/infoupdatekwd_full.xml : \
392$(DIRTMP)/infoupdatekwd.xml \
393$(DIRTMP)/rowskwd.xml
394        @xmllint \
395        --xinclude \
396        --encode utf-8 \
397        --noent \
398        --output $@ \
399        $<
400
401$(DIRTMP)/rowscm.xml : \
402../../ForOldVersion/updateold.pro
403        @echo "<tbody>" > $@
404        @grep "IF NOT key_forgetold AND n_elements(\(.* = .*\)" $< | \
405        sort | \
406        sed -e "s/\(^.* THEN \)\(.*\)\( = \)\(.*\)/<row><entry colname='old'><varname>\2<\/varname><\/entry> <entry colname='new'><varname>\4<\/varname><\/entry><\/row>/" >> $@
407        @echo "</tbody>" >> $@
408
409$(DIRTMP)/rowskwd.xml : \
410../../ForOldVersion/updatekwd.pro
411        @echo "<tbody>" > $@
412        @grep "^  old = \[old, .* new = \[new" $< | \
413        sort | \
414        sed -e "s/\( old = \[old, '\)\(.*\)\('\] *& new = \[new, '\)\(.*\)\('\]\)/<row><entry colname='old'><varname>\2<\/varname><\/entry> <entry colname='new'><varname>\4<\/varname><\/entry><\/row>/" >> $@
415
416        @echo "</tbody>" >> $@
417
418$(DIRWWW)/whatissaxo.html : \
419$(DIRTMP)/whatissaxo_full.xml \
420$(DIRSRC)/saxo_html.xsl \
421$(DIRSRC)/style.css \
422$(DIRSRC)/$(PRODUCT).css
423        @xsltproc \
424        --param html.stylesheet "'style.css $(PRODUCT).css'" \
425        --param css.decoration 1 \
426        --param link.mailto.url "'mailto:saxo-dev_at_forge.ipsl.jussieu.fr'" \
427        --param section.autolabel 1 \
428        --output $@ \
429        $(DIRSRC)/saxo_html.xsl \
430        $<
431
432$(DIRTMP)/whatissaxo_full.xml : \
433$(DIRSRC)/whatissaxo.xml
434        @xmllint \
435        --xinclude \
436        --encode utf-8 \
437        --noent \
438        --output $@ \
439        $<
440
441$(DIRWWW)/whatsnew.html : \
442$(DIRTMP)/whatsnew_full.xml \
443$(DIRSRC)/saxo_html.xsl \
444$(DIRSRC)/style.css \
445$(DIRSRC)/$(PRODUCT).css
446        @xsltproc \
447        --param html.stylesheet "'style.css $(PRODUCT).css'" \
448        --param css.decoration 1 \
449        --param link.mailto.url "'mailto:saxo-dev_at_forge.ipsl.jussieu.fr'" \
450        --param section.autolabel 1 \
451        --output $@ \
452        $(DIRSRC)/saxo_html.xsl \
453        $<
454       
455$(DIRTMP)/whatsnew_full.xml : \
456$(DIRSRC)/whatsnew.xml
457        @xmllint \
458        --xinclude \
459        --encode utf-8 \
460        --noent \
461        --output $@ \
462        $<
463
464$(DIRWWW)/updatesaxo.html : \
465$(DIRTMP)/updatesaxo_full.xml \
466$(DIRSRC)/saxo_html.xsl \
467$(DIRSRC)/style.css \
468$(DIRSRC)/$(PRODUCT).css
469        @xsltproc \
470        --param html.stylesheet "'style.css $(PRODUCT).css'" \
471        --param css.decoration 1 \
472        --param link.mailto.url "'mailto:saxo-dev_at_forge.ipsl.jussieu.fr'" \
473        --param section.autolabel 1 \
474        --output $@ \
475        $(DIRSRC)/saxo_html.xsl \
476        $<
477       
478$(DIRTMP)/updatesaxo_full.xml : \
479$(DIRSRC)/updatesaxo.xml
480        @xmllint \
481        --xinclude \
482        --encode utf-8 \
483        --noent \
484        --output $@ \
485        $<
Note: See TracBrowser for help on using the repository browser.