Makefile (LISPF): Add org-lparse.el and org-odt.el
[org-mode.git] / Makefile
blobd6b9d34adfa37bc6477cd41b178b46afe21f8c37
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 "(setq load-path (cons (expand-file-name \"./lisp/\") (cons \"$(lispdir)\" load-path)))"
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
48 TEXI2HTMLNOPSLIT = makeinfo --html --no-split --number-sections
50 # How to copy the lisp files and elc files to their distination.
51 CP = cp -p
53 # Name of the program to install info files
54 INSTALL_INFO=install-info
56 ##----------------------------------------------------------------------
57 ## BELOW THIS LINE ON YOUR OWN RISK!
58 ##----------------------------------------------------------------------
60 # The following variables need to be defined by the maintainer
61 LISPF = org.el \
62 org-agenda.el \
63 org-ascii.el \
64 org-attach.el \
65 org-archive.el \
66 org-bbdb.el \
67 org-beamer.el \
68 org-bibtex.el \
69 org-capture.el \
70 org-clock.el \
71 org-colview.el \
72 org-colview-xemacs.el \
73 org-compat.el \
74 org-pcomplete.el \
75 org-crypt.el \
76 org-ctags.el \
77 org-datetree.el \
78 org-docview.el \
79 org-entities.el \
80 org-exp.el \
81 org-exp-blocks.el \
82 org-docbook.el \
83 org-faces.el \
84 org-feed.el \
85 org-footnote.el \
86 org-freemind.el \
87 org-gnus.el \
88 org-habit.el \
89 org-html.el \
90 org-icalendar.el \
91 org-id.el \
92 org-indent.el \
93 org-info.el \
94 org-inlinetask.el \
95 org-jsinfo.el \
96 org-irc.el \
97 org-latex.el \
98 org-list.el \
99 org-lparse.el \
100 org-mac-message.el \
101 org-macs.el \
102 org-mew.el \
103 org-mhe.el \
104 org-mks.el \
105 org-mobile.el \
106 org-mouse.el \
107 org-odt.el \
108 org-publish.el \
109 org-plot.el \
110 org-protocol.el \
111 org-remember.el \
112 org-rmail.el \
113 org-special-blocks.el \
114 org-src.el \
115 org-table.el \
116 org-taskjuggler.el \
117 org-timer.el \
118 org-vm.el \
119 org-w3m.el \
120 org-wl.el \
121 org-xoxo.el \
122 ob.el \
123 ob-table.el \
124 ob-lob.el \
125 ob-ref.el \
126 ob-exp.el \
127 ob-tangle.el \
128 ob-comint.el \
129 ob-eval.el \
130 ob-keys.el \
131 ob-awk.el \
132 ob-C.el \
133 ob-calc.el \
134 ob-ditaa.el \
135 ob-haskell.el \
136 ob-perl.el \
137 ob-sh.el \
138 ob-R.el \
139 ob-dot.el \
140 ob-mscgen.el \
141 ob-latex.el \
142 ob-lisp.el \
143 ob-ledger.el \
144 ob-python.el \
145 ob-sql.el \
146 ob-asymptote.el \
147 ob-emacs-lisp.el \
148 ob-matlab.el \
149 ob-ruby.el \
150 ob-sqlite.el \
151 ob-clojure.el \
152 ob-ocaml.el \
153 ob-sass.el \
154 ob-css.el \
155 ob-gnuplot.el \
156 ob-octave.el \
157 ob-screen.el \
158 ob-plantuml.el \
159 ob-org.el \
160 ob-js.el \
161 ob-scheme.el \
162 ob-lilypond.el \
163 ob-java.el \
164 ob-shen.el \
165 ob-fortran.el \
166 ob-picolisp.el
168 LISPFILES0 = $(LISPF:%=lisp/%)
169 LISPFILES = $(LISPFILES0) lisp/org-install.el
170 ELCFILES0 = $(LISPFILES0:.el=.elc)
171 ELCFILES = $(LISPFILES:.el=.elc)
172 DOCFILES = doc/org.texi doc/org.pdf doc/org doc/dir \
173 doc/pdflayout.sty doc/.nosearch \
174 doc/orgguide.texi doc/orgguide.pdf
175 CARDFILES = doc/orgcard.tex doc/orgcard.pdf doc/orgcard_letter.pdf
176 TEXIFILES = doc/org.texi
177 INFOFILES = doc/org
179 # Package Manager (ELPA)
180 PKG_TAG = $(shell date +%Y%m%d)
181 PKG_DOC = "Outline-based notes management and organizer"
182 PKG_REQ = "nil"
184 PKG_FILES = $(LISPFILES0) \
185 doc/dir doc/org \
186 doc/pdflayout.sty \
187 doc/org.pdf \
188 doc/orgguide.pdf \
189 doc/orgcard.tex \
190 doc/orgcard.pdf \
191 doc/orgcard_letter.pdf
193 .SUFFIXES: .el .elc .texi
194 SHELL = /bin/sh
196 # Additional distribution files
197 DISTFILES_extra= Makefile request-assign-future.txt contrib
199 default: $(ELCFILES) $(ELCBFILES)
201 all: $(ELCFILES) $(ELCBFILES) $(INFOFILES)
203 up2: update
204 sudo ${MAKE} install
206 update:
207 git pull
208 ${MAKE} clean
209 ${MAKE} all
211 compile: $(ELCFILES0) $(ELCBFILES)
213 install: install-lisp
215 doc: doc/org.html doc/org.pdf doc/orgcard.pdf doc/orgcard_letter.pdf doc/orgguide.pdf doc/orgcard.txt
218 ${MAKE} pdf && open doc/org.pdf
221 ${MAKE} pdf && open doc/orgguide.pdf
223 install-lisp: $(LISPFILES) $(ELCFILES)
224 if [ ! -d $(lispdir) ]; then $(MKDIR) $(lispdir); else true; fi ;
225 $(CP) $(LISPFILES) $(lispdir)
226 $(CP) $(ELCFILES) $(lispdir)
228 install-info: $(INFOFILES)
229 if [ ! -d $(infodir) ]; then $(MKDIR) $(infodir); else true; fi ;
230 $(CP) $(INFOFILES) $(infodir)
231 $(INSTALL_INFO) --infodir=$(infodir) $(INFOFILES)
233 autoloads: lisp/org-install.el
235 lisp/org-install.el: $(LISPFILES0) Makefile
236 $(BATCH) --eval "(require 'autoload)" \
237 --eval '(find-file "lisp/org-install.el")' \
238 --eval '(erase-buffer)' \
239 --eval '(mapc (lambda (x) (generate-file-autoloads (symbol-name x))) (quote ($(LISPF))))' \
240 --eval '(insert "\n(provide (quote org-install))\n")' \
241 --eval '(save-buffer)'
243 doc/org: doc/org.texi
244 (cd doc && $(MAKEINFO) --no-split org.texi -o org)
246 doc/org.pdf: doc/org.texi
247 (cd doc && $(TEXI2PDF) org.texi)
249 doc/orgguide.pdf: doc/orgguide.texi
250 (cd doc && $(TEXI2PDF) orgguide.texi)
252 doc/org.html: doc/org.texi
253 (cd doc && $(TEXI2HTML) --no-split -o org.html org.texi)
254 UTILITIES/manfull.pl doc/org.html
256 doc/orgcard.pdf: doc/orgcard.tex
257 (cd doc && pdftex orgcard.tex)
259 doc/orgcard.txt: doc/orgcard.tex
260 (cd doc && perl ../UTILITIES/orgcard2txt.pl orgcard.tex > orgcard.txt)
262 doc/orgcard_letter.tex: doc/orgcard.tex
263 perl -pe 's/\\pdflayout=\(0l\)/\\pdflayout=(1l)/' \
264 doc/orgcard.tex > doc/orgcard_letter.tex
266 doc/orgcard_letter.pdf: doc/orgcard_letter.tex
267 (cd doc && pdftex orgcard_letter.tex)
269 # Below here are special targets for maintenance only
271 html: doc/org.html
273 html_manual: doc/org.texi
274 rm -rf doc/manual
275 mkdir doc/manual
276 $(TEXI2HTML) -o doc/manual doc/org.texi
277 UTILITIES/mansplit.pl doc/manual/*.html
279 html_guide: doc/orgguide.texi
280 rm -rf doc/guide
281 mkdir doc/guide
282 $(TEXI2HTML) -o doc/guide doc/orgguide.texi
283 UTILITIES/guidesplit.pl doc/guide/*.html
285 info: doc/org
287 pdf: doc/org.pdf doc/orgguide.pdf
289 card: doc/orgcard.pdf doc/orgcard_letter.pdf doc/orgcard.txt
291 testrelease:
292 git checkout -b testrelease origin/maint
293 git merge -s recursive -X theirs master
294 UTILITIES/set-version.pl testing
295 git commit -a -m "Release testing"
296 make distfile TAG=testversion
297 make cleanrel
298 rm -rf org-testversion*
299 git reset --hard
300 git checkout master
301 git branch -D testrelease
303 # The following target makes a full release for the stuff that is
304 # currently on master. Do it like this:
306 # make release TAG=7.01
308 release:
309 git checkout maint
310 git merge -s recursive -X theirs master
311 UTILITIES/set-version.pl $(TAG)
312 git commit -a -m "Release $(TAG)"
313 make relup TAG=$(TAG)
314 make cleanrel
315 rm -rf org-$(TAG)
316 rm -f org-$(TAG)*.zip
317 rm -f org-$(TAG)*.tar.gz
318 make pushreleasetag TAG=$(TAG)
319 git push -f origin maint
320 git checkout master
321 git merge -s ours maint
322 UTILITIES/set-version.pl -a $(TAG)
323 git commit -a -m "Update website to show $(TAG) as current release"
324 git push
326 # The following target makes a release, but from the stuff that is on
327 # maint, not from the stuff that is on master. The idea is that it pushes
328 # out a minor fix into a minor update, while development on master
329 # already went full steam ahead. To make a micro-relesse, cherry-pick
330 # the necessary changes into maint, then run (with proper version number)
331 # This is just like release, but we skip the step which merges master
332 # into maint.
334 # make fixrelease TAG=7.01.02
336 fixrelease:
337 git checkout maint
338 git merge -s recursive -X theirs master
339 UTILITIES/set-version.pl $(TAG)
340 git commit -a -m "Release $(TAG)"
341 make relup TAG=$(TAG)
342 make cleanrel
343 rm -rf org-$(TAG)
344 rm org-$(TAG)*.zip
345 rm org-$(TAG)*.tar.gz
346 make pushreleasetag TAG=$(TAG)
347 git push -f origin maint
348 git checkout master
349 git merge -s ours maint
350 UTILITIES/set-version.pl -o $(TAG)
351 git commit -a -m "Update website to show $(TAG) as current release"
352 git push
354 # ~$ make relup only makes sense from orgmode.org server
355 # Don't call it from your computer!
356 relup:
357 ${MAKE} makerelease
358 ${MAKE} sync_release
359 ${MAKE} sync_manual
361 makerelease:
362 @if [ "X$(TAG)" = "X" ]; then echo "*** No tag ***"; exit 1; fi
363 ${MAKE} distfile
364 ${MAKE} doc
365 UTILITIES/gplmanual.pl
366 ${MAKE} html_manual
367 ${MAKE} html_guide
368 rm -rf RELEASEDIR
369 $(MKDIR) RELEASEDIR
370 cp org-$(TAG).zip org-$(TAG).tar.gz RELEASEDIR
371 cp doc/org.pdf doc/orgcard.pdf doc/org.texi doc/org.html RELEASEDIR
372 cp doc/org_dual_license.texi RELEASEDIR
373 cp doc/orgguide.pdf doc/orgcard.txt RELEASEDIR
374 cp RELEASEDIR/org-$(TAG).zip RELEASEDIR/org.zip
375 cp RELEASEDIR/org-$(TAG).tar.gz RELEASEDIR/org.tar.gz
377 # ~$ make sync_release only makes sense from orgmode.org server
378 # Don't call it from your computer!
379 sync_release:
380 rsync -avuz RELEASEDIR/ /var/www/orgmode.org/
382 # ~$ make sync_manual only makes sense from orgmode.org server
383 # Don't call it from your computer!
384 sync_manual:
385 rsync -avuz --delete doc/manual/ /var/www/orgmode.org/manual/
386 rsync -avuz --delete doc/guide/ /var/www/orgmode.org/guide/
388 distfile:
389 @if [ "X$(TAG)" = "X" ]; then echo "*** No tag ***"; exit 1; fi
390 touch doc/org.texi doc/orgcard.tex # force update
391 ${MAKE} cleancontrib
392 ${MAKE} info
393 ${MAKE} doc
394 ${MAKE} lisp/org-install.el
395 rm -rf org-$(TAG) org-$(TAG).zip
396 $(MKDIR) org-$(TAG)
397 $(MKDIR) org-$(TAG)/doc
398 $(MKDIR) org-$(TAG)/lisp
399 cp -r $(LISPFILES) org-$(TAG)/lisp
400 cp -r $(DOCFILES) $(CARDFILES) org-$(TAG)/doc
401 cp -r $(DISTFILES_extra) org-$(TAG)/
402 cp -r README_DIST org-$(TAG)/README
403 zip -r org-$(TAG).zip org-$(TAG)
404 tar zcvf org-$(TAG).tar.gz org-$(TAG)
406 pkg:
407 @if [ "X$(PKG_TAG)" = "X" ]; then echo "*** No tag ***"; exit 1; fi
408 touch doc/org.texi doc/orgcard.tex # force update
409 ${MAKE} info
410 ${MAKE} doc
411 rm -rf org-$(PKG_TAG) org-$(PKG_TAG).tar
412 $(MKDIR) org-$(PKG_TAG)
413 cp -r $(PKG_FILES) org-$(PKG_TAG)
414 echo "(define-package \"org\" \"$(PKG_TAG)\" \"$(PKG_DOC)\" $(PKG_REQ))" > org-$(PKG_TAG)/org-pkg.el
415 tar cf org-$(PKG_TAG).tar org-$(PKG_TAG) --remove-files
417 cleanall:
418 ${MAKE} clean
419 rm -f lisp/org-install.el
421 clean:
422 ${MAKE} cleanelc
423 ${MAKE} cleandoc
424 ${MAKE} cleanrel
425 rm -f *~ */*~ */*/*~
427 cleancontrib:
428 find contrib -name \*~ -exec rm {} \;
430 cleanelc:
431 rm -f $(ELCFILES)
432 cleandoc:
433 -(cd doc && rm -f org.pdf org org.html orgcard.pdf orgguide.pdf)
434 -(cd doc && rm -f *.aux *.cp *.cps *.dvi *.fn *.fns *.ky *.kys *.pg *.pgs)
435 -(cd doc && rm -f *.toc *.tp *.tps *.vr *.vrs *.log *.html *.ps)
436 -(cd doc && rm -f orgcard_letter.tex orgcard_letter.pdf)
437 -(cd doc && rm -rf manual)
439 cleanrel:
440 rm -rf RELEASEDIR
441 rm -rf org-7.*
442 rm -rf org-7*zip org-7*tar.gz
444 .el.elc:
445 $(ELC) $<
448 push:
449 git push orgmode@orgmode.org:org-mode.git master
451 pushtag:
452 git tag -m "Adding tag" -a $(TAG)
453 git push orgmode@orgmode.org:org-mode.git $(TAG)
455 pushreleasetag:
456 git tag -m "Adding release tag" -a release_$(TAG)
457 git push orgmode@orgmode.org:org-mode.git release_$(TAG)
459 # Dependencies
461 lisp/org.elc: lisp/org-macs.el lisp/org-compat.el lisp/org-faces.el
462 lisp/org-agenda.elc: lisp/org.el
463 lisp/org-ascii.elc: lisp/org-exp.el
464 lisp/org-attach.elc: lisp/org.el lisp/org-id.el
465 lisp/org-archive.elc: lisp/org.el
466 lisp/org-bbdb.elc: lisp/org.el
467 lisp/org-beamer.elc: lisp/org.el
468 lisp/org-bibtex.elc: lisp/org.el
469 lisp/org-capture.elc: lisp/org.el lisp/org-mks.el
470 lisp/org-clock.elc: lisp/org.el
471 lisp/org-colview.elc: lisp/org.el
472 lisp/org-colview-xemacs.elc: lisp/org.el
473 lisp/org-compat.elc: lisp/org-macs.el
474 lisp/org-crypt.elc: lisp/org-crypt.el lisp/org.el
475 lisp/org-ctags.elc: lisp/org.el
476 lisp/org-datetree.elc: lisp/org.el
477 lisp/org-docview.elc: lisp/org.el
478 lisp/org-entities.elc:
479 lisp/org-exp.elc: lisp/org.el lisp/org-agenda.el
480 lisp/org-exp-blocks.elc: lisp/org.el
481 lisp/org-latex.elc: lisp/org.el lisp/org-exp.el lisp/org-beamer.el
482 lisp/org-docbook.elc: lisp/org.el lisp/org-exp.el
483 lisp/org-faces.elc: lisp/org-macs.el lisp/org-compat.el
484 lisp/org-feed.elc: lisp/org.el
485 lisp/org-footnotes.elc: lisp/org-macs.el lisp/org-compat.el
486 lisp/org-freemind.elc: lisp/org.el
487 lisp/org-gnus.elc: lisp/org.el
488 lisp/org-html.elc: lisp/org-exp.el
489 lisp/org-habit.elc: lisp/org.el lisp/org-agenda.el
490 lisp/org-icalendar.elc: lisp/org-exp.el
491 lisp/org-id.elc: lisp/org.el
492 lisp/org-indent.elc: lisp/org.el lisp/org-macs.el lisp/org-compat.el
493 lisp/org-info.elc: lisp/org.el
494 lisp/org-inlinetask.elc:
495 lisp/org-irc.elc: lisp/org.el
496 lisp/org-jsinfo.elc: lisp/org.el lisp/org-exp.el
497 lisp/org-list.elc: lisp/org-macs.el lisp/org-compat.el
498 lisp/org-lparse.elc: lisp/org-exp.el
499 lisp/org-mac-message.elc: lisp/org.el
500 lisp/org-macs.elc:
501 lisp/org-mew.elc: lisp/org.el
502 lisp/org-mhe.elc: lisp/org.el
503 lisp/org-mks.elc:
504 lisp/org-mobile.elc: lisp/org.el
505 lisp/org-mouse.elc: lisp/org.el
506 lisp/org-odt.elc: lisp/org-lparse.el
507 lisp/org-plot.elc: lisp/org.el lisp/org-exp.el lisp/org-table.el
508 lisp/org-publish.elc:
509 lisp/org-protocol.elc: lisp/org.el
510 lisp/org-remember.elc: lisp/org.el
511 lisp/org-rmail.elc: lisp/org.el
512 lisp/org-special-blocks.elc: lisp/org-compat.el
513 lisp/org-src.elc: lisp/org-macs.el lisp/org-compat.el
514 lisp/org-table.elc: lisp/org.el
515 lisp/org-taskjuggler.elc: lisp/org.el lisp/org-exp.el
516 lisp/org-timer.elc: lisp/org.el
517 lisp/org-vm.elc: lisp/org.el
518 lisp/org-w3m.elc: lisp/org.el
519 lisp/org-wl.elc: lisp/org.el
520 lisp/org-xoxo.elc: lisp/org-exp.el
522 # Describe valid make targets for org-mode.
523 targets help:
524 @echo "make - compile Org ELisp files"
525 @echo "make clean - clean Elisp and documentation files"
526 @echo "make all - compile Org ELisp files and documentation"
527 @echo ""
528 @echo "make doc - make all documentation"
529 @echo "make info - make Info documentation"
530 @echo "make html - make HTML documentation"
531 @echo "make pdf - make pdf documentation"
532 @echo "make card - make refcards documentation"
533 @echo ""
534 @echo "make install - install Org"
535 @echo "make install-lisp - install Org ELisp files"
536 @echo "make install-info - install Org Info file"