From owner-cvs-src@FreeBSD.ORG Mon Aug 9 15:55:16 2004 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DBA2316A4F5; Mon, 9 Aug 2004 15:55:15 +0000 (GMT) Received: from n33.kp.t-systems-sfr.com (n33.kp.t-systems-sfr.com [129.247.16.33]) by mx1.FreeBSD.org (Postfix) with ESMTP id 60D3F43D31; Mon, 9 Aug 2004 15:55:14 +0000 (GMT) (envelope-from harti@freebsd.org) Received: from n81.sp.op.dlr.de (n81g.sp.op.dlr.de [129.247.163.1]) i79FsqX324526; Mon, 9 Aug 2004 17:54:53 +0200 Received: from zeus.nt.op.dlr.de (zeus.nt.op.dlr.de [129.247.173.3]) i79Fsqf185600; Mon, 9 Aug 2004 17:54:52 +0200 Received: from beagle.kn.op.dlr.de (opkndnwsbsd178 [129.247.173.178]) by zeus.nt.op.dlr.de (8.11.7+Sun/8.9.1) with ESMTP id i79Fsoe00704; Mon, 9 Aug 2004 17:54:50 +0200 (MET DST) Date: Mon, 9 Aug 2004 17:54:51 +0200 (CEST) From: Harti Brandt X-X-Sender: brandt@beagle.kn.op.dlr.de To: "M. Warner Losh" In-Reply-To: <20040809.094110.04712576.imp@bsdimp.com> Message-ID: <20040809174540.U32590@beagle.kn.op.dlr.de> References: <7mllgolwsk.wl@black.imgsrc.co.jp> <20040809061817.GA53369@numeri.campus.luth.se> <20040809.094110.04712576.imp@bsdimp.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: kuriyama@imgsrc.co.jp cc: src-committers@freebsd.org cc: cvs-all@freebsd.org cc: johan@freebsd.org cc: cvs-src@freebsd.org Subject: Re: cvs commit: src/usr.bin/make Makefile main.c nonints.h var.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Harti Brandt List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 09 Aug 2004 15:55:16 -0000 On Mon, 9 Aug 2004, M. Warner Losh wrote: MWL>In message: <20040809.092824.11587387.imp@bsdimp.com> MWL> "M. Warner Losh" writes: MWL>: In message: <20040809061817.GA53369@numeri.campus.luth.se> MWL>: Johan Karlsson writes: MWL>: : On Mon, Aug 09, 2004 at 14:12 (+0900), Jun Kuriyama wrote: MWL>: : > At Tue, 3 Aug 2004 18:56:31 +0000 (UTC), MWL>: : > Hartmut Brandt wrote: MWL>: : > > Log: MWL>: : > > Put variable assignments from the command line into the MAKEFLAGS MWL>: : > > variable as required by POSIX. This causes such variables to be MWL>: : > > pushed into all sub-makes called by the make (except when the MAKEFLAGS MWL>: : > > variable is explicitely changed in the sub-make's environment). MWL>: : > > This makes them also mostly un-overrideable in sub-makes except on the MWL>: : > > sub-make's command line. Therefor specifying 'make CC=icc' will cause MWL>: : > > icc to be used as C compiler in all sub-makes no matter what the Makefiles MWL>: : > > itself try to do to the CC variable. MWL>: : > > MWL>: : > > This patch also corrects the handling of the MFLAGS variable. MFLAGS MWL>: : > > contains all the command line flags but not the command line variable MWL>: : > > assignments. The evaluation of the .MFLAGS or .MAKEFLAGS target now MWL>: : > > changes both MFLAGS and MAKEFLAGS (they used to change MAKEFLAGS only). MWL>: : > > Makefiles can use MFLAGS for their own purposes given that they do not MWL>: : > > except MFLAGS to be undefined at the beginning and that they don't evaluate MWL>: : > > .MFLAGS or .MAKEFLAGS. MFLAGS should be removed for POSIX compliance, MWL>: : > > but it is unfortunately heavily used by the X makefiles. MWL>: : > MWL>: : > I'm using MAKEOBJDIRPREFIX as a make argument to build the world. MWL>: : MWL>: : Don't. MWL>: : According to make(1) it is an environment variable. MWL>: MWL>: The current man page is stunningly vague about this. It says that it MWL>: respects these environment variables, but it doesn't say they have to MWL>: be set in the enviornment to the exclusion of setting them on the MWL>: command line. MWL> MWL>So either we can make it work, or document that the variables listed MWL>in the environment section must be set as environment variables only. There is nothing to be made work. Both variables are intended to be used as environment variables. That they happend to work from the command line was a side effect of make putting its variables into the environment. Does the following clarify things enough? harti Index: make.1 =================================================================== RCS file: /local/cvs/freebsd/src/usr.bin/make/make.1,v retrieving revision 1.77 diff -u -r1.77 make.1 --- make.1 4 Aug 2004 15:10:35 -0000 1.77 +++ make.1 9 Aug 2004 15:51:47 -0000 @@ -533,6 +533,13 @@ .Nm is unable to change into any of the remaining three directories, then the current directory is used. +Note, that +.Ev MAKEOBJDIRPREFIX +and +.Ev MAKEOBJDIR +must be environment variables and should not be set on +.Nm Ns 's +command line. .Pp The .Nm harti