From owner-freebsd-current Sun May 19 9:57:11 2002 Delivered-To: freebsd-current@freebsd.org Received: from srv1.cosmo-project.de (srv1.cosmo-project.de [213.83.6.106]) by hub.freebsd.org (Postfix) with ESMTP id 982C437B407; Sun, 19 May 2002 09:56:58 -0700 (PDT) Received: from cicely5.cicely.de (cicely5.cicely.de [IPv6:3ffe:400:8d0:301:200:92ff:fe9b:20e7]) (authenticated bits=0) by srv1.cosmo-project.de (8.12.3/8.12.3) with ESMTP id g4JGusHc054538 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=OK); Sun, 19 May 2002 18:56:56 +0200 (CEST) (envelope-from ticso@cicely5.cicely.de) Received: from cicely5.cicely.de (localhost [IPv6:::1]) by cicely5.cicely.de (8.12.1/8.12.1) with ESMTP id g4JGue95064209 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=NO); Sun, 19 May 2002 18:56:40 +0200 (CEST)?g (envelope-from ticso@cicely5.cicely.de) Received: (from ticso@localhost) by cicely5.cicely.de (8.12.1/8.12.1/Submit) id g4JGuenc064208; Sun, 19 May 2002 18:56:40 +0200 (CEST)?g (envelope-from ticso) Date: Sun, 19 May 2002 18:56:40 +0200 From: Bernd Walter To: "J. Mallett" Cc: freebsd-current@FreeBSD.ORG Subject: Re: make(1) patch to ReadMakefile() to use realpath(3) Message-ID: <20020519165639.GL44753@cicely5.cicely.de> References: <20020519100420.GA8356@FreeBSD.ORG> <20020519132159.GI44753@cicely5.cicely.de> <20020519140003.GA19399@FreeBSD.ORG> <20020519153428.GK44753@cicely5.cicely.de> <20020519162710.GA19228@FreeBSD.ORG> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20020519162710.GA19228@FreeBSD.ORG> User-Agent: Mutt/1.3.26i X-Operating-System: FreeBSD cicely5.cicely.de 5.0-CURRENT i386 Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sun, May 19, 2002 at 04:27:10PM +0000, J. Mallett wrote: > On Sun, May 19, 2002 at 05:34:28PM +0200, Bernd Walter wrote: > > > > I even can't buildworld on another machine without taking care of > > realpath. > > If I don't enshure that the source has the same realpath on the > > machine to run installworld as it had on the machine where I did > > the buildworld it break. > > installworld does? How? The only possibility I can see here is that > dependency rules might be bad because the full paths may differ, but > that wouldn't affect installworld. The filenames in /usr/obj are canonicalized. > > And all that without a real benefit from blindly using realpath(3). > > Show me a canonpath(3) or something which will give the simplest symbolic > i.e. a simplified full path given a relative or absolute path with all > redundancies resolved, without resolving away any symbolic paths. It would be possible to use the realpath code without the softlink handling. Not too difficult if we only had a non-canocalized basedir. > I'm ``blindly'' using the only answer we have to a question: how can I get > an absolute (thus unique) path to an object in the filesystem. Forget it - it's not possible with FreeBSD (see below). I'm just a bit frustrated about all the brokenness with softlink handling I saw, without noticing that FreeBSD doesn't give you a chance to do it right. > I'm open to alternative ways of doing that, especially as I described > canonpath(3) above. After some digging it seems like it's worse. getcwd already returns a canonical path on FreeBSD, NetBSD and Solaris. Only HP-UX returns the accumulated chdir path. Very dissapointing. -- B.Walter COSMO-Project http://www.cosmo-project.de ticso@cicely.de Usergroup info@cosmo-project.de To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message