Makefile 7.84 KB
Newer Older
Linus Tolke's avatar
Linus Tolke committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#
# $Id$
# Copyright (C) 1991  Lysator Academic Computer Association.
#
# This file is part of the LysKOM server.
# 
# LysKOM is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by 
# the Free Software Foundation; either version 1, or (at your option) 
# any later version.
# 
# LysKOM is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
# for more details.
# 
# You should have received a copy of the GNU General Public License
# along with LysKOM; see the file COPYING.  If not, write to
# Lysator, c/o ISY, Linkoping University, S-581 83 Linkoping, SWEDEN,
# or the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, 
# MA 02139, USA.
#
# Please mail bug reports to bug-lyskom@lysator.liu.se. 
#
25
26
# $Id$
# $Log$
Linus Tolke's avatar
Linus Tolke committed
27
28
29
30
# Revision 36.3  1993/05/27 15:22:43  linus
# install in local/var/elisp
#
# Revision 36.2  1993/05/27  13:21:12  linus
Linus Tolke's avatar
Linus Tolke committed
31
32
33
# obel18 => diag19
#
# Revision 36.1  1993/04/26  19:35:11  linus
Linus Tolke's avatar
Linus Tolke committed
34
35
36
# New version
#
# Revision 35.22  1993/04/26  19:30:54  linus
Linus Tolke's avatar
Linus Tolke committed
37
38
39
# Rewound to before prefetch.
#
# Revision 35.21  1993/02/04  04:00:48  linus
40
41
42
# Removed the import.make dependencie of the Makefile.
#
# Revision 35.20  1992/07/30  19:49:22  linus
43
44
45
# Moved around functions to the new reading.el file.
#
# Revision 35.19  1992/07/26  23:14:02  linus
Linus Tolke's avatar
Linus Tolke committed
46
47
48
# Added prefetch.el
#
# Revision 35.18  1992/06/16  11:33:32  linus
49
50
51
# Alfa-version is replaced upon installation also.
#
# Revision 35.17  1992/05/11  01:55:38  linus
52
53
54
# support for distribution to nanny removed
#
# Revision 35.16  1992/03/28  19:54:10  linus
Linus Tolke's avatar
Linus Tolke committed
55
56
57
# Removed mv to old-versions
#
# Revision 35.15  1992/03/22  21:10:12  linus
Linus Tolke's avatar
Linus Tolke committed
58
59
60
# Moved info-dir.
#
# Revision 35.14  1992/02/10  02:53:33  linus
Linus Tolke's avatar
Linus Tolke committed
61
62
63
# mkdir replaced by $(MKDIR).
#
# Revision 35.13  1991/12/19  12:03:51  linus
Linus Tolke's avatar
Linus Tolke committed
64
65
66
# .elc-files require macros.elc.
#
# Revision 35.12  1991/12/18  04:13:37  linus
Linus Tolke's avatar
$(MAKE)    
Linus Tolke committed
67
68
69
# $(MAKE)
#
# Revision 35.11  1991/10/08  17:11:18  linus
70
71
72
# Splitting the makefile install entries to make it easier to install without doc.
#
# Revision 35.10  1991/10/05  18:15:27  linus
73
74
75
# Now handles the english version of the client also.
#
# Revision 35.9  1991/09/26  14:02:16  linus
76
77
78
79
# Install in the correct directory on the ftp-area.
#
# Revision 35.8  1991/09/16  20:33:44  linus
# r{tt namn p} todo filen i wc.
Linus Tolke's avatar
Linus Tolke committed
80
81
#
# Revision 35.7  1991/09/16  19:59:28  linus
82
83
84
# Makefile now works with clientversion-long.
#
# Revision 35.6  1991/09/16  19:31:37  linus
85
86
87
# Makefile now works with new doc-file names.
#
# Revision 35.5  1991/09/16  18:02:02  linus
Linus Tolke's avatar
Linus Tolke committed
88
89
90
91
92
93
94
# * M ci     Makefile
# * A ci     makealfa.l
# =====================================================
# makealfa.l created to make the alfa version of lyskom.elc
#
# Revision 35.4  1991/09/16  16:40:27  linus
# alfa talar om att det {r alfa i versionsnumret.
95
96
#
# Revision 35.3  1991/09/15  10:07:04  linus
Linus Tolke's avatar
Linus Tolke committed
97
98
99
# Added copyright note
#
# Revision 35.2  1991/09/13  21:42:53  linus
Linus Tolke's avatar
Linus Tolke committed
100
101
102
# Lagt till distclean.
#
# Revision 35.1  1991/08/21  15:44:47  linus
103
104
# Lagt till lyskom-clientversion-long
#
Per Cederqvist's avatar
.    
Per Cederqvist committed
105

