Makefile 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172
  1. # Makefile - for the org-mode distribution
  2. #
  3. # Maintainer: Carsten Dominik <dominik@science.uva.nl>
  4. # Version: VERSIONTAG
  5. #
  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'.
  8. ##----------------------------------------------------------------------
  9. ## YOU MUST EDIT THE FOLLOWING LINES
  10. ##----------------------------------------------------------------------
  11. # Name of your emacs binary
  12. EMACS=emacs
  13. # Where local software is found
  14. prefix=/usr/local
  15. # Where local lisp files go.
  16. lispdir = $(prefix)/share/emacs/site-lisp
  17. # Where info files go.
  18. infodir = $(prefix)/info
  19. ##----------------------------------------------------------------------
  20. ## YOU MAY NEED TO EDIT THESE
  21. ##----------------------------------------------------------------------
  22. # Using emacs in batch mode.
  23. BATCH=$(EMACS) -batch -q
  24. # Specify the byte-compiler for compiling org-mode files
  25. ELC= $(BATCH) -f batch-byte-compile
  26. # How to make a pdf file from a texinfo file
  27. TEXI2PDF = texi2pdf
  28. # How to create directories
  29. MKDIR = mkdir -p
  30. # How to create the info files from the texinfo file
  31. MAKEINFO = makeinfo
  32. # How to create the HTML file
  33. TEXI2HTML = makeinfo --html --number-sections --no-split
  34. # How to move the byte compiled files to their destination.
  35. MV = mv
  36. # How to copy the lisp files to their distination.
  37. CP = cp -p
  38. ##----------------------------------------------------------------------
  39. ## BELOW THIS LINE ON YOUR OWN RISK!
  40. ##----------------------------------------------------------------------
  41. # The following variables need to be defined by the maintainer
  42. LISPFILES = org.el org-publish.el org-mouse.el org-install.el
  43. ELCFILES = $(LISPFILES:.el=.elc)
  44. DOCFILES = org.texi org.pdf org orgcard.tex orgcard.pdf
  45. TEXIFILES = org.texi
  46. INFOFILES = org
  47. HTMLDIR = /home/dominik/public_html/Tools/org
  48. .SUFFIXES: .el .elc .texi
  49. SHELL = /bin/sh
  50. DISTFILES= README ${LISPFILES} ${DOCFILES} Makefile
  51. DISTFILES_xemacs= xemacs/noutline.el xemacs/ps-print-invisible.el xemacs/README
  52. all: $(ELCFILES)
  53. install: install-lisp
  54. doc: org.html org.pdf orgcard.pdf
  55. p:
  56. make pdf && open org.pdf
  57. c:
  58. make card && gv orgcard.ps
  59. install-lisp: $(LISPFILES) $(ELCFILES)
  60. if [ ! -d $(lispdir) ]; then $(MKDIR) $(lispdir); else true; fi ;
  61. $(CP) $(LISPFILES) $(lispdir)
  62. $(CP) $(ELCFILES) $(lispdir)
  63. install-info: $(INFOFILES)
  64. if [ ! -d $(infodir) ]; then $(MKDIR) $(infodir); else true; fi ;
  65. $(CP) $(INFOFILES) $(infodir)
  66. install-noutline: xemacs/noutline.elc
  67. if [ ! -d $(lispdir) ]; then $(MKDIR) $(lispdir); else true; fi ;
  68. $(CP) xemacs/noutline.el xemacs/noutline.elc $(lispdir)
  69. org.elc: org.el
  70. org-publish.elc: org-publish.el
  71. org-install.elc: org-install.el
  72. xemacs/noutline.elc: xemacs/noutline.el
  73. org: org.texi
  74. $(MAKEINFO) --no-split org.texi -o org
  75. org.pdf: org.texi
  76. $(TEXI2PDF) org.texi
  77. org.html: org.texi
  78. $(TEXI2HTML) -o org.html org.texi
  79. orgcard.dvi: orgcard.tex
  80. tex orgcard.tex
  81. orgcard.pdf: orgcard.dvi
  82. dvips -q -f -t landscape orgcard.dvi | gs -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=orgcard.pdf -c .setpdfwrite -
  83. orgcard.ps: orgcard.dvi
  84. dvips -t landscape -o orgcard.ps orgcard.dvi
  85. # Below here are special targets for maintenance only
  86. info:
  87. $(MAKEINFO) --no-split org.texi -o org
  88. pdf: org.pdf
  89. card: orgcard.pdf orgcard.ps
  90. xcompile:
  91. xemacs -batch -q -f batch-byte-compile $(LISPFILES)
  92. ecompile:
  93. emacs -batch -q -f batch-byte-compile $(LISPFILES)
  94. distfile:
  95. @if [ "X$(TAG)" = "X" ]; then echo "*** No tag ***"; exit 1; fi
  96. touch org.texi orgcard.tex
  97. make info
  98. make doc
  99. rm -rf org-$(TAG) org-$(TAG).zip
  100. $(MKDIR) org-$(TAG)
  101. $(MKDIR) org-$(TAG)/xemacs
  102. cp $(DISTFILES) org-$(TAG)/
  103. cp $(DISTFILES_xemacs) org-$(TAG)/xemacs/
  104. zip -r org-$(TAG).zip org-$(TAG)
  105. gtar zcvf org-$(TAG).tar.gz org-$(TAG)
  106. dist:
  107. make distfile TAG=$(TAG)
  108. cp org-$(TAG).zip org-$(TAG).tar.gz $(HTMLDIR)
  109. rm -f $(HTMLDIR)/org.zip $(HTMLDIR)/org.tar.gz
  110. (cd $(HTMLDIR); ln -s org-$(TAG).zip org.zip)
  111. (cd $(HTMLDIR); ln -s org-$(TAG).tar.gz org.tar.gz)
  112. make doc
  113. cp org.pdf orgcard.pdf org.texi org.html $(HTMLDIR)
  114. minidist:
  115. rm -f org-$(TAG).zip
  116. zip org-$(TAG).zip org.el
  117. scp org-$(TAG).zip remote.science.uva.nl:public_html/Tools/org/
  118. clean:
  119. rm -f $(ELCFILES) org.pdf org org.html orgcard.pdf orgcard.ps
  120. rm -f *~
  121. rm -f *.aux *.cp *.cps *.dvi *.fn *.fns *.ky *.kys *.pg *.pgs
  122. rm -f *.toc *.tp *.tps *.vr *.vrs *.log *.html *.ps
  123. .el.elc:
  124. $(ELC) $<