From owner-freebsd-current Thu May 28 02:41:37 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id CAA10765 for freebsd-current-outgoing; Thu, 28 May 1998 02:41:37 -0700 (PDT) (envelope-from owner-freebsd-current@FreeBSD.ORG) Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id CAA10757 for ; Thu, 28 May 1998 02:41:35 -0700 (PDT) (envelope-from bde@godzilla.zeta.org.au) Received: from godzilla.zeta.org.au (godzilla.zeta.org.au [203.15.68.22]) by freefall.freebsd.org (8.8.8/8.8.5) with ESMTP id CAA21376 for ; Thu, 28 May 1998 02:35:56 -0700 (PDT) Received: (from bde@localhost) by godzilla.zeta.org.au (8.8.7/8.8.7) id TAA31697; Thu, 28 May 1998 19:41:26 +1000 Date: Thu, 28 May 1998 19:41:26 +1000 From: Bruce Evans Message-Id: <199805280941.TAA31697@godzilla.zeta.org.au> To: bde@zeta.org.au, kuku@gilberto.physik.RWTH-Aachen.DE Subject: Re: help! - nodes.h where is it? Cc: eivind@FreeBSD.ORG, freebsd-current@freefall.cdrom.com Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG >> It looks like your src/share/mk/bsd.prog.mk is broken. > >make mk doesn't work anymore, btw. It went away about a year ago. >OK, I overwrote all my /usr/share/mk files with the >new ones, >went into /usr/src/bin/sh ># make clean >rm -f mkinit mkinit.o mknodes mknodes.o mksyntax mksyntax.o builtins.c init.c nodes.c syntax.c builtins.h nodes.h syntax.h token.h y.tab.h sh alias.o arith.o arith_lex.o cd.o echo.o error.o eval.o exec.o expand.o histedit.o input.o jobs.o mail.o main.o memalloc.o miscbltin.o mystring.o options.o output.o parser.o printf.o redir.o show.o trap.o var.o builtins.o init.o nodes.o syntax.o sh.1.gz sh.1.cat.gz arith_lex.c arith.c y.tab.c y.tab.h ># make >cc -O2 -m486 -pipe -DSHELL -I. -I/a/src/bin/sh -c /a/src/bin/sh/alias.c >yacc -d /a/src/bin/sh/arith.y >cp y.tab.c arith.c >... With the current `mk' files and Makefiles, `make' should begin with: cc -O -pipe -DSHELL -I. -I/usr/src/bin/sh -c /usr/src/bin/sh/mknodes.c cc -O -pipe -DSHELL -I. -I/usr/src/bin/sh -static mknodes.o -o mknodes ./mknodes /usr/src/bin/sh/nodetypes /usr/src/bin/sh/nodes.c.pat cc -O -pipe -DSHELL -I. -I/usr/src/bin/sh -c /usr/src/bin/sh/mksyntax.c cc -O -pipe -DSHELL -I. -I/usr/src/bin/sh -static mksyntax.o -o mksyntax ./mksyntax sh /usr/src/bin/sh/mktokens yacc -d /usr/src/bin/sh/arith.y cp y.tab.c arith.c ... It builds all the headers first, as it must to satisfy the following rule in bsd.prog.mk: .if defined(PROG) && !exists(${DEPENDFILE}) ${OBJS}: ${SRCS:M*.h} .endif I think understand this now. This rule doesn't apply if .depend already exists, and if .depend already exists then it must have full dependencies on nodes.h to work properly. You probably have a stale .depend file in the source directory. A stale .depend file in the obj directory would be always be deleted by `make world'. A stale .depend file in the source directory would only sometimes be deleted by `make world'. This is another bug in `make world', like the libgmp/mp* one. Even if the current directory is readonly, `make world' will only attempt to change it if there is certain garbage in it. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message