From owner-freebsd-current Tue Aug 29 9:20:54 2000 Delivered-To: freebsd-current@freebsd.org Received: from alpha.dante.org.uk (alpha.dante.org.uk [193.63.211.19]) by hub.freebsd.org (Postfix) with ESMTP id C5F3F37B422; Tue, 29 Aug 2000 09:20:48 -0700 (PDT) Received: from theta.dante.org.uk ([193.63.211.7]) by alpha.dante.org.uk with esmtp (Exim 3.12 #4) id 13To7H-0007Cp-00; Tue, 29 Aug 2000 17:20:03 +0100 Received: from localhost ([127.0.0.1] helo=dante.org.uk) by theta.dante.org.uk with esmtp (Exim 3.12 #4) id 13To7A-0000Hr-00; Tue, 29 Aug 2000 17:19:56 +0100 Message-ID: <39ABE2AC.CD4C68CF@dante.org.uk> Date: Tue, 29 Aug 2000 17:19:56 +0100 From: Konstantin Chuguev Organization: Delivery of Advanced Networking Service to Europe Ltd. X-Mailer: Mozilla 4.75 [en] (X11; U; SunOS 5.6 sun4u) X-Accept-Language: en, ru MIME-Version: 1.0 To: Alexey Zelkin Cc: "Andrey A. Chernov" , i18n@FreeBSD.ORG, current@FreeBSD.ORG Subject: Re: Request for review: locale aliases support for libc References: <20000829140102.A29555@ark.cris.net> <20000829151857.A90464@nagual.pp.ru> <20000829152733.A90577@nagual.pp.ru> <20000829172651.A80899@ark.cris.net> <20000829190047.A91611@nagual.pp.ru> <20000829182449.A142@ark.cris.net> <39ABD828.3E56A782@dante.org.uk> <20000829190008.A5824@ark.cris.net> Content-Type: text/plain; charset=koi8-r Content-Transfer-Encoding: 7bit Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Alexey Zelkin wrote: > > > > You need to check LC_* existence corresponding to setlocale() request > > > > made. > > > > > > What to check if LC_ALL request is given ? > > > LC_ALL overrides all other LC_* variables. If it is set, there is no need to > > check anything else. > > > Then you should check all other LC_*, and then LANG. > > As I understand you're answering in concept, but we are talking about > exact case right now (see may patches attached to previous letter) > > I am trying to realize "is requested locale physicaly present on this system" > or it's just an alias. Currently I am just testing presence of > /usr/share/locale/$requested_locale/LC_CTYPE and make decision depends > on stat(2) return value. > Perhaps you should check presence of any of the following files in a locale directory: LC_COLLATE, LC_CTYPE, LC_MESSAGES, LC_MONETARY, LC_TIME, and proceed if any of them has been found... -- * * Konstantin Chuguev - Application Engineer * * Francis House, 112 Hills Road * Cambridge CB2 1PQ, United Kingdom D A N T E WWW: http://www.dante.net To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message