From owner-freebsd-standards Sun Oct 27 9:24:40 2002 Delivered-To: freebsd-standards@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C9AE637B401 for ; Sun, 27 Oct 2002 09:24:38 -0800 (PST) Received: from khavrinen.lcs.mit.edu (khavrinen.lcs.mit.edu [18.24.4.193]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3B1B443E42 for ; Sun, 27 Oct 2002 09:24:38 -0800 (PST) (envelope-from wollman@khavrinen.lcs.mit.edu) Received: from khavrinen.lcs.mit.edu (localhost [IPv6:::1]) by khavrinen.lcs.mit.edu (8.12.3/8.12.5) with ESMTP id g9RHObgQ031516 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=OK); Sun, 27 Oct 2002 12:24:37 -0500 (EST) (envelope-from wollman@khavrinen.lcs.mit.edu) Received: (from wollman@localhost) by khavrinen.lcs.mit.edu (8.12.3/8.12.5/Submit) id g9RHObQ2031513; Sun, 27 Oct 2002 12:24:37 -0500 (EST) (envelope-from wollman) Date: Sun, 27 Oct 2002 12:24:37 -0500 (EST) From: Garrett Wollman Message-Id: <200210271724.g9RHObQ2031513@khavrinen.lcs.mit.edu> To: Mark Valentine Cc: standards@FreeBSD.ORG Subject: Re: Why I am opposed to a Standards Ghetto In-Reply-To: <200210271115.g9RBFv1m031035@dotar.thuvia.org> References: <200210271115.g9RBFv1m031035@dotar.thuvia.org> Sender: owner-freebsd-standards@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG < said: > Is a Standard application expected to assume it will be run in a Standard > environment? It may, but need not. > If so, what is confstr(_CS_PATH, ...) for? Is it really reasonable > to assume this? It's not clear to me that changing other settings could not also be required. The purpose of the confstr() call is mainly to help applications have have no environment at all, or can't trust their environment (e.g., set-id programs) figure out what to do. > If a Standard application may be run in a non-Standard environment, how > does it bootstrap into a Standard environment? It is not clear that there is any defined mechanism. > If we can make the bridge from the BSD environment to the POSIX environment > easy to cross, that will surely encourage people to follow that path. I don't see much evidence that this has happened in systems where it has been tried (e.g., Solaris). If we were going to go down this road, the only implementation I could reasonably support would be an environment variable which downgraded from standard to ``like it was in FreeBSD 4.x'' -- with the default being standards-compliant. That is the approach I took for expr(1), and I'd be willing to extend that for the use of other applications. Perhaps something like this: - Deprecate EXPR_COMPAT. - Define a new standard environment variable, _FreeBSD_4_COMPAT, the value of which can be either the empty string or a list of programs to be affected. - Add a new library routine, int check_utility_compat(const char *utility), which centralizes checking for this environment variable. - Update expr(1) and sort(1) to be the first clients. I can have this done tonight after I take care of some existing business in my tree. -GAWollman To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-standards" in the body of the message