1 | # $Id: Makefile,v 1.36 1999-09-02 14:57:10 ghudson Exp $ |
---|
2 | |
---|
3 | SHELL=/bin/sh |
---|
4 | ATHRBINDIR=/bin/athena |
---|
5 | ATHBINDIR=/usr/athena/bin |
---|
6 | ATHETCDIR=/usr/athena/etc |
---|
7 | ATHMANDIR=/usr/athena/man |
---|
8 | ATHLIBEXECDIR=/usr/athena/libexec |
---|
9 | ATTACHRUN=addusr blanche bos chfn chpobox chsh dcmmaint help klog \ |
---|
10 | listmaint mailmaint moira mrcheck namespace olh olh_ascii \ |
---|
11 | olh_motif pts usermaint vos xinfo \ |
---|
12 | show-application show-audio show-binhex show-image \ |
---|
13 | show-msword show-pdf show-postscript show-text show-video \ |
---|
14 | store-binhex |
---|
15 | ANDREW=/afs/athena.mit.edu/astaff/project/andrew/export |
---|
16 | MOIRA=/afs/athena.mit.edu/system/moira |
---|
17 | HELP=/afs/athena.mit.edu/system/help |
---|
18 | MKSERV=/afs/athena.mit.edu/system/mkserv |
---|
19 | TELLME=/afs/athena.mit.edu/system/config/tellme |
---|
20 | |
---|
21 | # We make a lot of symlinks here, so we're going to make a hack to make it |
---|
22 | # a little more readable. |
---|
23 | SYMLINKS= ${MOIRA}/man/man1/addusr.1 ${ATHMANDIR}/man1/addusr.1 \ |
---|
24 | ${MOIRA}/man/cat1/addusr.1 ${ATHMANDIR}/cat1/addusr.1 \ |
---|
25 | ${MOIRA}/man/man1/blanche.1 ${ATHMANDIR}/man1/blanche.1 \ |
---|
26 | ${MOIRA}/man/cat1/blanche.1 ${ATHMANDIR}/cat1/blanche.1 \ |
---|
27 | ${MOIRA}/man/man1/chfn.1 ${ATHMANDIR}/man1/chfn.1 \ |
---|
28 | ${MOIRA}/man/cat1/chfn.1 ${ATHMANDIR}/cat1/chfn.1 \ |
---|
29 | ${MOIRA}/man/man1/chpobox.1 ${ATHMANDIR}/man1/chpobox.1 \ |
---|
30 | ${MOIRA}/man/cat1/chpobox.1 ${ATHMANDIR}/cat1/chpobox.1 \ |
---|
31 | ${MOIRA}/man/man1/chsh.1 ${ATHMANDIR}/man1/chsh.1 \ |
---|
32 | ${MOIRA}/man/cat1/chsh.1 ${ATHMANDIR}/cat1/chsh.1 \ |
---|
33 | ${MOIRA}/man/man1/dcmmaint.1 ${ATHMANDIR}/man1/dcmmaint.1 \ |
---|
34 | ${MOIRA}/man/cat1/dcmmaint.1 ${ATHMANDIR}/cat1/dcmmaint.1 \ |
---|
35 | ${HELP}/man/man1/help.1 ${ATHMANDIR}/man1/help.1 \ |
---|
36 | ${HELP}/man/cat1/help.1 ${ATHMANDIR}/cat1/help.1 \ |
---|
37 | ${MOIRA}/man/man1/listmaint.1 ${ATHMANDIR}/man1/listmaint.1 \ |
---|
38 | ${MOIRA}/man/cat1/listmaint.1 ${ATHMANDIR}/cat1/listmaint.1 \ |
---|
39 | ${MOIRA}/man/man1/mailmaint.1 ${ATHMANDIR}/man1/mailmaint.1 \ |
---|
40 | ${MOIRA}/man/cat1/mailmaint.1 ${ATHMANDIR}/cat1/mailmaint.1 \ |
---|
41 | ${MOIRA}/man/man1/moira.1 ${ATHMANDIR}/man1/moira.1 \ |
---|
42 | ${MOIRA}/man/cat1/moira.1 ${ATHMANDIR}/cat1/moira.1 \ |
---|
43 | ${MOIRA}/man/man1/mrcheck.1 ${ATHMANDIR}/man1/mrcheck.1 \ |
---|
44 | ${MOIRA}/man/cat1/mrcheck.1 ${ATHMANDIR}/cat1/mrcheck.1 \ |
---|
45 | ${HELP}/man/man1/olh.1 ${ATHMANDIR}/man1/olh.1 \ |
---|
46 | ${HELP}/man/cat1/olh.1 ${ATHMANDIR}/cat1/olh.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 | |
---|
54 | all: ${ATTACHRUN} |
---|
55 | cd os/${OS} && ${MAKE} $@ |
---|
56 | |
---|
57 | ${ATTACHRUN}: specs template.sh |
---|
58 | set `grep '^$@[ ]' specs`; sed -e "s|@LOCKER@|$$2|g" \ |
---|
59 | -e "s|@PROGRAM@|$@|g" template.sh > $@ |
---|
60 | |
---|
61 | check: |
---|
62 | cd os/${OS} && ${MAKE} $@ |
---|
63 | |
---|
64 | install: |
---|
65 | mkdir -p ${DESTDIR}/usr |
---|
66 | mkdir -p ${DESTDIR}${ATHRBINDIR} |
---|
67 | mkdir -p ${DESTDIR}${ATHBINDIR} |
---|
68 | mkdir -p ${DESTDIR}${ATHETCDIR} |
---|
69 | mkdir -p ${DESTDIR}${ATHLIBEXECDIR} |
---|
70 | mkdir -p ${DESTDIR}${ATHMANDIR}/man1 |
---|
71 | mkdir -p ${DESTDIR}${ATHMANDIR}/cat1 |
---|
72 | mkdir -p ${DESTDIR}${ATHMANDIR}/man8 |
---|
73 | mkdir -p ${DESTDIR}${ATHMANDIR}/cat8 |
---|
74 | install -c -m 555 addusr ${DESTDIR}${ATHBINDIR} |
---|
75 | install -c -m 555 blanche ${DESTDIR}${ATHBINDIR} |
---|
76 | install -c -m 555 bos ${DESTDIR}${ATHRBINDIR} |
---|
77 | install -c -m 555 chfn ${DESTDIR}${ATHBINDIR} |
---|
78 | install -c -m 555 chpobox ${DESTDIR}${ATHBINDIR} |
---|
79 | install -c -m 555 chsh ${DESTDIR}${ATHBINDIR} |
---|
80 | install -c -m 555 dcmmaint ${DESTDIR}${ATHBINDIR} |
---|
81 | install -c -m 555 help ${DESTDIR}${ATHBINDIR} |
---|
82 | install -c -m 555 klog ${DESTDIR}${ATHRBINDIR} |
---|
83 | install -c -m 555 mkserv.sh ${DESTDIR}${ATHBINDIR}/mkserv |
---|
84 | install -c -m 555 listmaint ${DESTDIR}${ATHBINDIR} |
---|
85 | install -c -m 555 mailmaint ${DESTDIR}${ATHBINDIR} |
---|
86 | install -c -m 444 mh.1 ${DESTDIR}${ATHMANDIR}/man1 |
---|
87 | install -c -m 555 moira ${DESTDIR}${ATHBINDIR} |
---|
88 | install -c -m 555 mrcheck ${DESTDIR}${ATHBINDIR} |
---|
89 | install -c -m 555 namespace ${DESTDIR}${ATHBINDIR} |
---|
90 | install -c -m 555 olc_answers.sh ${DESTDIR}${ATHBINDIR}/olc_answers |
---|
91 | install -c -m 555 olh ${DESTDIR}${ATHBINDIR} |
---|
92 | install -c -m 555 olh_ascii ${DESTDIR}${ATHBINDIR} |
---|
93 | install -c -m 555 olh_motif ${DESTDIR}${ATHBINDIR} |
---|
94 | install -c -m 555 psgrind.sh ${DESTDIR}${ATHBINDIR}/psgrind |
---|
95 | install -c -m 555 pts ${DESTDIR}${ATHRBINDIR} |
---|
96 | install -c -m 555 sis.sh ${DESTDIR}${ATHBINDIR}/sis |
---|
97 | install -c -m 555 usermaint ${DESTDIR}${ATHBINDIR} |
---|
98 | install -c -m 555 vacation.sh ${DESTDIR}${ATHBINDIR}/vacation |
---|
99 | install -c -m 555 verify-message.sh \ |
---|
100 | ${DESTDIR}${ATHBINDIR}/verify-message |
---|
101 | install -c -m 555 vos ${DESTDIR}${ATHRBINDIR} |
---|
102 | install -c -m 555 xinfo ${DESTDIR}${ATHBINDIR} |
---|
103 | install -c -m 444 xinfo.1 ${DESTDIR}${ATHMANDIR}/man1 |
---|
104 | install -c -m 555 xlock.sh ${DESTDIR}${ATHBINDIR}/xlock |
---|
105 | install -c -m 555 show-application ${DESTDIR}${ATHLIBEXECDIR} |
---|
106 | install -c -m 555 show-audio ${DESTDIR}${ATHLIBEXECDIR} |
---|
107 | install -c -m 555 show-binhex ${DESTDIR}${ATHLIBEXECDIR} |
---|
108 | install -c -m 555 show-image ${DESTDIR}${ATHLIBEXECDIR} |
---|
109 | install -c -m 555 show-msword ${DESTDIR}${ATHLIBEXECDIR} |
---|
110 | install -c -m 555 show-pdf ${DESTDIR}${ATHLIBEXECDIR} |
---|
111 | install -c -m 555 show-postscript ${DESTDIR}${ATHLIBEXECDIR} |
---|
112 | install -c -m 555 show-text ${DESTDIR}${ATHLIBEXECDIR} |
---|
113 | install -c -m 555 show-video ${DESTDIR}${ATHLIBEXECDIR} |
---|
114 | install -c -m 555 store-binhex ${DESTDIR}${ATHLIBEXECDIR} |
---|
115 | @set ${SYMLINKS}; while [ $$# -ne 0 ]; do \ |
---|
116 | echo rm -f ${DESTDIR}$$2; \ |
---|
117 | rm -f ${DESTDIR}$$2; \ |
---|
118 | echo ln -s $$1 ${DESTDIR}$$2; \ |
---|
119 | ln -s $$1 ${DESTDIR}$$2; \ |
---|
120 | shift 2; \ |
---|
121 | done |
---|
122 | rm -f ${DESTDIR}${ATHETCDIR}/update_server |
---|
123 | ln -s `athdir -c -p ${MOIRA} -t bin`/update_server \ |
---|
124 | ${DESTDIR}${ATHETCDIR}/update_server |
---|
125 | rm -f ${DESTDIR}${ATHBINDIR}/tellme |
---|
126 | ln -s `athdir -c -p ${TELLME} -t bin`/tellme \ |
---|
127 | ${DESTDIR}${ATHBINDIR}/tellme |
---|
128 | rm -f ${DESTDIR}/usr/andrew |
---|
129 | . ../build/version; \ |
---|
130 | vers=$$major.$$minor; \ |
---|
131 | ln -s ${ANDREW}/athena-$$vers/$$HOSTTYPE ${DESTDIR}/usr/andrew |
---|
132 | cd os/${OS} && ${MAKE} $@ |
---|
133 | |
---|
134 | clean: |
---|
135 | rm -f ${ATTACHRUN} |
---|
136 | cd os/${OS} && ${MAKE} $@ |
---|
137 | |
---|
138 | distclean: |
---|
139 | rm -f ${ATTACHRUN} |
---|
140 | cd os/${OS} && ${MAKE} $@ |
---|