yatex
view makefile @ 253:90aa4b6d96e1
Add note on auto-rerun.
author | HIROSE Yuuji <yuuji@gentei.org> |
---|---|
date | Sat, 11 Feb 2012 23:40:33 +0900 |
parents | 03f7349a6223 |
children | d467c0fb6083 |
line source
1 #
2 # Makefile for YaTeX/yahtml
3 #
5 # Edit these variables to be suitable for your site
6 PREFIX = /usr/local
8 ## mule2
9 #EMACS = mule
10 #EMACSDIR= ${PREFIX}/lib/${EMACS}
11 ## emacs20 or later
12 EMACS = emacs
13 EMACSDIR= ${PREFIX}/share/${EMACS}
14 ## XEmacs
15 #EMACS = xemacs
16 #EMACSDIR= ${PREFIX}/lib/${EMACS}
17 ## Meadow (Sample)
18 #EMACS = meadow
19 #EMACSDIR = c:/usr/local/meadow
20 ## CarbonEmacs on Darwin (Sample)
21 #EMACS = /Applications/Emacs.app/Contents/MacOS/Emacs
22 #PREFIX = /Applications/Emacs.app/Contents/Resources
23 #EMACSDIR = ${PREFIX}
25 LISPDIR = ${EMACSDIR}/site-lisp/yatex
26 # LISPDIR = ${EMACSDIR}/site-packages/lisp/yatex
27 DOCDIR = ${LISPDIR}/docs
28 HELPDIR = ${EMACSDIR}/site-lisp
29 INFODIR = ${PREFIX}/info
31 TAR = tar
32 INSTALL = install -c -m 444
33 MKDIR = mkdir -p
34 INSTINFO= install-info
37 # Comment out below if you are using Emacs Windows(meadow, etc)
38 GEO = -geometry 80x20+0+0
40 ###################
41 # Do not edit below
42 ###################
43 # make install to install YaTeX into public space
44 # make install-nw same as above, but -nw mode, or Emacs18(Nemacs)
45 # make ajimi to feel taste
46 # make ajimi-nw same as above, but -nw mode
47 # make package to create package for relase
48 # make yahtmlpack to create package for relase
49 # make clean to delete all producted files
50 # make ci to check in all
51 # make co to check out all
52 MVER = 1.75
53 LISP = ${LISP18} ${LISP19}
54 YAHTML = yahtml.el
55 COMMON = yatexlib.el yatexprc.el
56 LISP18 = comment.el yatex.el yatexadd.el yatexgen.el yatexenv.el \
57 ${COMMON} \
58 yatexmth.el yatexhks.el yatexhlp.el \
59 yatexm-o.el yatexsec.el yatexhie.el yatexpkg.el ${YAHTML}
60 LISP19 = yatex19.el
61 DOCS = ${DOCSRC} ${DOCOBJ} ${NEWS}
62 NEWS = yatex.new
63 DOCHTML = docs/htmlqa docs/htmlqa.eng docs/yahtmlj.tex docs/yahtmle.tex
64 DOCSRC = docs/yatexj.tex docs/yatexe.tex \
65 docs/yatex.ref docs/yatexref.eng \
66 docs/yatexadd.doc docs/yatexgen.doc \
67 docs/qanda docs/qanda.eng ${DOCHTML}
68 DOCOBJ = docs/yatexj docs/yatexe docs/yahtmlj docs/yahtmle
69 HELP = help/YATEXHLP.jp help/YATEXHLP.eng
70 MANIFEST= manifest
71 EXTRA = dir install 00readme makefile readme.meadow.j newpage.rb
72 DISTRIB = ${EXTRA} ${LISP} ${DOCS} ${MANIFEST} ${HELP}
73 RCSFILE = ${LISP} ${NEWS} ${DOCSRC} ${HELP}
74 YAHTMLLISP = ${YAHTML} ${COMMON}
75 YAHTMLDIST = ${YAHTMLLISP} install 00readme makefile newpage.rb
76 PACK = `ls ${DISTRIB}`
77 TMPDIR = /tmp
78 VERSION = `head yatex.el|awk '/rev\./{print $$4}'`
79 PACKDIR = ${TMPDIR}/yatex${VERSION}
81 all:
82 @echo "Edit this makefile first."
83 @echo 'Type "make install" to install YaTeX.'
84 @echo 'Type "make install-yahtml" to install yahtml.'
85 @echo 'If you cling to elc files. type "make elc" before make install'
86 # @echo "If you don't use X-clinet of Emacs,"
87 # @echo 'type "make install-nw" instead.'
89 install: install-real
90 #install-yahtml: bytecompile-yahtml
91 install-yahtml:
92 [ -d ${LISPDIR} ] || mkdir ${LISPDIR}
93 for f in *.el; do \
94 rm -f ${LISPDIR}/$${f}c; \
95 done
97 ${INSTALL} *.el* ${LISPDIR}
99 install-real:
100 if [ ! -d ${LISPDIR} ]; then ${MKDIR} ${LISPDIR}; fi
101 if [ ! -d ${DOCDIR} ]; then ${MKDIR} ${DOCDIR}; fi
102 if [ ! -d ${INFODIR} ]; then ${MKDIR} ${INFODIR}; fi
103 for f in *.el; do \
104 rm -f ${LISPDIR}/$${f}c; \
105 done
106 ${INSTALL} *.el* ${NEWS} ${LISPDIR}
107 ${INSTALL} ${DOCSRC} ${DOCDIR}
108 ${INSTALL} ${DOCOBJ} ${INFODIR}
109 ${INSTALL} ${HELP} ${HELPDIR}
110 @echo "--------------------------------"
111 @echo "If you have install-info command, type 'make install-info'."
112 @echo "If not, add next lines into your site's info dir manually."
113 @cat dir
115 install-info:
116 for f in ${DOCOBJ}; do \
117 b=`basename $$f | sed 's,/.*,,'`; \
118 ${INSTINFO} --entry="`grep $$b dir`" --section=TeX \
119 --section=Emacs $${f} ${INFODIR}/dir; \
120 done
122 install-nw: bytecompile-nw install-real
124 elc: bytecompile
126 bytecompile: lp
127 if [ "$$DISPLAY"x = ""x ]; then \
128 echo "Set DISPLAY environment variable!!"; exit 1; fi
129 ${EMACS} -q ${GEO} -l ./yatexlib.el -e bcf-and-exit ${LISP}
131 bytecompile-nw: lp1
132 ${EMACS} -batch -l ./yatexlib.el -e batch-byte-compile ${LISP18}
134 bytecompile-yahtml:
135 if [ "$$DISPLAY"x = ""x ]; then \
136 echo "Set DISPLAY environment variable!!"; exit 1; fi
137 ${EMACS} -q -g 80x20+0+0 -l ./yatexlib.el -e bcf-and-exit ${YAHTMLLISP}
139 lp:
140 echo '(setq load-path (cons "." load-path))' > lp.el
141 echo '(load-file "./yatexlib.el")' >>lp.el
143 lp1: lp
144 echo '(load-file "./yatex.el")' >>lp.el
145 echo '(load-file "./comment.el")' >>lp.el
147 lp2:
148 echo '(setq load-path (cons "'`pwd`'" load-path))' >>lp.el
149 echo '(setq auto-mode-alist' >>lp.el
150 echo '(cons (cons "\\.tex" '"'yatex-mode) auto-mode-alist))" >>lp.el
151 echo '(load-library "yatex")' >>lp.el
153 ajimi: lp lp2
154 ${EMACS} -l ./lp.el -e yatex-mode
156 ajimi-nw: lp lp2
157 ${EMACS} -nw -l ./lp.el -e yatex-mode
159 clean:
160 rm -f *.elc *~ lp.el
162 info: docs/yatexj docs/yatexe docs/yahtmlj docs/yahtmle
164 docs/yatexj: docs/yatexj.tex
165 (cd docs; ${EMACS} -batch -l ../yatexlib.el -e tfb-and-exit yatexj.tex)
167 docs/yatexe: docs/yatexe.tex
168 (cd docs; ${EMACS} -batch -l ../yatexlib.el -e tfb-and-exit yatexe.tex)
170 docs/yahtmlj: docs/yahtmlj.tex
171 (cd docs;${EMACS} -batch -l ../yatexlib.el -e tfb-and-exit yahtmlj.tex)
173 docs/yahtmle: docs/yahtmle.tex
174 (cd docs;${EMACS} -batch -l ../yatexlib.el -e tfb-and-exit yahtmle.tex)
176 package: info
177 @-mkdir ${PACKDIR}
178 @tar cf - ${PACK} | (cd ${PACKDIR}; tar xf -)
179 ( version=${VERSION}; cd ${TMPDIR}; \
180 ${TAR} vzcf ${TMPDIR}/yatex$$version.tar.gz yatex$$version)
182 yahtmlpack:
183 @-mkdir ${PACKDIR}
184 @tar cf - ${YAHTMLDIST} | (cd ${PACKDIR}; tar xf -)
185 ( version=${VERSION}; cd ${TMPDIR}; \
186 ${TAR} vzcf ${TMPDIR}/yahtml$$version.tar.gz yatex$$version)
188 ci:
189 ci -r${VERSION} -sRel -f ${RCSFILE}
190 ci -u${VERSION} makefile 00readme
192 co:
193 co ${RCSFILE}
195 co-l:
196 co -l ${RCSFILE}
198 tci:
199 ci -l${VERSION}.0 -Ncurrent ${RCSFILE} makefile
201 dostci:
202 ci -l${MVER}.0 -Ncurrent @rcsfile
204 gohome:
205 zip -u -r /com/okoma/yuuji/tmp/dosconv/yatex.zip . \
206 -x '*RCS/*' -x 'texinfo/*'
208 RSYNCDIR = ${HOME}/http/yatex/rsync/yatex
209 #sync:
210 # @-mkdir ${PACKDIR}
211 # @tar cf - ${PACK} | (cd ${PACKDIR}; tar xf -)
212 # syncdir -A -x CVS ${PACKDIR} ${RSYNCDIR}
213 # (cd ${RSYNCDIR}; cvs ci -m '')
214 # rm -rf ${PACKDIR}