default.mk 5.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163
  1. ##----------------------------------------------------------------------
  2. ## NEVER EDIT THIS FILE, PUT ANY ADAPTATIONS INTO local.mk
  3. ##-8<-------------------------------------------------------------------
  4. ## CHECK AND ADAPT THE FOLLOWING DEFINITIONS
  5. ##----------------------------------------------------------------------
  6. # Name of your emacs binary
  7. EMACS = emacs
  8. # Where local software is found
  9. prefix = /usr/share
  10. # Where local lisp files go.
  11. lispdir= $(prefix)/emacs/site-lisp/org
  12. # Where local data files go.
  13. datadir = $(prefix)/emacs/etc/org
  14. # Where info files go.
  15. infodir = $(prefix)/info
  16. # Define if you only need info documentation, the default includes html and pdf
  17. #ORG_MAKE_DOC = info # html pdf
  18. # Define if you want to include some (or all) files from contrib/lisp
  19. # just the filename please (no path prefix, no .el suffix), maybe with globbing
  20. #ORG_ADD_CONTRIB = ox-* # e.g. the contributed exporter
  21. # Where to create temporary files for the testsuite
  22. # respect TMPDIR if it is already defined in the environment
  23. TMPDIR ?= /tmp
  24. testdir = $(TMPDIR)/tmp-orgtest
  25. # Configuration for testing
  26. # add options before standard load-path
  27. BTEST_PRE =
  28. # add options after standard load path
  29. BTEST_POST =
  30. # -L <path-to>/ert # needed for Emacs23, Emacs24 has ert built in
  31. # -L <path-to>/ess # needed for running R tests
  32. # -L <path-to>/htmlize # need at least version 1.34 for source code formatting
  33. BTEST_OB_LANGUAGES = awk C fortran maxima lilypond octave perl python
  34. # R # requires ESS to be installed and configured
  35. # ruby # requires inf-ruby to be installed and configured
  36. # extra packages to require for testing
  37. BTEST_EXTRA =
  38. # ess-site # load ESS for R tests
  39. ##->8-------------------------------------------------------------------
  40. ## YOU MAY NEED TO ADAPT THESE DEFINITIONS
  41. ##----------------------------------------------------------------------
  42. # How to run tests
  43. req-ob-lang = --eval '(require '"'"'ob-$(ob-lang))'
  44. lst-ob-lang = ($(ob-lang) . t)
  45. req-extra = --eval '(require '"'"'$(req))'
  46. BTEST_RE ?= \\(org\\|ob\\)
  47. BTEST_INIT = $(BATCH) \
  48. $(BTEST_PRE) \
  49. --eval '(add-to-list '"'"'load-path (concat default-directory "lisp"))' \
  50. --eval '(add-to-list '"'"'load-path (concat default-directory "testing"))' \
  51. $(BTEST_POST)
  52. BTEST = $(BTEST_INIT) \
  53. -l org-batch-test-init \
  54. --eval '(setq \
  55. org-batch-test t \
  56. org-babel-load-languages \
  57. (quote ($(foreach ob-lang,$(BTEST_OB_LANGUAGES) emacs-lisp shell org,$(lst-ob-lang)))) \
  58. org-test-select-re "$(BTEST_RE)" \
  59. )' \
  60. -l org-loaddefs.el \
  61. -l cl -l testing/org-test.el \
  62. -l ert -l org -l ox \
  63. $(foreach req,$(BTEST_EXTRA),$(req-extra)) \
  64. --eval '(org-test-run-batch-tests org-test-select-re)'
  65. # Running a plain emacs with no config and this Org-mode loaded. This
  66. # should be useful for testing and for manually verrifying problems.
  67. NOBATCH = $(filter-out -batch,$(BTEST_INIT)) -l org -f org-version
  68. # Using emacs in batch mode.
  69. # BATCH = $(EMACS) -batch -vanilla # XEmacs
  70. BATCH = $(EMACS) -batch -Q \
  71. --eval '(setq vc-handled-backends nil org-startup-folded nil)'
  72. # Emacs must be started in toplevel directory
  73. BATCHO = $(BATCH) \
  74. --eval '(add-to-list '"'"'load-path "./lisp")'
  75. # How to generate local.mk
  76. MAKE_LOCAL_MK = $(BATCHO) \
  77. --eval '(load "org-compat.el")' \
  78. --eval '(load "../mk/org-fixup.el")' \
  79. --eval '(org-make-local-mk)'
  80. # Emacs must be started in lisp directory
  81. BATCHL = $(BATCH) \
  82. --eval '(add-to-list '"'"'load-path ".")'
  83. # How to generate org-loaddefs.el
  84. MAKE_ORG_INSTALL = $(BATCHL) \
  85. --eval '(load "org-compat.el")' \
  86. --eval '(load "../mk/org-fixup.el")' \
  87. --eval '(org-make-org-loaddefs)'
  88. # How to generate org-version.el
  89. MAKE_ORG_VERSION = $(BATCHL) \
  90. --eval '(load "org-compat.el")' \
  91. --eval '(load "../mk/org-fixup.el")' \
  92. --eval '(org-make-org-version "$(ORGVERSION)" "$(GITVERSION)" "'$(datadir)'")'
  93. # How to byte-compile the whole source directory
  94. ELCDIR = $(BATCHL) \
  95. --eval '(batch-byte-recompile-directory 0)'
  96. # How to byte-compile a single file
  97. ELC = $(BATCHL) \
  98. --eval '(batch-byte-compile)'
  99. # How to make a pdf file from a texinfo file
  100. TEXI2PDF = texi2pdf --batch --clean --expand
  101. # How to make a pdf file from a tex file
  102. PDFTEX = pdftex
  103. # How to create directories with leading path components
  104. # MKDIR = mkdir -m 755 -p # try this if you have no install
  105. MKDIR = install -m 755 -d
  106. # How to create the info files from the texinfo file
  107. MAKEINFO = makeinfo
  108. # How to create the HTML file
  109. TEXI2HTML = makeinfo --html --number-sections
  110. # How to find files
  111. FIND = find
  112. # How to remove files
  113. RM = rm -f
  114. # How to remove files recursively
  115. RMR = rm -fr
  116. # How to copy the lisp files and elc files to their destination.
  117. # CP = cp -p # try this if you have no install
  118. CP = install -m 644 -p
  119. # How to obtain administrative privileges
  120. # leave blank if you don't need this
  121. # SUDO =
  122. SUDO = sudo
  123. # Name of the program to install info files
  124. # INSTALL_INFO = ginstall-info # Debian: avoid harmless warning message
  125. INSTALL_INFO = install-info
  126. # target method for 'compile'
  127. ORGCM = dirall
  128. # ORGCM = dirall # 1x slowdown compared to default compilation method
  129. # ORGCM = single # 4x one Emacs process per compilation
  130. # ORGCM = source # 5x ditto, but remove compiled file immediately
  131. # ORGCM = slint1 # 3x possibly elicit more warnings
  132. # ORGCM = slint2 # 7x possibly elicit even more warnings