source: projects/Vine-manual/trunk/Makefile @ 137

Revision 137, 3.2 KB checked in by yasumichi, 15 years ago (diff)

devide from users-manual to cui-guide and desktop-guide.

Line 
1NAME=Vine-manual
2VERSION=`date +'%Y%m%d'`
3SOURCES=index cui-guide desktop-guide making-rpm getinfo
4#SOURCES=preface install-vine login vine-lprng vine-cups ppxp-quickstart \
5#       XWindow utils server using_rpm kernel-upgrade \
6#       FAQ package license Mozilla xim synaptic making-rpm
7
8#DeskTop QuickStart WindowMaker freebsd-license information
9
10
11REST_SOURCES=freebsd-license
12XMLS=$(addsuffix .xml, $(SOURCES))
13OTXTS=$(addsuffix .txt, $(SOURCES))
14TXTS=$(addsuffix .euc, $(SOURCES)) $(addsuffix .sjis, $(SOURCES))
15HTMLS=$(addsuffix .html, $(SOURCES))
16OHTMLS=$(addsuffix *.html, $(SOURCES))
17TEXS=$(addsuffix .tex, $(SOURCES))
18DVIS=$(addsuffix .dvi, $(SOURCES))
19PSS=$(addsuffix .ps, $(SOURCES))
20
21DESTDIR=
22DOCDIR=/usr/share/doc/Vine
23
24.SUFFIXES: .txt .html .euc .sjis .tex .dvi .ps .xml
25
26.xml.txt:
27        xsltproc /usr/share/sgml/docbook/xsl-stylesheets/html/docbook.xsl $< | w3m -T text/html -dump > $@
28
29.xml.html:
30        #xsltproc -stringparam chunker.output.encoding euc-jp -stringparam chunker.output.indent yes custom.xsl $<
31        xsltproc -stringparam chunker.output.indent yes custom.xsl $<
32
33.txt.euc:
34        nkf -e $< > $@
35
36.txt.sjis:
37        nkf -cs $< > $@
38
39.sgml.tex:
40        sgml2latex $<
41
42%.dvi: %.tex
43
44.tex.dvi:
45        jlatex $<
46        jlatex $<
47        jlatex $<
48        rm -f $(basename $<).{aux,log,toc}
49
50.dvi.ps:
51        dvips $<
52
53all: txt html
54
55txt: $(TXTS)
56
57html: $(HTMLS)
58
59ps: $(PSS)
60
61dvi: $(DVIS)
62
63tex: $(TEXS)
64
65clean:
66        rm -f *.{sjis,euc,tex,log,aux,dvi,toc,ps,html} *~
67
68dist: clean
69        cd .. && rm -rf ${NAME}-${VERSION}
70        cd .. && cp -arf ${NAME} ${NAME}-${VERSION}
71        cd .. && tar cf - --exclude CVS ${NAME}-${VERSION} | bzip2 -9 > ${NAME}-${VERSION}.tar.bz2
72        cd .. && rm -rf ${NAME}-${VERSION}
73
74install: all install-online
75
76install-online:
77        install -d ${DESTDIR}${DOCDIR}
78        install -d ${DESTDIR}${DOCDIR}/manuals-sjis
79        install -d ${DESTDIR}${DOCDIR}/manuals-euc
80        install -m 644 *.html ${DESTDIR}${DOCDIR}
81        install -m 644 *.css ${DESTDIR}${DOCDIR}
82        install -m 644 *.sjis ${DESTDIR}${DOCDIR}/manuals-sjis/
83        install -m 644 *.euc ${DESTDIR}${DOCDIR}/manuals-euc/
84        install -d ${DESTDIR}${DOCDIR}/images
85        install -m 644 images/*.png ${DESTDIR}${DOCDIR}/images/
86        #install -d ${DESTDIR}${DOCDIR}/images/callouts/
87        #install -m 644 images/callouts/*.png ${DESTDIR}${DOCDIR}/images/callouts/
88        #install -d ${DESTDIR}${DOCDIR}/stylesheet-images
89        #install -m 644 stylesheet-images/*.png ${DESTDIR}${DOCDIR}/manuals/stylesheet-images/
90
91install-web:
92        [ -d ${RPM_BUILD_ROOT}${HTMLDIR}/manuals ] || install -d ${RPM_BUILD_ROOT}${HTMLDIR}/manuals
93        [ -d ${RPM_BUILD_ROOT}${HTMLDIR}/manuals-sjis ] || install -d ${RPM_BUILD_ROOT}${HTMLDIR}/manuals-sjis
94        [ -d ${RPM_BUILD_ROOT}${HTMLDIR}/manuals-euc ] || install -d ${RPM_BUILD_ROOT}${HTMLDIR}/manuals-euc
95        install -m 664 *.html ${RPM_BUILD_ROOT}${HTMLDIR}/manuals
96        install -m 664 *.sjis ${RPM_BUILD_ROOT}${HTMLDIR}/manuals-sjis/
97        install -m 664 *.euc ${RPM_BUILD_ROOT}${HTMLDIR}/manuals-euc/
98        install -d ${RPM_BUILD_ROOT}${HTMLDIR}/manuals/images
99        install -m 644 images/*.png ${RPM_BUILD_ROOT}${HTMLDIR}/manuals/images/
100        #install -d ${RPM_BUILD_ROOT}${HTMLDIR}/manuals/images/callouts/
101        #install -m 644 images/callouts/*.png ${RPM_BUILD_ROOT}${HTMLDIR}/manuals/images/callouts/
102        #install -d ${RPM_BUILD_ROOT}${HTMLDIR}/manuals/stylesheet-images
103        #install -m 644 stylesheet-images/*.gif ${RPM_BUILD_ROOT}${HTMLDIR}/manuals/stylesheet-images/
104
Note: See TracBrowser for help on using the repository browser.