1 | # $Id: Makefile,v 1.60 2004-04-23 13:52:15 rbasch Exp $ |
---|
2 | |
---|
3 | SHELL=/bin/sh |
---|
4 | ATHBINDIR=/usr/athena/bin |
---|
5 | ATHETCDIR=/usr/athena/etc |
---|
6 | ATHMANDIR=/usr/athena/man |
---|
7 | ATHLIBEXECDIR=/usr/athena/libexec |
---|
8 | ATTACHRUN=acroread addusr blanche chfn chpobox chsh dcmmaint gs gv lastlog \ |
---|
9 | listmaint mailmaint mitch moira mrcheck namespace stanley stella \ |
---|
10 | usermaint show-application show-audio show-binhex show-excel \ |
---|
11 | show-image show-msword show-pdf show-postscript show-text show-video \ |
---|
12 | store-binhex afmdit pscat pscatmap psdit psdraft pslpr psnup psplot \ |
---|
13 | psrev psroff |
---|
14 | MOIRA=/afs/athena.mit.edu/system/moira |
---|
15 | MKSERV=/afs/athena.mit.edu/system/mkserv |
---|
16 | TELLME=/afs/athena.mit.edu/system/config/tellme |
---|
17 | PSUTILS=/afs/athena.mit.edu/astaff/project/psutils |
---|
18 | |
---|
19 | # We make a lot of symlinks here, so we're going to make a hack to make it |
---|
20 | # a little more readable. |
---|
21 | SYMLINKS= ${MOIRA}/man/man1/addusr.1 ${ATHMANDIR}/man1/addusr.1 \ |
---|
22 | ${MOIRA}/man/cat1/addusr.1 ${ATHMANDIR}/cat1/addusr.1 \ |
---|
23 | ${MOIRA}/man/man1/blanche.1 ${ATHMANDIR}/man1/blanche.1 \ |
---|
24 | ${MOIRA}/man/cat1/blanche.1 ${ATHMANDIR}/cat1/blanche.1 \ |
---|
25 | ${MOIRA}/man/man1/chfn.1 ${ATHMANDIR}/man1/chfn.1 \ |
---|
26 | ${MOIRA}/man/cat1/chfn.1 ${ATHMANDIR}/cat1/chfn.1 \ |
---|
27 | ${MOIRA}/man/man1/chpobox.1 ${ATHMANDIR}/man1/chpobox.1 \ |
---|
28 | ${MOIRA}/man/cat1/chpobox.1 ${ATHMANDIR}/cat1/chpobox.1 \ |
---|
29 | ${MOIRA}/man/man1/chsh.1 ${ATHMANDIR}/man1/chsh.1 \ |
---|
30 | ${MOIRA}/man/cat1/chsh.1 ${ATHMANDIR}/cat1/chsh.1 \ |
---|
31 | ${MOIRA}/man/man1/dcmmaint.1 ${ATHMANDIR}/man1/dcmmaint.1 \ |
---|
32 | ${MOIRA}/man/cat1/dcmmaint.1 ${ATHMANDIR}/cat1/dcmmaint.1 \ |
---|
33 | ${MOIRA}/man/man1/listmaint.1 ${ATHMANDIR}/man1/listmaint.1 \ |
---|
34 | ${MOIRA}/man/cat1/listmaint.1 ${ATHMANDIR}/cat1/listmaint.1 \ |
---|
35 | ${MOIRA}/man/man1/mailmaint.1 ${ATHMANDIR}/man1/mailmaint.1 \ |
---|
36 | ${MOIRA}/man/cat1/mailmaint.1 ${ATHMANDIR}/cat1/mailmaint.1 \ |
---|
37 | ${MOIRA}/man/man1/mitch.1 ${ATHMANDIR}/man1/mitch.1 \ |
---|
38 | ${MOIRA}/man/cat1/mitch.1 ${ATHMANDIR}/cat1/mitch.1 \ |
---|
39 | ${MOIRA}/man/man1/moira.1 ${ATHMANDIR}/man1/moira.1 \ |
---|
40 | ${MOIRA}/man/cat1/moira.1 ${ATHMANDIR}/cat1/moira.1 \ |
---|
41 | ${MOIRA}/man/man1/mrcheck.1 ${ATHMANDIR}/man1/mrcheck.1 \ |
---|
42 | ${MOIRA}/man/cat1/mrcheck.1 ${ATHMANDIR}/cat1/mrcheck.1 \ |
---|
43 | ${MOIRA}/man/man1/stanley.1 ${ATHMANDIR}/man1/stanley.1 \ |
---|
44 | ${MOIRA}/man/cat1/stanley.1 ${ATHMANDIR}/cat1/stanley.1 \ |
---|
45 | ${MOIRA}/man/man1/stella.1 ${ATHMANDIR}/man1/stella.1 \ |
---|
46 | ${MOIRA}/man/cat1/stella.1 ${ATHMANDIR}/cat1/stella.1 \ |
---|
47 | ${MOIRA}/man/man1/usermaint.1 ${ATHMANDIR}/man1/usermaint.1 \ |
---|
48 | ${MOIRA}/man/cat1/usermaint.1 ${ATHMANDIR}/cat1/usermaint.1 \ |
---|
49 | ${MKSERV}/man/man8/mkserv.8 ${ATHMANDIR}/man8/mkserv.8 \ |
---|
50 | ${MKSERV}/man/cat8/mkserv.8 ${ATHMANDIR}/cat8/mkserv.8 \ |
---|
51 | ${MOIRA}/man/man8/update_server.8 ${ATHMANDIR}/man8/update_server.8 \ |
---|
52 | ${MOIRA}/man/cat8/update_server.8 ${ATHMANDIR}/cat8/update_server.8 \ |
---|
53 | ${PSUTILS}/man/man1/ps4014.1 ${ATHMANDIR}/man1/ps4014.1 \ |
---|
54 | ${PSUTILS}/man/cat1/ps4014.1 ${ATHMANDIR}/cat1/ps4014.1 \ |
---|
55 | ${PSUTILS}/man/man1/ps630.1 ${ATHMANDIR}/man1/ps630.1 \ |
---|
56 | ${PSUTILS}/man/cat1/ps630.1 ${ATHMANDIR}/cat1/ps630.1 \ |
---|
57 | ${PSUTILS}/man/man1/pscat.1 ${ATHMANDIR}/man1/pscat.1 \ |
---|
58 | ${PSUTILS}/man/cat1/pscat.1 ${ATHMANDIR}/cat1/pscat.1 \ |
---|
59 | ${PSUTILS}/man/man1/psdit.1 ${ATHMANDIR}/man1/psdit.1 \ |
---|
60 | ${PSUTILS}/man/cat1/psdit.1 ${ATHMANDIR}/cat1/psdit.1 \ |
---|
61 | ${PSUTILS}/man/man1/psdraft.1 ${ATHMANDIR}/man1/psdraft.1 \ |
---|
62 | ${PSUTILS}/man/cat1/psdraft.1 ${ATHMANDIR}/cat1/psdraft.1 \ |
---|
63 | ${PSUTILS}/man/man1/psfax.1 ${ATHMANDIR}/man1/psfax.1 \ |
---|
64 | ${PSUTILS}/man/cat1/psfax.1 ${ATHMANDIR}/cat1/psfax.1 \ |
---|
65 | ${PSUTILS}/man/man1/psfonts.1 ${ATHMANDIR}/man1/psfonts.1 \ |
---|
66 | ${PSUTILS}/man/cat1/psfonts.1 ${ATHMANDIR}/cat1/psfonts.1 \ |
---|
67 | ${PSUTILS}/man/man1/pslpr.1 ${ATHMANDIR}/man1/pslpr.1 \ |
---|
68 | ${PSUTILS}/man/cat1/pslpr.1 ${ATHMANDIR}/cat1/pslpr.1 \ |
---|
69 | ${PSUTILS}/man/man1/psnup.1 ${ATHMANDIR}/man1/psnup.1 \ |
---|
70 | ${PSUTILS}/man/cat1/psnup.1 ${ATHMANDIR}/cat1/psnup.1 \ |
---|
71 | ${PSUTILS}/man/man1/psplot.1 ${ATHMANDIR}/man1/psplot.1 \ |
---|
72 | ${PSUTILS}/man/cat1/psplot.1 ${ATHMANDIR}/cat1/psplot.1 \ |
---|
73 | ${PSUTILS}/man/man1/psrev.1 ${ATHMANDIR}/man1/psrev.1 \ |
---|
74 | ${PSUTILS}/man/cat1/psrev.1 ${ATHMANDIR}/cat1/psrev.1 \ |
---|
75 | ${PSUTILS}/man/man1/psroff.1 ${ATHMANDIR}/man1/psroff.1 \ |
---|
76 | ${PSUTILS}/man/cat1/psroff.1 ${ATHMANDIR}/cat1/psroff.1 \ |
---|
77 | ${PSUTILS}/man/man1/pssymbols.1 ${ATHMANDIR}/man1/pssymbols.1 \ |
---|
78 | ${PSUTILS}/man/cat1/pssymbols.1 ${ATHMANDIR}/cat1/pssymbols.1 \ |
---|
79 | ${PSUTILS}/man/man1/transcript.1 ${ATHMANDIR}/man1/transcript.1 \ |
---|
80 | ${PSUTILS}/man/cat1/transcript.1 ${ATHMANDIR}/cat1/transcript.1 \ |
---|
81 | ${PSUTILS}/man/man7/afm.7 ${ATHMANDIR}/man7/afm.7 \ |
---|
82 | ${PSUTILS}/man/cat7/afm.7 ${ATHMANDIR}/cat7/afm.7 \ |
---|
83 | ${PSUTILS}/man/man7/postscript.7 ${ATHMANDIR}/man7/postscript.7 \ |
---|
84 | ${PSUTILS}.man/cat7/postscript.7 ${ATHMANDIR}/cat7/postscript.7 \ |
---|
85 | ${PSUTILS}/man/man8/pscatmap.8 ${ATHMANDIR}/man8/pscatmap.8 \ |
---|
86 | ${PSUTILS}/man/cat8/pscatmap.8 ${ATHMANDIR}/cat8/pscatmap.8 \ |
---|
87 | ${PSUTILS}/man/man8/psdman.8 ${ATHMANDIR}/man8/psdman.8 \ |
---|
88 | ${PSUTILS}/man/cat8/psdman.8 ${ATHMANDIR}/cat8/psdman.8 \ |
---|
89 | ${PSUTILS}/man/man8/psint.8 ${ATHMANDIR}/man8/psint.8 \ |
---|
90 | ${PSUTILS}/man/cat8/psint.8 ${ATHMANDIR}/cat8/psint.8 |
---|
91 | |
---|
92 | all: ${ATTACHRUN} |
---|
93 | cd os/${OS} && ${MAKE} $@ |
---|
94 | |
---|
95 | ${ATTACHRUN}: specs template.sh |
---|
96 | set `grep '^$@[ ]' specs`; sed -e "s|@LOCKER@|$$2|g" \ |
---|
97 | -e "s|@PROGRAM@|$@|g" template.sh > $@ |
---|
98 | |
---|
99 | check: |
---|
100 | cd os/${OS} && ${MAKE} $@ |
---|
101 | |
---|
102 | install: |
---|
103 | mkdir -p ${DESTDIR}/usr |
---|
104 | mkdir -p ${DESTDIR}${ATHBINDIR} |
---|
105 | mkdir -p ${DESTDIR}${ATHETCDIR} |
---|
106 | mkdir -p ${DESTDIR}${ATHLIBEXECDIR} |
---|
107 | mkdir -p ${DESTDIR}${ATHMANDIR}/man1 |
---|
108 | mkdir -p ${DESTDIR}${ATHMANDIR}/cat1 |
---|
109 | mkdir -p ${DESTDIR}${ATHMANDIR}/man7 |
---|
110 | mkdir -p ${DESTDIR}${ATHMANDIR}/cat7 |
---|
111 | mkdir -p ${DESTDIR}${ATHMANDIR}/man8 |
---|
112 | mkdir -p ${DESTDIR}${ATHMANDIR}/cat8 |
---|
113 | install -c -m 555 acroread ${DESTDIR}${ATHBINDIR} |
---|
114 | install -c -m 555 addusr ${DESTDIR}${ATHBINDIR} |
---|
115 | install -c -m 555 blanche ${DESTDIR}${ATHBINDIR} |
---|
116 | install -c -m 555 chfn ${DESTDIR}${ATHBINDIR} |
---|
117 | install -c -m 555 chpobox ${DESTDIR}${ATHBINDIR} |
---|
118 | install -c -m 555 chsh ${DESTDIR}${ATHBINDIR} |
---|
119 | install -c -m 555 dcmmaint ${DESTDIR}${ATHBINDIR} |
---|
120 | install -c -m 555 gs ${DESTDIR}${ATHBINDIR} |
---|
121 | install -c -m 555 gv ${DESTDIR}${ATHBINDIR} |
---|
122 | install -c -m 555 help.sh ${DESTDIR}${ATHBINDIR}/help |
---|
123 | install -c -m 555 htmlview.sh ${DESTDIR}${ATHBINDIR}/htmlview |
---|
124 | install -c -m 555 ksrvutil.sh ${DESTDIR}${ATHBINDIR}/ksrvutil |
---|
125 | install -c -m 555 mkserv.sh ${DESTDIR}${ATHBINDIR}/mkserv |
---|
126 | install -c -m 555 lastlog ${DESTDIR}${ATHBINDIR} |
---|
127 | install -c -m 555 listmaint ${DESTDIR}${ATHBINDIR} |
---|
128 | install -c -m 555 mailmaint ${DESTDIR}${ATHBINDIR} |
---|
129 | install -c -m 444 mh.1 ${DESTDIR}${ATHMANDIR}/man1 |
---|
130 | install -c -m 555 mitch ${DESTDIR}${ATHBINDIR} |
---|
131 | install -c -m 555 moira ${DESTDIR}${ATHBINDIR} |
---|
132 | install -c -m 555 mrcheck ${DESTDIR}${ATHBINDIR} |
---|
133 | install -c -m 555 namespace ${DESTDIR}${ATHBINDIR} |
---|
134 | install -c -m 555 olc_answers.sh ${DESTDIR}${ATHBINDIR}/olc_answers |
---|
135 | install -c -m 555 psgrind.sh ${DESTDIR}${ATHBINDIR}/psgrind |
---|
136 | install -c -m 555 sis.sh ${DESTDIR}${ATHBINDIR}/sis |
---|
137 | install -c -m 555 stanley ${DESTDIR}${ATHBINDIR} |
---|
138 | install -c -m 555 stella ${DESTDIR}${ATHBINDIR} |
---|
139 | install -c -m 555 usermaint ${DESTDIR}${ATHBINDIR} |
---|
140 | install -c -m 555 vacation.sh ${DESTDIR}${ATHBINDIR}/vacation |
---|
141 | install -c -m 555 verify-message.sh \ |
---|
142 | ${DESTDIR}${ATHBINDIR}/verify-message |
---|
143 | install -c -m 555 xlock.sh ${DESTDIR}${ATHBINDIR}/xlock |
---|
144 | install -c -m 555 show-application ${DESTDIR}${ATHLIBEXECDIR} |
---|
145 | install -c -m 555 show-audio ${DESTDIR}${ATHLIBEXECDIR} |
---|
146 | install -c -m 555 show-binhex ${DESTDIR}${ATHLIBEXECDIR} |
---|
147 | install -c -m 555 show-excel ${DESTDIR}${ATHLIBEXECDIR} |
---|
148 | install -c -m 555 show-image ${DESTDIR}${ATHLIBEXECDIR} |
---|
149 | install -c -m 555 show-msword ${DESTDIR}${ATHLIBEXECDIR} |
---|
150 | install -c -m 555 show-pdf ${DESTDIR}${ATHLIBEXECDIR} |
---|
151 | install -c -m 555 show-postscript ${DESTDIR}${ATHLIBEXECDIR} |
---|
152 | install -c -m 555 show-text ${DESTDIR}${ATHLIBEXECDIR} |
---|
153 | install -c -m 555 show-video ${DESTDIR}${ATHLIBEXECDIR} |
---|
154 | install -c -m 555 store-binhex ${DESTDIR}${ATHLIBEXECDIR} |
---|
155 | install -c -m 555 afmdit ${DESTDIR}${ATHBINDIR} |
---|
156 | install -c -m 555 pscat ${DESTDIR}${ATHBINDIR} |
---|
157 | install -c -m 555 pscatmap ${DESTDIR}${ATHBINDIR} |
---|
158 | install -c -m 555 psdit ${DESTDIR}${ATHBINDIR} |
---|
159 | install -c -m 555 psdraft ${DESTDIR}${ATHBINDIR} |
---|
160 | install -c -m 555 pslpr ${DESTDIR}${ATHBINDIR} |
---|
161 | install -c -m 555 psnup ${DESTDIR}${ATHBINDIR} |
---|
162 | install -c -m 555 psplot ${DESTDIR}${ATHBINDIR} |
---|
163 | install -c -m 555 psrev ${DESTDIR}${ATHBINDIR} |
---|
164 | install -c -m 555 psroff ${DESTDIR}${ATHBINDIR} |
---|
165 | @set ${SYMLINKS}; while [ $$# -ne 0 ]; do \ |
---|
166 | echo rm -f ${DESTDIR}$$2; \ |
---|
167 | rm -f ${DESTDIR}$$2; \ |
---|
168 | echo ln -s $$1 ${DESTDIR}$$2; \ |
---|
169 | ln -s $$1 ${DESTDIR}$$2; \ |
---|
170 | shift 2; \ |
---|
171 | done |
---|
172 | rm -f ${DESTDIR}${ATHETCDIR}/update_server |
---|
173 | ln -s `athdir -c -p ${MOIRA} -t bin`/update_server \ |
---|
174 | ${DESTDIR}${ATHETCDIR}/update_server |
---|
175 | rm -f ${DESTDIR}${ATHBINDIR}/tellme |
---|
176 | ln -s `athdir -c -p ${TELLME} -t bin`/tellme \ |
---|
177 | ${DESTDIR}${ATHBINDIR}/tellme |
---|
178 | cd os/${OS} && ${MAKE} $@ |
---|
179 | |
---|
180 | clean: |
---|
181 | rm -f ${ATTACHRUN} |
---|
182 | cd os/${OS} && ${MAKE} $@ |
---|
183 | |
---|
184 | distclean: |
---|
185 | rm -f ${ATTACHRUN} |
---|
186 | cd os/${OS} && ${MAKE} $@ |
---|