Makefile revision 39145
1#	$Id:$
2
3#	from: @(#)Makefile	5.11 (Berkeley) 5/21/91
4#	$Id: Makefile,v 1.170 1998/08/31 20:45:41 jb Exp $
5
6SUBDIR=	sendmail
7
8# -rw-r--r--
9BINOWN= root
10BINGRP= wheel
11BIN1=   aliases amd.map crontab csh.cshrc csh.login csh.logout dm.conf \
12	ftpusers gettytab group hosts host.conf hosts.equiv hosts.lpd \
13	inetd.conf login.conf login.access motd modems networks \
14	newsyslog.conf phones pccard.conf.sample printcap profile protocols \
15	rc rc.conf rc.firewall rc.local rc.network rc.pccard rc.serial \
16	rc.shutdown etc.${MACHINE_ARCH}/rc.${MACHINE_ARCH} \
17	remote security services shells syslog.conf \
18	etc.${MACHINE_ARCH}/ttys etc.${MACHINE_ARCH}/disktab rpc make.conf \
19	${.CURDIR}/../gnu/usr.bin/man/manpath/manpath.config \
20	${.CURDIR}/../usr.bin/mail/misc/mail.rc \
21	${.CURDIR}/../usr.bin/locate/locate/locate.rc
22
23# -rwxr-xr-x root.wheel, for the new cron root.wheel
24BIN2=	netstart pccard_ether
25
26MTREE=	BSD.include.dist BSD.local.dist BSD.root.dist BSD.usr.dist \
27	BSD.var.dist BSD.x11.dist
28NAMEDB= PROTO.localhost.rev named.conf named.root make-localhost
29PPPCNF= ppp.conf.sample ppp.linkup.sample ppp.linkdown.sample \
30	ppp.secret.sample ppp.deny ppp.shells.sample
31NOSPAM=	Makefile README sendmail.cf.additions
32
33
34# Special top level files for FreeBSD
35COPYRIGHT=	COPYRIGHT
36FREEBSD=
37FREEBSD+=	${COPYRIGHT}
38
39# Compatibility stuff, remove those links
40LATIN1LINKS = \
41	da_DK de_AT de_CH de_DE en_AU en_CA en_GB en_US es_ES fi_FI \
42	fr_BE fr_CA fr_CH fr_FR is_IS it_CH it_IT nl_BE nl_NL no_NO \
43	pt_PT sv_SE
44
45etc:
46
47distribute:
48	cd ${.CURDIR} ; ${MAKE} distribution DESTDIR=${DISTDIR}/bin
49
50distribution:
51	(cd ${.CURDIR}; \
52	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 ${BIN1} ${DESTDIR}/etc; \
53	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 755 ${BIN2} ${DESTDIR}/etc; \
54	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 600 /dev/null \
55	    ${DESTDIR}/var/cron/log; \
56	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 600 \
57	    master.passwd ${DESTDIR}/etc; \
58	( cd ${.CURDIR}/periodic; ${MAKE} install );\
59	( cd ${.CURDIR}/../gnu/usr.bin/send-pr; ${MAKE} etc-gnats-freefall );\
60	( cd ${.CURDIR}/../gnu/libexec/uucp/sample; ${MAKE} install ); \
61	( cd ${.CURDIR}/../share/termcap; ${MAKE} etc-termcap ); \
62	( cd ${.CURDIR}/../usr.sbin/rmt; ${MAKE} etc-rmt ); \
63	( cd ${.CURDIR}/sendmail; ${MAKE} etc-sendmail.cf ); \
64	( cd ${.CURDIR}/../sys/i386/boot/biosboot; ${MAKE} install-boothelp ); \
65	pwd_mkdb -p -d ${DESTDIR}/etc ${DESTDIR}/etc/master.passwd; \
66	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 555 \
67	     MAKEDEV.local etc.${MACHINE_ARCH}/MAKEDEV ${DESTDIR}/dev )
68	(cd ${DESTDIR}/dev; sh MAKEDEV all) ;
69	(cd ${.CURDIR}/root; \
70		${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 dot.cshrc \
71		    ${DESTDIR}/root/.cshrc; \
72		${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 dot.klogin \
73		    ${DESTDIR}/root/.klogin; \
74		${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 dot.login \
75		    ${DESTDIR}/root/.login; \
76		${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 dot.profile \
77		    ${DESTDIR}/root/.profile; \
78		rm -f ${DESTDIR}/.cshrc ${DESTDIR}/.profile; \
79		ln ${DESTDIR}/root/.cshrc ${DESTDIR}/.cshrc; \
80		ln ${DESTDIR}/root/.profile ${DESTDIR}/.profile)
81	cd ${.CURDIR}/mtree; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 444 \
82	    ${MTREE} ${DESTDIR}/etc/mtree
83	cd ${.CURDIR}/namedb; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 \
84	    ${NAMEDB} ${DESTDIR}/etc/namedb
85	cd ${.CURDIR}/ppp; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 \
86	    ${PPPCNF} ${DESTDIR}/etc/ppp
87	cd ${.CURDIR}/mail; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 \
88	    ${NOSPAM} ${DESTDIR}/etc/mail
89	${INSTALL} -c -o ${BINOWN} -g operator -m 664 /dev/null \
90	    ${DESTDIR}/etc/dumpdates
91	${INSTALL} -c -o nobody -g ${BINGRP} -m 664 /dev/null \
92	    ${DESTDIR}/var/db/locate.database
93	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \
94	    ${DESTDIR}/var/log/lpd-errs
95	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \
96	    ${DESTDIR}/var/log/maillog
97	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \
98	    ${DESTDIR}/var/log/lastlog
99	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \
100	    ${DESTDIR}/var/log/messages
101	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 600 /dev/null \
102	    ${DESTDIR}/var/log/slip.log
103	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 600 /dev/null \
104	    ${DESTDIR}/var/log/ppp.log
105	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \
106	    ${DESTDIR}/var/log/wtmp
107	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \
108	    ${DESTDIR}/var/run/utmp
109	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 ${.CURDIR}/minfree \
110	    ${DESTDIR}/var/crash
111	(cd ${.CURDIR}/..; \
112	    ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 444 ${FREEBSD} \
113		${DESTDIR}/)
114	(cd ${.CURDIR}/../share/man; ${MAKE} makedb; )
115
116distrib-dirs:
117	mtree -deU -f ${.CURDIR}/mtree/BSD.root.dist -p ${DESTDIR}/
118	mtree -deU -f ${.CURDIR}/mtree/BSD.var.dist -p ${DESTDIR}/var
119# Compatibility stuff, remove obsoleted links, if exists
120	if [ -d	${DESTDIR}/usr/share/locale ] ;	\
121	then \
122		cd ${DESTDIR}/usr/share/locale;	\
123		for l in ${LATIN1LINKS}	; do \
124			if [ -h $$l.ISO_8859-1 ]; then \
125				rm $$l.ISO_8859-1; \
126			fi ; \
127		done; \
128	fi
129	mtree -deU -f ${.CURDIR}/mtree/BSD.usr.dist -p ${DESTDIR}/usr
130	mtree -deU -f ${.CURDIR}/mtree/BSD.include.dist \
131		-p ${DESTDIR}/usr/include
132	cd ${DESTDIR}/; rm -f ${DESTDIR}/sys; ln -s usr/src/sys sys
133	cd ${DESTDIR}/usr/share/locale; \
134	set - `cat ${.CURDIR}/locale.alias`; \
135	while [ $$# -gt 0 ] ; \
136	do \
137		rm -rf "$$1"; \
138		ln -s "$$2" "$$1"; \
139		shift; shift; \
140	done
141	cd ${DESTDIR}/usr/share/nls; \
142	set - `cat ${.CURDIR}/locale.alias`; \
143	while [ $$# -gt 0 ] ; \
144	do \
145		rm -rf "$$1"; \
146		ln -s "$$2" "$$1"; \
147		shift; shift; \
148	done; \
149	rm -rf POSIX; \
150	ln -s C POSIX
151
152.include <bsd.prog.mk>
153