From owner-freebsd-stable Mon Nov 13 10:19:50 2000 Delivered-To: freebsd-stable@freebsd.org Received: from palrel3.hp.com (palrel3.hp.com [156.153.255.226]) by hub.freebsd.org (Postfix) with ESMTP id 1223537B479; Mon, 13 Nov 2000 10:19:44 -0800 (PST) Received: from adlmail.cup.hp.com (adlmail.cup.hp.com [15.0.100.30]) by palrel3.hp.com (Postfix) with ESMTP id 5570D60C; Mon, 13 Nov 2000 10:19:39 -0800 (PST) Received: from cup.hp.com (gauss.cup.hp.com [15.28.97.152]) by adlmail.cup.hp.com (8.9.3 (PHNE_18546)/8.9.3 SMKit7.02) with ESMTP id KAA22127; Mon, 13 Nov 2000 10:19:39 -0800 (PST) Message-ID: <3A1030BA.D6CB42D0@cup.hp.com> Date: Mon, 13 Nov 2000 13:19:38 -0500 From: Marcel Moolenaar Organization: Hewlett-Packard X-Mailer: Mozilla 4.73 [en] (X11; U; Linux 2.2.12 i386) X-Accept-Language: en MIME-Version: 1.0 To: Bruce Evans Cc: Makoto MATSUSHITA , current@FreeBSD.ORG, stable@FreeBSD.ORG Subject: Re: "make modules" kicks the first module directory twice References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Bruce Evans wrote: > > > Index: Makefile.i386 > > =================================================================== > > RCS file: /home/ncvs/src/sys/conf/Makefile.i386,v > > retrieving revision 1.212 > > diff -u -r1.212 Makefile.i386 > > --- Makefile.i386 2000/10/29 09:47:50 1.212 > > +++ Makefile.i386 2000/11/13 07:49:00 > > @@ -271,11 +271,13 @@ > > > > modules: > > @mkdir -p ${.OBJDIR}/modules > > - cd $S/modules && env ${MKMODULESENV} ${MAKE} obj all > > + cd $S/modules && env ${MKMODULESENV} ${MAKE} obj && \ > > + env ${MKMODULESENV} ${MAKE} all > > > > modules-depend: > > @mkdir -p ${.OBJDIR}/modules > > - cd $S/modules && env ${MKMODULESENV} ${MAKE} obj depend > > + cd $S/modules && env ${MKMODULESENV} ${MAKE} obj $$ \ > > + env ${MKMODULESENV} ${MAKE} depend > > > > modules-clean: > > cd $S/modules && env ${MKMODULESENV} ${MAKE} clean > > > > `&&' should never be used in shell commands in makefiles, although it > may be only a bad example. Mostly that, yes. The first try for a "fix" was: cd $S/modules && env ${MKMODULESENV} ${MAKE} obj cd $S/modules && env ${MKMODULESENV} ${MAKE} all But since $S expands to "../.." and -j runs a single shell, the first cd will succeed, but not the second. I simply copied the "construction" in the second and posted fix. I'll commit a fix with just semi-colons today for all architectures if someone hasn't done that already by that time. -- Marcel Moolenaar mail: marcel@cup.hp.com / marcel@FreeBSD.org tel: (408) 447-4222 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message