bugGNU gettext - Bugs: bug #32004, setlocale does not work on Mac OS...

 
 

You are not allowed to post comments on this tracker with your current authentification level.

bug #32004: setlocale does not work on Mac OS X with custom currency set

Submitted by:  Boris Dušek <dusek>
Submitted on:  Wed Dec 29 13:56:38 2010  
 
Category: End-user / runtimeSeverity: 3 - Normal
Item Group: NoneStatus: Not a Bug
Privacy: PublicAssigned to: Daiki Ueno <ueno>
Open/Closed: Closed

Sat Mar 9 00:26:48 2013, comment #1:

Does MacPorts replaces system's gettext? If not, it seems a problem of system's setlocale, not gettext.

Daiki Ueno <ueno>
Project AdministratorIn charge of this item.
Wed Dec 29 13:56:38 2010, original submission:

Hello,

I am using Mac OS X 10.6.5 and I have "English" set as my language in System Preferences > Language & Text > Language, but "Czech Republic Koruna" as currency in System Preferences > Language & Text > Formats. A call to setlocale(LC_ALL, "") results in NULL return value. perror then prints in log:

Dec 29 14:07:35 Pioneer org.freebsoft.speech-dispatcher-session[289]: setlocale: No such file or directory

I traced the speech-dispatcher process with dtrace to see what files it opens, here is the result:

0 18561 open:entry taskgated /usr/local/bin/speech-dispatcher
0 18561 open:entry speech-dispatch /opt/local/lib/libgmodule-2.0.0.dylib
0 18561 open:entry speech-dispatch /opt/local/lib/libintl.8.dylib
0 18561 open:entry speech-dispatch /opt/local/lib/libiconv.2.dylib
0 18561 open:entry speech-dispatch /opt/local/lib/libltdl.7.dylib
0 18561 open:entry speech-dispatch /dev/dtracehelper
0 19347 open_nocancel:entry speech-dispatch /dev/urandom
0 19347 open_nocancel:entry speech-dispatch /dev/urandom
0 19347 open_nocancel:entry speech-dispatch /opt/local/lib/charset.alias
0 19347 open_nocancel:entry speech-dispatch /usr/share/locale/locale.alias
0 18561 open:entry speech-dispatch /Users/boris/Library/Preferences/ByHost/.GlobalPreferences.001b63a34ecf.plist
0 18561 open:entry speech-dispatch /Users/boris/Library/Preferences/.GlobalPreferences.plist
0 18561 open:entry speech-dispatch /Library/Preferences/.GlobalPreferences.plist
0 19347 open_nocancel:entry speech-dispatch /usr/share/locale/en_US@currency=CZK/LC_COLLATE

Based on the last line, it looks like setlocale fails because it does not find this directory (which really does not exist): /usr/share/locale/en_US@currency=CZK. The directory /usr/share/locale/en_US does exist.

The version of gettext I am using is 0.18.1.1 from MacPorts.

Boris Dušek <dusek>

 

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by haible (Updated the item)
  • -unavailable- added by ueno (Posted a comment)
  • -unavailable- added by dusek (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 4 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sun Nov 27 01:08:40 2016haibleCategoryNone=>End-user / runtime
      Assigned toNone=>ueno
    Sat Mar 9 00:26:48 2013uenoStatusNone=>Not a Bug
      Open/ClosedOpen=>Closed

    Back to the top


    Powered by Savane 3.1-cleanup