Re: Wrong character set in Cofiguration Tool

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: Wrong character set in Cofiguration Tool

Uwe Kindler-2
Hi Fabian,

I have no solution for this problem but I can confirm that it also
exists on Windows 7. The problem occures for warnings and errors. Here
is an example of console output with warnings:

cc1: warning: command line option ‘-Woverloaded-virtual’ is valid
for C++/ObjC++ but not for C [enabled by default]
cc1: warning: command line option ‘-fno-rtti’ is valid for
C++/ObjC++ but not for C [enabled by default]

> Hi
> The console output of the configuration tool prints out strange symbols.
> It looks like that there is a wrong character set used! Has anybody an
> idea how to fix that?
>
> I'm running the configuration tool on Windows XP with cygwin!
>
> Regards Fabian
>

--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

Reply | Threaded
Open this post in threaded view
|

Re: Wrong character set in Cofiguration Tool

Sergei Gavrikov-4
On Tue, 18 Jun 2013, Uwe Kindler wrote:

> Hi Fabian,
>
> I have no solution for this problem but I can confirm that it also
> exists on Windows 7. The problem occures for warnings and errors. Here
> is an example of console output with warnings:
>
> cc1: warning: command line option ‘-Woverloaded-virtual’ is valid for
> C++/ObjC++ but not for C [enabled by default]
> cc1: warning: command line option ‘-fno-rtti’ is valid for C++/ObjC++ but
> not for C [enabled by default]
>
> > Hi
> > The console output of the configuration tool prints out strange symbols.
> > It looks like that there is a wrong character set used! Has anybody an
> > idea how to fix that?
> >
> > I'm running the configuration tool on Windows XP with cygwin!
> >
> > Regards Fabian
 
Hi

That is just the quotes in UTF-8. Two examples below are true for Linux
and I hope this true for Cygwin environment too.

For LANG=en_US.utf8 and if terminal supports UNICODE you have to see

  % echo 'main(){return 0;}'>a.c
  % cc -Wall a.c
  a.c:1: warning: return type defaults to ‘int’

For standard "C" locale and for *any* terminal we see only ASCII (no
potential mess)

  % LC_ALL=C cc -Wall a.c
  a.c:1: warning: return type defaults to 'int'

If you set LANG variable properly and your terminal supports Unicode
then you have to see normal quotes, otherwise you will see some garbage
in output. So, try either to fix LANG variable or just use standard "C"
locale: append a line 'export LC_ALL=C' in your ~/.bashrc and re-login.

I do not sure about UTF-8 in Cygwin environment, but I hope LC_ALL=C
has to help.

Sergei

> --
> Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
> and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
>

--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
Reply | Threaded
Open this post in threaded view
|

Re: Wrong character set in Cofiguration Tool

Buehler, Fabian
Hi,
Sergei you're right that's the problem and also the solution! For me it worked to set an environment variable called "LC_ALL" and set the value to "C"! I did that in windows but I think the result using the cygwin bash is the same!


Regards Fabian



-----Original Message-----
From: Sergei Gavrikov [mailto:[hidden email]]
Sent: Wednesday, June 19, 2013 12:13 AM
To: Uwe Kindler
Cc: [hidden email]; Buehler, Fabian
Subject: Re: [ECOS] Re: Wrong character set in Cofiguration Tool

On Tue, 18 Jun 2013, Uwe Kindler wrote:

> Hi Fabian,
>
> I have no solution for this problem but I can confirm that it also
> exists on Windows 7. The problem occures for warnings and errors. Here
> is an example of console output with warnings:
>
> cc1: warning: command line option ‘-Woverloaded-virtual’ is valid
> for
> C++/ObjC++ but not for C [enabled by default]
> cc1: warning: command line option ‘-fno-rtti’ is valid for
> C++/ObjC++ but not for C [enabled by default]
>
> > Hi
> > The console output of the configuration tool prints out strange symbols.
> > It looks like that there is a wrong character set used! Has anybody
> > an idea how to fix that?
> >
> > I'm running the configuration tool on Windows XP with cygwin!
> >
> > Regards Fabian

Hi

That is just the quotes in UTF-8. Two examples below are true for Linux and I hope this true for Cygwin environment too.

For LANG=en_US.utf8 and if terminal supports UNICODE you have to see

  % echo 'main(){return 0;}'>a.c
  % cc -Wall a.c
  a.c:1: warning: return type defaults to ‘int’

For standard "C" locale and for *any* terminal we see only ASCII (no potential mess)

  % LC_ALL=C cc -Wall a.c
  a.c:1: warning: return type defaults to 'int'

If you set LANG variable properly and your terminal supports Unicode then you have to see normal quotes, otherwise you will see some garbage in output. So, try either to fix LANG variable or just use standard "C"
locale: append a line 'export LC_ALL=C' in your ~/.bashrc and re-login.

I do not sure about UTF-8 in Cygwin environment, but I hope LC_ALL=C has to help.

Sergei

> --
> Before posting, please read the FAQ:
> http://ecos.sourceware.org/fom/ecos
> and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
>