LC_MESSAGES on darwin

Tom Tromey
Thu Jan 10 10:44:00 GMT 2002

>>>>> "Andreas" == Andreas Tobler <> writes:

Andreas> your latest patch breaks the darwin build since LC_MESSAGES
Andreas> is not defined on darwin.

Sorry about that.

Andreas> In autoconf/header/aclocal there is a macro AM_LC_MESSAGES (seen in
Andreas> gcc/gcc) where do I place what? 

I wrote a patch.  Since it is a link test it has to go in the
native-only section of  We can't run link tests for
cross builds.

Andreas> As a result I expect something in auto-host.h. But where do I put
Andreas> AM_LC_MESSAGES if I have to? Do I have to put the block from
Andreas> gcc/gcc/aclocal.m4 (see below) in the one from java? 

You would copy the definition of AM_LC_MESSAGES into
libjava/acinclude.m4, add the invocation to the right part of, and then re-run aclocal, autoheader, and autoconf (and,
technically, automake, though in this case it doesn't matter).

Andreas> #if !defined LC_MESSAGES && !defined __LOCALE_H
Andreas> # define LC_MESSAGES 1729
Andreas> #endif 
Andreas> What do you think?

We can't do this since (I think) it isn't guaranteed that LC_MESSAGES
is a define.  Also where does 1729 come from?

Maybe instead of using setlocale we should just parse LANG ourselves.
I'm reluctant to do that though.  My patch makes it so that if
LC_MESSAGES isn't defined, then the `en_US' locale is assumed.  This
isn't that good of a solution, but I don't know what else to do.


More information about the Java mailing list