SCM Repository
Annotation of /sml/trunk/sml-mode/Makefile
Parent Directory
|
Revision Log
Revision 769 - (view) (download)
1 : | monnier | 319 | # Makefile for emacs-lisp package |
2 : | monnier | 300 | |
3 : | monnier | 535 | #ident "@(#)$Name$:$Id$" |
4 : | |||
5 : | monnier | 394 | # Copyright (C) 1998-1999 Stefan Monnier <monnier@cs.yale.edu> |
6 : | |||
7 : | monnier | 319 | # This file is free software; you can redistribute it and/or modify it |
8 : | # under the terms of the GNU General Public License as published by the | ||
9 : | # Free Software Foundation; either version 2, or (at your option) any | ||
10 : | # later version. | ||
11 : | monnier | 300 | |
12 : | monnier | 319 | # This file is distributed in the hope that it will be useful, but WITHOUT |
13 : | # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | ||
14 : | # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License | ||
15 : | # for more details. | ||
16 : | monnier | 300 | |
17 : | monnier | 394 | # You should have received a copy of the GNU General Public License |
18 : | # along with GNU Emacs; see the file COPYING. If not, write to | ||
19 : | # the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. | ||
20 : | |||
21 : | monnier | 535 | # load the package-specific settings |
22 : | include makefile.pkg | ||
23 : | |||
24 : | # set up the usual installation paths | ||
25 : | monnier | 319 | prefix = /usr/local |
26 : | monnier | 394 | datadir = $(prefix)/share |
27 : | monnier | 319 | |
28 : | # the directory where you install third-party emacs packges | ||
29 : | monnier | 394 | lispdir = $(datadir)/emacs/site-lisp |
30 : | monnier | 535 | |
31 : | # the directory where the .elc files will be installed | ||
32 : | elcdir = $(lispdir)/$(PACKAGE) | ||
33 : | # the directory where the .el files will be installed | ||
34 : | eldir = $(elcdir) | ||
35 : | |||
36 : | # the file where the initialization goes. | ||
37 : | #startupfile = $(HOME/.emacs | ||
38 : | monnier | 395 | startupfile = $(lispdir)/site-start.el |
39 : | monnier | 319 | |
40 : | # the directory where you installed the elib .elc files. | ||
41 : | # This is only needed if your site-start.el (or default.el) does not | ||
42 : | # set up elib correctly. | ||
43 : | elibdir = $(lispdir)/elib | ||
44 : | |||
45 : | # the directory where you install the info doc | ||
46 : | infodir = $(prefix)/info | ||
47 : | docdir = $(prefix)/doc | ||
48 : | |||
49 : | monnier | 394 | EMACS = emacs |
50 : | MAKEINFO= makeinfo | ||
51 : | TEXI2DVI= texi2dvi | ||
52 : | SHELL = /bin/sh | ||
53 : | DVIPS = dvips | ||
54 : | CP = cp | ||
55 : | monnier | 535 | RM = rm -f |
56 : | monnier | 394 | MKDIR = mkdir -p |
57 : | ETAGS = etags | ||
58 : | |||
59 : | monnier | 319 | ###################################################################### |
60 : | ### No changes below this line should be necessary ### | ||
61 : | ###################################################################### | ||
62 : | |||
63 : | ELFLAGS = --eval '(setq load-path (append (list "." "$(elibdir)" "$(lispdir)") load-path))' | ||
64 : | ELC = $(EMACS) -batch $(ELFLAGS) -f batch-byte-compile | ||
65 : | |||
66 : | ELCFILES = $(ELFILES:.el=.elc) | ||
67 : | |||
68 : | TEXEXTS = *.cps *.fns *.kys *.vr *.tp *.pg *.log *.aux *.toc *.cp *.ky *.fn | ||
69 : | |||
70 : | .SUFFIXES: .elc .el .info .ps .dvi .texi | ||
71 : | .PHONY: elcfiles info clean distclean default | ||
72 : | .PHONY: install_startup install_elc install install_el install_info | ||
73 : | monnier | 395 | .PHONY: dvi postscript |
74 : | monnier | 319 | |
75 : | .el.elc: | ||
76 : | $(ELC) $< | ||
77 : | |||
78 : | .texi.info: | ||
79 : | monnier | 394 | $(MAKEINFO) $< |
80 : | monnier | 319 | |
81 : | .texi.dvi: | ||
82 : | monnier | 394 | $(TEXI2DVI) $< |
83 : | monnier | 319 | |
84 : | .dvi.ps: | ||
85 : | monnier | 394 | $(DVIPS) -f $< >$@ |
86 : | monnier | 319 | |
87 : | ###################################################################### | ||
88 : | |||
89 : | default: elcfiles | ||
90 : | |||
91 : | elcfiles: $(ELCFILES) | ||
92 : | info: $(PACKAGE).info | ||
93 : | |||
94 : | monnier | 535 | install_elc: $(ELCFILES) $(PACKAGE)-startup.el |
95 : | monnier | 394 | $(MKDIR) $(elcdir) |
96 : | monnier | 535 | for f in $(ELCFILES) $(PACKAGE)-startup.el; do \ |
97 : | $(CP) $$f $(elcdir)/$$f ;\ | ||
98 : | done | ||
99 : | monnier | 319 | |
100 : | install_el: | ||
101 : | monnier | 394 | $(MKDIR) $(eldir) |
102 : | monnier | 535 | for f in $(ELFILES); do \ |
103 : | $(CP) $$f $(eldir)/$$f ;\ | ||
104 : | done | ||
105 : | monnier | 319 | |
106 : | install_info: $(PACKAGE).info | ||
107 : | monnier | 394 | $(MKDIR) $(infodir) |
108 : | $(CP) *.info* $(infodir)/ | ||
109 : | monnier | 535 | -[ ! -w $(infodir)/dir ] \ |
110 : | || install-info --info-dir=$(infodir)/dir $(PACKAGE).info | ||
111 : | monnier | 319 | |
112 : | install_startup: | ||
113 : | monnier | 394 | $(MKDIR) $(lispdir) |
114 : | monnier | 535 | @if grep $(PACKAGE) $(lispdir)/site-start.el >/dev/null 2>&1 || \ |
115 : | grep $(PACKAGE) $(startupfile) >/dev/null 2>&1 || \ | ||
116 : | monnier | 394 | grep $(PACKAGE) $(lispdir)/default.el >/dev/null 2>&1; then \ |
117 : | monnier | 535 | echo "**********************************************************" ;\ |
118 : | echo "*** It seems you already have some setup code" ;\ | ||
119 : | echo "*** for $(PACKAGE) in your startup files." ;\ | ||
120 : | echo "*** Check that it properly loads \"$(PACKAGE)-startup\"" ;\ | ||
121 : | echo "**********************************************************" ;\ | ||
122 : | monnier | 394 | else \ |
123 : | monnier | 535 | echo 'echo ";; load $(PACKAGE) setup code" >>$(startupfile)' ;\ |
124 : | echo ";; load $(PACKAGE) setup code" >>$(startupfile) ;\ | ||
125 : | echo 'echo "(add-to-list '\''load-path \"$(elcdir)\")" >>$(startupfile)' ;\ | ||
126 : | echo "(add-to-list 'load-path \"$(elcdir)\")" >>$(startupfile) ;\ | ||
127 : | echo 'echo "(load \"$(PACKAGE)-startup\")" >>$(startupfile)' ;\ | ||
128 : | echo "(load \"$(PACKAGE)-startup\")" >>$(startupfile) ;\ | ||
129 : | monnier | 319 | fi |
130 : | |||
131 : | monnier | 395 | postscript: $(PACKAGE).ps |
132 : | dvi: $(PACKAGE).dvi | ||
133 : | install_dvi: dvi | ||
134 : | monnier | 394 | $(MKDIR) $(docdir) |
135 : | monnier | 535 | $(CP) `find . -type f -name '*.dvi' -print` $(docdir)/ |
136 : | monnier | 319 | |
137 : | monnier | 769 | install: install_elc install_info install_startup install_el |
138 : | monnier | 319 | |
139 : | clean: | ||
140 : | monnier | 394 | $(RM) *~ core .\#* $(TEXEXTS) |
141 : | monnier | 319 | |
142 : | monnier | 394 | TAGS tags: |
143 : | $(ETAGS) $(ELFILES) | ||
144 : | |||
145 : | monnier | 319 | distclean: clean |
146 : | $(RM) *.elc *.dvi *.info* *.ps | ||
147 : | |||
148 : | ###################################################################### | ||
149 : | ### don't look below ### | ||
150 : | ###################################################################### | ||
151 : | |||
152 : | monnier | 535 | $(PACKAGE)-startup.el: $(ELFILES) |
153 : | [ -f $@ ] || echo '' >$@ | ||
154 : | monnier | 378 | $(EMACS) --batch --eval '(setq generated-autoload-file "'`pwd`'/$@")' -f batch-update-autoloads "." |
155 : | |||
156 : | ## | ||
157 : | |||
158 : | monnier | 319 | TAG = $(shell echo v$(VERSION) | tr '.' '_') |
159 : | ftpdir=/home/ftp/pub/monnier/$(PACKAGE) | ||
160 : | monnier | 769 | cvsmodule=elisp/$(PACKAGE) |
161 : | cvsroot=$(cat CVS/Root) | ||
162 : | monnier | 319 | |
163 : | dist: | ||
164 : | cvs tag -F $(TAG) &&\ | ||
165 : | cd $(TMP) &&\ | ||
166 : | monnier | 769 | cvs -d $(cvsroot) export -r $(TAG) -d $(PACKAGE)-$(VERSION) $(cvsmodule) &&\ |
167 : | monnier | 319 | cd $(PACKAGE)-$(VERSION) &&\ |
168 : | monnier | 535 | gmake info $(PACKAGE)-startup.el &&\ |
169 : | monnier | 319 | cd .. &&\ |
170 : | ztar $(PACKAGE)-$(VERSION) &&\ | ||
171 : | rm -rf $(PACKAGE)-$(VERSION) | ||
172 : | mv $(TMP)/$(PACKAGE)-$(VERSION).tar.gz $(ftpdir)/ | ||
173 : | ln -sf $(PACKAGE)-$(VERSION).tar.gz $(ftpdir)/$(PACKAGE).tar.gz |
root@smlnj-gforge.cs.uchicago.edu | ViewVC Help |
Powered by ViewVC 1.0.0 |