From owner-freebsd-stable@FreeBSD.ORG Sat Jan 22 16:41:34 2005 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A784316A4CE for ; Sat, 22 Jan 2005 16:41:34 +0000 (GMT) Received: from smtp01.syd.iprimus.net.au (smtp01.syd.iprimus.net.au [210.50.30.196]) by mx1.FreeBSD.org (Postfix) with ESMTP id 661B043D1D for ; Sat, 22 Jan 2005 16:41:34 +0000 (GMT) (envelope-from tim@robbins.dropbear.id.au) Received: from robbins.dropbear.id.au (210.50.36.56) by smtp01.syd.iprimus.net.au (7.0.036) id 41A76DD90186949B; Sun, 23 Jan 2005 03:41:28 +1100 Received: by robbins.dropbear.id.au (Postfix, from userid 1000) id 3103A433F; Sun, 23 Jan 2005 03:41:42 +1100 (EST) Date: Sun, 23 Jan 2005 03:41:42 +1100 From: Tim Robbins To: Bj?rn K?nig Message-ID: <20050122164142.GA79245@cat.robbins.dropbear.id.au> References: <41F276CD.8020907@cs.tu-berlin.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <41F276CD.8020907@cs.tu-berlin.de> User-Agent: Mutt/1.4.1i cc: freebsd-stable@freebsd.org Subject: Re: correct value for LANG variable X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Jan 2005 16:41:34 -0000 On Sat, Jan 22, 2005 at 04:52:45PM +0100, Bj?rn K?nig wrote: > I am a bit confused. Neither de_DE.ISO-8859-1 nor > de_DE.ISO8859-1 work properly in all cases. > > > setenv LANG de_DE.ISO8859-1 > > echo abcdef uvwxyz | tr '[a-z]' '[A-Z]' > ABCDEF ?WXY?] For better or worse, this is not the correct way to perform case conversion in non-ASCII locales on FreeBSD 5 and later. See the COMPATIBILITY section of the tr(1) manpage for more information. > > > setenv LANG de_DE.ISO-8859-1 > > echo abcdef uvwxyz | tr '[a-z]' '[A-Z]' > ABCDEF UVWXYZ > > perl > perl: warning: Setting locale failed. > [lot of indignation about locale settings] FreeBSD uses the name de_DE.ISO8859-1 instead of de_DE.ISO-8859-1. Most base system utilities don't complain if LANG or the related LC_* variables are invalid. > > I am suspicious that de_DE.UTF-8 would work correct > with most software. Is it the only solution to don't > use localization currently at all or should it be my > ambition to fix this? What should be the correct > value? I would prefer the notation "ISO-8859-1", but > even the almighty perl does not. Setting LANG to de_DE.ISO8859-1 should work. The alternative is UTF-8, which is understood by most text-processing utilities in the base system (ls, wc, grep, sed, ...). However, at this stage neither sh nor vi work correctly with UTF-8, so you would need to replace these with (for example) bash and vim. Tim