From dee3138ca253e65242d46b2a6f055ae7e18ab655 Mon Sep 17 00:00:00 2001 From: todd <> Date: Fri, 4 Jan 2002 09:34:35 +0000 Subject: [PATCH] rules to build the MAKEDEV files: all -> builds 'this' arch (etc.$(uname -m)/MAKEDEV) allarchs -> builds all archs (etc.*/MAKEDEV) clean -> cleans 'this' arch (etc.$(uname -m)/MAKEDEV) cleandirs -> cleans all archs (etc.*/MAKEDEV) also, build the MAKEDEV files during the release process --- src/etc/Makefile | 28 ++++++++++++++++++++++++++-- 1 file changed, 26 insertions(+), 2 deletions(-) diff --git a/src/etc/Makefile b/src/etc/Makefile index 39e2cb80..a4fdf62c 100644 --- a/src/etc/Makefile +++ b/src/etc/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.135 2001/12/25 01:30:22 deraadt Exp $ +# $OpenBSD: Makefile,v 1.136 2002/01/04 09:34:35 todd Exp $ TZDIR= /usr/share/zoneinfo LOCALTIME= US/Pacific @@ -55,7 +55,7 @@ distribution-etc-root-var distribution distrib-dirs release snapshot: @echo setenv DESTDIR before doing that! @false .else -distribution-etc-root-var: distrib-dirs +distribution-etc-root-var: distrib-dirs allarchs ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 ${BIN1} ${DESTDIR}/etc cat etc.${MACHINE}/ttys ttys.pty > ${DESTDIR}/etc/ttys && \ chown ${BINOWN} ${DESTDIR}/etc/ttys && \ @@ -318,4 +318,28 @@ snap_md: .endif # DESTDIR check +MAKEDEVARCHS+=sparc64 + +all: + @make M=${MACHINE} m4 + +clean: + rm -f etc.${MACHINE}/MAKEDEV + +cleandir: + @cd ${.CURDIR}; for m in ${MAKEDEVARCHS}; do \ + make MACHINE=$$m clean; done + +m4: etc.${M}/MAKEDEV + +etc.${M}/MAKEDEV: MAKEDEV.sub MAKEDEV.mi etc.${M}/MAKEDEV.md + @echo "==> etc.${M}/MAKEDEV" + @m4 -DMACHINE=${M} MAKEDEV.mi > etc.${M}/.MAKEDEV.tmp && \ + mv etc.${M}/.MAKEDEV.tmp etc.${M}/MAKEDEV || \ + rm etc.${M}/.MAKEDEV.tmp + +allarchs: MAKEDEV.sub MAKEDEV.mi + @cd ${.CURDIR}; for m in ${MAKEDEVARCHS}; do \ + make M=$$m m4; done + .include