comparison Makefile @ 0:04124a4423d4 noffle

[svn] Initial revision
author enz
date Tue, 04 Jan 2000 11:35:42 +0000
parents
children 29a576bc379a
comparison
equal deleted inserted replaced
-1:000000000000 0:04124a4423d4
1 ###############################################################################
2 #
3 # Makefile for Noffle news server
4 #
5 # $Id: Makefile 3 2000-01-04 11:35:42Z enz $
6 #
7 ###############################################################################
8
9 SPOOLDIR = /var/spool/noffle
10 PREFIX = /usr/local
11
12 CONFIGFILE = /etc/noffle.conf
13 BINDIR = $(PREFIX)/bin
14 MANDIR = $(PREFIX)/man
15 DOCDIR = $(PREFIX)/doc/noffle
16
17 CC = gcc
18 CFLAGS = -Wall -O -g
19 #CFLAGS = -Wall -g -DDEBUG
20
21 VERSION = 19991217
22
23 FILESH = client.h common.h config.h content.h database.h dynamicstring.h \
24 fetch.h fetchlist.h group.h lock.h log.h online.h outgoing.h over.h \
25 protocol.h pseudo.h request.h server.h util.h
26
27 FILESC = fetch.c client.c config.c content.c database.c dynamicstring.c \
28 fetchlist.c group.c lock.c log.c noffle.c online.c outgoing.c over.c \
29 protocol.c pseudo.c request.c server.c util.c
30
31 OBJS = $(patsubst %.c,%.o,$(FILESC))
32
33 all: noffle
34
35 noffle: $(OBJS)
36 $(CC) $(CFLAGS) -o noffle $(OBJS) -lgdbm
37
38 config.o: config.c config.h Makefile
39 $(CC) $(CFLAGS) -c -DSPOOLDIR=\"$(SPOOLDIR)\" \
40 -DVERSION=\"$(VERSION)\" -DCONFIGFILE=\"$(CONFIGFILE)\" config.c
41
42 log.o: log.c log.h Makefile
43
44 depend:
45 gcc -MM -MG -E $(FILESC) >depend
46
47 clean:
48 rm -f depend $(OBJS) noffle
49
50 install: noffle
51 install -o 0 -g 0 -d $(RPM_BUILD_ROOT)$(BINDIR)
52 install -m 4755 -o news -g news noffle $(RPM_BUILD_ROOT)$(BINDIR)
53 install -o 0 -g 0 -d $(RPM_BUILD_ROOT)$(MANDIR)/man1
54 install -m 0644 -o 0 -g 0 noffle.1 \
55 $(RPM_BUILD_ROOT)$(MANDIR)/man1/noffle.1
56 install -o 0 -g 0 -d $(RPM_BUILD_ROOT)$(MANDIR)/man5
57 install -m 0644 -o 0 -g 0 noffle.conf.5 \
58 $(RPM_BUILD_ROOT)$(MANDIR)/man5/noffle.conf.5
59 install -m 2755 -o news -g news -d $(RPM_BUILD_ROOT)$(SPOOLDIR)
60 install -o news -g news -d $(RPM_BUILD_ROOT)$(SPOOLDIR)/data
61 install -o news -g news -d $(RPM_BUILD_ROOT)$(SPOOLDIR)/lock
62 install -o news -g news -d $(RPM_BUILD_ROOT)$(SPOOLDIR)/requested
63 install -o news -g news -d $(RPM_BUILD_ROOT)$(SPOOLDIR)/outgoing
64 install -o news -g news -d $(RPM_BUILD_ROOT)$(SPOOLDIR)/overview
65 install -o 0 -g 0 -d $(RPM_BUILD_ROOT)$(DOCDIR)
66 install -m 0644 -o 0 -g 0 README.txt $(RPM_BUILD_ROOT)$(DOCDIR)
67 install -m 0644 -o 0 -g 0 NOTES.txt $(RPM_BUILD_ROOT)$(DOCDIR)
68 install -m 0644 -o 0 -g 0 INSTALL.txt $(RPM_BUILD_ROOT)$(DOCDIR)
69 install -m 0644 -o 0 -g 0 CHANGELOG.txt $(RPM_BUILD_ROOT)$(DOCDIR)
70 install -m 0644 -o 0 -g 0 FAQ.txt $(RPM_BUILD_ROOT)$(DOCDIR)
71 install -m 0644 -o 0 -g 0 COPYING.txt $(RPM_BUILD_ROOT)$(DOCDIR)
72 install -m 0644 -o 0 -g 0 noffle.conf.example \
73 $(RPM_BUILD_ROOT)$(DOCDIR)
74 chown -R news.news $(RPM_BUILD_ROOT)$(SPOOLDIR)
75 @echo
76 @echo Read INSTALL.txt for further instructions.
77
78 tags:
79 etags $(FILESC) $(FILESH)
80
81 -include depend