Makefile revision 14662
1#	from: @(#)Makefile	5.11 (Berkeley) 5/21/91
2#	$Id: Makefile,v 1.133 1996/03/17 08:48:20 markm Exp $
3
4# -rw-r--r--
5BINOWN= root
6BINGRP= wheel
7BIN1=   aliases amd.map csh.cshrc csh.login csh.logout dm.conf \
8	ftpusers gettytab group hosts host.conf hosts.equiv hosts.lpd \
9	inetd.conf login.access motd modems netstart networks \
10	newsyslog.conf phones pccard.conf.sample printcap profile protocols \
11	rc rc.local rc.serial etc.${MACHINE}/rc.${MACHINE} \
12	remote security services sysconfig shells \
13	syslog.conf ttys etc.${MACHINE}/disktab rpc make.conf \
14	${.CURDIR}/../gnu/usr.bin/man/manpath/manpath.config \
15	${.CURDIR}/../usr.bin/mail/misc/mail.rc
16
17# -rw-rw-rw-
18BIN2=	motd
19
20# -rwxr-xr-x root.wheel, for the new cron root.wheel
21BIN3=	daily weekly monthly pccard_ether
22
23MTREE=	BSD.local.dist BSD.root.dist BSD.usr.dist BSD.var.dist
24NAMEDB=	PROTO.localhost.rev named.boot named.root make-localhost
25PPPCNF= ppp.conf.filter.sample ppp.conf.iij ppp.conf.sample \
26	ppp.linkup.sample ppp.secret.sample
27
28# Special top level files for FreeBSD
29COPYRIGHT=	COPYRIGHT
30FREEBSD=
31FREEBSD+=	${COPYRIGHT}
32
33# Compatibility stuff, remove those links
34LATIN1LINKS = \
35	da_DK de_AT de_CH de_DE en_AU en_CA en_GB en_US es_ES fi_FI \
36	fr_BE fr_CA fr_CH fr_FR is_IS it_CH it_IT nl_BE nl_NL no_NO \
37	pt_PT sv_SE
38
39all depend etc install lint:
40
41distribute:
42	cd ${.CURDIR} ; ${MAKE} distribution DESTDIR=${DISTDIR}/bin
43
44distribution:
45	(cd ${.CURDIR}; \
46	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 ${BIN1} ${DESTDIR}/etc; \
47	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 666 ${BIN2} ${DESTDIR}/etc; \
48	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 755 ${BIN3} ${DESTDIR}/etc; \
49	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 crontab ${DESTDIR}/etc; \
50	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 600 /dev/null \
51	    ${DESTDIR}/var/cron/log; \
52	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 600 \
53	    master.passwd ${DESTDIR}/etc; \
54	pwd_mkdb -p -d ${DESTDIR}/etc ${DESTDIR}/etc/master.passwd; \
55	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 555 \
56	     MAKEDEV.local etc.${MACHINE}/MAKEDEV ${DESTDIR}/dev )
57	(cd ${DESTDIR}/dev; sh MAKEDEV all) ;
58	(cd ${.CURDIR}/root; \
59		${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 dot.fvwmrc \
60		    ${DESTDIR}/root/.fvwmrc; \
61		${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 dot.Xdefaults \
62		    ${DESTDIR}/root/.Xdefaults; \
63		${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 dot.xsession \
64		    ${DESTDIR}/root/.xsession; \
65		${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 dot.cshrc \
66		    ${DESTDIR}/root/.cshrc; \
67		${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 dot.klogin \
68		    ${DESTDIR}/root/.klogin; \
69		${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 dot.login \
70		    ${DESTDIR}/root/.login; \
71		${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 dot.profile \
72		    ${DESTDIR}/root/.profile; \
73		rm -f ${DESTDIR}/.cshrc ${DESTDIR}/.profile; \
74		ln ${DESTDIR}/root/.cshrc ${DESTDIR}/.cshrc; \
75		ln ${DESTDIR}/root/.profile ${DESTDIR}/.profile)
76	cd ${.CURDIR}/mtree; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 444 \
77	    ${MTREE} ${DESTDIR}/etc/mtree
78	cd ${.CURDIR}/namedb; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 \
79	    ${NAMEDB} ${DESTDIR}/etc/namedb
80	cd ${.CURDIR}/ppp; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 \
81	    ${PPPCNF} ${DESTDIR}/etc/ppp
82	${INSTALL} -c -o ${BINOWN} -g operator -m 664 /dev/null \
83	    ${DESTDIR}/etc/dumpdates
84	${INSTALL} -c -o nobody -g ${BINGRP} -m 664 /dev/null \
85	    ${DESTDIR}/var/db/locate.database
86	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \
87	    ${DESTDIR}/var/log/lpd-errs
88	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \
89	    ${DESTDIR}/var/log/maillog
90	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \
91	    ${DESTDIR}/var/log/lastlog
92	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \
93	    ${DESTDIR}/var/log/messages
94	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 600 /dev/null \
95	    ${DESTDIR}/var/log/slip.log
96	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \
97	    ${DESTDIR}/var/log/wtmp
98	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \
99	    ${DESTDIR}/var/run/utmp
100	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 ${.CURDIR}/minfree \
101	    ${DESTDIR}/var/crash
102	(cd ${.CURDIR}/../usr.sbin/sendmail/src; \
103	    ${MAKE} obj; \
104	    ${MAKE} all; \
105	    ${MAKE} install; \
106	 cd ../cf/cf; \
107	    ${MAKE} obj; \
108	    ${MAKE} freebsd.cf; \
109	    ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 obj/freebsd.cf \
110		${DESTDIR}/etc/sendmail.cf)
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.if defined(MAKE_LOCAL)
133	mtree -deU -f ${.CURDIR}/mtree/BSD.local.dist -p ${DESTDIR}/usr/local
134.endif
135	cd ${DESTDIR}/; rm -f ${DESTDIR}/sys; ln -s usr/src/sys sys
136	cd ${DESTDIR}/usr/share/locale; \
137	set - `cat ${.CURDIR}/locale.alias`; \
138	while [ $$# -gt 0 ] ; \
139	do \
140		rm -rf "$$1"; \
141		ln -s "$$2" "$$1"; \
142		shift; shift; \
143	done
144	cd ${DESTDIR}/usr/share/nls; \
145	set - `cat ${.CURDIR}/locale.alias`; \
146	while [ $$# -gt 0 ] ; \
147	do \
148		rm -rf "$$1"; \
149		ln -s "$$2" "$$1"; \
150		shift; shift; \
151	done; \
152	rm -rf POSIX; \
153	ln -s C POSIX
154.if defined(MAKE_LOCAL)
155	cd ${DESTDIR}/usr/local/share/nls; \
156	set - `cat ${.CURDIR}/locale.alias`; \
157	while [ $$# -gt 0 ] ; \
158	do \
159		rm -rf "$$1"; \
160		ln -s "$$2" "$$1"; \
161		shift; shift; \
162	done; \
163	rm -rf POSIX; \
164	ln -s C POSIX
165.endif
166
167.include <bsd.prog.mk>
168