106
107
108
GENERIC-CLEAN = *~ *.o core
GENERIC-DIST-CLEAN = TAGS
MKDIR = /bin/mkdir
Linus Tolke's avatar
Linus Tolke committed
109

Per Cederqvist's avatar
.    
Per Cederqvist committed
110
RM = /usr/gnu/bin/rm -vf
111
EMACS-BATCH = emacs -batch -l /usr/local/var/elisp/bytecomp
Per Cederqvist's avatar
.    
Per Cederqvist committed
112
113

# NOTE: lyskom-rest.el must be the last file in PARTS-EL and SRC-ELC.
114
PARTS-EL = komtypes.el clienttypes.el startup.el \
Linus Tolke's avatar
Linus Tolke committed
115
	reading.el \
Per Cederqvist's avatar
.    
Per Cederqvist committed
116
117
118
119
120
	internal.el parse.el services.el cache.el\
	commands1.el commands2.el review.el edit-text.el \
	view-text.el async.el completing-read.el \
	prioritize.el flags.el \
	elib-string.el \
121
	lyskom-rest.el
122
123
124
125
126
127
128
HEADER-EL = macros.el vars.el
HEADER-ELC = macros.elc vars.elc
SWEDISH-EL = swedish-strings.el
SWEDISH-ELC = swedish-strings.elc
ENGLISH-EL = english-strings.el
ENGLISH-ELC = english-strings.elc
SRC-ELC = komtypes.elc clienttypes.elc startup.elc \
Linus Tolke's avatar
Linus Tolke committed
129
	reading.elc \
Per Cederqvist's avatar
.    
Per Cederqvist committed
130
131
132
133
134
	internal.elc parse.elc services.elc cache.elc\
	commands1.elc commands2.elc review.elc edit-text.elc \
	view-text.elc async.elc completing-read.elc \
	prioritize.elc flags.elc \
	elib-string.elc \
135
	lyskom-rest.elc 
Per Cederqvist's avatar
.    
Per Cederqvist committed
136
137
138
139
140
141
142
143
PARTS-ELC = $(SRC-ELC)

.SUFFIXES : .el .elc
.el.elc:
	$(EMACS-BATCH) -l ./macros.elc -f batch-byte-compile $*.el

all: lyskom.elc

Linus Tolke's avatar
Linus Tolke committed
144
LEX = flex -8
145
146
SWEDISH-ALFA-VERSION = /usr/local/src/2kom/lyskom.elc
ENGLISH-ALFA-VERSION = /usr/local/src/2kom/english-lyskom.elc
147
alfa: lyskom.elc makealfa english-lyskom.elc
148
149
	./makealfa < lyskom.elc > $(SWEDISH-ALFA-VERSION)
	./makealfa < english-lyskom.elc > $(ENGLISH-ALFA-VERSION)
150
151
152

lyskom.elc: $(HEADER-ELC) $(SWEDISH-ELC) $(PARTS-ELC)
	cat $(HEADER-ELC) $(SWEDISH-ELC) $(PARTS-ELC) > lyskom.elc
