BSD 4_3_Tahoe development
[unix-history] / usr / src / local / Makefile
CommitLineData
526d75a7
C
1#
2DESTDIR=
3CFLAGS= -O
4
5# Programs that live in subdirectories, and have makefiles of their own.
6#
7SUBDIR=
8
9# C programs that live in the current directory and do not need
10# explicit make lines.
11#
12STD=
13
14# C programs that live in the current directory and need explicit make lines.
15#
16NSTD=
17
18# Shell scripts
19#
20SHELL=
21
22all: ${SUBDIR} ${STD} ${NSTD}
23
24#${SUBDIR}: /tmp
25# cd $@; make ${MFLAGS}
26#
27#${STD}:
28# cc ${CFLAGS} -o $@ $@.c
29#
30# Files listed in ${NSTD} have explicit make lines given below.
31
32install:
33# -for i in ${SUBDIR}; do \
34# (cd $$i; make ${MFLAGS} DESTDIR=${DESTDIR} install); done
35# -for i in ${STD} ${NSTD}; do \
36# (install $$i ${DESTDIR}/usr/local/$$i); done
37# -for i in ${SHELL}; do \
38# (install -c -m 755 $$i.sh ${DESTDIR}/usr/local/$$i); done
39
40clean:
41# rm -f a.out core *.s *.o
42# for i in ${SUBDIR}; do (cd $$i; make ${MFLAGS} clean); done
43# rm -f ${STD} ${NSTD}
44
45depend:
46# cat </dev/null >x.c
47# for i in ${STD} ${NSTD}; do \
48# (echo $$i: $$i.c >>makedep; \
49# /bin/grep '^#[ ]*include' x.c $$i.c | sed \
50# -e 's,<\(.*\)>,"/usr/include/\1",' \
51# -e 's/:[^"]*"\([^"]*\)".*/: \1/' \
52# -e 's/\.c//' >>makedep); done
53# echo '/^# DO NOT DELETE THIS LINE/+2,$$d' >eddep
54# echo '$$r makedep' >>eddep
55# echo 'w' >>eddep
56# cp Makefile Makefile.bak
57# ed - Makefile < eddep
58# rm eddep makedep x.c
59# echo '# DEPENDENCIES MUST END AT END OF FILE' >> Makefile
60# echo '# IF YOU PUT STUFF HERE IT WILL GO AWAY' >> Makefile
61# echo '# see make depend above' >> Makefile
62
63# DO NOT DELETE THIS LINE -- make depend uses it
64
65# DEPENDENCIES MUST END AT END OF FILE
66# IF YOU PUT STUFF HERE IT WILL GO AWAY
67# see make depend above