Makefile revision 99451
11195Srgrimes#	from: @(#)Makefile	5.11 (Berkeley) 5/21/91
250472Speter# $FreeBSD: head/etc/Makefile 99451 2002-07-05 13:39:38Z ru $
337Srgrimes
473251Sgshapiro.if !defined(NO_SENDMAIL)
538103SpeterSUBDIR=	sendmail
673251Sgshapiro.endif
738103Speter
899451SruBIN1=	amd.map apmd.conf auth.conf \
955230Speter	crontab csh.cshrc csh.login csh.logout \
1082480Sbrian	dhclient.conf dm.conf fbtab ftpusers gettytab group \
1165532Snectar	hosts hosts.allow hosts.equiv hosts.lpd \
1255230Speter	inetd.conf login.access login.conf \
1388878Ssheldonh	motd modems netconfig networks newsyslog.conf \
1489364Sdes	phones printcap profile protocols \
1567929Sume	rc rc.atm rc.devfs rc.diskless1 rc.diskless2 rc.firewall rc.firewall6 \
1695227Sgshapiro	rc.network rc.network6 rc.pccard rc.sendmail rc.serial rc.shutdown \
1798187Sgordon	rc.subr rc.syscons rc.sysctl remote rpc services \
1898187Sgordon	shells sysctl.conf syslog.conf usbd.conf \
1955230Speter	etc.${MACHINE_ARCH}/disktab \
2055230Speter	etc.${MACHINE_ARCH}/rc.${MACHINE_ARCH} \
2155230Speter	etc.${MACHINE_ARCH}/ttys \
221734Sjkh	${.CURDIR}/../gnu/usr.bin/man/manpath/manpath.config \
2317639Swosch	${.CURDIR}/../usr.bin/mail/misc/mail.rc \
2417639Swosch	${.CURDIR}/../usr.bin/locate/locate/locate.rc
2537Srgrimes
2677041Sru.if !defined(NO_I4B)
2777041SruBIN1+=	rc.isdn
2877041Sru.endif
2977041Sru
3098548Sru.if exists(${.CURDIR}/../crypto) && !defined(NO_OPENSSL)
3198548Sru.if !defined(NO_OPENSSH)
3257488SpeterSSH=	${.CURDIR}/../crypto/openssh/ssh_config \
3374837Sgreen	${.CURDIR}/../crypto/openssh/sshd_config \
3492898Sdes	moduli
3557459Smarkm.endif
3660677SkrisSSL=	${.CURDIR}/../crypto/openssl/apps/openssl.cnf
3760677Skris.endif
3860677Skris
3982521Salex# -rwxr-xr-x root:wheel, for the new cron root:wheel
4048734SiwasakiBIN2=	netstart pccard_ether rc.suspend rc.resume
41147Srgrimes
4299449SruDEFAULTS= rc.conf pccard.conf periodic.conf
4399449Sru
4427487SasamiMTREE=	BSD.include.dist BSD.local.dist BSD.root.dist BSD.usr.dist \
4565168Sasami	BSD.var.dist BSD.x11.dist BSD.x11-4.dist
4695144Sgshapiro.if !defined(NO_SENDMAIL)
4795144SgshapiroMTREE+=	BSD.sendmail.dist
4895144Sgshapiro.endif
4999451Sru
5099451SruNAMEDB=	PROTO.localhost.rev PROTO.localhost-v6.rev named.conf named.root \
5190281Sume	make-localhost
5299451Sru
5399451SruPPPCNF=	ppp.conf
5499451Sru
5564598SgshapiroETCMAIL=Makefile README mailer.conf access.sample virtusertable.sample \
5664598Sgshapiro	mailertable.sample aliases
5737Srgrimes
58263Srgrimes# Special top level files for FreeBSD
5999449SruFREEBSD=COPYRIGHT
60263Srgrimes
6138103Speteretc:
6237Srgrimes
634487Sphkdistribute:
6495327Sobrien	cd ${.CURDIR} ; ${MAKE} distribution DESTDIR=${DISTDIR}/${DISTRIBUTION}
6539590Sjkh.if defined(OBJFORMAT)
6695327Sobrien	echo OBJFORMAT=${OBJFORMAT} > ${DISTDIR}/${DISTRIBUTION}/etc/objformat
6739590Sjkh.endif
6895509Sru	${INSTALL} ${COPY} -o ${BINOWN} -g ${BINGRP} -m 444 \
6995509Sru	    ${.CURDIR}/../sys/${MACHINE}/conf/GENERIC.hints \
7095509Sru	    ${DISTDIR}/${DISTRIBUTION}/boot/device.hints
715948Sjkh
724487Sphkdistribution:
7399449Sru	cd ${.CURDIR}; \
7499451Sru	    ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 \
7599451Sru		${BIN1} ${DESTDIR}/etc; \
7699451Sru	    ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 755 \
7799451Sru		${BIN2} ${DESTDIR}/etc; \
7899451Sru	    ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 600 \
7999451Sru		master.passwd nsmb.conf opieaccess ${DESTDIR}/etc; \
8099451Sru	    pwd_mkdb -p -d ${DESTDIR}/etc ${DESTDIR}/etc/master.passwd
8199449Sru	cd ${.CURDIR}/defaults; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 \
8299449Sru	    ${DEFAULTS} ${DESTDIR}/etc/defaults
8399449Sru	cd ${.CURDIR}/periodic; ${MAKE} install
8499449Sru	cd ${.CURDIR}/rc.d; ${MAKE} install
8599449Sru	cd ${.CURDIR}/../gnu/usr.bin/send-pr; ${MAKE} etc-gnats-freefall
8699449Sru	cd ${.CURDIR}/../share/termcap; ${MAKE} etc-termcap
8799449Sru	cd ${.CURDIR}/../usr.sbin/rmt; ${MAKE} etc-rmt
8899449Sru	cd ${.CURDIR}/pam.d; ${MAKE} install
8977041Sru.if !defined(NO_I4B)
9099449Sru	cd ${.CURDIR}/isdn; ${MAKE} install
9177041Sru.endif
9273251Sgshapiro.if !defined(NO_SENDMAIL)
9399449Sru	cd ${.CURDIR}/sendmail; ${MAKE} distribution
9473251Sgshapiro.endif
9598548Sru.if exists(${.CURDIR}/../crypto) && !defined(NO_OPENSSL)
9698548Sru.if !defined(NO_OPENSSH)
9799451Sru	cd ${.CURDIR}; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 \
9899451Sru	    ${SSH} ${DESTDIR}/etc/ssh
9957488Speter.endif
10099451Sru	cd ${.CURDIR}; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 \
10199451Sru	    ${SSL} ${DESTDIR}/etc/ssl
10260677Skris.endif
10374990Sasmodai.if !defined(NO_MAKEDEV_INSTALL)
10499449Sru	cd ${.CURDIR}; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 555 \
10599451Sru	    MAKEDEV.local MAKEDEV ${DESTDIR}/dev
10674990Sasmodai.if !defined(NO_MAKEDEV_RUN)
10799449Sru	cd ${DESTDIR}/dev; sh MAKEDEV all
10857071Srwatson.endif
10974990Sasmodai.endif
11099449Sru	cd ${.CURDIR}/root; \
11199451Sru	    ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 \
11299451Sru		dot.cshrc ${DESTDIR}/root/.cshrc; \
11399451Sru	    ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 \
11499451Sru		dot.klogin ${DESTDIR}/root/.klogin; \
11599451Sru	    ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 \
11699451Sru		dot.login ${DESTDIR}/root/.login; \
11799451Sru	    ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 \
11899451Sru		dot.profile ${DESTDIR}/root/.profile; \
11999451Sru	    rm -f ${DESTDIR}/.cshrc ${DESTDIR}/.profile; \
12099451Sru	    ln ${DESTDIR}/root/.cshrc ${DESTDIR}/.cshrc; \
12199451Sru	    ln ${DESTDIR}/root/.profile ${DESTDIR}/.profile
1229970Sbde	cd ${.CURDIR}/mtree; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 444 \
1231731Sjkh	    ${MTREE} ${DESTDIR}/etc/mtree
1249970Sbde	cd ${.CURDIR}/namedb; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 \
1251731Sjkh	    ${NAMEDB} ${DESTDIR}/etc/namedb
12689936Scjc	cd ${.CURDIR}/ppp; ${INSTALL} -c -o root -g ${BINGRP} -m 600 \
1276177Samurai	    ${PPPCNF} ${DESTDIR}/etc/ppp
12830589Sjmb	cd ${.CURDIR}/mail; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 \
12964598Sgshapiro	    ${ETCMAIL} ${DESTDIR}/etc/mail
13064629Sgshapiro	@if [ -d ${DESTDIR}/etc/mail -a -f ${DESTDIR}/etc/mail/aliases -a \
13164629Sgshapiro	      ! -f ${DESTDIR}/etc/aliases ]; then \
13264629Sgshapiro		set -x; \
13364629Sgshapiro		ln -s mail/aliases ${DESTDIR}/etc/aliases; \
13464629Sgshapiro	fi
1359970Sbde	${INSTALL} -c -o ${BINOWN} -g operator -m 664 /dev/null \
13637Srgrimes	    ${DESTDIR}/etc/dumpdates
13763097Speter	${INSTALL} -c -o nobody -g ${BINGRP} -m 644 /dev/null \
138147Srgrimes	    ${DESTDIR}/var/db/locate.database
13992099Srwatson	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 600 /dev/null \
14092100Srwatson	    ${DESTDIR}/var/log/auth.log
14199449Sru	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 600 /dev/null \
14299449Sru	    ${DESTDIR}/var/log/cron
14363097Speter	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 /dev/null \
144147Srgrimes	    ${DESTDIR}/var/log/lpd-errs
14583561Sjlemon	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 640 /dev/null \
14637Srgrimes	    ${DESTDIR}/var/log/maillog
14763097Speter	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 /dev/null \
148288Srgrimes	    ${DESTDIR}/var/log/lastlog
14963097Speter	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 /dev/null \
150147Srgrimes	    ${DESTDIR}/var/log/messages
15113378Sache	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 600 /dev/null \
15250126Sgreen	    ${DESTDIR}/var/log/security
15382866Sbrian	${INSTALL} -c -o ${BINOWN} -g network -m 640 /dev/null \
15413378Sache	    ${DESTDIR}/var/log/slip.log
15582866Sbrian	${INSTALL} -c -o ${BINOWN} -g network -m 640 /dev/null \
15617104Spst	    ${DESTDIR}/var/log/ppp.log
15763097Speter	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 /dev/null \
158147Srgrimes	    ${DESTDIR}/var/log/wtmp
15963097Speter	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 /dev/null \
16037Srgrimes	    ${DESTDIR}/var/run/utmp
16164665Skris	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 ${.CURDIR}/minfree \
1621759Sjkh	    ${DESTDIR}/var/crash
16399451Sru	cd ${.CURDIR}/..; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 444 \
16499451Sru		${FREEBSD} ${DESTDIR}/
16561888Sasmodai.if !defined(NOMAN)
16699449Sru	cd ${.CURDIR}/../share/man; ${MAKE} makedb
16761888Sasmodai.endif
16837Srgrimes
169147Srgrimesdistrib-dirs:
17089074Sphantom	-set - `grep "^[a-zA-Z]" ${.CURDIR}/locale.deprecated`; \
17189074Sphantom	while [ $$# -gt 0 ] ; \
17289074Sphantom	do \
17389074Sphantom		for dir in /usr/share/locale \
17489074Sphantom			   /usr/share/nls \
17589074Sphantom			   /usr/local/share/nls; \
17689074Sphantom		do \
17789074Sphantom			test -d ${DESTDIR}/$${dir} && cd ${DESTDIR}/$${dir}; \
17889074Sphantom			test -L "$$2" && rm -rf "$$2"; \
17989074Sphantom			test \! -L "$$1" && test -d "$$1" && mv "$$1" "$$2"; \
18089074Sphantom		done; \
18189074Sphantom		shift; shift; \
18289074Sphantom	done
18365884Sache	mtree -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.root.dist -p ${DESTDIR}/
18465884Sache	mtree -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.var.dist -p ${DESTDIR}/var
18565884Sache	mtree -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.usr.dist -p ${DESTDIR}/usr
18665884Sache	mtree -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.include.dist \
1877129Srgrimes		-p ${DESTDIR}/usr/include
18895144Sgshapiro.if !defined(NO_SENDMAIL)
18995144Sgshapiro	mtree -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.sendmail.dist -p ${DESTDIR}/
19095144Sgshapiro.endif
191410Srgrimes	cd ${DESTDIR}/; rm -f ${DESTDIR}/sys; ln -s usr/src/sys sys
19277993Sache	cd ${DESTDIR}/usr/share/man/en.ISO8859-1; ln -sf ../man* .
19377993Sache	cd ${DESTDIR}/usr/share/man; \
19477993Sache	set - `grep "^[a-zA-Z]" ${.CURDIR}/man.alias`; \
19577993Sache	while [ $$# -gt 0 ] ; \
19677993Sache	do \
19777993Sache		rm -rf "$$1"; \
19877993Sache		ln -s "$$2" "$$1"; \
19977993Sache		shift; shift; \
20077993Sache	done
2017129Srgrimes	cd ${DESTDIR}/usr/share/locale; \
20277976Sache	set - `grep "^[a-zA-Z]" ${.CURDIR}/locale.alias`; \
20311635Sache	while [ $$# -gt 0 ] ; \
20411635Sache	do \
20511635Sache		rm -rf "$$1"; \
20611635Sache		ln -s "$$2" "$$1"; \
20711635Sache		shift; shift; \
2087129Srgrimes	done
20911635Sache	cd ${DESTDIR}/usr/share/nls; \
21077999Sache	set - `grep "^[a-zA-Z]" ${.CURDIR}/nls.alias`; \
21111635Sache	while [ $$# -gt 0 ] ; \
21211635Sache	do \
21311635Sache		rm -rf "$$1"; \
21411635Sache		ln -s "$$2" "$$1"; \
21511635Sache		shift; shift; \
21677999Sache	done
217147Srgrimes
21848185Ssheldonhetc-examples:
21999451Sru	cd ${.CURDIR}; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 444 \
22099451Sru	    ${BIN1} ${BIN2} nsmb.conf opieaccess \
22199451Sru	    ${DESTDIR}/usr/share/examples/etc
22299451Sru	cd ${.CURDIR}/defaults; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 444 \
22399451Sru	    ${DEFAULTS} ${DESTDIR}/usr/share/examples/etc/defaults
22448185Ssheldonh
22537Srgrimes.include <bsd.prog.mk>
226