Date: Thu, 30 Oct 2003 09:19:34 +0100 From: DM <isaac@belial.pl.eu.org> To: freebsd-questions@freebsd.org Subject: g++ && imbue locale Message-ID: <20031030091934.A4266@waagh.ustronet>
next in thread | raw e-mail | index | archive | help
Hello.
I'm having problem with locale in g++ on freebsd (5.1-RELEASE-p2).
Following program should print 1,6 whereas it prints 1.6
#include <iostream>
using namespace std;
int main()
{
cout.imbue( locale("pl_PL.ISO_8859-2") );
cout << 1.6 << endl ;
return 0;
}
It refers to g++ 3.2.2 located in basesystem and port g++ 3.2.3
(maybe to others too).
After comparing configure args in gcc 3.2.3 port and in linux debian, where
it works, I added --enable-clocale=generic.
So now I have:
g++32 -v
Reading specs from /usr/local/lib/gcc-lib/i386-portbld-freebsd5.1/3.2.3/specs
Configured with: ./..//gcc-3.2.3/configure --disable-nls --enable-clocale=generic --with-gxx-include-dir=/usr/local/lib/gcc-lib/i386-portbld-freebsd5.1/3.2.3/include/g++-v3 --with-system-zlib --includedir=/usr/local/lib/gcc-lib/i386-portbld-freebsd5.1/3.2.3/include/Java --disable-shared --prefix=/usr/local i386-portbld-freebsd5.1
Thread model: posix
gcc version 3.2.3
but it still does not work.
Does any one know how to "turn on" proper locale behaviour?
Thanks in advance.
--
DM
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20031030091934.A4266>
