lkml.org 
[lkml]   [1998]   [Mar]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: New Feature Idea: Configurable text(msgs)
On Tue, Mar 17, 1998 at 08:21:42PM +0100, ketil@ii.uib.no wrote:
> a) Do a search on Altavista for the message, and come up with people
> who've had the same problem, and hopefully a solution as well. Even if
> they're posting the rest of the post in German (babelfish, here I come!)
> b) Mail the error message to developers, without having them twisting
> their brain trying to work out the correct back-translation from
> Norwegian to English (or whatever their working language is)
> c) Rely on a complete set of sensible and consistent error messages
> (i.e. what happens if somebody translates a kernel, and I apply patches
> to it in a different language? )

What about the OS/2 system (which I'm sure has been used elsewhere).

We assign every error message a number. The kernel puts that error number
in the printk. A kernel error daemon, or indeed klogd, uses a message file
to translate the message into the language of choice. The printk can still
include a message which would be used instead of, or in addition to, the
message file.

eg:
printk("Oh my God! You killed Kenny!");
becomes:
printk("@0056@Oh my God! You killed Kenny!");

The klogd sees that and if it has no alternate message file just prints the
message or otherwise looks up the message file and prints:
kernel: 0056: Mein Got! Kenny ist kaput!");
Command line options can tell it to include the original message as well.

The problem is when there are arguments to the message in which case you'd
either need to expand printk to re-encode the arguments so klogd could
insert them into the new message, or rely on printing both messages and the
info ino the first one can be gleaned once you have the translation.

You can cut down on bloat by not preloading the message file and having a
db index of the file to speed up access.

--
[======================================================================]
[ Kevin Lentin Email: K.Lentin@cs.monash.edu.au ]
[ finger kevinl@fangorn.cs.monash.edu.au for PGP public key block. ]
[ KeyId: 06808EED FingerPrint: 6024308DE1F84314 811B511DBA6FD596 ]
[======================================================================]

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu

\
 
 \ /
  Last update: 2005-03-22 13:41    [W:0.063 / U:0.544 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site