1 # Makefile - for the org-mode distribution
3 # Maintainer: Carsten Dominik <dominik@science.uva.nl>
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
16 # Where local software is found
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
40 # How to create directories
43 # How to create the info files from the texinfo file
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.
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
72 org-colview-xemacs.el \
111 org-special-blocks.el \
162 LISPFILES0
= $(LISPF
:%=lisp
/%)
163 LISPFILES
= $(LISPFILES0
) lisp
/org-install.el
164 ELCFILES0
= $(LISPFILES0
:.el
=.elc
)
165 ELCFILES
= $(LISPFILES
:.el
=.elc
)
166 DOCFILES
= doc
/org.texi doc
/org.pdf doc
/org doc
/dir \
167 doc
/pdflayout.sty doc
/.nosearch \
168 doc
/orgguide.texi doc
/orgguide.pdf
169 CARDFILES
= doc
/orgcard.
tex doc
/orgcard.pdf doc
/orgcard_letter.pdf
170 TEXIFILES
= doc
/org.texi
173 # Package Manager (ELPA)
174 PKG_TAG
= $(shell date
+%Y
%m
%d
)
175 PKG_DOC
= "Outline-based notes management and organizer"
178 PKG_FILES
= $(LISPFILES0
) \
185 doc
/orgcard_letter.pdf
187 .SUFFIXES
: .el .elc .texi
190 # Additional distribution files
191 DISTFILES_extra
= Makefile request-assign-future.txt contrib
193 default
: $(ELCFILES
) $(ELCBFILES
)
195 all: $(ELCFILES
) $(ELCBFILES
) $(INFOFILES
)
205 compile
: $(ELCFILES0
) $(ELCBFILES
)
207 install: install-lisp
209 doc
: doc
/org.html doc
/org.pdf doc
/orgcard.pdf doc
/orgcard_letter.pdf doc
/orgguide.pdf doc
/orgcard.txt
212 ${MAKE} pdf
&& open doc
/org.pdf
215 ${MAKE} pdf
&& open doc
/orgguide.pdf
217 install-lisp
: $(LISPFILES
) $(ELCFILES
)
218 if
[ ! -d
$(lispdir
) ]; then
$(MKDIR
) $(lispdir
); else true
; fi
;
219 $(CP
) $(LISPFILES
) $(lispdir
)
220 $(CP
) $(ELCFILES
) $(lispdir
)
222 install-info
: $(INFOFILES
)
223 if
[ ! -d
$(infodir) ]; then
$(MKDIR
) $(infodir); else true
; fi
;
224 $(CP
) $(INFOFILES
) $(infodir)
225 $(INSTALL_INFO
) --info-file
=$(INFOFILES
) --info-dir
=$(infodir)
227 install-info-debian
: $(INFOFILES
)
228 $(INSTALL_INFO
) --infodir=$(infodir) $(INFOFILES
)
230 autoloads
: lisp
/org-install.el
232 lisp
/org-install.el
: $(LISPFILES0
) Makefile
233 $(BATCH
) --eval
"(require 'autoload)" \
234 --eval
'(find-file "org-install.el")' \
235 --eval
'(erase-buffer)' \
236 --eval
'(mapc (lambda (x) (generate-file-autoloads (symbol-name x))) (quote ($(LISPFILES0))))' \
237 --eval
'(insert "\n(provide (quote org-install))\n")' \
238 --eval
'(save-buffer)'
239 mv org-install.el lisp
241 doc
/org
: doc
/org.texi
242 (cd doc
&& $(MAKEINFO
) --no-split org.texi
-o org
)
244 doc
/org.pdf
: doc
/org.texi
245 (cd doc
&& $(TEXI2PDF
) org.texi
)
247 doc
/orgguide.pdf
: doc
/orgguide.texi
248 (cd doc
&& $(TEXI2PDF
) orgguide.texi
)
250 doc
/org.html
: doc
/org.texi
251 (cd doc
&& $(TEXI2HTML
) --no-split
-o org.html org.texi
)
252 UTILITIES
/manfull.pl doc
/org.html
254 doc
/orgcard.pdf
: doc
/orgcard.
tex
255 (cd doc
&& pdftex orgcard.
tex)
257 doc
/orgcard.txt
: doc
/orgcard.
tex
258 (cd doc
&& perl ..
/UTILITIES
/orgcard2txt.pl orgcard.
tex > orgcard.txt
)
260 doc
/orgcard_letter.
tex: doc
/orgcard.
tex
261 perl
-pe
's/\\pdflayout=\(0l\)/\\pdflayout=(1l)/' \
262 doc
/orgcard.
tex > doc
/orgcard_letter.
tex
264 doc
/orgcard_letter.pdf
: doc
/orgcard_letter.
tex
265 (cd doc
&& pdftex orgcard_letter.
tex)
267 # Below here are special targets for maintenance only
271 html_manual
: doc
/org.texi
274 $(TEXI2HTML
) -o doc
/manual doc
/org.texi
275 UTILITIES
/mansplit.pl doc
/manual
/*.html
277 html_guide
: doc
/orgguide.texi
280 $(TEXI2HTML
) -o doc
/guide doc
/orgguide.texi
281 UTILITIES
/guidesplit.pl doc
/guide
/*.html
285 pdf
: doc
/org.pdf doc
/orgguide.pdf
287 card
: doc
/orgcard.pdf doc
/orgcard_letter.pdf doc
/orgcard.txt
290 git checkout
-b testrelease
origin/maint
291 git merge
-s recursive
-X theirs master
292 UTILITIES
/set-version.pl testing
293 git commit
-a
-m
"Release testing"
294 make distfile TAG
=testversion
296 rm -rf org-testversion
*
299 git branch
-D testrelease
301 # The following target makes a full release for the stuff that is
302 # currently on master. Do it like this:
304 # make release TAG=7.01
308 git merge
-s recursive
-X theirs master
309 UTILITIES
/set-version.pl
$(TAG
)
310 git commit
-a
-m
"Release $(TAG)"
311 make relup TAG
=$(TAG
)
314 rm -f org-
$(TAG
)*.zip
315 rm -f org-
$(TAG
)*.
tar.gz
316 make pushreleasetag TAG
=$(TAG
)
317 git push
-f
origin maint
319 git merge
-s ours maint
320 UTILITIES
/set-version.pl
-a
$(TAG
)
321 git commit
-a
-m
"Update website to show $(TAG) as current release"
324 # The following target makes a release, but from the stuff that is on
325 # maint, not from the stuff that is on master. The idea is that it pushes
326 # out a minor fix into a minor update, while development on master
327 # already went full steam ahead. To make a micro-relesse, cherry-pick
328 # the necessary changes into maint, then run (with proper version number)
329 # This is just like release, but we skip the step which merges master
332 # make fixrelease TAG=7.01.02
336 git merge
-s recursive
-X theirs master
337 UTILITIES
/set-version.pl
$(TAG
)
338 git commit
-a
-m
"Release $(TAG)"
339 make relup TAG
=$(TAG
)
343 rm org-
$(TAG
)*.
tar.gz
344 make pushreleasetag TAG
=$(TAG
)
345 git push
-f
origin maint
347 git merge
-s ours maint
348 UTILITIES
/set-version.pl
-o
$(TAG
)
349 git commit
-a
-m
"Update website to show $(TAG) as current release"
352 # ~$ make relup only makes sense from orgmode.org server
353 # Don't call it from your computer!
360 @if
[ "X$(TAG)" = "X" ]; then echo
"*** No tag ***"; exit
1; fi
363 UTILITIES
/gplmanual.pl
368 cp org-
$(TAG
).zip org-
$(TAG
).
tar.gz RELEASEDIR
369 cp doc
/org.pdf doc
/orgcard.pdf doc
/org.texi doc
/org.html RELEASEDIR
370 cp doc
/org_dual_license.texi RELEASEDIR
371 cp doc
/orgguide.pdf doc
/orgcard.txt RELEASEDIR
372 cp RELEASEDIR
/org-
$(TAG
).zip RELEASEDIR
/org.zip
373 cp RELEASEDIR
/org-
$(TAG
).
tar.gz RELEASEDIR
/org.
tar.gz
375 # ~$ make sync_release only makes sense from orgmode.org server
376 # Don't call it from your computer!
378 rsync
-avuz RELEASEDIR
/ /var
/www
/orgmode.org
/
380 # ~$ make sync_manual only makes sense from orgmode.org server
381 # Don't call it from your computer!
383 rsync
-avuz
--delete doc
/manual
/ /var
/www
/orgmode.org
/manual
/
384 rsync
-avuz
--delete doc
/guide
/ /var
/www
/orgmode.org
/guide
/
387 @if
[ "X$(TAG)" = "X" ]; then echo
"*** No tag ***"; exit
1; fi
388 touch doc
/org.texi doc
/orgcard.
tex # force update
392 ${MAKE} lisp
/org-install.el
393 rm -rf org-
$(TAG
) org-
$(TAG
).zip
395 $(MKDIR
) org-
$(TAG
)/doc
396 $(MKDIR
) org-
$(TAG
)/lisp
397 cp
-r
$(LISPFILES
) org-
$(TAG
)/lisp
398 cp
-r
$(DOCFILES
) $(CARDFILES
) org-
$(TAG
)/doc
399 cp
-r
$(DISTFILES_extra
) org-
$(TAG
)/
400 cp
-r README_DIST org-
$(TAG
)/README
401 zip
-r org-
$(TAG
).zip org-
$(TAG
)
402 tar zcvf org-
$(TAG
).
tar.gz org-
$(TAG
)
405 @if
[ "X$(PKG_TAG)" = "X" ]; then echo
"*** No tag ***"; exit
1; fi
406 touch doc
/org.texi doc
/orgcard.
tex # force update
409 rm -rf org-
$(PKG_TAG
) org-
$(PKG_TAG
).
tar
410 $(MKDIR
) org-
$(PKG_TAG
)
411 cp
-r
$(PKG_FILES
) org-
$(PKG_TAG
)
412 echo
"(define-package \"org\" \"$(PKG_TAG)\" \"$(PKG_DOC)\" $(PKG_REQ))" > org-
$(PKG_TAG
)/org-pkg.el
413 tar cf org-
$(PKG_TAG
).
tar org-
$(PKG_TAG
) --remove-files
417 rm -f lisp
/org-install.el
426 find contrib
-name \
*~
-exec
rm {} \
;
431 -(cd doc
&& rm -f org.pdf org org.html orgcard.pdf orgguide.pdf
)
432 -(cd doc
&& rm -f
*.aux
*.cp
*.cps
*.
dvi *.fn
*.fns
*.ky
*.kys
*.pg
*.pgs
)
433 -(cd doc
&& rm -f
*.toc
*.tp
*.tps
*.vr
*.vrs
*.log
*.html
*.ps
)
434 -(cd doc
&& rm -f orgcard_letter.
tex orgcard_letter.pdf
)
435 -(cd doc
&& rm -rf manual
)
440 rm -rf org-7
*zip org-7
*tar.gz
447 git push orgmode@orgmode.org
:org-mode.git master
450 git tag
-m
"Adding tag" -a
$(TAG
)
451 git push orgmode@orgmode.org
:org-mode.git
$(TAG
)
454 git tag
-m
"Adding release tag" -a release_
$(TAG
)
455 git push orgmode@orgmode.org
:org-mode.git release_
$(TAG
)
459 lisp
/org.elc
: lisp
/org-macs.el lisp
/org-compat.el lisp
/org-faces.el
460 lisp
/org-agenda.elc
: lisp
/org.el
461 lisp
/org-ascii.elc
: lisp
/org-exp.el
462 lisp
/org-attach.elc
: lisp
/org.el lisp
/org-id.el
463 lisp
/org-archive.elc
: lisp
/org.el
464 lisp
/org-bbdb.elc
: lisp
/org.el
465 lisp
/org-beamer.elc
: lisp
/org.el
466 lisp
/org-bibtex.elc
: lisp
/org.el
467 lisp
/org-capture.elc
: lisp
/org.el lisp
/org-mks.el
468 lisp
/org-clock.elc
: lisp
/org.el
469 lisp
/org-colview.elc
: lisp
/org.el
470 lisp
/org-colview-xemacs.elc
: lisp
/org.el
471 lisp
/org-compat.elc
: lisp
/org-macs.el
472 lisp
/org-crypt.elc
: lisp
/org-crypt.el lisp
/org.el
473 lisp
/org-ctags.elc
: lisp
/org.el
474 lisp
/org-datetree.elc
: lisp
/org.el
475 lisp
/org-docview.elc
: lisp
/org.el
476 lisp
/org-entities.elc
:
477 lisp
/org-exp.elc
: lisp
/org.el lisp
/org-agenda.el
478 lisp
/org-exp-blocks.elc
: lisp
/org.el
479 lisp
/org-latex.elc
: lisp
/org.el lisp
/org-exp.el lisp
/org-beamer.el
480 lisp
/org-docbook.elc
: lisp
/org.el lisp
/org-exp.el
481 lisp
/org-faces.elc
: lisp
/org-macs.el lisp
/org-compat.el
482 lisp
/org-feed.elc
: lisp
/org.el
483 lisp
/org-footnotes.elc
: lisp
/org-macs.el lisp
/org-compat.el
484 lisp
/org-freemind.elc
: lisp
/org.el
485 lisp
/org-gnus.elc
: lisp
/org.el
486 lisp
/org-html.elc
: lisp
/org-exp.el
487 lisp
/org-habit.elc
: lisp
/org.el lisp
/org-agenda.el
488 lisp
/org-icalendar.elc
: lisp
/org-exp.el
489 lisp
/org-id.elc
: lisp
/org.el
490 lisp
/org-indent.elc
: lisp
/org.el lisp
/org-macs.el lisp
/org-compat.el
491 lisp
/org-info.elc
: lisp
/org.el
492 lisp
/org-inlinetask.elc
:
493 lisp
/org-irc.elc
: lisp
/org.el
494 lisp
/org-jsinfo.elc
: lisp
/org.el lisp
/org-exp.el
495 lisp
/org-list.elc
: lisp
/org-macs.el lisp
/org-compat.el
496 lisp
/org-mac-message.elc
: lisp
/org.el
498 lisp
/org-mew.elc
: lisp
/org.el
499 lisp
/org-mhe.elc
: lisp
/org.el
501 lisp
/org-mobile.elc
: lisp
/org.el
502 lisp
/org-mouse.elc
: lisp
/org.el
503 lisp
/org-plot.elc
: lisp
/org.el lisp
/org-exp.el lisp
/org-table.el
504 lisp
/org-publish.elc
:
505 lisp
/org-protocol.elc
: lisp
/org.el
506 lisp
/org-remember.elc
: lisp
/org.el
507 lisp
/org-rmail.elc
: lisp
/org.el
508 lisp
/org-special-blocks.elc
: lisp
/org-compat.el
509 lisp
/org-src.elc
: lisp
/org-macs.el lisp
/org-compat.el
510 lisp
/org-table.elc
: lisp
/org.el
511 lisp
/org-taskjuggler.elc
: lisp
/org.el lisp
/org-exp.el
512 lisp
/org-timer.elc
: lisp
/org.el
513 lisp
/org-vm.elc
: lisp
/org.el
514 lisp
/org-w3m.elc
: lisp
/org.el
515 lisp
/org-wl.elc
: lisp
/org.el
516 lisp
/org-xoxo.elc
: lisp
/org-exp.el
518 # Describe valid make targets for org-mode.
520 @echo
"make - compile Org ELisp files"
521 @echo
"make clean - clean Elisp and documentation files"
522 @echo
"make all - compile Org ELisp files and documentation"
524 @echo
"make doc - make all documentation"
525 @echo
"make info - make Info documentation"
526 @echo
"make html - make HTML documentation"
527 @echo
"make pdf - make pdf documentation"
528 @echo
"make card - make refcards documentation"
530 @echo
"make install - install Org"
531 @echo
"make install-lisp - install Org ELisp files"
532 @echo
"make install-info - install Org Info file"
533 @echo
"make install-info-debian - install info on old debian systems (newer use ginstall)"