]> diplodocus.org Git - nmh/blob - docs/historical/mh-6.8.5/conf/makefiles/MH-Makefile
Silenced warnings when built without iconv.
[nmh] / docs / historical / mh-6.8.5 / conf / makefiles / MH-Makefile
1 ##############################################################################
2 # Instructions to Make, for compilation of MH modules
3 #
4 # @(MHWARNING)
5 # @(#)$Id: MH-Makefile,v 2.16 1993/08/27 22:15:49 jromine Exp $
6 ##############################################################################
7
8 MAKE = make DESTDIR=$(DESTDIR) $(MFLAGS) -k
9 SHELL = /bin/sh
10
11 # Targets to Make:
12 #
13 # all: generate MH system, assumes configuration previously done
14 #
15 # depend: generate dependencies, for MH master maintainers only!
16 #
17 # lint: verify code, for MH master maintainers only!
18 #
19 # compat-v7: verify V7 restrictions, for MH master maintainers only!
20 #
21 # install: install system
22 #
23 # inst-all: install system
24 #
25 # inst-lib: install shared libraries
26 #
27 # mkdirs: make MH target directories
28 #
29 # tar: generate tar commands to move targets to other systems
30 # e.g., make TFLAGS="cf mh.tar" tar
31 #
32 # uninstall: undo installation
33 #
34 # distribution:
35 # revert source tree to MH distribution
36 # unconfig:
37 # removes configured files - for MH master maintainers only!
38 #
39 # checkout: MH maintainers only!
40 #
41 # clean: remove all objects and targets plus clean up
42 #
43 # unclean: remove scratch files and backups
44
45
46 ##############################################################################
47 # Generate MH system
48 ##############################################################################
49
50 ALL = config sbr mts zotnet uip support doc
51
52 all:; for d in $(ALL); do (cd $$d; $(MAKE) all); done
53
54 depend:; for d in $(ALL); do (cd $$d; $(MAKE) depend); done
55
56 lint:; for d in $(ALL); do (cd $$d; $(MAKE) lint); done
57
58 compat-v7: all
59 miscellany/tools/7limit */x* */*/x*
60 miscellany/tools/8limit */*.o */*/*.o
61
62
63 INSTALL = zotnet support uip doc
64 BINDIR = $(DESTDIR)@(MHBINPATH)
65 ETCDIR = $(DESTDIR)@(MHETCPATH)
66 MANDIR = $(DESTDIR)@(MHMANDIR)
67 SLIB = sbr
68
69 install: inst-all
70
71 inst-all: mkdirs inst-lib
72 for d in $(INSTALL); do (cd $$d; $(MAKE) inst-all); done
73
74 inst-lib:; for d in $(SLIB); do (cd $$d; $(MAKE) inst-lib); done
75
76 mkdirs: $(BINDIR) $(ETCDIR) $(MANDIR)
77
78 $(BINDIR) $(ETCDIR) $(MANDIR):
79 mkdir $@ && chmod 0755 $@
80
81 tar:; @for d in $(INSTALL); \
82 do (cd $$d; $(MAKE) TFLAGS="$(TFLAGS)" tar); done
83
84 uninstall:; for d in $(INSTALL); do (cd $$d; $(MAKE) uninstall); done
85
86
87 ##############################################################################
88 # Miscellaneous tasks
89 ##############################################################################
90
91 DISTRIBUTION= dist conf config sbr mts zotnet support uip doc papers
92
93 distribution: READ-ME CHANGES
94 rm -f _* :*
95 @if test -f tma/mh/files; \
96 then \
97 echo rm -f `cat tma/mh/files`; rm -f `cat tma/mh/files`; \
98 echo rm -rf tma; rm -rf tma; \
99 fi
100 -rm -f support/pop/mmdfII/pop/lock.c
101 -rm -f support/bboards/mmdfII/bboards/lock.c
102 -rm -f zotnet/tws/tws.h
103 -rm -f uip/pshsbr.c
104 cd support/pop/mmdfII/pop ; @(LN) ../../../../zotnet/mts/lock.c .
105 cd support/bboards/mmdfII/bboards ; @(LN) ../../../../zotnet/mts/lock.c .
106 cd zotnet/tws ; @(LN) ../tws.h .
107 cd uip ; @(LN) popsbr.c pshsbr.c
108 for d in $(DISTRIBUTION); \
109 do (cd $$d; $(MAKE) distribution); done
110
111 READ-ME: conf/mh-gen.8
112 nroff -man conf/mh-gen.8 > read-me.tmp
113 mv read-me.tmp $@
114
115 CHANGES: papers/changes/mh-changes.ms
116 nroff -ms papers/changes/mh-changes.ms > changes.tmp
117 mv changes.tmp $@
118
119 unconfig:; rm -f _* :* core READ-ME
120 -rm -f support/pop/mmdfII/pop/lock.c
121 -rm -f support/bboards/mmdfII/bboards/lock.c
122 -rm -f zotnet/tws/tws.h
123 -rm -f uip/pshsbr.c
124 for d in $(DISTRIBUTION); do (cd $$d; $(MAKE) unconfig); done
125 cp conf/makefiles/MH-Unconfig tmp
126 mv tmp Makefile
127
128 checkout: unclean lint compat-v7
129 find . \( -name ":*" -o -name "_*" -o -name "#*" \) -a -print
130
131 clean:; rm -f _* :* core
132 for d in $(DISTRIBUTION); do (cd $$d; $(MAKE) clean); done
133
134 unclean:; rm -f _* :* core
135 for d in $(DISTRIBUTION); do (cd $$d; $(MAKE) unclean); done