Linus Tolke's avatar
Linus Tolke committed
153

154
155
english-lyskom.elc: $(HEADER-ELC) $(ENGLISH-ELC) $(PARTS-ELC)
	cat $(HEADER-ELC) $(ENGLISH-ELC) $(PARTS-ELC) > english-lyskom.elc
Per Cederqvist's avatar
.    
Per Cederqvist committed
156

157
158
lyskom.el: $(HEADER-EL) $(SWEDISH-EL) $(PARTS-EL)
	cat $(HEADER-EL) $(SWEDISH-EL) $(PARTS-EL) > lyskom.el
Per Cederqvist's avatar
.    
Per Cederqvist committed
159

Linus Tolke's avatar
Linus Tolke committed
160
161
162
makealfa: makealfa.c
	$(CC) -o makealfa $(CFLAGS) makealfa.c -ll

Linus Tolke's avatar
Linus Tolke committed
163
$(SRC-ELC) $(SWEDISH-ELC) $(ENGLISH-ELC): macros.elc
Per Cederqvist's avatar
.    
Per Cederqvist committed
164
165
166
167
168
169
170
171
172
173
174
175
176
177

elc-files: $(HEADER-ELC) $(PARTS-ELC) 


#Detta kr{ver gnu-make. Tyv{rr funkade inte $(SRC-ELC)-prylen l{ngre ner alls.
#Kanske denna $(SRC-ELC) pryl fungerar.
#$(SRC-ELC) :%.elc: %.el macros.elc
#	$(EMACS-BATCH) -l ./macros.elc -f batch-byte-compile $<

#$(SRC-ELC):
#	$(EMACS-BATCH) -l ./macros.el -f batch-byte-compile $*.el


wc:
178
	@wc $(HEADER-EL) $(PARTS-EL) $(SWEDISH-EL) $(ENGLISH-EL)
Linus Tolke's avatar
Linus Tolke committed
179
	@wc ../doc/elisp-client.latexinfo ChangeLog ../misc/todo
Per Cederqvist's avatar
.    
Per Cederqvist committed
180
181

tags:
182
	etags $(HEADER-EL) $(PARTS-EL) $(SWEDISH-EL) $(ENGLISH-EL)
Per Cederqvist's avatar
.    
Per Cederqvist committed
183
184

doc:
Linus Tolke's avatar
$(MAKE)    
Linus Tolke committed
185
	(cd ../doc ; $(MAKE) elisp-client elisp-client.txt ; )
Per Cederqvist's avatar
.    
Per Cederqvist committed
186

187
install: installnodoc installdoc
Per Cederqvist's avatar
.    
Per Cederqvist committed
188

189
installnodoc: lyskom.elc lyskom.el
Linus Tolke's avatar
Linus Tolke committed
190
	cp lyskom.elc /usr/local/var/elisp/lyskom.elc
191
	cp lyskom.elc $(SWEDISH-ALFA-VERSION)
192
#	rcp lyskom.elc nanny:/usr/local/lib/elisp/lyskom.elc
193
194
	(VER=`grep "lyskom-clientversion " vars.el | \
	 sed -n 's/^.*defconst.*lyskom-clientversion[^"]*"\([^"]*\)".*$$/\1/p'`;\
195
196
	 cp lyskom.elc lyskom-$${VER}.elc;\
	 compress lyskom-$${VER}.elc;\
197
	 mv lyskom-$${VER}.elc.Z /usr/local/ftp/pub/lyskom/elisp-client;\
Per Cederqvist's avatar
.    
Per Cederqvist committed
198
199
	 cp lyskom.el lyskom-$${VER}.el;\
	 compress lyskom-$${VER}.el;\
Linus Tolke's avatar
Linus Tolke committed
200
201
	 cp lyskom-$${VER}.el.Z /usr/local/ftp/pub/lyskom/elisp-client;)

202
203
204
205

