From owner-freebsd-arch@FreeBSD.ORG Tue May 6 11:08:23 2003 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B10BB37B401; Tue, 6 May 2003 11:08:23 -0700 (PDT) Received: from burka.carrier.kiev.ua (burka.carrier.kiev.ua [193.193.193.107]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9B9E443F85; Tue, 6 May 2003 11:08:21 -0700 (PDT) (envelope-from netch@lucky.net) Received: from netch@localhost [127.0.0.1] (netch@localhost [127.0.0.1]) by burka.carrier.kiev.ua with ESMTP id h46I8FiT071154; Tue, 6 May 2003 21:08:16 +0300 (EEST) (envelope-from netch@burka.carrier.kiev.ua) Received: (from netch@localhost) by burka.carrier.kiev.ua (8.12.8p1/8.12.8/Submit) id h46I8Elf071150; Tue, 6 May 2003 21:08:14 +0300 (EEST) (envelope-from netch) Date: Tue, 6 May 2003 21:08:14 +0300 From: Valentin Nechayev To: "Jacques A. Vidrine" Message-ID: <20030506180814.GK83663@lucky.net> References: <20030501182820.GA53641@madman.celabo.org> <20030505110601.H53365@beagle.fokus.fraunhofer.de> <20030505175426.GA19352@madman.celabo.org> <20030506093754.B838@beagle.fokus.fraunhofer.de> <20030506092519.GA3158@cirb503493.alcatel.com.au> <20030506112711.K838@beagle.fokus.fraunhofer.de> <20030506153641.GI77708@madman.celabo.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20030506153641.GI77708@madman.celabo.org> X-42: On X-Verify-Sender: verified cc: arch@freebsd.org Subject: Re: Re: `Hiding' libc symbols X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: netch@lucky.net List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 May 2003 18:08:24 -0000 Tue, May 06, 2003 at 10:36:41, nectar wrote about "Re: Re: `Hiding' libc symbols": > Renaming the internal implementation of `foo' to `_foo', and creating > a weak symbol alias with the original name (`foo'). Within libc, > use the `_foo' name when the semantics must be known (e.g. when the > behavior must not be overridden by an application accidently, i.e. > almost always). Macros in `namespace.h' help the compiler with > prototypes etc. OK. How will you distinguish accidental replacing of libc symbols from intentional replacing? It is not reasonable (just IMHO) to divide libc symbols into `allowed to override' and 'disallowed to override' groups. Well, one can say: if, e.g., application exposes Posix accordance, it should not see strlcpy() (let's continue to use it as example) from libc. So, define _strlcpy if not _POSIX_SOURCE of analog. Well, consider next Posix will include it. Define non-hidden version and break compatibility of old applications? If I don't understand something, please explain. But I think now is standards@ issue. -netch-