Minor fix
[org-mode/org-mode-NeilSmithlineMods.git] / Makefile
bloba70ac329655a92a61fec628a352551c109df09e7
1 # Makefile - for the org-mode distribution
3 # Maintainer: Carsten Dominik <dominik@science.uva.nl>
4 # Version: VERSIONTAG
6 # To install org-mode, edit the Makefile, type `make', then `make install'.
7 # To create the PDF and HTML documentation files, type `make doc'.
9 ##----------------------------------------------------------------------
10 ## YOU MUST EDIT THE FOLLOWING LINES
11 ##----------------------------------------------------------------------
13 # Name of your emacs binary
14 EMACS=emacs
16 # Where local software is found
17 prefix=/usr/local
19 # Where local lisp files go.
20 lispdir = $(prefix)/share/emacs/site-lisp
22 # Where info files go.
23 infodir = $(prefix)/share/info
25 ##----------------------------------------------------------------------
26 ## YOU MAY NEED TO EDIT THESE
27 ##----------------------------------------------------------------------
29 # Using emacs in batch mode.
31 BATCH=$(EMACS) -batch -q -no-site-file -eval \
32 "(progn (add-to-list (quote load-path) \"$(lispdir)\") (add-to-list (quote load-path) (expand-file-name \"./lisp/\")))"
34 # Specify the byte-compiler for compiling org-mode files
35 ELC= $(BATCH) -f batch-byte-compile
37 # How to make a pdf file from a texinfo file
38 TEXI2PDF = texi2pdf
40 # How to create directories
41 MKDIR = mkdir -p
43 # How to create the info files from the texinfo file
44 MAKEINFO = makeinfo
46 # How to create the HTML file
47 TEXI2HTML = makeinfo --html --number-sections
49 # How to copy the lisp files and elc files to their distination.
50 CP = cp -p
52 # Name of the program to install info files
53 INSTALL_INFO=install-info
55 ##----------------------------------------------------------------------
56 ## BELOW THIS LINE ON YOUR OWN RISK!
57 ##----------------------------------------------------------------------
59 # The following variables need to be defined by the maintainer
60 LISPF = org.el \
61 org-agenda.el \
62 org-ascii.el \
63 org-attach.el \
64 org-archive.el \
65 org-bbdb.el \
66 org-bibtex.el \
67 org-clock.el \
68 org-colview.el \
69 org-colview-xemacs.el \
70 org-compat.el \
71 org-crypt.el \
72 org-datetree.el \
73 org-exp.el \
74 org-exp-blocks.el \
75 org-docbook.el \
76 org-faces.el \
77 org-feed.el \
78 org-footnote.el \
79 org-freemind.el \
80 org-gnus.el \
81 org-habit.el \
82 org-html.el \
83 org-icalendar.el \
84 org-id.el \
85 org-indent.el \
86 org-info.el \
87 org-inlinetask.el \
88 org-jsinfo.el \
89 org-irc.el \
90 org-latex.el \
91 org-list.el \
92 org-mac-message.el \
93 org-macs.el \
94 org-mew.el \
95 org-mhe.el \
96 org-mobile.el \
97 org-mouse.el \
98 org-publish.el \
99 org-plot.el \
100 org-protocol.el \
101 org-remember.el \
102 org-rmail.el \
103 org-src.el \
104 org-table.el \
105 org-timer.el \
106 org-vm.el \
107 org-w3m.el \
108 org-wl.el \
109 org-xoxo.el
111 LISPFILES0 = $(LISPF:%=lisp/%)
112 LISPFILES = $(LISPFILES0) lisp/org-install.el
113 ELCFILES0 = $(LISPFILES0:.el=.elc)
114 ELCFILES = $(LISPFILES:.el=.elc)
115 DOCFILES = doc/org.texi doc/org.pdf doc/org doc/dir doc/.nosearch
116 CARDFILES = doc/orgcard.tex doc/orgcard.pdf doc/orgcard_letter.pdf
117 TEXIFILES = doc/org.texi
118 INFOFILES = doc/org
121 .SUFFIXES: .el .elc .texi
122 SHELL = /bin/sh
124 # Additional distribution files
125 DISTFILES_extra= Makefile ChangeLog request-assign-future.txt contrib
126 DISTFILES_xemacs= xemacs/noutline.el xemacs/ps-print-invisible.el xemacs/README
128 default: $(ELCFILES)
130 all: $(ELCFILES) $(INFOFILES)
132 up2: update
133 sudo ${MAKE} install
135 update:
136 git pull
137 ${MAKE} clean
138 ${MAKE} all
140 compile: $(ELCFILES0)
142 install: install-lisp
144 doc: doc/org.html doc/org.pdf doc/orgcard.pdf doc/orgcard_letter.pdf
147 ${MAKE} pdf && open doc/org.pdf
150 ${MAKE} card && gv doc/orgcard.ps
152 install-lisp: $(LISPFILES) $(ELCFILES)
153 if [ ! -d $(lispdir) ]; then $(MKDIR) $(lispdir); else true; fi ;
154 $(CP) $(LISPFILES) $(lispdir)
155 $(CP) $(ELCFILES) $(lispdir)
157 install-info: $(INFOFILES)
158 if [ ! -d $(infodir) ]; then $(MKDIR) $(infodir); else true; fi ;
159 $(CP) $(INFOFILES) $(infodir)
160 $(INSTALL_INFO) --info-file=$(INFOFILES) --info-dir=$(infodir)
162 install-info-debian: $(INFOFILES)
163 $(INSTALL_INFO) --infodir=$(infodir) $(INFOFILES)
165 install-noutline: xemacs/noutline.elc
166 if [ ! -d $(lispdir) ]; then $(MKDIR) $(lispdir); else true; fi ;
167 $(CP) xemacs/noutline.el xemacs/noutline.elc $(lispdir)
169 autoloads: lisp/org-install.el
171 lisp/org-install.el: $(LISPFILES0) Makefile
172 $(BATCH) --eval "(require 'autoload)" \
173 --eval '(find-file "org-install.el")' \
174 --eval '(erase-buffer)' \
175 --eval '(mapc (lambda (x) (generate-file-autoloads (symbol-name x))) (quote ($(LISPFILES0))))' \
176 --eval '(insert "\n(provide (quote org-install))\n")' \
177 --eval '(save-buffer)'
178 mv org-install.el lisp
180 xemacs/noutline.elc: xemacs/noutline.el
182 doc/org: doc/org.texi
183 (cd doc; $(MAKEINFO) --no-split org.texi -o org)
185 doc/org.pdf: doc/org.texi
186 (cd doc; $(TEXI2PDF) org.texi)
188 doc/org.html: doc/org.texi
189 (cd doc; $(TEXI2HTML) --no-split -o org.html org.texi)
190 UTILITIES/manfull.pl doc/org.html
192 doc/orgcard.dvi: doc/orgcard.tex
193 (cd doc; tex orgcard.tex)
195 doc/orgcard.pdf: doc/orgcard.dvi
196 dvips -q -f -t landscape doc/orgcard.dvi | gs -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=doc/orgcard.pdf -c .setpdfwrite -
198 doc/orgcard.ps: doc/orgcard.dvi
199 dvips -t landscape -o doc/orgcard.ps doc/orgcard.dvi
201 doc/orgcard_letter.dvi: doc/orgcard.tex
202 perl -pe 's/letterpaper=0/letterpaper=1/' doc/orgcard.tex > doc/orgcard_letter.tex
203 (cd doc; tex orgcard_letter.tex)
205 doc/orgcard_letter.pdf: doc/orgcard_letter.dvi
206 dvips -q -f -t landscape doc/orgcard_letter.dvi | gs -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=doc/orgcard_letter.pdf -c .setpdfwrite -
208 doc/orgcard_letter.ps: doc/orgcard_letter.dvi
209 dvips -t landscape -o doc/orgcard_letter.ps doc/orgcard_letter.dvi
211 # Below here are special targets for maintenance only
213 updateweb:
214 ssh cdominik@caprisun.dreamhost.com 'pull-worg-org.sh && publish-worg-org.sh'
216 html: doc/org.html
218 html_manual: doc/org.texi
219 rm -rf doc/manual
220 mkdir doc/manual
221 $(TEXI2HTML) -o doc/manual doc/org.texi
222 UTILITIES/mansplit.pl doc/manual/*.html
224 info: doc/org
226 pdf: doc/org.pdf
228 card: doc/orgcard.pdf doc/orgcard.ps doc/orgcard_letter.pdf doc/orgcard_letter.ps
230 distfile:
231 @if [ "X$(TAG)" = "X" ]; then echo "*** No tag ***"; exit 1; fi
232 touch doc/org.texi doc/orgcard.tex # force update
233 ${MAKE} cleancontrib
234 ${MAKE} info
235 ${MAKE} doc
236 ${MAKE} lisp/org-install.el
237 rm -rf org-$(TAG) org-$(TAG).zip
238 $(MKDIR) org-$(TAG)
239 $(MKDIR) org-$(TAG)/xemacs
240 $(MKDIR) org-$(TAG)/doc
241 $(MKDIR) org-$(TAG)/lisp
242 cp -r $(LISPFILES) org-$(TAG)/lisp
243 cp -r $(DOCFILES) $(CARDFILES) org-$(TAG)/doc
244 cp -r $(DISTFILES_extra) org-$(TAG)/
245 cp -r README_DIST org-$(TAG)/README
246 cp -r ORGWEBPAGE/Changes.org org-$(TAG)/
247 cp -r $(DISTFILES_xemacs) org-$(TAG)/xemacs/
248 zip -r org-$(TAG).zip org-$(TAG)
249 gtar zcvf org-$(TAG).tar.gz org-$(TAG)
251 release:
252 @if [ "X$(TAG)" = "X" ]; then echo "*** No tag ***"; exit 1; fi
253 ${MAKE} distfile
254 ${MAKE} doc
255 UTILITIES/gplmanual.pl
256 ${MAKE} html_manual
257 rm -rf RELEASEDIR
258 $(MKDIR) RELEASEDIR
259 cp org-$(TAG).zip org-$(TAG).tar.gz RELEASEDIR
260 cp doc/org.pdf doc/orgcard.pdf doc/org.texi doc/org.html RELEASEDIR
261 cp RELEASEDIR/org-$(TAG).zip RELEASEDIR/org.zip
262 cp RELEASEDIR/org-$(TAG).tar.gz RELEASEDIR/org.tar.gz
264 upload_release:
265 rsync -avuz RELEASEDIR/ cdominik@orgmode.org:orgmode.org/
267 upload_manual:
268 rsync -avuz --delete doc/manual/ cdominik@orgmode.org:orgmode.org/manual/
270 relup0:
271 ${MAKE} release
272 ${MAKE} upload_release
274 relup:
275 ${MAKE} release
276 ${MAKE} upload_release
277 ${MAKE} upload_manual
280 grep -e '(debug)' lisp/*el
282 cleancontrib:
283 find contrib -name \*~ -exec rm {} \;
285 cleanelc:
286 rm -f $(ELCFILES)
287 cleandoc:
288 (cd doc; rm -f org.pdf org org.html orgcard.pdf orgcard.ps)
289 (cd doc; rm -f *.aux *.cp *.cps *.dvi *.fn *.fns *.ky *.kys *.pg *.pgs)
290 (cd doc; rm -f *.toc *.tp *.tps *.vr *.vrs *.log *.html *.ps)
291 (cd doc; rm -f orgcard_letter.tex orgcard_letter.pdf)
292 (cd doc; rm -rf manual)
294 cleanrel:
295 rm -rf RELEASEDIR
296 rm -rf org-6.*
297 rm -rf org-6*zip org-6*tar.gz
299 clean:
300 ${MAKE} cleanelc
301 ${MAKE} cleandoc
302 ${MAKE} cleanrel
303 rm -f *~ */*~ */*/*~
305 cleanall:
306 ${MAKE} clean
307 rm -f lisp/org-install.el
309 .el.elc:
310 $(ELC) $<
313 push:
314 git-push git+ssh://repo.or.cz/srv/git/org-mode.git master
316 pushtag:
317 git-tag -m "Adding tag" -a $(TAG)
318 git-push git+ssh://repo.or.cz/srv/git/org-mode.git $(TAG)
320 pushreleasetag:
321 git-tag -m "Adding release tag" -a release_$(TAG)
322 git-push git+ssh://repo.or.cz/srv/git/org-mode.git release_$(TAG)
324 dummy:
325 echo ${prefix}
327 # Dependencies
329 lisp/org.elc: lisp/org-macs.el lisp/org-compat.el lisp/org-faces.el
330 lisp/org-agenda.elc: lisp/org.el
331 lisp/org-ascii.elc: lisp/org-exp.el
332 lisp/org-attach.elc: lisp/org.el lisp/org-id.el
333 lisp/org-archive.elc: lisp/org.el
334 lisp/org-bbdb.elc: lisp/org.el
335 lisp/org-bibtex.elc: lisp/org.el
336 lisp/org-clock.elc: lisp/org.el
337 lisp/org-colview.elc: lisp/org.el
338 lisp/org-colview-xemacs.elc: lisp/org.el
339 lisp/org-compat.elc: lisp/org-macs.el
340 lisp/org-crypt.elc: lisp/org-crypt.el lisp/org.el
341 lisp/org-datetree.elc: lisp/org.el
342 lisp/org-exp.elc: lisp/org.el lisp/org-agenda.el
343 lisp/org-exp-blocks.elc: lisp/org.el
344 lisp/org-latex.elc: lisp/org.el lisp/org-exp.el
345 lisp/org-docbook.elc: lisp/org.el lisp/org-exp.el
346 lisp/org-faces.elc: lisp/org-macs.el lisp/org-compat.el
347 lisp/org-feed.elc: lisp/org.el
348 lisp/org-footnotes.elc: lisp/org-macs.el lisp/org-compat.el
349 lisp/org-freemind.elc: lisp/org.el
350 lisp/org-gnus.elc: lisp/org.el
351 lisp/org-html.elc: lisp/org-exp.el
352 lisp/org-habit.elc: lisp/org.el lisp/org-agenda.el
353 lisp/org-icalendar.elc: lisp/org-exp.el
354 lisp/org-id.elc: lisp/org.el
355 lisp/org-indent.elc: lisp/org.el lisp/org-macs.el lisp/org-compat.el
356 lisp/org-info.elc: lisp/org.el
357 lisp/org-inlinetask.elc:
358 lisp/org-irc.elc: lisp/org.el
359 lisp/org-jsinfo.elc: lisp/org.el lisp/org-exp.el
360 lisp/org-list.elc: lisp/org-macs.el lisp/org-compat.el
361 lisp/org-mac-message.elc: lisp/org.el
362 lisp/org-macs.elc:
363 lisp/org-mew.elc: lisp/org.el
364 lisp/org-mhe.elc: lisp/org.el
365 lisp/org-mobile.elc: lisp/org.el
366 lisp/org-mouse.elc: lisp/org.el
367 lisp/org-plot.elc: lisp/org.el lisp/org-exp.el lisp/org-table.el
368 lisp/org-publish.elc:
369 lisp/org-protocol.elc: lisp/org.el
370 lisp/org-remember.elc: lisp/org.el
371 lisp/org-rmail.elc: lisp/org.el
372 lisp/org-src.elc: lisp/org-macs.el lisp/org-compat.el
373 lisp/org-table.elc: lisp/org.el
374 lisp/org-timer.elc: lisp/org.el
375 lisp/org-vm.elc: lisp/org.el
376 lisp/org-w3m.elc: lisp/org.el
377 lisp/org-wl.elc: lisp/org.el
378 lisp/org-xoxo.elc: lisp/org-exp.el