installdoc: doc
	(VER=`grep "lyskom-clientversion " vars.el | \
	 sed -n 's/^.*defconst.*lyskom-clientversion[^"]*"\([^"]*\)".*$$/\1/p'`;\
206
207
208
	 cp ../doc/elisp-client ../doc/elisp-client.txt .;\
	 compress elisp-client elisp-client.txt;\
	 mv elisp-client.Z \
209
		/usr/local/ftp/pub/lyskom/elisp-client/elisp-client-$${VER}.info.Z; \
210
	 mv elisp-client.txt.Z \
211
	     /usr/local/ftp/pub/lyskom/elisp-client/elisp-client-$${VER}.txt.Z; \
Linus Tolke's avatar
Linus Tolke committed
212
	 cp ../doc/elisp-client /usr/gnu/info; \
Per Cederqvist's avatar
.    
Per Cederqvist committed
213
214
215
	)

clean:
Linus Tolke's avatar
Linus Tolke committed
216
	$(RM) *~ *.elc $(GENERIC-CLEAN) makealfa.c
Per Cederqvist's avatar
.    
Per Cederqvist committed
217
218
	-$(RM) -r distribution

Linus Tolke's avatar
Linus Tolke committed
219
distclean: clean
Linus Tolke's avatar
Linus Tolke committed
220
	$(RM) $(GENERIC-DIST-CLEAN) makealfa Topdir.make */Topdir.make
Linus Tolke's avatar
Linus Tolke committed
221

Per Cederqvist's avatar
.    
Per Cederqvist committed
222
223
224

distrib distribution: lyskom.el lyskom.elc doc
	-$(RM) -r distribution
Linus Tolke's avatar
Linus Tolke committed
225
	$(MKDIR)  distribution
Per Cederqvist's avatar
.    
Per Cederqvist committed
226
227
	cp distribution-makefile distribution/Makefile
	cp distribution-README distribution/README
228
	cp $(HEADER-EL) $(PARTS-EL) $(SWEDISH-EL) $(ENGLISH-EL) distribution
Per Cederqvist's avatar
.    
Per Cederqvist committed
229
230
231
232
233
	cat distribution-README vars.el > distribution/vars.el
	cp README distribution
	cat distribution-README lyskom.el  > distribution/lyskom.el
	$(RM) lyskom.el
	cat distribution-README lyskom.elc > distribution/lyskom.elc
234
	cp ../doc/elisp-client.txt ../doc/elisp-client distribution
Per Cederqvist's avatar
.    
Per Cederqvist committed
235
	cd distribution; \
236
	  shar -v -cCmx -l 50 -o PARTS README Makefile $(HEADER-EL) $(PARTS-EL)  $(SWEDISH-EL) $(ENGLISH-EL)
Per Cederqvist's avatar
.    
Per Cederqvist committed
237
238
239
240
241
242
	cd distribution; \
	  shar -v -cCmx -l 50 -o ALL lyskom.el
	cd distribution; \
	  shar -v -cCmx -l 50 -o BYTEC README lyskom.elc
	cd distribution; \
	  ( $(RM) lyskom.elc ; \
Linus Tolke's avatar
Linus Tolke committed
243
	    sed 's/kom\.lysator\.liu\.se/diag19.ida.liu.se/g' > lyskom.elc )\
Per Cederqvist's avatar
.    
Per Cederqvist committed
244
	  < lyskom.elc ; \
245
	  chmod 644 lyskom.el lyskom.elc elisp-client.txt
Per Cederqvist's avatar
.    
Per Cederqvist committed
246
	cd distribution; \
247
	  shar -v -cCmx -l 50 -o DOC elisp-client.txt
Per Cederqvist's avatar
.    
Per Cederqvist committed
248
249
250
251
252
253
254
	cd distribution; \
	  shar -v -cCmx -l 50 -o IDOC elisp-client


send:
	cd distribution ; ../../bin/lyskom-do-send