Makefile 5.56 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 35.8  1991/09/16 20:33:44  linus
# rätt namn på todo filen i wc.
#
# Revision 35.7  1991/09/16  19:59:28  linus
31
32
33
# Makefile now works with clientversion-long.
#
# Revision 35.6  1991/09/16  19:31:37  linus
34
35
36
# 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
37
38
39
40
41
42
43
# * 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.
44
45
#
# Revision 35.3  1991/09/15  10:07:04  linus
Linus Tolke's avatar
Linus Tolke committed
46
47
48
# Added copyright note
#
# Revision 35.2  1991/09/13  21:42:53  linus
Linus Tolke's avatar
Linus Tolke committed
49
50
51
# Lagt till distclean.
#
# Revision 35.1  1991/08/21  15:44:47  linus
52
53
# Lagt till lyskom-clientversion-long
#
Per Cederqvist's avatar
.    
Per Cederqvist committed
54

Linus Tolke's avatar
Linus Tolke committed
55
56
57
include Topdir.make
include $(TOPDIR)/scripts/import.make

Per Cederqvist's avatar
.    
Per Cederqvist committed
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
RM = /usr/gnu/bin/rm -vf
EMACS-BATCH = emacs -batch -l /usr/local/lib/elisp/bytecomp

# NOTE: lyskom-rest.el must be the last file in PARTS-EL and SRC-ELC.
PARTS-EL = vars.el swedish-strings.el komtypes.el clienttypes.el startup.el \
	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 \
	lyskom-rest.el
HEADER-EL = macros.el
HEADER-ELC = macros.elc
SRC-ELC = vars.elc swedish-strings.elc komtypes.elc clienttypes.elc startup.elc \
	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 \
	lyskom-rest.elc
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
86
87
88
LEX = flex -8
alfa: lyskom.elc makealfa
	./makealfa < lyskom.elc > /usr/local/src/2kom/lyskom.elc
Linus Tolke's avatar
Linus Tolke committed
89

Per Cederqvist's avatar
.    
Per Cederqvist committed
90
91
92
93
94
95
lyskom.elc: $(HEADER-ELC) $(PARTS-ELC)
	cat $(HEADER-ELC) $(PARTS-ELC) > lyskom.elc

lyskom.el: $(HEADER-EL) $(PARTS-EL)
	cat $(HEADER-EL) $(PARTS-EL) > lyskom.el

Linus Tolke's avatar
Linus Tolke committed
96
97
98
makealfa: makealfa.c
	$(CC) -o makealfa $(CFLAGS) makealfa.c -ll

Per Cederqvist's avatar
.    
Per Cederqvist committed
99
100
101
102
103
104
105
106
107
108
109
110
111
112

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:
Linus Tolke's avatar
Linus Tolke committed
113
114
	@wc $(HEADER-EL) $(PARTS-EL)
	@wc ../doc/elisp-client.latexinfo ChangeLog ../misc/todo
Per Cederqvist's avatar
.    
Per Cederqvist committed
115
116
117
118
119

tags:
	etags $(HEADER-EL) $(PARTS-EL)

doc:
120
	(cd ../doc ; make elisp-client elisp-client.txt ; )
Per Cederqvist's avatar
.    
Per Cederqvist committed
121
122
123
124
125


install: lyskom.elc lyskom.el doc
	cp lyskom.elc /usr/local/lib/elisp/lyskom.elc
	rcp lyskom.elc nanny:/usr/local/lib/elisp/lyskom.elc
126
127
	(VER=`grep "lyskom-clientversion " vars.el | \
	 sed -n 's/^.*defconst.*lyskom-clientversion[^"]*"\([^"]*\)".*$$/\1/p'`;\
128
129
130
	 cp lyskom.elc lyskom-$${VER}.elc;\
	 compress lyskom-$${VER}.elc;\
	 mv lyskom-$${VER}.elc.Z /usr/local/ftp/pub/lyskom/;\
Per Cederqvist's avatar
.    
Per Cederqvist committed
131
132
	 cp lyskom.el lyskom-$${VER}.el;\
	 compress lyskom-$${VER}.el;\
133
	 cp lyskom-$${VER}.el.Z /usr/local/ftp/pub/lyskom/;\
Per Cederqvist's avatar
.    
Per Cederqvist committed
134
	 mv lyskom-$${VER}.el.Z ../old-versions/;\
135
136
137
138
139
140
	 cp ../doc/elisp-client ../doc/elisp-client.txt .;\
	 compress elisp-client elisp-client.txt;\
	 mv elisp-client.Z \
		/usr/local/ftp/pub/lyskom/elisp-client-$${VER}.info.Z; \
	 mv elisp-client.txt.Z \
	     /usr/local/ftp/pub/lyskom/elisp-client-$${VER}.txt.Z; \
Per Cederqvist's avatar
.    
Per Cederqvist committed
141
142
143
144
	 cp ../doc/elisp-client /usr/gnu/emacs/info; \
	)

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

Linus Tolke's avatar
Linus Tolke committed
148
distclean: clean
Linus Tolke's avatar
Linus Tolke committed
149
	$(RM) $(GENERIC-DIST-CLEAN) makealfa Topdir.make */Topdir.make
Linus Tolke's avatar
Linus Tolke committed
150

Per Cederqvist's avatar
.    
Per Cederqvist committed
151
152
153
154
155
156
157
158
159
160
161
162

distrib distribution: lyskom.el lyskom.elc doc
	-$(RM) -r distribution
	mkdir     distribution
	cp distribution-makefile distribution/Makefile
	cp distribution-README distribution/README
	cp $(HEADER-EL) $(PARTS-EL) distribution
	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
163
	cp ../doc/elisp-client.txt ../doc/elisp-client distribution
Per Cederqvist's avatar
.    
Per Cederqvist committed
164
165
166
167
168
169
170
171
172
173
	cd distribution; \
	  shar -v -cCmx -l 50 -o PARTS README Makefile $(HEADER-EL) $(PARTS-EL)
	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 ; \
	    sed 's/kom\.lysator\.liu\.se/obel18.ida.liu.se/g' > lyskom.elc )\
	  < lyskom.elc ; \
174
	  chmod 644 lyskom.el lyskom.elc elisp-client.txt
Per Cederqvist's avatar
.    
Per Cederqvist committed
175
	cd distribution; \
176
	  shar -v -cCmx -l 50 -o DOC elisp-client.txt
Per Cederqvist's avatar
.    
Per Cederqvist committed
177
178
179
180
181
182
183
	cd distribution; \
	  shar -v -cCmx -l 50 -o IDOC elisp-client


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