[Buildd-tools-devel] unsetting locale

Michael Banck mbanck@debian.org
Thu, 28 Oct 2004 00:57:10 +0200


On Fri, Oct 08, 2004 at 09:44:32AM +0200, Francesco P. Lovergine wrote:
> On Thu, Oct 07, 2004 at 08:45:04PM +0200, Michael Banck wrote:
> > Hi,
> > 
> > one thing which has always bugged me is that sbuild apparently does not
> > reset the locale, and perl always barfs on this, cluttering up the
> > build-log:
> > 
> This should do the trick.
> 
> @@ -70,6 +72,8 @@
>  use FileHandle;
>  use Cwd;
>  
> +setlocale(LC_ALL,"POSIX");
> +

This does not seem to work as the executed programs don't inherit the
locale, AFAICT.

However, adding this instead of setlocale appears to work fine:

$ENV{'LC_ALL'} = "POSIX";


Michael