Release 6.05b.
[org-mode.git] / Makefile
blobe4208eefa2dc2cae9c522ac4135ee09a9fc0710f
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)/info
25 ##----------------------------------------------------------------------
26 ## YOU MAY NEED TO EDIT THESE
27 ##----------------------------------------------------------------------
29 # Using emacs in batch mode.
30 # BATCH=$(EMACS) -batch -q
31 # BATCH=$(EMACS) -batch -q -eval "(add-to-list (quote load-path) \".\")"
33 BATCH=$(EMACS) -batch -q -eval \
34 "(progn (add-to-list (quote load-path) (expand-file-name \"./lisp/\")) \
35 (add-to-list (quote load-path) \"$(lispdir)\"))"
37 # Specify the byte-compiler for compiling org-mode files
38 ELC= $(BATCH) -f batch-byte-compile
40 # How to make a pdf file from a texinfo file
41 TEXI2PDF = texi2pdf
43 # How to create directories
44 MKDIR = mkdir -p
46 # How to create the info files from the texinfo file
47 MAKEINFO = makeinfo
49 # How to create the HTML file
50 TEXI2HTML = makeinfo --html --number-sections
52 # How to move the byte compiled files to their destination.
53 MV = mv
55 # How to copy the lisp files to their distination.
56 CP = cp -p
58 ##----------------------------------------------------------------------
59 ## BELOW THIS LINE ON YOUR OWN RISK!
60 ##----------------------------------------------------------------------
62 # The following variables need to be defined by the maintainer
63 LISPF = org.el \
64 org-agenda.el \
65 org-archive.el \
66 org-bbdb.el \
67 org-bibtex.el \
68 org-clock.el \
69 org-colview.el \
70 org-colview-xemacs.el \
71 org-compat.el \
72 org-exp.el \
73 org-export-latex.el \
74 org-faces.el \
75 org-gnus.el \
76 org-id.el \
77 org-info.el \
78 org-jsinfo.el \
79 org-irc.el \
80 org-mac-message.el \
81 org-macs.el \
82 org-mew.el \
83 org-mhe.el \
84 org-mouse.el \
85 org-publish.el \
86 org-remember.el \
87 org-rmail.el \
88 org-table.el \
89 org-vm.el \
90 org-wl.el
92 LISPFILES0 = $(LISPF:%=lisp/%)
93 LISPFILES = $(LISPFILES0) lisp/org-install.el
94 ELCFILES0 = $(LISPFILES0:.el=.elc)
95 ELCFILES = $(LISPFILES:.el=.elc)
96 DOCFILES = doc/org.texi doc/org.pdf doc/org doc/dir
97 CARDFILES = doc/orgcard.tex doc/orgcard.pdf doc/orgcard_letter.pdf
98 TEXIFILES = doc/org.texi
99 INFOFILES = doc/org
102 .SUFFIXES: .el .elc .texi
103 SHELL = /bin/sh
105 # Additional distribution files
106 DISTFILES_extra= Makefile ChangeLog request-assign-future.txt contrib
107 DISTFILES_xemacs= xemacs/noutline.el xemacs/ps-print-invisible.el xemacs/README
109 default: $(ELCFILES)
111 all: $(ELCFILES) $(INFOFILES)
113 compile: $(ELCFILES0)
115 install: install-lisp
117 doc: doc/org.html doc/org.pdf doc/orgcard.pdf doc/orgcard_letter.pdf
120 make pdf && open doc/org.pdf
123 make card && gv doc/orgcard.ps
125 install-lisp: $(LISPFILES) $(ELCFILES)
126 if [ ! -d $(lispdir) ]; then $(MKDIR) $(lispdir); else true; fi ;
127 $(CP) $(LISPFILES) $(lispdir)
128 $(CP) $(ELCFILES) $(lispdir)
130 install-info: $(INFOFILES)
131 if [ ! -d $(infodir) ]; then $(MKDIR) $(infodir); else true; fi ;
132 $(CP) $(INFOFILES) $(infodir)
134 install-noutline: xemacs/noutline.elc
135 if [ ! -d $(lispdir) ]; then $(MKDIR) $(lispdir); else true; fi ;
136 $(CP) xemacs/noutline.el xemacs/noutline.elc $(lispdir)
138 autoloads: lisp/org-install.el
140 lisp/org-install.el: $(LISPFILES0) Makefile
141 $(BATCH) --eval "(require 'autoload)" \
142 --eval '(find-file "org-install.el")' \
143 --eval '(erase-buffer)' \
144 --eval '(mapc (lambda (x) (generate-file-autoloads (symbol-name x))) (quote ($(LISPFILES0))))' \
145 --eval '(insert "\n(provide (quote org-install))\n")' \
146 --eval '(save-buffer)'
147 mv org-install.el lisp
149 xemacs/noutline.elc: xemacs/noutline.el
151 doc/org: doc/org.texi
152 (cd doc; $(MAKEINFO) --no-split org.texi -o org)
154 doc/org.pdf: doc/org.texi
155 (cd doc; $(TEXI2PDF) org.texi)
157 doc/org.html: doc/org.texi
158 (cd doc; $(TEXI2HTML) --no-split -o org.html org.texi)
160 doc/orgcard.dvi: doc/orgcard.tex
161 (cd doc; tex orgcard.tex)
163 doc/orgcard.pdf: doc/orgcard.dvi
164 dvips -q -f -t landscape doc/orgcard.dvi | gs -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=doc/orgcard.pdf -c .setpdfwrite -
166 doc/orgcard.ps: doc/orgcard.dvi
167 dvips -t landscape -o doc/orgcard.ps doc/orgcard.dvi
169 doc/orgcard_letter.dvi: doc/orgcard.tex
170 perl -pe 's/letterpaper=0/letterpaper=1/' doc/orgcard.tex > doc/orgcard_letter.tex
171 (cd doc; tex orgcard_letter.tex)
173 doc/orgcard_letter.pdf: doc/orgcard_letter.dvi
174 dvips -q -f -t landscape doc/orgcard_letter.dvi | gs -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=doc/orgcard_letter.pdf -c .setpdfwrite -
176 doc/orgcard_letter.ps: doc/orgcard_letter.dvi
177 dvips -t landscape -o doc/orgcard_letter.ps doc/orgcard_letter.dvi
179 # Below here are special targets for maintenance only
181 updateweb:
182 ssh cdominik@caprisun.dreamhost.com 'pull-worg-org.sh && publish-worg-org.sh'
184 html: doc/org.html
186 html_manual: doc/org.texi
187 rm -rf doc/manual
188 mkdir doc/manual
189 $(TEXI2HTML) -o doc/manual doc/org.texi
191 info: doc/org
193 pdf: doc/org.pdf
195 card: doc/orgcard.pdf doc/orgcard.ps doc/orgcard_letter.pdf doc/orgcard_letter.ps
197 distfile:
198 @if [ "X$(TAG)" = "X" ]; then echo "*** No tag ***"; exit 1; fi
199 touch doc/org.texi doc/orgcard.tex # force update
200 make info
201 make doc
202 make lisp/org-install.el
203 rm -rf org-$(TAG) org-$(TAG).zip
204 $(MKDIR) org-$(TAG)
205 $(MKDIR) org-$(TAG)/xemacs
206 $(MKDIR) org-$(TAG)/doc
207 $(MKDIR) org-$(TAG)/lisp
208 cp -r $(LISPFILES) org-$(TAG)/lisp
209 cp -r $(DOCFILES) $(CARDFILES) org-$(TAG)/doc
210 cp -r $(DISTFILES_extra) org-$(TAG)/
211 cp -r README_DIST org-$(TAG)/README
212 cp -r ORGWEBPAGE/Changes.org org-$(TAG)/
213 cp -r $(DISTFILES_xemacs) org-$(TAG)/xemacs/
214 zip -r org-$(TAG).zip org-$(TAG)
215 gtar zcvf org-$(TAG).tar.gz org-$(TAG)
217 release:
218 @if [ "X$(TAG)" = "X" ]; then echo "*** No tag ***"; exit 1; fi
219 make distfile
220 make doc
221 UTILITIES/gplmanual.pl
222 make html_manual
223 rm -rf RELEASEDIR
224 $(MKDIR) RELEASEDIR
225 cp org-$(TAG).zip org-$(TAG).tar.gz RELEASEDIR
226 cp doc/org.pdf doc/orgcard.pdf doc/org.texi doc/org.html RELEASEDIR
227 cp RELEASEDIR/org-$(TAG).zip RELEASEDIR/org.zip
228 cp RELEASEDIR/org-$(TAG).tar.gz RELEASEDIR/org.tar.gz
230 upload_release:
231 (cd RELEASEDIR; lftp -f ../../org-mode-proprietary/ftp_upload_release_legito)
233 upload_manual:
234 lftp -f ../org-mode-proprietary/ftp_upload_manual_legito
236 relup0:
237 make release
238 make upload_release
240 relup:
241 make release
242 make upload_release
243 make upload_manual
246 grep -e '(debug)' lisp/*el
248 cleanelc:
249 rm -f $(ELCFILES)
250 cleandoc:
251 (cd doc; rm -f org.pdf org org.html orgcard.pdf orgcard.ps)
252 (cd doc; rm -f *.aux *.cp *.cps *.dvi *.fn *.fns *.ky *.kys *.pg *.pgs)
253 (cd doc; rm -f *.toc *.tp *.tps *.vr *.vrs *.log *.html *.ps)
254 (cd doc; rm -f orgcard_letter.tex orgcard_letter.pdf)
255 (cd doc; rm -rf manual)
256 clean:
257 make cleanelc
258 make cleandoc
259 rm -f *~ */*~ */*/*~
260 rm -rf RELEASEDIR
261 rm -f lisp/org-install.el
263 .el.elc:
264 $(ELC) $<
267 push:
268 git-push git+ssh://repo.or.cz/srv/git/org-mode.git master
270 pushtag:
271 git-tag -m "Adding tag" -a $(TAG)
272 git-push git+ssh://repo.or.cz/srv/git/org-mode.git $(TAG)
274 pushreleasetag:
275 git-tag -m "Adding release tag" -a release_$(TAG)
276 git-push git+ssh://repo.or.cz/srv/git/org-mode.git release_$(TAG)
278 dummy:
279 echo ${prefix}
281 # Dependencies
283 lisp/org.elc: lisp/org-macs.elc lisp/org-compat.elc lisp/org-faces.elc
284 lisp/org-agenda.elc: lisp/org.elc
285 lisp/org-archive.elc: lisp/org.elc
286 lisp/org-bbdb.elc: lisp/org.elc
287 lisp/org-bibtex.elc: lisp/org.elc
288 lisp/org-clock.elc: lisp/org.elc
289 lisp/org-colview.elc: lisp/org.elc
290 lisp/org-colview-xemacs.elc: lisp/org.elc
291 lisp/org-compat.elc:
292 lisp/org-exp.elc: lisp/org.elc lisp/org-agenda.elc
293 lisp/org-export-latex.elc: lisp/org.elc lisp/org-exp.elc
294 lisp/org-faces.elc: lisp/org-macs.elc lisp/org-compat.elc
295 lisp/org-gnus.elc: lisp/org.elc
296 lisp/org-id.elc: lisp/org.elc
297 lisp/org-info.elc: lisp/org.elc
298 lisp/org-jsinfo.elc: lisp/org.elc lisp/org-exp.elc
299 lisp/org-irc.elc: lisp/org.elc
300 lisp/org-mac-message.elc: lisp/org.elc
301 lisp/org-macs.elc:
302 lisp/org-mew.elc: lisp/org.elc
303 lisp/org-mhe.elc: lisp/org.elc
304 lisp/org-mouse.elc: lisp/org.elc
305 lisp/org-publish.elc:
306 lisp/org-remember.elc: lisp/org.elc
307 lisp/org-rmail.elc: lisp/org.elc
308 lisp/org-table.elc: lisp/org.elc
309 lisp/org-vm.elc: lisp/org.elc
310 lisp/org-wl.elc: lisp/org.elc