]> diplodocus.org Git - nmh/blob - zotnet/Makefile.in
Just reworded the bit about '%s' being safe not to quote (it's only safe not to
[nmh] / zotnet / Makefile.in
1 #
2 # Makefile for zotnet subdirectory
3 #
4 # $Id$
5 #
6
7 SHELL = /bin/sh
8
9 srcdir = @srcdir@
10 VPATH = @srcdir@
11
12 LORDER = @LORDER@
13 TSORT = @TSORT@
14 RANLIB = @RANLIB@
15 LIBTOOL = @LIBTOOL@
16 GNU_LIBTOOL = @GNU_LIBTOOL@
17
18 # flags passed to recursive makes in subdirectories
19 MAKEDEFS = CC='$(CC)' CPPFLAGS='$(CPPFLAGS)' DEFS='$(DEFS)' \
20 CFLAGS='$(CFLAGS)' LDFLAGS='$(LDFLAGS)' LIBS='$(LIBS)' \
21 prefix='$(prefix)' exec_prefix='$(exec_prefix)' bindir='$(bindir)' \
22 etcdir='$(etcdir)' libdir='$(libdir)' mandir='$(mandir)' \
23 mailspool='$(mailspool)' sendmailpath='$(sendmailpath)' \
24 default_editor='$(default_editor)' default_pager='$(default_pager)'
25
26 # object files in libzot.a
27 OBJS = mts/mts.o mts/client.o \
28 tws/dtime.o tws/dtimep.o tws/lexstring.o \
29 mf/mf.o \
30 bboards/getbbent.o
31
32 # auxiliary files
33 AUX = Makefile.in
34
35 # all files in this directory included in the distribution
36 DIST = $(AUX)
37
38 # subdirectories
39 SUBDIRS = mts tws mf bboards
40
41 # ========= DEPENDENCIES FOR BUILDING AND INSTALLING ==========
42
43 all: all-recursive libzot.a
44
45 libzot.a: $(OBJS)
46 rm -f $@
47 if test x$(LIBTOOL) != x -a x$(GNU_LIBTOOL) = x ; then \
48 $(LIBTOOL) -static -c $(OBJS) -o $@ ; \
49 else \
50 ar cr $@ `$(LORDER) $(OBJS) | $(TSORT)` ; \
51 $(RANLIB) $@ ; \
52 fi
53
54 all-recursive:
55 for subdir in $(SUBDIRS); do \
56 (cd $$subdir && $(MAKE) $(MAKEDEFS) all) || exit 1; \
57 done
58
59 install uninstall:
60 for subdir in $(SUBDIRS); do \
61 (cd $$subdir && $(MAKE) $(MAKEDEFS) $@) || exit 1; \
62 done
63
64 # ========== DEPENDENCIES FOR CLEANUP ==========
65
66 mostlyclean: mostlyclean-recursive mostlyclean-local
67 clean: clean-recursive clean-local
68 distclean: distclean-recursive distclean-local
69 realclean: realclean-recursive realclean-local
70 superclean: superclean-recursive superclean-local
71
72 mostlyclean-local:
73 rm -f *~
74
75 clean-local: mostlyclean-local
76 rm -f libzot.a
77
78 distclean-local: clean-local
79 rm -f Makefile
80
81 realclean-local: distclean-local
82
83 superclean-local: realclean-local
84
85 mostlyclean-recursive clean-recursive distclean-recursive realclean-recursive superclean-recursive:
86 for subdir in $(SUBDIRS); do \
87 target=`echo $@ | sed 's/-recursive//'`; \
88 (cd $$subdir && $(MAKE) $(MAKEDEFS) $$target) || exit 1; \
89 done
90
91 # ========== DEPENDENCIES FOR MAINTENANCE ==========
92
93 subdir = zotnet
94
95 Makefile: Makefile.in ../config.status
96 cd .. && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= ./config.status
97
98 distdir = ../`cat ../distname`/$(subdir)
99 nmhdist: $(DIST)
100 @echo "Copying distribution files in $(subdir)"
101 @for file in $(DIST); do \
102 cp -p $(srcdir)/$$file $(distdir); \
103 done
104 @for subdir in $(SUBDIRS); do \
105 mkdir $(distdir)/$$subdir; \
106 chmod 755 $(distdir)/$$subdir; \
107 (cd $$subdir && $(MAKE) $@) || exit 1; \
108 done
109